Automatic date update in version.in
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
a0de763e
TT
12018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2 Tom Tromey <tom@tromey.com>
3
4 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
5 test for it.
6 * configure: Rebuild.
7
3b20124b
TT
82018-07-22 Tom Tromey <tom@tromey.com>
9
10 * regformats/regdat.sh: Define xmltarget_${name} inside
11 #ifndef IN_PROCESS_AGENT.
12
8c8807f4
TT
132018-07-22 Tom Tromey <tom@tromey.com>
14
15 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
16
c486b610
TT
172018-07-22 Tom Tromey <tom@tromey.com>
18
19 * symfile.c (reread_symbols): Notify iter, not objfile.
20
494f80a9
TT
212018-07-22 Tom Tromey <tom@tromey.com>
22
23 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
24 Use arch_ops.
25 (ravenscar_thread_target::prepare_to_store): Likewise.
26
c51f6a54
TT
272018-07-22 Tom Tromey <tom@tromey.com>
28
29 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
30 unused variable. Call value_fetch_lazy when needed.
31 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
32 Remove unused variable. Call value_fetch_lazy when needed.
33
374fd1fd
TT
342018-07-22 Tom Tromey <tom@tromey.com>
35
36 * m32c-tdep.c (mark_dma): Return void.
37 (make_regs): Remove unused declarations.
38
d5e9a511
TT
392018-07-22 Tom Tromey <tom@tromey.com>
40
41 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
42 cmdscm_get_valid_command_smob_arg_unsafe for effect.
43 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
44 bkscm_get_valid_block_smob_arg_unsafe for effect.
45
996d693a
TT
462018-07-22 Tom Tromey <tom@tromey.com>
47
48 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
49 value_type.
50
15766370
TT
512018-07-22 Tom Tromey <tom@tromey.com>
52
53 * windows-nat.c (saved_context): Conditionally define.
54 * remote.c (remote_target::remote_btrace_maybe_reopen):
55 Conditionally declare "warned".
56 * inflow.c (sigquit_ours): Conditionally define.
57 (new_tty): Move "tty" declaration inside #if.
58 * guile/guile.c (guile_datadir): Conditionally define.
59 * charset.c (set_be_le_names): Move some declarations inside #if.
60 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
61 #if.
62 (parse_xml_btrace_conf): Likewise.
63
f4e80e13
TT
642018-07-22 Tom Tromey <tom@tromey.com>
65
66 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
67
8d49165d
TT
682018-07-22 Tom Tromey <tom@tromey.com>
69
70 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
71 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
72 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
73 * buildsym-legacy.c (get_macro_table): Remove unused variable.
74 * stack.c (frame_apply_level_command): Remove unused variable.
75 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
76 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
77 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
78 unused variable.
79 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
80 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
81 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
82 variable.
83 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
84 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
85 variable.
86 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
87 Remove unused variable.
88 * cli/cli-script.c (recurse_read_control_structure): Remove unused
89 variable.
90 * common/tdesc.c (print_xml_feature::visit): Remove unused
91 variable.
92 * compile/compile-object-load.c (store_regs): Remove unused
93 variables.
94 * complaints.c (clear_complaints): Remove unused variable.
95 * corelow.c (core_target_open): Remove unused variable.
96 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
97 variable.
98 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
99 variable.
100 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
101 variable.
102 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
103 variable.
104 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
105 variable.
106 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
107 variable.
108 * ia64-tdep.c (examine_prologue): Remove unused variable.
109 * infcall.c (run_inferior_call): Remove unused variable.
110 * inferior.c (exit_inferior): Remove unused variable.
111 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
112 * linespec.c (decode_line_2): Remove unused variable.
113 * linux-nat.c (super_close): Remove.
114 * linux-tdep.c (linux_info_proc): Remove unused variable.
115 * mi/mi-main.c (mi_execute_command): Remove unused variable.
116 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
117 Remove unused variable.
118 * parse.c (find_minsym_type_and_address): Remove unused variable.
119 * printcmd.c (info_symbol_command, printf_floating): Remove unused
120 variable.
121 * python/py-breakpoint.c (bppy_set_commands): Remove unused
122 variable.
123 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
124 variables.
125 * record-btrace.c (record_btrace_target::store_registers): Remove
126 unused variable.
127 (cmd_show_record_btrace_cpu): Remove unused variable.
128 * riscv-tdep.c (riscv_register_reggroup_p)
129 (riscv_push_dummy_call, riscv_return_value): Remove unused
130 variable.
131 * rust-exp.y (literal): Remove unused variable.
132 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
133 unused variable.
134 <STRUCTOP_ANONYMOUS>: Likewise.
135 * s390-linux-tdep.c (s390_linux_init_abi_31)
136 (s390_linux_init_abi_64): Remove unused variable.
137 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
138 (file_select_thread, net_windows_open, _initialize_ser_windows):
139 Remove unused variables.
140 * symtab.c (find_pc_sect_line): Remove unused variable.
141 * target-memory.c (compute_garbled_blocks): Remove unused
142 variable.
143 (target_write_memory_blocks): Remove unused variable.
144 * target.c (target_stack::unpush): Remove unused variables.
145 * tracepoint.c (start_tracing, all_tracepoint_actions)
146 (merge_uploaded_trace_state_variables)
147 (print_one_static_tracepoint_marker): Remove unused variable.
148 * unittests/basic_string_view/element_access/char/1.cc (test01):
149 Remove unused variable.
150 * windows-nat.c (windows_continue, windows_add_all_dlls)
151 (do_initial_windows_stuff, windows_nat_target::create_inferior):
152 Remove unused variables.
153
17cbafdb
SM
1542018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
155
156 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
157 attr_profile in HAVE_ELF.
158 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
159 HAVE_ELF.
160
0ee6c332
SM
1612018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
162
163 * frame.c (frame_register_unwind): Change parameter name.
164 (frame_unwind_register): Likewise.
165 (frame_unwind_register_value): Likewise.
166 (frame_unwind_register_signed): Likewise.
167 (frame_unwind_register_unsigned): Likewise.
168 * frame.h (frame_register_unwind): Likewise.
169 (frame_unwind_register): Likewise.
170 (frame_unwind_register_value): Likewise.
171 (frame_unwind_register_signed): Likewise.
172 (frame_unwind_register_unsigned): Likewise.
173 (frame_unwind_arch): Likewise.
174
e2e31f10
MR
1752018-07-20 Maciej W. Rozycki <macro@mips.com>
176
177 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
178 ISA maintenance.
179
2d389915
MR
1802018-07-20 Maciej W. Rozycki <macro@mips.com>
181
182 * mips-linux-nat.c (mips_linux_nat_target::read_description):
183 Call `get_ptrace_pid' rather than extracting the ptrace PID by
184 hand.
185
cbb09508
KS
1862018-07-20 Keith Seitz <keiths@redhat.com>
187
188 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
189 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
190 m_compunit_symtab, m_language>: Add "m_" prefix.
191 Update all uses.
192 * buildsym.c: Update all uses.
193
bfe2e011
TT
1942018-07-20 Tom Tromey <tom@tromey.com>
195
196 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
197 * buildsym.h (record_line_ftype): Remove typedef.
198
0e6f3061
TT
1992018-07-20 Tom Tromey <tom@tromey.com>
200
201 * buildsym-legacy.h (augment_type_symtab): Don't declare.
202 (end_expandable_symtab): Likewise.
203 (end_symtab_get_static_block): Likewise.
204 (end_symtab_from_static_block): Likewise.
205 * buildsym-legacy.c (augment_type_symtab): Remove.
206 (end_expandable_symtab): Remove.
207 (end_symtab_get_static_block): Remove.
208 (end_symtab_from_static_block): Remove.
209
804d2729
TT
2102018-07-20 Tom Tromey <tom@tromey.com>
211
212 * dwarf2read.c: Include buildsym.h.
213 (struct dwarf2_cu) <builder>: New method.
214 (fixup_go_packaging): Update.
215 (process_full_comp_unit, process_full_type_unit): Update. Don't
216 use scoped_free_pendings.
217 (using_directives): Add "cu" parameter, remove "language".
218 (read_import_statement, setup_type_unit_groups, )
219 (read_func_scope, read_lexical_block_scope)
220 (dwarf2_record_block_ranges, read_namespace): Update.
221 (lnp_state_machine::lnp_state_machine): Add cu parameter.
222 (lnp_state_machine::handle_end_sequence): Update.
223 (class lnp_state_machine) <m_cu>: New member.
224 <m_record_line_callback>: Remove.
225 <m_currently_recording_lines>: New member.
226 (lnp_state_machine::handle_set_file): Update.
227 (noop_record_line): Remove.
228 (dwarf_record_line_p): Add cu parameter.
229 (dwarf_record_line_1, dwarf_finish_line): Likewise.
230 (lnp_state_machine::record_line)
231 (lnp_state_machine::lnp_state_machine)
232 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
233 (dwarf_decode_lines): Update.
234 (dwarf2_start_subfile): Add cu parameter.
235 (dwarf2_start_symtab, new_symbol): Update.
236 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
237 Remove dwarf2_per_objfile parameter.
238 (dwarf_decode_macros): Update.
239
80e649fc
TT
2402018-07-20 Tom Tromey <tom@tromey.com>
241
242 * stabsread.c (define_symbol): Update.
243 * buildsym-legacy.h (get_buildsym_compunit): Declare.
244 * dwarf2read.c (new_symbol): Update.
245 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
246 * cp-namespace.c: Include buildsym.h.
247 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
248 * buildsym-legacy.c (get_buildsym_compunit): New function.
249
0baae8db
TT
2502018-07-20 Tom Tromey <tom@tromey.com>
251
252 * xcoffread.c: Include buildsym-legacy.h.
253 * windows-nat.c: Include buildsym-legacy.h.
254 * stabsread.c: Include buildsym-legacy.h.
255 * mdebugread.c: Include buildsym-legacy.h.
256 * buildsym-legacy.h: New file.
257 * buildsym-legacy.c: New file, from buildsym.c.
258 * go32-nat.c: Include buildsym-legacy.h.
259 * dwarf2read.c: Include buildsym-legacy.h.
260 * dbxread.c: Include buildsym-legacy.h.
261 * cp-namespace.c: Include buildsym-legacy.h.
262 * coffread.c: Include buildsym-legacy.h.
263 * buildsym.h: Move some contents to buildsym-legacy.h.
264 * buildsym.c: Include buildsym-legacy.h. Move many functions to
265 buildsym-legacy.c.
266 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
267
ab209f6f
TT
2682018-07-20 Tom Tromey <tom@tromey.com>
269
270 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
271 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
272 (buildsym_compunit::buildsym_compunit)
273 (buildsym_compunit::~buildsym_compunit)
274 (buildsym_compunit::get_macro_table): Define.
275
74c72eac
TT
2762018-07-20 Tom Tromey <tom@tromey.com>
277
278 * buildsym.c (reset_symtab_globals): Remove.
279 (buildsym_compunit::end_symtab_from_static_block): Update.
280 (buildsym_compunit::augment_type_symtab): Update.
281 (end_symtab_from_static_block): Call free_buildsym_compunit.
282 (augment_type_symtab, end_symtab, end_expandable_symtab):
283 Likewise.
284
da6580e5
TT
2852018-07-20 Tom Tromey <tom@tromey.com>
286
287 * arch-utils.c: Do not include buildsym.h.
288 * mipsread.c: Do not include buildsym.h.
289 * machoread.c: Do not include buildsym.h.
290 * elfread.c: Do not include buildsym.h.
291
4a2125f5
TT
2922018-07-20 Tom Tromey <tom@tromey.com>
293
294 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
295 initialization.
296 (buildsym_compunit): Add new constructor.
297 (struct buildsym_compunit) <get_last_source_file, finish_block,
298 record_block_range, start_subfile, patch_subfile_names,
299 push_subfile, pop_subfile, record_line, get_compunit_symtab,
300 set_last_source_start_addr, get_last_source_start_addr,
301 get_local_using_directives, set_local_using_directives,
302 get_global_using_directives, outermost_context_p,
303 get_current_context_stack, get_context_stack_depth,
304 get_current_subfile, get_local_symbols, get_file_symbols,
305 get_global_symbols, record_debugformat, record_producer,
306 push_context, pop_context, end_symtab_get_static_block,
307 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
308 New public methods.
309 <record_pending_block, finish_block_internal, make_blockvector,
310 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
311 private methods.
312 Update all users.
313
3142018-05-22 Tom Tromey <tom@tromey.com>
315
316 * buildsym.c (record_pending_block): Move earlier. Remove objfile
317 parameter.
318 (finish_block_internal): Update.
319
6b213a47
TT
3202018-07-20 Tom Tromey <tom@tromey.com>
321
322 * buildsym.c (record_pending_block): Move earlier. Remove objfile
323 parameter.
324 (finish_block_internal): Update.
325
b80a981d
TT
3262018-07-20 Tom Tromey <tom@tromey.com>
327
328 * buildsym.h (EXTERN): Don't define or undef.
329 * buildsym.c (EXTERN): Don't define.
330
ddb70602
TT
3312018-07-20 Tom Tromey <tom@tromey.com>
332
333 * buildsym.c: Remove TODO comment.
334
b37dd3bc
TT
3352018-07-20 Tom Tromey <tom@tromey.com>
336
337 * coffread.c (coff_symtab_read): Update.
338 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
339 (xcoff_new_init): Update.
340 * mipsread.c (mipscoff_new_init): Update.
341 * mdebugread.c (mdebug_build_psymtabs): Update.
342 * elfread.c (elf_new_init): Update.
343 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
344 Update.
345 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
346 (coffstab_build_psymtabs, elfstab_build_psymtabs)
347 (stabsect_build_psymtabs): Update.
348 * buildsym.h (buildsym_init): Don't declare.
349 * buildsym.c: Update comment.
350 (prepare_for_building): Remove.
351 (start_symtab, restart_symtab): Update.
352 (reset_symtab_globals): Update comment.
353 (buildsym_init): Remove.
354
e148f09d
TT
3552018-07-20 Tom Tromey <tom@tromey.com>
356
357 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
358 * stabsread.c (patch_block_stabs, define_symbol, read_type)
359 (read_enum_type, common_block_start, common_block_end)
360 (cleanup_undefined_types_1, finish_global_stabs): Update.
361 * mdebugread.c (psymtab_to_symtab_1): Update.
362 * dwarf2read.c (fixup_go_packaging, read_func_scope)
363 (read_lexical_block_scope, new_symbol): Update.
364 * dbxread.c (process_one_symbol): Update.
365 * coffread.c (coff_symtab_read, process_coff_symbol)
366 (coff_read_enum_type): Update.
367 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
368 declare.
369 (get_local_symbols, get_file_symbols, get_global_symbols): New
370 functions.
371 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
372 m_global_symbols.
373 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
374 (~scoped_free_pendings): Update.
375 (finish_block, prepare_for_building, reset_symtab_globals)
376 (end_symtab_get_static_block, end_symtab_with_blockvector)
377 (augment_type_symtab, push_context): Update.
378 (get_local_symbols, get_file_symbols, get_global_symbols): New
379 functions.
380 (buildsym_init): Update.
381
93b8bea4
TT
3822018-07-20 Tom Tromey <tom@tromey.com>
383
384 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
385 (process_full_type_unit): Likewise.
386 (dwarf2_start_symtab): Set list_in_scope.
387
f62f6af5
TT
3882018-07-20 Tom Tromey <tom@tromey.com>
389
390 * dwarf2read.c (process_psymtab_comp_unit_reader)
391 (build_type_psymtabs_reader): Do not set list_in_scope.
392
1d376700
TT
3932018-07-20 Tom Tromey <tom@tromey.com>
394
395 * buildsym.c (free_pendings): Remove.
396 (add_symbol_to_list, scoped_free_pendings)
397 (finish_block_internal, buildsym_init): Update.
398
c233e9c6
TT
3992018-07-20 Tom Tromey <tom@tromey.com>
400
401 * xcoffread.c (read_xcoff_symtab): Update.
402 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
403 Update.
404 * dbxread.c (process_one_symbol): Update.
405 * coffread.c (coff_symtab_read): Update.
406 * buildsym.h (finish_block): Update.
407 * buildsym.c (finish_block): Remove "listhead" argument.
408 (end_symtab_get_static_block): Update.
409
5ac04550
TT
4102018-07-20 Tom Tromey <tom@tromey.com>
411
412 * buildsym.h (class scoped_free_pendings): Remove constructor.
413 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
414 method.
415 <m_pending_block_obstack, m_pending_blocks>: New members.
416 (pending_block_obstack, pending_blocks): Remove.
417 (scoped_free_pendings::scoped_free_pendings): Default.
418 (~scoped_free_pendings): Update.
419 (free_pending_blocks): Remove.
420 (finish_block_internal, record_pending_block, make_blockvector)
421 (end_symtab_get_static_block, augment_type_symtab, push_context)
422 (buildsym_init): Update.
423
7ea05a7b
TT
4242018-07-20 Tom Tromey <tom@tromey.com>
425
426 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
427 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
428 members.
429 (pending_addrmap, pending_addrmap_obstack)
430 (pending_addrmap_interesting): Remove.
431 (scoped_free_pendings, record_block_range, make_blockvector)
432 (prepare_for_building, reset_symtab_globals, buildsym_init):
433 Update.
434
3c65e5b3
TT
4352018-07-20 Tom Tromey <tom@tromey.com>
436
437 * xcoffread.c (process_linenos): Update.
438 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
439 * mdebugread.c (psymtab_to_symtab_1): Update.
440 * dwarf2read.c (setup_type_unit_groups)
441 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
442 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
443 * dbxread.c (process_one_symbol): Update.
444 * coffread.c (coff_symtab_read, enter_linenos)
445 (process_coff_symbol): Update.
446 * buildsym.h (current_subfile): Don't declare.
447 (get_current_subfile): Declare.
448 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
449 member.
450 (start_subfile, free_buildsym_compunit, push_subfile)
451 (prepare_for_building, start_symtab): Update.
452 (get_current_subfile): New function.
453
a60f3166
TT
4542018-07-20 Tom Tromey <tom@tromey.com>
455
456 * coffread.c (coff_symtab_read): Update.
457 * xcoffread.c (read_xcoff_symtab): Update.
458 * dwarf2read.c (new_symbol): Update.
459 (read_func_scope, read_lexical_block_scope): Update.
460 * dbxread.c (process_one_symbol): Update.
461 * buildsym.h (context_stack, context_stack_depth): Don't declare.
462 (outermost_context_p): Remove macro.
463 (outermost_context_p, get_current_context_stack)
464 (get_context_stack_depth): Declare.
465 (pop_context): Return struct context_stack.
466 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
467 member.
468 (context_stack_size): Remove.
469 (INITIAL_CONTEXT_STACK_SIZE): Remove.
470 (prepare_for_building, end_symtab_get_static_block)
471 (augment_type_symtab, push_context): Update.
472 (pop_context): Return struct context_stack.
473 (outermost_context_p, get_current_context_stack)
474 (get_context_stack_depth): New functions.
475 (buildsym_init): Update.
476
56ba65a0
TT
4772018-07-20 Tom Tromey <tom@tromey.com>
478
479 * rust-exp.y: Now a pure parser. Update all rules.
480 (%union): Move earlier.
481 (current_parser, work_obstack): Remove globals.
482 (rust_parser, ~rust_parser): Update.
483 (class rust_parser) <copy_name, concat3, crate_name, super_name,
484 lex_character, lex_number, lex_string, lex_identifier,
485 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
486 convert_name, convert_params_to_expression,
487 convert_ast_to_expression, ast_basic_type, ast_operation,
488 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
489 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
490 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
491 ast_array_type, ast_slice_type, ast_reference_type,
492 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
493 (rust_parse): Update.
494 (rustyyerror, rustyylex): Add parser parameter.
495 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
496 (rust_lex_stringish_test, rust_lex_test_sequence)
497 (rust_lex_test_trailing_dot, rust_lex_test_completion)
498 (rust_lex_test_push_back, rust_lex_tests): Update.
499
4c693332
PA
5002018-07-19 Pedro Alves <palves@redhat.com>
501
502 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
503 gdb::unique_xmalloc_ptr.
504 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
505 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
506 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
507 copy-initialization.
508 * guile/scm-pretty-print.c (ppscm_print_children): Use
509 gdb::unique_xmalloc_ptr instead of cleanups.
510 (gdbscm_apply_val_pretty_printer): Remove cleanups.
511 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
512 gdb::unique_xmalloc_ptr.
513 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
514 Adjust to use gdb::unique_xmalloc_ptr.
515 * guile/scm-utils.c (extract_arg): Adjust.
516 * guile/scm-value.c (gdbscm_value_field): Adjust to use
517 gdb::unique_xmalloc_ptr instead of a cleanup.
518
4581dc82
TT
5192018-07-19 Tom Tromey <tom@tromey.com>
520
521 * utils.c (do_value_free_to_mark)
522 (make_cleanup_value_free_to_mark): Remove.
523 * utils.h (make_cleanup_value_free_to_mark): Remove.
524
43cc6c3a
PA
5252018-07-19 Pedro Alves <palves@redhat.com>
526
527 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
528 forwarding reference.
529
3a5f2a48
PA
5302018-07-18 Pedro Alves <palves@redhat.com>
531
532 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
533 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
534 cleanup.
535
557e56be
PA
5362018-07-18 Pedro Alves <palves@redhat.com>
537
538 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
539 exceptions.
540 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
541 (gdbscm_wrap): New.
542 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
543 directly instead of a cleanup.
544 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
545 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
546 (vlscm_binop_gdbthrow): New, factored out from ...
547 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
548 (vlscm_rich_compare): Use gdbscm_wrap.
549 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
550 instead of a cleanup.
551 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
552 cleanup.
553 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
554 Use xfree directly instead of a cleanup.
555 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
556 Adjust to use gdbscm_wrap and scoped_value_mark.
557 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
558 (gdbscm_value_address, gdbscm_value_dereference)
559 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
560 scoped_value_mark.
561 (gdbscm_value_dynamic_type): Use scoped_value_mark.
562 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
563 scoped_value_mark.
564 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
565 gdbscm_wrap and scoped_value_mark.
566 (gdbscm_value_to_string): Use xfree directly instead of a
567 cleanup. Move 'buffer' unique_ptr to TRY scope.
568 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
569 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
570 scoped_value_mark.
571 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
572 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
573 scoped_value_mark.
574 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
575 gdbscm_wrap.
576
42dc7699
TV
5772018-07-18 Tom de Vries <tdevries@suse.de>
578
579 * findvar.c (default_read_var_value): Also resolve dynamic type for
580 LOC_OPTIMIZED_OUT vars.
581
6592ceed
MR
5822018-07-18 Maciej W. Rozycki <macro@mips.com>
583
584 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
585 decoding.
586
c6c6149a
TT
5872018-07-17 Tom Tromey <tom@tromey.com>
588
589 * guile/scm-param.c (pascm_set_func, pascm_show_func)
590 (compute_enum_list, pascm_set_param_value_x)
591 (gdbscm_parameter_value): Update.
592 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
593 (gdbscm_scm_to_host_string): Update.
594 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
595 Update.
596 * guile/scm-cmd.c (cmdscm_add_completion): Update.
597 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
598 * guile/scm-string.c (gdbscm_scm_to_string): Return
599 unique_xmalloc_ptr.
600 (gdbscm_scm_to_host_string): Likewise.
601
a1a31cb8
TT
6022018-07-17 Tom Tromey <tom@tromey.com>
603
604 * guile/guile.c (gdbscm_eval_from_control_command): Update.
605 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
606 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
607 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
608 unique_xmalloc_ptr.
609
15bf3002
TT
6102018-07-17 Tom Tromey <tom@tromey.com>
611
612 * guile/scm-param.c (pascm_signal_setshow_error): Update.
613 * guile/guile-internal.h (gdbscm_exception_message_to_string):
614 Update.
615 * guile/scm-cmd.c (cmdscm_function): Update.
616 * guile/scm-pretty-print.c
617 (ppscm_print_exception_unless_memory_error): Update.
618 * guile/scm-exception.c (gdbscm_exception_message_to_string):
619 Return unique_xmalloc_ptr.
620
7eb1a66c
TT
6212018-07-17 Tom Tromey <tom@tromey.com>
622
623 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
624 Use string_printf.
625
ce73f310
JW
6262018-07-17 Jim Wilson <jimw@sifive.com>
627
27724bad
JW
628 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
629 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
630 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
631 unecessary braces after EF_RISCV_RVC test. Delete call to
632 set_gdbarch_decr_pc_after_break.
633
ce73f310
JW
634 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
635 RISCV_LAST_FP_REGNUM + 1.
636 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
637
056dec39
TT
6382018-07-17 Tom Tromey <tom@tromey.com>
639
640 * configure.ac: Remove --disable-gdbcli.
641 * configure: Rebuild.
642 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
643 (SUBDIR_CLI_CFLAGS): Remove.
644 (SFILES): Use SUBDIR_CLI_SRCS.
645 (COMMON_OBS): Use SUBDIR_CLI_OBS.
646
4735f0ed
TT
6472018-07-17 Tom Tromey <tom@tromey.com>
648
649 PR gdb/18624:
650 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
651
117a0e99
JW
6522018-07-16 Jim Wilson <jimw@sifive.com>
653
654 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
655
8a67aaa8
SM
6562018-07-16 Simon Marchi <simon.marchi@ericsson.com>
657
658 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
659 variable.
660 (libunwind_frame_sniffer): Likewise.
661 (libunwind_frame_prev_register): Likewise.
662 (libunwind_sigtramp_frame_sniffer): Likewise.
663 * ia64-tdep.c (ia64_access_reg): Likewise.
664 (ia64_access_rse_reg): Likewise.
665 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
666 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
667
ec74dcd8
SM
6682018-07-16 Simon Marchi <simon.marchi@ericsson.com>
669
670 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
671
a700e753
SM
6722018-07-16 Simon Marchi <simon.marchi@ericsson.com>
673
674 * remote-sim.c (gdbsim_target::close,
675 gdbsim_target::mourn_inferior): Remove unused variables.
676
8b411ff8
SM
6772018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
678
679 * ia64-tdep.c (ktab_buf): New global.
680 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
681 (get_kernel_table): Adjust.
682
edb0470b
TT
6832018-07-16 Tom Tromey <tom@tromey.com>
684
685 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
686 * dwarf2read.c (using_directives, new_symbol): Use
687 outermost_context_p.
688 * dbxread.c (process_one_symbol): Use outermost_context_p.
689 * coffread.c (coff_symtab_read): Use outermost_context_p.
690
6cccc9a8
TT
6912018-07-16 Tom Tromey <tom@tromey.com>
692
693 * dwarf2read.c (using_directives, read_func_scope)
694 (read_lexical_block_scope): Update.
695 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
696 * buildsym.h (local_using_directives, global_using_directives):
697 Don't declare.
698 (get_local_using_directives, set_local_using_directives)
699 (get_global_using_directives): Declare.
700 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
701 m_global_using_directives>: New members.
702 (finish_block_internal, prepare_for_building)
703 (reset_symtab_globals, end_symtab_get_static_block)
704 (push_context): Update.
705 (get_local_using_directives, set_local_using_directives)
706 (get_global_using_directives): New functions.
707 (buildsym_init): Update.
708
652788a7
TT
7092018-07-16 Tom Tromey <tom@tromey.com>
710
711 * xcoffread.c (xcoff_initial_scan): Don't call
712 free_pending_blocks.
713 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
714 * buildsym.h (class scoped_free_pendings): Add constructor.
715 (free_pending_blocks): Don't declare.
716 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
717 (free_pending_blocks): Now static.
718
8419ee53
TT
7192018-07-16 Tom Tromey <tom@tromey.com>
720
721 * buildsym.h (push_subfile, pop_subfile): Update declarations.
722 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
723 member.
724 (struct subfile_stack): Remove.
725 (subfile_stack): Remove.
726 (push_subfile, pop_subfile, buildsym_init): Update.
727
ccdac490
TT
7282018-07-16 Tom Tromey <tom@tromey.com>
729
730 * buildsym.c (push_subfile): Use gdb_assert.
731 (pop_subfile): Use gdb_assert.
732
43130d6f
TT
7332018-07-16 Tom Tromey <tom@tromey.com>
734
735 * buildsym.h (merge_symbol_lists): Remove.
736 * buildsym.c (merge_symbol_lists): Remove.
737
77d6f1aa
TT
7382018-07-16 Tom Tromey <tom@tromey.com>
739
740 * stabsread.c (scan_file_globals): Update comment.
741 * stabsread.h (scan_file_globals): Move from buildsym.h.
742 * buildsym.h (scan_file_globals): Move to stabsread.h.
743
2c722d18
TT
7442018-07-16 Tom Tromey <tom@tromey.com>
745
746 * xcoffread.c (xcoff_new_init): Update.
747 * mipsread.c (mipscoff_new_init): Update.
748 * mdebugread.c (mdebug_build_psymtabs): Update.
749 * elfread.c (elf_new_init): Update.
750 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
751 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
752 * buildsym.h (buildsym_new_init): Don't declare.
753 * buildsym.c (buildsym_new_init): Remove.
754
5985ac61
TT
7552018-07-16 Tom Tromey <tom@tromey.com>
756
757 * stabsread.h (within_function): Move from buildsym.h.
758 * stabsread.c (start_stabs): Clear within_function.
759 * coffread.c (coff_start_symtab): Clear within_function.
760 * buildsym.h (within_function): Move to stabsread.h.
761 * buildsym.c (prepare_for_building): Update.
762
6b84eeb2
TT
7632018-07-16 Tom Tromey <tom@tromey.com>
764
765 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
766 * dwarf2read.c (dwarf2_start_symtab): Don't set
767 processing_gcc_compilation.
768 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
769
2150c3ef
TT
7702018-07-16 Tom Tromey <tom@tromey.com>
771
772 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
773 (next_symbol_text_func): Move from buildsym.h.
774 * stabsread.c (hashname): Move from buildsym.c.
775 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
776 (next_symbol_text_func, hashname): Move to stabsread.h.
777 * buildsym.c: Don't include bcache.h
778 (hashname): Move to stasbread.c.
779
0ec44fc0
TT
7802018-07-16 Tom Tromey <tom@tromey.com>
781
782 * buildsym.h (context_stack_size): Don't declare.
783 * buildsym.c (context_stack_size): New global.
784
81cc346d
TT
7852018-07-16 Tom Tromey <tom@tromey.com>
786
787 * dbxread.c (processing_acc_compilation): New global.
788 * buildsym.h (processing_acc_compilation): Don't declare.
789
2c99ee5c
TT
7902018-07-16 Tom Tromey <tom@tromey.com>
791
792 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
793 * dbxread.c (read_ofile_symtab): Update.
794 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
795 * buildsym.h (last_source_start_addr): Remove.
796 (set_last_source_start_addr, get_last_source_start_addr):
797 Declare.
798 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
799 parameter.
800 (struct buildsym_compunit) <m_last_source_start_addr>: New
801 member.
802 (prepare_for_building): Remove start_addr parameter.
803 (start_symtab, restart_symtab, end_symtab_get_static_block)
804 (end_symtab_with_blockvector): Update.
805 (set_last_source_start_addr, get_last_source_start_addr): New
806 functions.
807
530fedbc
TT
8082018-07-16 Tom Tromey <tom@tromey.com>
809
810 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
811 member.
812 (have_line_numbers): Remove.
813 (record_line, prepare_for_building, end_symtab_get_static_block)
814 (augment_type_symtab): Update.
815
6a976300
TT
8162018-07-16 Tom Tromey <tom@tromey.com>
817
818 * buildsym.c (~buildsym_compunit): Free the macro table.
819 (struct buildsym_compunit) <get_macro_table, release_macros>: New
820 methods.
821 <m_pending_macros>: New member.
822 (pending_macros): Remove.
823 (~scoped_free_pendings, get_macro_table, prepare_for_building)
824 (reset_symtab_globals, end_symtab_get_static_block)
825 (end_symtab_with_blockvector, augment_type_symtab)
826 (buildsym_init): Update.
827
c0015d44
TT
8282018-07-16 Tom Tromey <tom@tromey.com>
829
830 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
831 parameter.
832 (buildsym_compunit::set_last_source_file): New method.
833 <m_last_source_file>: New member.
834 (prepare_for_building): Remove "name" parameter.
835 (start_symtab, restart_symtab, reset_symtab_globals): Update.
836 (last_source_file): Remove.
837 (set_last_source_file, get_last_source_file): Update.
838
e62cca7c
TT
8392018-07-16 Tom Tromey <tom@tromey.com>
840
841 * buildsym.c (prepare_for_building): Add assert.
842
905eb0e2
TT
8432018-07-16 Tom Tromey <tom@tromey.com>
844
845 * buildsym.c (~buildsym_compunit): Update.
846 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
847 (start_subfile, patch_subfile_names)
848 (end_symtab_with_blockvector): Update.
849
b248663f
TT
8502018-07-16 Tom Tromey <tom@tromey.com>
851
852 * buildsym.c (struct buildsym_compunit): Add constructor,
853 destructor, initializers.
854 (start_buildsym_compunit): Remove.
855 (free_buildsym_compunit): Use "delete".
856 (start_symtab, restart_symtab): Use "new".
857
ff27d073
SM
8582018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
859
860 * symfile.c (set_objfile_default_section_offset): Remove struct
861 keyword.
862
6a15ecf5
SH
8632018-07-14 Stafford Horne <shorne@gmail.com>
864
865 * (Responsible Maintainers): Add myself as or1k maintainer.
866
027a4c30
TT
8672018-07-13 Tom Tromey <tom@tromey.com>
868
869 * symfile.c (set_objfile_default_section_offset): Use extra braces
870 around initializer.
871
5c1eda30
AA
8722018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
873
874 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
875 non-branching basr.
876
bc7b042b
PW
8772018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
878
879 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
880 unittests/cli-utils-selftests.c
881 * unittests/cli-utils-selftests.c: New file.
882
a14c4daa
PW
8832018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
884
885 * NEWS: Mention new commands. Mention change to 'thread apply'.
886
1fe75df7
PW
8872018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
888
889 * thread.c (thr_try_catch_cmd): New function.
890 (thread_apply_all_command): Handle qcs flags.
891 (thread_apply_command): Handle qcs flags.
892 (taas_command): New function.
893 (tfaas_command): New function.
894 (_initialize_thread): Update to setup the new commands 'taas
895 and 'tfaas'. Change doc string for 'thread apply'.
896
6a70eb7d
PW
8972018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
898
899 * stack.c: (trailing_outermost_frame): New function, mostly
900 extracted from backtrace_command_1.
901 (leading_innermost_frame): New function.
902 (backtrace_command_1): Update to call trailing_outermost_frame.
903 (frame_apply_command_count): New function.
904 (frame_apply_level_command): New function.
905 (frame_apply_all_command): New function.
906 (frame_apply_command): New function.
907 (faas_command): New function.
908 (frame_cmd_list): New variable.
909 (_initialize_stack): Update to setup the new commands 'frame apply'
910 and 'faas'.
911
529c08b2
PW
9122018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
913
914 * cli-utils.c (number_or_range_parser::get_number): Only handle
915 numbers or convenience var as numbers.
916 (parse_flags): New function.
917 (parse_flags_qcs): New function.
918 (number_or_range_parser::finished): Ensure parsing end is detected
919 before end of string.
920 * cli-utils.h (parse_flags): New function.
921 (parse_flags_qcs): New function.
922 (number_or_range_parser): Remove m_finished bool.
923 (number_or_range_parser::skip_range): Set m_in_range to false.
924
64b58472
SDJ
9252018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
926
927 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
928 on Windows.
929
c7ab0aef
SDJ
9302018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
931 Jan Kratochvil <jan.kratochvil@redhat.com>
932 Paul Fertser <fercerpav@gmail.com>
933 Tsutomu Seki <sekiriki@gmail.com>
934 Pedro Alves <palves@redhat.com>
935
936 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
937 'unittests/parse-connection-spec-selftests.c'.
938 (COMMON_SFILES): Add 'common/netstuff.c'.
939 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
940 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
941 * common/netstuff.c: New file.
942 * common/netstuff.h: New file.
943 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
944 (wait_for_connect): Update comment. New parameter
945 'gdb::optional<int> sock' instead of 'struct serial *scb'.
946 Use 'sock' directly instead of 'scb->fd'.
947 (try_connect): New function, with code from 'net_open'.
948 (net_open): Rewrite main loop to deal with multiple
949 sockets/addresses. Handle IPv6-style hostnames; implement
950 support for IPv6 connections.
951 * unittests/parse-connection-spec-selftests.c: New file.
952
4c7333b3
PA
9532018-07-11 Pedro Alves <palves@redhat.com>
954
955 PR gdb/23377
956 * remote.c (remote_target::remote_detach_pid): Call
957 set_current_process.
958
a6f88f6e
PA
9592018-07-11 Pedro Alves <palves@redhat.com>
960
961 * h8300-tdep.c (h8300_gdbarch_init): Remove
962 set_gdbarch_ecoff_reg_to_regnum calls.
963
16ff70dd
SDJ
9642018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
965
966 PR c++/23373
967 * c-typeprint.c (c_type_print_base_struct_union): Don't print
968 offsets/sizes for static members of a class/struct.
969
12863263
AH
9702018-07-11 Alan Hayward <alan.hayward@arm.com>
971
972 * target-descriptions.c (tdesc_register_bitsize): Rename.
973 * target-descriptions.h (tdesc_register_bitsize): Likewise.
974 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
975 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
976
1123588c
TT
9772018-07-10 Tom Tromey <tom@tromey.com>
978
979 * breakpoint.c (moribund_locations): Now static and a
980 std::vector.
981 (breakpoint_init_inferior, moribund_breakpoint_here_p)
982 (build_bpstat_chain, update_global_location_list)
983 (breakpoint_retire_moribund): Update.
984 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
985 VEC.
986
8c49aa89
AB
9872018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
988
989 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
990 (riscv_register_reggroup_p): Use new function, remove unneeded
991 parenthesis.
992 (riscv_push_dummy_call): Extend assert to compare against xlen or
993 flen based on register type.
994
42ecac17
AB
9952018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
996
997 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
998
055303e2
AB
9992018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
1000
1001 * remote.c (show_hardware_watchpoint_limit): New function.
1002 (show_hardware_watchpoint_length_limit): New function.
1003 (show_hardware_breakpoint_limit): New function.
1004 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
1005 where appropriate, update help text.
1006
8fd32c1c
TT
10072018-07-09 Tom Tromey <tom@tromey.com>
1008
1009 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
1010 (CLIBS): Don't mention NAT_CLIBS.
1011
31278b51
TT
10122018-07-09 Tom Tromey <tom@tromey.com>
1013
1014 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
1015 (LIBGDB_OBS, clean mostlyclean): Update.
1016 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
1017
e5fd1493
TT
10182018-07-09 Tom Tromey <tom@tromey.com>
1019
1020 * Makefile.in (%.c: %.y): Use ECHO_YACC.
1021 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
1022 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
1023
981e0c0c
TT
10242018-07-09 Tom Tromey <tom@tromey.com>
1025
1026 * Makefile.in (ALLDEPFILES): Remove exec.c.
1027 (COMMON_OBS): Remove exec.o.
1028 (COMMON_SFILES): Add exec.c.
1029
14ccceb2
TT
10302018-07-09 Tom Tromey <tom@tromey.com>
1031
1032 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
1033
5d3c3a68
TT
10342018-07-09 Tom Tromey <tom@tromey.com>
1035
1036 * Makefile.in (clean mostlyclean): Remove stamp-version.
1037 (version.c): Depend on stamp-version.
1038 (stamp-version): New rule, from version.c rule.
1039
1998086d
TT
10402018-07-09 Tom Tromey <tom@tromey.com>
1041
1042 * Makefile.in (init.c): Depend on stamp-init.
1043 (stamp-init): New rule, from init.c rule.
1044 (clean mostlyclean): Remove stamp-init.
1045
4c754949
TT
10462018-07-09 Tom Tromey <tom@tromey.com>
1047
1048 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
1049 SUBDIR_GCC_COMPILE_SRCS.
1050
6497f1dd
TT
10512018-07-09 Tom Tromey <tom@tromey.com>
1052
1053 * Makefile.in (init.c): Remove some unused sed rules.
1054
97a34db9
TT
10552018-07-09 Tom Tromey <tom@tromey.com>
1056
1057 * Makefile.in (TSOBS): Remove.
1058 (INIT_FILES): Update.
1059 (LIBGDB_OBS): Update.
1060 (COMMON_SFILES): Add inflow.c.
1061 (SFILES): Remove inflow.c.
1062
25289ac1
JK
10632018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
1064
1065 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
1066
e83f4d97
SM
10672018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
1068
4869c585
SM
1069 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
1070 get_saveloc_name, is_signal_frame_name, step_name,
1071 init_remote_name, create_addr_space_name,
1072 destroy_addr_space_name, search_unwind_table_name,
1073 find_dyn_list_name): Constify.
e83f4d97 1074
6821842f
SM
10752018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
1076
1077 * darwin-nat.c (darwin_pthread_kill): New function.
1078 (darwin_resume_thread): Use darwin_pthread_kill.
1079
c530603c
TV
10802018-07-05 Tom de Vries <tdevries@suse.de>
1081
1082 * macroexp.c (macro_buffer) <operator=>: New member function.
1083
a7d0f0f0
TT
10842018-07-04 Tom Tromey <tom@tromey.com>
1085
1086 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
1087
6242c6a6
SM
10882018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
1089
1090 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
1091 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
1092 * maint.c: Likewise.
1093 * top.c: Likewise.
1094
4e5b2f89
JB
10952018-07-04 Joel Brobecker <brobecker@adacore.com>
1096
1097 * NEWS: Create a new section for the next release branch.
1098 Rename the section of the current branch, now that it has
1099 been cut.
1100
538ccc4a
JB
11012018-07-04 Joel Brobecker <brobecker@adacore.com>
1102
1103 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
1104 * version.in: Bump version to 8.2.50.DATE-git.
1105
1b919490
VB
11062018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1107 Pedro Alves <palves@redhat.com>
1108
1109 * linux-nat.c (linux_init_ptrace): Rename to ...
1110 (linux_init_ptrace_procfs): ... this. Call
1111 linux_proc_init_warnings.
1112 (linux_nat_target::post_attach)
1113 (linux_nat_target::post_startup_inferior): Adjust.
1114 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
1115 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
1116
1ea5da02
TV
11172018-07-04 Tom de Vries <tdevries@suse.de>
1118
1119 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
1120 check ...
1121 (read_comp_unit_head): ... here.
1122
f51e0e20
TT
11232018-07-03 Tom Tromey <tom@tromey.com>
1124
1125 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
1126 (stop_tracing, tstatus_command)
1127 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
1128 (print_one_static_tracepoint_marker): Update.
1129 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
1130 std::vector.
1131 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
1132 VEC.
1133 (all_tracepoints, static_tracepoints_here): Return std::vector.
1134
d7e15655
TT
11352018-07-03 Tom Tromey <tom@tromey.com>
1136
1137 * common/ptid.c (ptid_equal): Remove.
1138 * common/ptid.h (ptid_equal): Don't declare.
1139 * ada-tasks.c: Update.
1140 * breakpoint.c: Update.
1141 * common/agent.c: Update.
1142 * corelow.c: Update.
1143 * darwin-nat-info.c: Update.
1144 * darwin-nat.c: Update.
1145 * dcache.c: Update.
1146 * dtrace-probe.c: Update.
1147 * dummy-frame.c: Update.
1148 * fbsd-nat.c: Update.
1149 * frame.c: Update.
1150 * gdbthread.h: Update.
1151 * gnu-nat.c: Update.
1152 * go32-nat.c: Update.
1153 * inf-loop.c: Update.
1154 * inf-ptrace.c: Update.
1155 * infcall.c: Update.
1156 * infcmd.c: Update.
1157 * inflow.c: Update.
1158 * infrun.c: Update.
1159 * linux-fork.c: Update.
1160 * linux-nat.c: Update.
1161 * linux-thread-db.c: Update.
1162 * mi/mi-cmd-var.c: Update.
1163 * mi/mi-interp.c: Update.
1164 * mi/mi-main.c: Update.
1165 * nto-procfs.c: Update.
1166 * ppc-linux-tdep.c: Update.
1167 * procfs.c: Update.
1168 * python/py-inferior.c: Update.
1169 * python/py-record-btrace.c: Update.
1170 * python/py-record.c: Update.
1171 * ravenscar-thread.c: Update.
1172 * regcache.c: Update.
1173 * remote-sim.c: Update.
1174 * remote.c: Update.
1175 * sol-thread.c: Update.
1176 * solib.c: Update.
1177 * target.c: Update.
1178 * tui/tui-stack.c: Update.
1179 * varobj.c: Update.
1180 * windows-nat.c: Update.
1181 * windows-tdep.c: Update.
1182
26a57c92
TT
11832018-07-03 Tom Tromey <tom@tromey.com>
1184
1185 * common/ptid.c (ptid_match): Remove.
1186 * common/ptid.h (ptid_match): Don't declare.
1187 * fbsd-nat.c: Update.
1188 * infcmd.c: Update.
1189 * infrun.c: Update.
1190 * linux-nat.c: Update.
1191 * record-btrace.c: Update.
1192 * regcache.c: Update.
1193 * remote.c: Update.
1194
d2a107e3
TT
11952018-07-03 Tom Tromey <tom@tromey.com>
1196
1197 * common/ptid.c (ptid_tid_p): Remove.
1198 * common/ptid.h (ptid_tid_p): Don't declare.
1199 * sol-thread.c: Update.
1200
15a9e13e
TT
12012018-07-03 Tom Tromey <tom@tromey.com>
1202
1203 * common/ptid.c (ptid_lwp_p): Remove.
1204 * common/ptid.h (ptid_lwp_p): Don't declare.
1205 * fbsd-nat.c: Update.
1206 * linux-nat.c: Update.
1207 * nat/linux-procfs.c: Update.
1208 * nat/x86-linux-dregs.c: Update.
1209 * sol-thread.c: Update.
1210
0e998d96
TT
12112018-07-03 Tom Tromey <tom@tromey.com>
1212
1213 * common/ptid.c (ptid_is_pid): Remove.
1214 * common/ptid.h (ptid_is_pid): Don't declare.
1215 * infrun.c: Update.
1216 * linux-nat.c: Update.
1217 * mi/mi-interp.c: Update.
1218 * remote.c: Update.
1219 * thread.c: Update.
1220
cc6bcb54
TT
12212018-07-03 Tom Tromey <tom@tromey.com>
1222
1223 * common/ptid.c (ptid_get_tid): Remove.
1224 * common/ptid.h (ptid_get_tid): Don't declare.
1225 * ada-tasks.c: Update.
1226 * aix-thread.c: Update.
1227 * bsd-uthread.c: Update.
1228 * darwin-nat.c: Update.
1229 * fbsd-nat.c: Update.
1230 * i386-darwin-nat.c: Update.
1231 * infrun.c: Update.
1232 * linux-tdep.c: Update.
1233 * nto-procfs.c: Update.
1234 * ppc-ravenscar-thread.c: Update.
1235 * python/py-infthread.c: Update.
1236 * ravenscar-thread.c: Update.
1237 * sol-thread.c: Update.
1238 * sparc-ravenscar-thread.c: Update.
1239 * windows-nat.c: Update.
1240
e38504b3
TT
12412018-07-03 Tom Tromey <tom@tromey.com>
1242
1243 * common/ptid.c (ptid_get_lwp): Remove.
1244 * common/ptid.h (ptid_get_lwp): Don't declare.
1245 * aarch64-linux-nat.c: Update.
1246 * ada-tasks.c: Update.
1247 * aix-thread.c: Update.
1248 * amd64-linux-nat.c: Update.
1249 * arm-linux-nat.c: Update.
1250 * corelow.c: Update.
1251 * fbsd-nat.c: Update.
1252 * fbsd-tdep.c: Update.
1253 * gnu-nat.c: Update.
1254 * i386-cygwin-tdep.c: Update.
1255 * i386-gnu-nat.c: Update.
1256 * i386-linux-nat.c: Update.
1257 * ia64-linux-nat.c: Update.
1258 * inf-ptrace.c: Update.
1259 * infrun.c: Update.
1260 * linux-fork.c: Update.
1261 * linux-nat.c: Update.
1262 * linux-tdep.c: Update.
1263 * linux-thread-db.c: Update.
1264 * mips-linux-nat.c: Update.
1265 * nat/aarch64-linux-hw-point.c: Update.
1266 * nat/aarch64-linux.c: Update.
1267 * nat/linux-btrace.c: Update.
1268 * nat/linux-osdata.c: Update.
1269 * nat/linux-procfs.c: Update.
1270 * nat/x86-linux-dregs.c: Update.
1271 * obsd-nat.c: Update.
1272 * ppc-fbsd-nat.c: Update.
1273 * ppc-linux-nat.c: Update.
1274 * procfs.c: Update.
1275 * python/py-infthread.c: Update.
1276 * ravenscar-thread.c: Update.
1277 * remote.c: Update.
1278 * s390-linux-nat.c: Update.
1279 * sol-thread.c: Update.
1280 * sol2-tdep.c: Update.
1281 * spu-linux-nat.c: Update.
1282 * x86-linux-nat.c: Update.
1283 * xtensa-linux-nat.c: Update.
1284
e99b03dc
TT
12852018-07-03 Tom Tromey <tom@tromey.com>
1286
1287 * common/ptid.c (ptid_get_pid): Remove.
1288 * common/ptid.h (ptid_get_pid): Don't declare.
1289 * aarch64-linux-nat.c: Update.
1290 * ada-lang.c: Update.
1291 * aix-thread.c: Update.
1292 * alpha-bsd-nat.c: Update.
1293 * amd64-fbsd-nat.c: Update.
1294 * amd64-linux-nat.c: Update.
1295 * arm-linux-nat.c: Update.
1296 * arm-nbsd-nat.c: Update.
1297 * auxv.c: Update.
1298 * break-catch-syscall.c: Update.
1299 * breakpoint.c: Update.
1300 * bsd-uthread.c: Update.
1301 * corelow.c: Update.
1302 * ctf.c: Update.
1303 * darwin-nat.c: Update.
1304 * fbsd-nat.c: Update.
1305 * fbsd-tdep.c: Update.
1306 * gcore.c: Update.
1307 * gnu-nat.c: Update.
1308 * hppa-nbsd-nat.c: Update.
1309 * hppa-obsd-nat.c: Update.
1310 * i386-fbsd-nat.c: Update.
1311 * ia64-linux-nat.c: Update.
1312 * inf-ptrace.c: Update.
1313 * infcmd.c: Update.
1314 * inferior.c: Update.
1315 * inferior.h: Update.
1316 * inflow.c: Update.
1317 * infrun.c: Update.
1318 * linux-fork.c: Update.
1319 * linux-nat.c: Update.
1320 * linux-tdep.c: Update.
1321 * linux-thread-db.c: Update.
1322 * m68k-bsd-nat.c: Update.
1323 * mi/mi-interp.c: Update.
1324 * mi/mi-main.c: Update.
1325 * mips-linux-nat.c: Update.
1326 * mips-nbsd-nat.c: Update.
1327 * mips64-obsd-nat.c: Update.
1328 * nat/aarch64-linux-hw-point.c: Update.
1329 * nat/aarch64-linux.c: Update.
1330 * nat/linux-btrace.c: Update.
1331 * nat/linux-osdata.c: Update.
1332 * nat/linux-procfs.c: Update.
1333 * nat/x86-linux-dregs.c: Update.
1334 * nto-procfs.c: Update.
1335 * obsd-nat.c: Update.
1336 * ppc-linux-nat.c: Update.
1337 * ppc-nbsd-nat.c: Update.
1338 * ppc-obsd-nat.c: Update.
1339 * proc-service.c: Update.
1340 * procfs.c: Update.
1341 * python/py-inferior.c: Update.
1342 * python/py-infthread.c: Update.
1343 * ravenscar-thread.c: Update.
1344 * record.c: Update.
1345 * remote-sim.c: Update.
1346 * remote.c: Update.
1347 * rs6000-nat.c: Update.
1348 * s390-linux-nat.c: Update.
1349 * sh-nbsd-nat.c: Update.
1350 * sol-thread.c: Update.
1351 * sparc-nat.c: Update.
1352 * sparc64-tdep.c: Update.
1353 * spu-linux-nat.c: Update.
1354 * spu-tdep.c: Update.
1355 * target-debug.h: Update.
1356 * target.c: Update.
1357 * thread.c: Update.
1358 * tid-parse.c: Update.
1359 * tracefile-tfile.c: Update.
1360 * vax-bsd-nat.c: Update.
1361 * windows-nat.c: Update.
1362 * x86-linux-nat.c: Update.
1363 * x86-nat.c: Update.
1364
f2907e49
TT
13652018-07-03 Tom Tromey <tom@tromey.com>
1366
1367 * common/ptid.c (pid_to_ptid): Remove.
1368 * common/ptid.h (pid_to_ptid): Don't declare.
1369 * aix-thread.c: Update.
1370 * arm-linux-nat.c: Update.
1371 * common/ptid.c: Update.
1372 * common/ptid.h: Update.
1373 * corelow.c: Update.
1374 * ctf.c: Update.
1375 * darwin-nat.c: Update.
1376 * fbsd-nat.c: Update.
1377 * fork-child.c: Update.
1378 * gnu-nat.c: Update.
1379 * go32-nat.c: Update.
1380 * inf-ptrace.c: Update.
1381 * infcmd.c: Update.
1382 * inferior.c: Update.
1383 * infrun.c: Update.
1384 * linux-fork.c: Update.
1385 * linux-nat.c: Update.
1386 * nat/aarch64-linux-hw-point.c: Update.
1387 * nat/fork-inferior.c: Update.
1388 * nat/x86-linux-dregs.c: Update.
1389 * nto-procfs.c: Update.
1390 * obsd-nat.c: Update.
1391 * procfs.c: Update.
1392 * progspace.c: Update.
1393 * remote.c: Update.
1394 * rs6000-nat.c: Update.
1395 * s390-linux-nat.c: Update.
1396 * sol-thread.c: Update.
1397 * spu-linux-nat.c: Update.
1398 * target.c: Update.
1399 * top.c: Update.
1400 * tracefile-tfile.c: Update.
1401 * windows-nat.c: Update.
1402
fd79271b
TT
14032018-07-03 Tom Tromey <tom@tromey.com>
1404
1405 * common/ptid.h (ptid_build): Don't declare.
1406 * common/ptid.c (ptid_build): Remove.
1407 * aix-thread.c: Update.
1408 * bsd-kvm.c: Update.
1409 * bsd-uthread.c: Update.
1410 * common/agent.c: Update.
1411 * common/ptid.c: Update.
1412 * common/ptid.h: Update.
1413 * corelow.c: Update.
1414 * darwin-nat.c: Update.
1415 * fbsd-nat.c: Update.
1416 * gnu-nat.c: Update.
1417 * linux-fork.c: Update.
1418 * linux-nat.c: Update.
1419 * linux-thread-db.c: Update.
1420 * nat/linux-osdata.c: Update.
1421 * nat/linux-procfs.c: Update.
1422 * nto-procfs.c: Update.
1423 * obsd-nat.c: Update.
1424 * proc-service.c: Update.
1425 * procfs.c: Update.
1426 * ravenscar-thread.c: Update.
1427 * remote-sim.c: Update.
1428 * remote.c: Update.
1429 * sol-thread.c: Update.
1430 * target.c: Update.
1431 * windows-nat.c: Update.
1432
057302ce
TT
14332018-07-03 Tom Tromey <tom@tromey.com>
1434
1435 * infrun.c (follow_exec): Use exit_inferior_silent.
1436 * inferior.c (exit_inferior_num_silent): Remove.
1437 * inferior.h (exit_inferior_num_silent): Don't declare.
1438
a50c11c6
TT
14392018-07-03 Tom Tromey <tom@tromey.com>
1440
1441 PR cli/23340:
1442 * darwin-nat.c (darwin_attach_pid): Reset inferior and
1443 inferior_ptid on error.
1444
471b9d15
MR
14452018-07-02 Maciej W. Rozycki <macro@mips.com>
1446 Simon Marchi <simon.marchi@polymtl.ca>
1447
1448 PR tdep/8282
1449 * disasm.h (gdb_disassembler): Add
1450 `m_disassembler_options_holder'. member
1451 * disasm.c (get_all_disassembler_options): New function.
1452 (gdb_disassembler::gdb_disassembler): Use it.
1453 (gdb_buffered_insn_length_init_dis): Likewise.
1454 (gdb_buffered_insn_length): Adjust accordingly.
1455 (set_disassembler_options): Handle options with arguments.
1456 (show_disassembler_options_sfunc): Likewise. Add a leading new
1457 line if showing options with descriptions.
1458 (disassembler_options_completer): Adapt to using the
1459 `disasm_options_and_args_t' structure.
1460 * mips-tdep.c (mips_disassembler_options): New variable.
1461 (mips_disassembler_options_o32): Likewise.
1462 (mips_disassembler_options_n32): Likewise.
1463 (mips_disassembler_options_n64): Likewise.
1464 (gdb_print_insn_mips): Don't set `disassembler_options'.
1465 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
1466 functions.
1467 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
1468 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
1469 `gdbarch_disassembler_options_implicit' and
1470 `gdbarch_valid_disassembler_options'.
1471 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
1472 `disasm_options_and_args_t' structure.
1473 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
1474 method.
1475 (valid_disassembler_options): Switch from `disasm_options_t' to
1476 the `disasm_options_and_args_t' structure.
1477 * NEWS: Document `set disassembler-options' support for the MIPS
1478 target.
1479 * gdbarch.h: Regenerate.
1480 * gdbarch.c: Regenerate.
1481
41823f29
SH
14822018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
1483
1484 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
1485
41206e32
JB
14862018-06-29 Joel Brobecker <brobecker@adacore.com>
1487
1488 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
1489 parameter in call to amd64_target_description.
1490 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
1491 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
1492 (amd64fbsd_init_abi): Likewise.
1493 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
1494 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
1495 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
1496 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
1497
de52b960
PA
14982018-06-29 Pedro Alves <palves@redhat.com>
1499
1500 * gdb/amd64-tdep.h (amd64_create_target_description): Add
1501 "segments" parameter.
1502 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
1503 (_initialize_amd64_tdep): Update call to
1504 amd64_create_target_description.
1505 (amd64_target_description): Add "segments" parameter. Adjust
1506 the implementation to use it.
1507 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
1508 call to amd64_create_target_description.
1509 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
1510 * gdb/arch/amd64.h (amd64_create_target_description): Add
1511 "segments" register.
1512 * gdb/arch/amd64.c (amd64_create_target_description): Add
1513 "segments" parameter. Call create_feature_i386_64bit_segments
1514 only if SEGMENTS is true.
1515 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
1516 call to amd64_create_target_description.
1517
75acb486
PA
15182018-06-29 Pedro Alves <palves@redhat.com>
1519
1520 * thread.c (thread_target_id_str): New, factored out from ...
1521 (print_thread_info_1): ... here. Use it to compute the max
1522 "Target Id" column width.
1523
c76a8ea3
PA
15242018-06-29 Pedro Alves <palves@redhat.com>
1525
1526 * remote.c (remote_target::extra_thread_info): Delete
1527 'display_buf' and 'n' locals. from the cache, regardless of
1528 packet mechanims is in use. Use cache for qThreadExtra and qP
1529 methods too.
1530
cd2bb709
PA
15312018-06-29 Pedro Alves <palves@redhat.com>
1532
1533 * blockframe.c (find_pc_sect_containing_function): New function.
1534 * breakpoint.c (print_breakpoint_location): Don't call
1535 find_pc_sect_function.
1536 * linespec.c (create_sals_line_offset): Record the location's
1537 symbol in the sal.
1538 * linespec.c (convert_address_location_to_sals): Fill in sal's
1539 symbol with find_pc_sect_containing_function.
1540 * symtab.c (find_function_start_sal): Rename to ...
1541 (find_function_start_sal_1): ... this.
1542 (find_function_start_sal): Reimplement as wrapper around
1543 find_function_start_sal_1, and use
1544 find_pc_sect_containing_function to fill in the sal's symbol.
1545 (find_function_start_sal(symbol*, bool)): Adjust.
1546 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
1547 comments.
1548 (find_pc_sect_containing_function): Declare.
1549
991ff292
PA
15502018-06-29 Pedro Alves <palves@redhat.com>
1551
1552 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
1553 true if the the location has no symbol.
1554
44cee4fd
TT
15552018-06-28 Tom Tromey <tom@tromey.com>
1556
1557 * NEWS: Mention --enable-codesign.
1558 * silent-rules.mk (ECHO_SIGN): New variable.
1559 * configure.ac: Add --enable-codesign.
1560 * configure: Rebuild.
1561 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
1562 (gdb$(EXEEXT)): Optionally invoke codesign.
1563
f2ffa92b
PA
15642018-06-28 Pedro Alves <palves@redhat.com>
1565
1566 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
1567 comments.
1568 (switch_to_thread_no_regs): Adjust comment.
1569 * infcmd.c (stop_pc): Delete.
1570 (post_create_inferior, info_program_command): Replace references
1571 to stop_pc with references to thread_info->suspend.stop_pc.
1572 * inferior.h (stop_pc): Delete declaration.
1573 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
1574 (handle_inferior_event_1, handle_signal_stop)
1575 (process_event_stop_test, keep_going_stepped_thread)
1576 (handle_step_into_function, handle_step_into_function_backward)
1577 (print_stop_location): Replace references to stop_pc with
1578 references to thread_info->suspend.stop_pc.
1579 (struct infcall_suspend_state) <stop_pc>: Delete field.
1580 (save_infcall_suspend_state, restore_infcall_suspend_state):
1581 Remove references to inf_stat->stop_pc.
1582 * linux-fork.c (fork_load_infrun_state): Likewise.
1583 * record-btrace.c (record_btrace_set_replay): Likewise.
1584 * record-full.c (record_full_goto_entry): Likewise.
1585 * remote.c (print_one_stopped_thread): Likewise.
1586 * target.c (target_resume): Extend comment.
1587 * thread.c (set_executing_thread): New.
1588 (set_executing): Use it.
1589 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
1590 Remove references to stop_pc.
1591
ecdc3a72
PA
15922018-06-28 Pedro Alves <palves@redhat.com>
1593
1594 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
1595 Moving fetching stop_pc until after ecs->event_thread is refreshed.
1596
d95d3aef
TT
15972018-06-28 Tom Tromey <tom@tromey.com>
1598
1599 * coffread.c (coff_symfile_finish): Update.
1600 * xcoffread.c (xcoff_symfile_finish): Update.
1601 * elfread.c (elf_symfile_finish): Update.
1602 * symfile.h (dwarf2_free_objfile): Don't declare.
1603 * dwarf2read.c (_initialize_dwarf2_read): Use
1604 register_objfile_data_with_cleanup.
1605 (dwarf2_free_objfile): Now static. Change signature.
1606
291f9a96
PT
16072018-06-28 Petr Tesarik <ptesarik@suse.cz>
1608
1609 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
1610 option "-o" to add-symbol-file-load to add an offset to each
1611 section's load address.
1612 * symfile.c (set_objfile_default_section_offset): New function.
1613
d81a3eaf
PT
16142018-06-28 Petr Tesarik <ptesarik@suse.cz>
1615
1616 * symfile.c (add_symbol_file_command): Make sure that sections
1617 with the same name are sorted in the same order.
1618
ed6dfe51
PT
16192018-06-28 Petr Tesarik <ptesarik@suse.cz>
1620
1621 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
1622 require the second argument. If omitted, load sections at the
1623 addresses specified in the file.
1624
d4d429d5
PT
16252018-06-28 Petr Tesarik <ptesarik@suse.cz>
1626
1627 * symfile.c (symbol_file_command, symbol_file_add_main_1)
1628 (_initialize_symfile): Add option "-o" to symbol-file to add an
1629 offset to each section of the symbol file.
1630
39b27ab6
PT
16312018-06-28 Petr Tesarik <ptesarik@suse.cz>
1632
1633 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
1634
41827fc3
TT
16352018-06-27 Tom Tromey <tom@tromey.com>
1636
1637 * stack.c (_initialize_stack): Update "func" help text.
1638
0c6aef22
TT
16392018-06-27 Tom Tromey <tom@tromey.com>
1640
1641 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
1642 std::vector.
1643 (unwind_infopy_str, pyuw_create_unwind_info)
1644 (unwind_infopy_add_saved_register, pyuw_sniffer)
1645 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
1646 Update.
1647 (struct saved_reg): Add constructor.
1648 <value>: Now a gdbpy_ref<>.
1649
63177289
TT
16502018-06-27 Tom Tromey <tom@tromey.com>
1651
1652 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
1653
e76f78a0
SM
16542018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1655
1656 * gdb-gdb.py.in: Format using autopep8.
1657
9a14af7b
SM
16582018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1659
1660 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
1661 (type_lookup_function): Recognize CORE_ADDR values.
1662
189366cd
SM
16632018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1664
1665 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
1666 print tag_name.
1667
68ad5fb9
SM
16682018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1669
1670 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
1671 <__lt__>: Add.
1672
141ec9f6
SM
16732018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1674
1675 * gdb-gdb.py: Move to...
1676 * gdb-gdb.py.in: ... here.
1677 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
1678 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
1679 dependencies.
1680 (distclean): Remove gdb-gdb.py when cleaning.
1681 (gdb-gdb.py, gdb-gdb.gdb): New rules.
1682 * configure: Re-generate.
1683
4c4e7ad4
PA
16842018-06-27 Pedro Alves <palves@redhat.com>
1685
1686 * proc-service.c (get_ps_regcache): New.
1687 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
1688 (ps_lsetfpregs): Use it.
1689
7ab6656f
OJ
16902018-06-27 Omair Javaid <omair.javaid@linaro.org>
1691
1692 PR gdb/21695
1693 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
1694 (dwarf_decode_lines_1): Adjust.
1695
bd583225
SM
16962018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1697
1698 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
1699 override.
1700 <info_proc>: Likewise.
1701
9a325b7b
JB
17022018-06-26 Joel Brobecker <brobecker@adacore.com>
1703
1704 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
1705 to windows_fetch_one_register, and only handle the case of
1706 fetching one register. Move the code that reloads the context
1707 and iterates over all registers if R is negative to...
1708 (windows_nat_target::fetch_registers): ... here.
1709 (do_windows_store_inferior_registers): Rename to
1710 windows_store_one_register, and only handle the case of storing
1711 one register. Move the code that handles the case where r is
1712 negative to...
1713 (windows_nat_target::store_registers) ... here.
1714
a33ccfc7
TT
17152018-06-26 Tom Tromey <tom@tromey.com>
1716
1717 PR rust/22574:
1718 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
1719 * rust-lang.c (rust_print_struct_def): Add podata parameter.
1720 Update.
1721 (rust_internal_print_type): Add podata parameter.
1722 (rust_print_type): Update.
1723
e0c547d1
TT
17242018-06-26 Tom Tromey <tom@tromey.com>
1725
1726 * typeprint.h (struct print_offset_data) <update, finish,
1727 maybe_print_hole>: New methods.
1728 <indentation>: New constant.
1729 * typeprint.c (print_offset_data::indentation): Define.
1730 (print_offset_data::maybe_print_hole, print_offset_data::update)
1731 (print_offset_data::finish): Move from c-typeprint.c and rename.
1732 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
1733 (print_spaces_filtered_with_print_options): Update.
1734 (c_print_type_union_field_offset, maybe_print_hole)
1735 (c_print_type_struct_field_offset): Move to typeprint.c and
1736 rename.
1737 (c_type_print_base_struct_union): Update.
1738
75cbc781
PA
17392018-06-25 Pedro Alves <palves@redhat.com>
1740
1741 * gdbthread.h (thread_info_ref, delete_thread)
1742 (delete_thread_silent, first_thread_of_inferior)
1743 (any_thread_of_inferior, switch_to_thread)
1744 (enable_thread_stack_temporaries)
1745 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1746 (get_last_thread_stack_temporary)
1747 (value_in_thread_stack_temporaries, can_access_registers_thread):
1748 Spell out "struct thread_info" instead of just "thread_info".
1749 * inferior.h (notice_new_inferior): Likewise.
1750
b7a08269
PA
17512018-06-25 Pedro Alves <palves@redhat.com>
1752
1753 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1754 pass thread_info pointer to delete_thread.
1755 (windows_nat_target::detach): Pass inferior pointer to
1756 detach_inferior.
1757 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
1758 delete_thread.
1759 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
1760 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
1761 and pass a thread_info pointer to delete_thread.
1762 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
1763 pass thread_info pointer to delete_thread.
1764 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
1765 delete_thread_silent call.
1766 * procfs.c (procfs_target::detach): Pass inferior pointer to
1767 detach_inferior.
1768 (procfs_target::wait): Pass thread_info pointer to delete_thread.
1769 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
1770 delete_thread_silent call.
1771 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1772 pass thread_info pointer to delete_thread.
1773 (windows_nat_target::detach): Pass inferior pointer to
1774 delete_inferior.
1775
8e7767e3
AH
17762018-06-22 Alan Hayward <alan.hayward@arm.com>
1777
1778 * regcache.c (readable_regcache::read_part): Fix asserts.
1779 (reg_buffer::raw_collect_part): New function.
1780 (regcache::write_part): Fix asserts.
1781 (reg_buffer::raw_supply_part): New function.
1782 (regcache::transfer_regset_register): New helper function.
1783 (regcache::transfer_regset): Call new functions.
1784 (regcache_supply_regset): Use gdb_byte*.
1785 (regcache::supply_regset): Likewise.
1786 (regcache_collect_regset): Likewise.
1787 (regcache::collect_regset): Likewise.
1788 * regcache.h (reg_buffer::raw_collect_part): New declaration.
1789 (reg_buffer::raw_supply_part): Likewise.
1790 (regcache::transfer_regset_register): Likewise.
1791 (regcache::transfer_regset): Use gdb_byte*.
1792
bfd60e34
AH
17932018-06-22 Alan Hayward <alan.hayward@arm.com>
1794
1795 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
1796
00431a78
PA
17972018-06-21 Pedro Alves <palves@redhat.com>
1798
1799 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
1800 instead of a ptid_t. All callers adjusted.
1801 * ada-tasks.c (ada_get_task_number): Likewise. All callers
1802 adjusted.
1803 (print_ada_task_info, display_current_task_id, task_command_1):
1804 Adjust.
1805 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
1806 inferior_thread.
1807 (breakpoint_kind): Adjust.
1808 (remove_breakpoints_pid): Rename to ...
1809 (remove_breakpoints_inf): ... this. Adjust to take an inferior
1810 pointer. All callers adjusted.
1811 (bpstat_clear_actions): Use inferior_thread.
1812 (get_bpstat_thread): New.
1813 (bpstat_do_actions): Use it.
1814 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
1815 to take a thread_info pointer. All callers adjusted.
1816 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
1817 (breakpoint_re_set_thread): Use inferior_thread.
1818 * breakpoint.h (struct inferior): Forward declare.
1819 (bpstat_stop_status): Update.
1820 (remove_breakpoints_pid): Delete.
1821 (remove_breakpoints_inf): New.
1822 * bsd-uthread.c (bsd_uthread_target::wait)
1823 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
1824 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
1825 (maint_btrace_packet_history_cmd)
1826 (maint_btrace_clear_packet_history_cmd): Adjust.
1827 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
1828 inferior_thread.
1829 * cli/cli-interp.c: Include "inferior.h".
1830 * common/refcounted-object.h (struct
1831 refcounted_object_ref_policy): New.
1832 * compile/compile-object-load.c: Include gdbthread.h.
1833 (store_regs): Use inferior_thread.
1834 * corelow.c (core_target::close): Use current_inferior.
1835 (core_target_open): Adjust to use first_thread_of_inferior and use
1836 the current inferior.
1837 * ctf.c (ctf_target::close): Adjust to use current_inferior.
1838 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
1839 <thread>: ... this new field. All references adjusted.
1840 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
1841 Take a thread_info pointer instead of a ptid_t.
1842 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
1843 (dummy_frame_discard, register_dummy_frame_dtor): Take a
1844 thread_info pointer instead of a ptid_t.
1845 * elfread.c: Include "inferior.h".
1846 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
1847 Use inferior_thread.
1848 * eval.c (evaluate_subexp): Likewise.
1849 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
1850 inferior_thread.
1851 * gdb_proc_service.h (struct thread_info): Forward declare.
1852 (struct ps_prochandle) <ptid>: Delete, replaced by ...
1853 <thread>: ... this new field. All references adjusted.
1854 * gdbarch.h, gdbarch.c: Regenerate.
1855 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
1856 'thread' parameter. All implementations and callers adjusted.
1857 * gdbthread.h (thread_info) <set_running>: New method.
1858 (delete_thread, delete_thread_silent): Take a thread_info pointer
1859 instead of a ptid.
1860 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
1861 (first_thread_of_process): Delete, replaced by ...
1862 (first_thread_of_inferior): ... this new function. All callers
1863 adjusted.
1864 (any_live_thread_of_process): Delete, replaced by ...
1865 (any_live_thread_of_inferior): ... this new function. All callers
1866 adjusted.
1867 (switch_to_thread, switch_to_no_thread): Declare.
1868 (is_executing): Delete.
1869 (enable_thread_stack_temporaries): Update comment.
1870 <enable_thread_stack_temporaries>: Take a thread_info pointer
1871 instead of a ptid_t. Incref the thread.
1872 <~enable_thread_stack_temporaries>: Decref the thread.
1873 <m_ptid>: Delete
1874 <m_thr>: New.
1875 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1876 (get_last_thread_stack_temporary)
1877 (value_in_thread_stack_temporaries, can_access_registers_thread):
1878 Take a thread_info pointer instead of a ptid_t. All callers
1879 adjusted.
1880 * infcall.c (get_call_return_value): Use inferior_thread.
1881 (run_inferior_call): Work with thread pointers instead of ptid_t.
1882 (call_function_by_hand_dummy): Work with thread pointers instead
1883 of ptid_t. Use thread_info_ref.
1884 * infcmd.c (proceed_thread_callback): Access thread's state
1885 directly.
1886 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
1887 access thread's state directly.
1888 (continue_command): Use inferior_thread.
1889 (info_program_command): Use find_thread_ptid and access thread
1890 state directly.
1891 (proceed_after_attach_callback): Use thread state directly.
1892 (notice_new_inferior): Take a thread_info pointer instead of a
1893 ptid_t. All callers adjusted.
1894 (exit_inferior): Take an inferior pointer instead of a pid. All
1895 callers adjusted.
1896 (exit_inferior_silent): New.
1897 (detach_inferior): Delete.
1898 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
1899 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
1900 (detach_inferior_command, kill_inferior_command): Use
1901 find_inferior_id instead of valid_gdb_inferior_id and
1902 gdb_inferior_id_to_pid.
1903 (inferior_command): Use inferior and thread pointers.
1904 * inferior.h (struct thread_info): Forward declare.
1905 (notice_new_inferior): Take a thread_info pointer instead of a
1906 ptid_t. All callers adjusted.
1907 (detach_inferior): Delete declaration.
1908 (exit_inferior, exit_inferior_silent): Take an inferior pointer
1909 instead of a pid. All callers adjusted.
1910 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
1911 (valid_gdb_inferior_id): Delete.
1912 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
1913 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
1914 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
1915 ...
1916 <inf>: ... this new field.
1917 <step_ptid>: Delete, replaced by ...
1918 <step_thread>: ... this new field.
1919 (get_displaced_stepping_state): Take an inferior pointer instead
1920 of a pid. All callers adjusted.
1921 (displaced_step_in_progress_any_inferior): Adjust.
1922 (displaced_step_in_progress_thread): Take a thread pointer instead
1923 of a ptid_t. All callers adjusted.
1924 (displaced_step_in_progress, add_displaced_stepping_state): Take
1925 an inferior pointer instead of a pid. All callers adjusted.
1926 (get_displaced_step_closure_by_addr): Adjust.
1927 (remove_displaced_stepping_state): Take an inferior pointer
1928 instead of a pid. All callers adjusted.
1929 (displaced_step_prepare_throw, displaced_step_prepare)
1930 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
1931 All callers adjusted.
1932 (start_step_over): Adjust.
1933 (infrun_thread_ptid_changed): Remove bit updating ptids in the
1934 displaced step queue.
1935 (do_target_resume): Adjust.
1936 (fetch_inferior_event): Use inferior_thread.
1937 (context_switch, get_inferior_stop_soon): Take an
1938 execution_control_state pointer instead of a ptid_t. All callers
1939 adjusted.
1940 (switch_to_thread_cleanup): Delete.
1941 (stop_all_threads): Use scoped_restore_current_thread.
1942 * inline-frame.c: Include "gdbthread.h".
1943 (inline_state) <inline_state>: Take a thread pointer instead of a
1944 ptid_t. All callers adjusted.
1945 <ptid>: Delete, replaced by ...
1946 <thread>: ... this new field.
1947 (find_inline_frame_state): Take a thread pointer instead of a
1948 ptid_t. All callers adjusted.
1949 (skip_inline_frames, step_into_inline_frame)
1950 (inline_skipped_frames, inline_skipped_symbol): Take a thread
1951 pointer instead of a ptid_t. All callers adjusted.
1952 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
1953 (inline_skipped_frames, inline_skipped_symbol): Likewise.
1954 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
1955 pointers directly.
1956 * linux-nat.c (get_detach_signal): Likewise.
1957 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
1958 (thread_db_notice_clone): Adjust.
1959 (thread_db_find_new_threads_silently)
1960 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
1961 a thread pointer instead of a ptid_t. All callers adjusted.
1962 * mi/mi-cmd-var.c: Include "inferior.h".
1963 (mi_cmd_var_update_iter): Update to use thread pointers.
1964 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
1965 inferior directly.
1966 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
1967 out to ...
1968 (mi_output_running): ... this new function.
1969 (mi_on_resume_1): Adjust to use it.
1970 (mi_user_selected_context_changed): Adjust to use inferior_thread.
1971 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
1972 directly.
1973 (interrupt_thread_callback): : Adjust to use thread and inferior
1974 pointers.
1975 * proc-service.c: Include "gdbthread.h".
1976 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
1977 * progspace-and-thread.c: Include "inferior.h".
1978 * progspace.c: Include "inferior.h".
1979 * python/py-exitedevent.c (create_exited_event_object): Adjust to
1980 hold a reference to an inferior_object.
1981 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
1982 inferior_thread.
1983 * python/py-inferior.c (struct inferior_object): Give the type a
1984 tag name instead of a typedef.
1985 (python_on_normal_stop): No need to check if the current thread is
1986 listed.
1987 (inferior_to_inferior_object): Change return type to
1988 inferior_object. All callers adjusted.
1989 (find_thread_object): Delete, bits factored out to ...
1990 (thread_to_thread_object): ... this new function.
1991 * python/py-infthread.c (create_thread_object): Use
1992 inferior_to_inferior_object.
1993 (thpy_is_stopped): Use thread pointer directly.
1994 (gdbpy_selected_thread): Use inferior_thread.
1995 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
1996 field, replaced with ...
1997 <thread>: ... this new field. All users adjusted.
1998 (btpy_insn_or_gap_new): Drop const.
1999 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
2000 callers adjusted.
2001 * python/py-record.c: Include "gdbthread.h".
2002 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2003 a ptid_t. All callers adjusted.
2004 (gdbpy_current_recording): Use inferior_thread.
2005 * python/py-record.h (recpy_record_object) <ptid>: Delete
2006 field, replaced with ...
2007 <thread>: ... this new field. All users adjusted.
2008 (recpy_element_object) <ptid>: Delete
2009 field, replaced with ...
2010 <thread>: ... this new field. All users adjusted.
2011 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2012 a ptid_t. All callers adjusted.
2013 * python/py-threadevent.c: Include "gdbthread.h".
2014 (get_event_thread): Use thread_to_thread_object.
2015 * python/python-internal.h (struct inferior_object): Forward
2016 declare.
2017 (find_thread_object, find_inferior_object): Delete declarations.
2018 (thread_to_thread_object, inferior_to_inferior_object): New
2019 declarations.
2020 * record-btrace.c: Include "inferior.h".
2021 (require_btrace_thread): Use inferior_thread.
2022 (record_btrace_frame_sniffer)
2023 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
2024 (get_thread_current_frame): Use scoped_restore_current_thread and
2025 switch_to_thread.
2026 (get_thread_current_frame): Use thread pointer directly.
2027 (record_btrace_replay_at_breakpoint): Use thread's inferior
2028 pointer directly.
2029 * record-full.c: Include "inferior.h".
2030 * regcache.c: Include "gdbthread.h".
2031 (get_thread_arch_regcache): Use the inferior's address space
2032 directly.
2033 (get_thread_regcache, registers_changed_thread): New.
2034 * regcache.h (get_thread_regcache(thread_info *thread)): New
2035 overload.
2036 (registers_changed_thread): New.
2037 (remote_target) <remote_detach_1>: Swap order of parameters.
2038 (remote_add_thread): <remote_add_thread>: Return the new thread.
2039 (get_remote_thread_info(ptid_t)): New overload.
2040 (remote_target::remote_notice_new_inferior): Use thread pointers
2041 directly.
2042 (remote_target::process_initial_stop_replies): Use
2043 thread_info::set_running.
2044 (remote_target::remote_detach_1, remote_target::detach)
2045 (extended_remote_target::detach): Adjust.
2046 * stack.c (frame_show_address): Use inferior_thread.
2047 * target-debug.h (target_debug_print_thread_info_pp): New.
2048 * target-delegates.c: Regenerate.
2049 * target.c (default_thread_address_space): Delete.
2050 (memory_xfer_partial_1): Use current_inferior.
2051 (target_detach): Use current_inferior.
2052 (target_thread_address_space): Delete.
2053 (generic_mourn_inferior): Use current_inferior.
2054 * target.h (struct target_ops) <thread_address_space>: Delete.
2055 (target_thread_address_space): Delete.
2056 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
2057 pointers directly.
2058 (delete_thread_1, delete_thread, delete_thread_silent): Take a
2059 thread pointer instead of a ptid_t. Adjust all callers.
2060 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
2061 (first_thread_of_process): Delete, replaced by ...
2062 (first_thread_of_inferior): ... this new function. All callers
2063 adjusted.
2064 (any_thread_of_process): Rename to ...
2065 (any_thread_of_inferior): ... this, and take an inferior pointer.
2066 (any_live_thread_of_process): Rename to ...
2067 (any_live_thread_of_inferior): ... this, and take an inferior
2068 pointer.
2069 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2070 (value_in_thread_stack_temporaries)
2071 (get_last_thread_stack_temporary): Take a thread pointer instead
2072 of a ptid_t. Adjust all callers.
2073 (thread_info::set_running): New.
2074 (validate_registers_access): Use inferior_thread.
2075 (can_access_registers_ptid): Rename to ...
2076 (can_access_registers_thread): ... this, and take a thread
2077 pointer.
2078 (print_thread_info_1): Adjust to compare thread pointers instead
2079 of ptids.
2080 (switch_to_no_thread, switch_to_thread): Make extern.
2081 (scoped_restore_current_thread::~scoped_restore_current_thread):
2082 Use m_thread pointer directly.
2083 (scoped_restore_current_thread::scoped_restore_current_thread):
2084 Use inferior_thread.
2085 (thread_command): Use thread pointer directly.
2086 (thread_num_make_value_helper): Use inferior_thread.
2087 * top.c (execute_command): Use inferior_thread.
2088 * tui/tui-interp.c: Include "inferior.h".
2089 * varobj.c (varobj_create): Use inferior_thread.
2090 (value_of_root_1): Use find_thread_global_id instead of
2091 global_thread_id_to_ptid.
2092
33bab475
AH
20932018-06-21 Alan Hayward <alan.hayward@arm.com>
2094
2095 * regcache.c (readable_regcache::read_part): Avoid memcpy when
2096 possible.
2097 (regcache::write_part): Likewise.
2098 (readable_regcache::cooked_read_part): Update comment.
2099 (readable_regcache::cooked_write_part): Likewise.
2100 * regcache.h: (readable_regcache::read_part): Likewise.
2101 (regcache::write_part): Likewise.
2102
8363f9d5
RB
21032018-06-21 Richard Bunt <richard.bunt@arm.com>
2104 Dirk Schubert <dirk.schubert@arm.com>
2105
2106 * aarch64-linux-nat.c (post_attach): New.
2107 (aarch64_linux_nat_target::post_attach): Override post_attach to
2108 record the number of hardware debug registers.
2109
0d0b0ea2
TT
21102018-06-20 Tom Tromey <tom@tromey.com>
2111
2112 * python/py-param.c (add_setshow_generic): Make parameters const.
2113 (parmpy_init): Update.
2114
302abd6e
SM
21152018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2116
2117 * regcache.h (regcache_cooked_read_ftype): Rename to...
2118 (register_read_ftype): ...this, change type to function_view.
2119 (class reg_buffer) <save>: Remove src parameter.
2120 (readonly_detached_regcache) <readonly_detached_regcache>: Make
2121 parameter non-const in first overload. Remove src parameter in
2122 second overload.
2123 * regcache.c (do_cooked_read): Remove.
2124 (readonly_detached_regcache::readonly_detached_regcache): Make
2125 parameter non-const, adjust call to other constructor.
2126 (reg_buffer::save): Remove src parameter.
2127 * frame.c (do_frame_register_read): Remove.
2128 (frame_save_as_regcache): Use lambda function.
2129 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
2130 parameter to ppu2spu_data *.
2131 (ppu2spu_sniffer): Use lambda function.
2132
19f3f25f
SM
21332018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2134
2135 * record-full.c (record_full_target::insert_breakpoint): Remove
2136 "struct" keyword, add const.
2137
d0ac1c44
SM
21382018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2139
2140 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
2141 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
2142 * configure.ac: Remove AC_PREREQ, add missing quoting.
2143 * gnulib/configure.ac: Modernize usage of
2144 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
2145 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
2146 (AUTOMAKE_VERSION): Bump to 1.15.1.
2147 * configure: Re-generate.
2148 * config.in: Re-generate.
2149 * aclocal.m4: Re-generate.
2150 * gnulib/aclocal.m4: Re-generate.
2151 * gnulib/config.in: Re-generate.
2152 * gnulib/configure: Re-generate.
2153 * gnulib/import/Makefile.in: Re-generate.
2154
6ae50267
PA
21552018-06-19 Pedro Alves <palves@redhat.com>
2156
2157 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
2158 (lookup_minimal_symbol_by_pc_section): ... here with
2159 gdb_assert_not_reached added.
2160
61b04dd0
PA
21612018-06-19 Pedro Alves <palves@redhat.com>
2162
2163 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
2164 parameter with a block parameter. Compare location's block symbol
2165 with the frame's block instead of addresses.
2166 (skip_inline_frames): Pass the current block instead of the
2167 frame's address. Break out as soon as we determine the frame
2168 should not be skipped.
2169
f709fabb
TT
21702018-06-18 Tom Tromey <tom@tromey.com>
2171
2172 * solib-aix.c (solib_aix_get_section_offsets): Return
2173 unique_xmalloc_ptr.
2174 (solib_aix_solib_create_inferior_hook): Update.
2175
668eb2f0
TT
21762018-06-18 Tom Tromey <tom@tromey.com>
2177
2178 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
2179
309822ca
TT
21802018-06-18 Tom Tromey <tom@tromey.com>
2181
2182 * solib-frv.c (frv_relocate_main_executable): Use
2183 unique_xmalloc_ptr.
2184 * solib-dsbt.c (dsbt_relocate_main_executable): Use
2185 unique_xmalloc_ptr.
2186
06424eac
TT
21872018-06-18 Tom Tromey <tom@tromey.com>
2188
2189 * objfiles.h (inhibit_section_map_updates): Update.
2190 (resume_section_map_updates, resume_section_map_updates_cleanup):
2191 Remove.
2192 * solib-svr4.c (svr4_handle_solib_event): Update.
2193 * objfiles.c (inhibit_section_map_updates): Return
2194 scoped_restore_tmpl<int>.
2195 (resume_section_map_updates, resume_section_map_updates_cleanup):
2196 Remove.
2197
b4be9fad
TT
21982018-06-18 Tom Tromey <tom@tromey.com>
2199
2200 * valprint.h (read_string): Update.
2201 * valprint.c (read_string): Change type of "buffer".
2202 (val_print_string): Update.
2203 * python/py-value.c (valpy_string): Update.
2204 * language.h (struct language_defn) <la_get_string>: Change
2205 type of "buffer".
2206 (default_get_string, c_get_string): Update.
2207 * language.c (default_get_string): Change type of "buffer".
2208 * guile/scm-value.c (gdbscm_value_to_string): Update.
2209 * c-lang.c (c_get_string): Change type of "buffer".
2210
3f0dbd67
TT
22112018-06-18 Tom Tromey <tom@tromey.com>
2212
2213 * ser-mingw.c (struct pipe_state_destroyer): New.
2214 (pipe_state_up): New typedef.
2215 (cleanup_pipe_state): Remove.
2216 (pipe_windows_open): Use pipe_state_up. Don't release argv.
2217
69d340c6
TT
22182018-06-18 Tom Tromey <tom@tromey.com>
2219
2220 * rust-lang.h (rust_yyerror): Don't declare.
2221 * rust-lang.c (rust_language_defn): Update.
2222 * rust-exp.y (yyerror): Now static.
2223 * parse.c (parse_exp_in_context_1): Update.
2224 * p-lang.h (p_yyerror): Don't declare.
2225 * p-lang.c (p_language_defn): Update.
2226 * p-exp.y (yyerror): Now static.
2227 * opencl-lang.c (opencl_language_defn): Update.
2228 * objc-lang.c (objc_language_defn): Update.
2229 * m2-lang.h (m2_yyerror): Don't declare.
2230 * m2-lang.c (m2_language_defn): Update.
2231 * m2-exp.y (yyerror): Now static.
2232 * language.h (struct language_defn) <la_error>: Remove.
2233 * language.c (unk_lang_error): Remove.
2234 (unknown_language_defn, auto_language_defn): Remove.
2235 * go-lang.h (go_yyerror): Don't declare.
2236 * go-lang.c (go_language_defn): Update.
2237 * go-exp.y (yyerror): Now static.
2238 * f-lang.h (f_yyerror): Don't declare.
2239 * f-lang.c (f_language_defn): Update.
2240 * f-exp.y (yyerror): Now static.
2241 * d-lang.h (d_yyerror): Don't declare.
2242 * d-lang.c (d_language_defn): Update.
2243 * d-exp.y (yyerror): Now static.
2244 * c-lang.h (c_yyerror): Don't declare.
2245 * c-lang.c (c_language_defn, cplus_language_defn)
2246 (asm_language_defn, minimal_language_defn): Update.
2247 * c-exp.y (yyerror): Now static.
2248 * ada-lang.h (ada_yyerror): Don't declare.
2249 * ada-lang.c (ada_language_defn): Update.
2250 * ada-exp.y (yyerror): Now static.
2251
e9902bfc
AH
22522018-06-18 Alan Hayward <alan.hayward@arm.com>
2253
2254 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
2255 (store_sveregs_to_thread): Likewise.
2256 (aarch64_linux_fetch_inferior_registers): Check for SVE.
2257 (aarch64_linux_store_inferior_registers): Likewise.
2258 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
2259 function.
2260 (aarch64_sve_regs_copy_to_regcache): Likewise.
2261 (aarch64_sve_regs_copy_from_regcache): Likewise.
2262 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
2263 declaration.
2264 (aarch64_sve_regs_copy_to_regcache): Likewise.
2265 (aarch64_sve_regs_copy_from_regcache): Likewise.
2266 (sve_context): Structure from Linux headers.
2267 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
2268 (SVE_SIG_ZREG_SIZE): Likewise.
2269 (SVE_SIG_PREG_SIZE): Likewise.
2270 (SVE_SIG_FFR_SIZE): Likewise.
2271 (SVE_SIG_REGS_OFFSET): Likewise.
2272 (SVE_SIG_ZREGS_OFFSET): Likewise.
2273 (SVE_SIG_ZREG_OFFSET): Likewise.
2274 (SVE_SIG_ZREGS_SIZE): Likewise.
2275 (SVE_SIG_PREGS_OFFSET): Likewise.
2276 (SVE_SIG_PREG_OFFSET): Likewise.
2277 (SVE_SIG_PREGS_SIZE): Likewise.
2278 (SVE_SIG_FFR_OFFSET): Likewise.
2279 (SVE_SIG_REGS_SIZE): Likewise.
2280 (SVE_SIG_CONTEXT_SIZE): Likewise.
2281 (SVE_PT_REGS_MASK): Likewise.
2282 (SVE_PT_REGS_FPSIMD): Likewise.
2283 (SVE_PT_REGS_SVE): Likewise.
2284 (SVE_PT_VL_INHERIT): Likewise.
2285 (SVE_PT_VL_ONEXEC): Likewise.
2286 (SVE_PT_REGS_OFFSET): Likewise.
2287 (SVE_PT_FPSIMD_OFFSET): Likewise.
2288 (SVE_PT_FPSIMD_SIZE): Likewise.
2289 (SVE_PT_SVE_ZREG_SIZE): Likewise.
2290 (SVE_PT_SVE_PREG_SIZE): Likewise.
2291 (SVE_PT_SVE_FFR_SIZE): Likewise.
2292 (SVE_PT_SVE_FPSR_SIZE): Likewise.
2293 (SVE_PT_SVE_FPCR_SIZE): Likewise.
2294 (__SVE_SIG_TO_PT): Likewise.
2295 (SVE_PT_SVE_OFFSET): Likewise.
2296 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
2297 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
2298 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
2299 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
2300 (SVE_PT_SVE_PREG_OFFSET): Likewise.
2301 (SVE_PT_SVE_PREGS_SIZE): Likewise.
2302 (SVE_PT_SVE_FFR_OFFSET): Likewise.
2303 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
2304 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
2305 (SVE_PT_SVE_SIZE): Likewise.
2306 (SVE_PT_SIZE): Likewise.
2307 (HAS_SVE_STATE): New define.
2308
17a1cc89
AH
23092018-06-18 Alan Hayward <alan.hayward@arm.com>
2310
2311 * nat/aarch64-sve-linux-sigcontext.h: New file.
2312 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
2313 new files.
2314 (SVE_VQ_MIN): Likewise.
2315 (SVE_VQ_MAX): Likewise.
2316 (SVE_VL_MIN): Likewise.
2317 (SVE_VL_MAX): Likewise.
2318 (SVE_NUM_ZREGS): Likewise.
2319 (SVE_NUM_PREGS): Likewise.
2320 (sve_vl_valid): Likewise.
2321 (struct user_sve_header): Likewise.
2322
7010835a
AB
23232018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
2324 Richard Bunt <Richard.Bunt@arm.com>
2325
2326 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
2327 was requested by GDB.
2328
479b3ef4
TV
23292018-06-15 Tom de Vries <tdevries@suse.de>
2330
2331 * MAINTAINERS (Write After Approval): Add Tom de Vries.
2332
8199b8f4
SM
23332018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
2334
2335 * gnulib/update-gnulib.sh: Print expected versions of
2336 autoconf/aclocal.
2337
55c748a1
SM
23382018-06-14 Simon Marchi <simon.marchi@ericsson.com>
2339
2340 * arch-utils.c (default_type_align): Use type_length_units.
2341 * gdbtypes.c (type_align): Use type_length_units.
2342
87a8eca7
PW
23432018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2344
2345 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
2346 of 'define' command.
2347
5d9a0608
TV
23482018-06-14 Tom de Vries <tdevries@suse.de>
2349
2350 PR cli/22573
2351 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
2352 get_no_prettyformat_print_options.
2353
ab89b5a5
SM
23542018-06-13 Simon Marchi <simon.marchi@ericsson.com>
2355
2356 * sparc-nat.h: Include target.h.
2357 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
2358 <fetch_registers>: Remove this argument in function call.
2359 <store_registers>: Remove this argument in function call, remove
2360 extra semicolon.
2361 <low_forget_process>: Call sparc64_forget_process instead of
2362 sparc_forget_process.
2363
62c808ae
RO
23642018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2365
2366 * procfs.c (_initialize_procfs): Use add_inf_child_target.
2367 (procfs_target::make_corefile_notes): Adjust to new
2368 target_read_alloc return type.
2369
1840d81a
AB
23702018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2371 Stephen Roberts <stephen.roberts@arm.com>
2372
2373 PR gdb/22882
2374 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
2375 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
2376 Move should_notify_stop local into more inner scope.
2377
9516f85a
AB
23782018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2379 Stephen Roberts <stephen.roberts@arm.com>
2380
2381 PR gdb/22882
2382 * infrun.c (resume_1): Add call to mark_async_event_handler.
2383
defd2172
AB
23842018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2385
2386 * infrun.c (do_target_wait): Change old version of $pc printed.
2387
7b23e087
SM
23882018-06-11 Simon Marchi <simon.marchi@ericsson.com>
2389
2390 * dwarf2read.c (read_index_from_section): Rename to...
2391 (read_gdb_index_from_section): ... this, update all callers.
2392 (dwarf2_read_index): Rename to...
2393 (dwarf2_read_gdb_index): ... this, update all callers.
2394
69c67a0b
JDA
23952018-06-11 John David Anglin <danglin@gcc.gnu.org>
2396
2397 * gdb/hppa-linux-nat.c
2398 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
2399 hppa_linux_nat_target::fetch_registers.
2400
65d4cada
AH
24012018-06-11 Alan Hayward <alan.hayward@arm.com>
2402
2403 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
2404 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
2405 (AARCH64_DWARF_SVE_FFR): Likewise.
2406 (AARCH64_DWARF_SVE_P0): Likewise.
2407 (AARCH64_DWARF_SVE_Z0): Likewise.
2408
f868386e
AH
24092018-06-11 Alan Hayward <alan.hayward@arm.com>
2410
2411 * common/common-regcache.h (raw_compare): New function.
2412 * regcache.c (regcache::raw_compare): Likewise.
2413 * regcache.h (regcache::raw_compare): New declaration.
2414
9c861883
AH
24152018-06-11 Alan Hayward <alan.hayward@arm.com>
2416
2417 * common/common-regcache.h (reg_buffer_common): New structure.
2418 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
2419 (reg_buffer::raw_supply): Likewise.
2420 (reg_buffer::raw_supply_integer): Likewise.
2421 (reg_buffer::raw_supply_zeroed): Likewise.
2422 (reg_buffer::raw_collect): Likewise.
2423 (reg_buffer::raw_collect_integer): Likewise.
2424 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
2425 (reg_buffer::raw_supply): Likewise.
2426 (reg_buffer::raw_supply_integer): Likewise.
2427 (reg_buffer::raw_supply_zeroed): Likewise.
2428 (reg_buffer::raw_collect): Likewise.
2429 (reg_buffer::raw_collect_integer): Likewise.
2430
953edf2b
TT
24312018-06-10 Tom Tromey <tom@tromey.com>
2432
2433 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
2434 (class remote_state) <stop_reply_queue>: Now std::vector.
2435 (remote_state::~remote_state)
2436 (remote_target::stop_reply_queue_length): Update.
2437 (struct queue_iter_param, remove_child_of_pending_fork)
2438 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
2439 (check_pending_event_prevents_wildcard_vcont_callback)
2440 (remove_stop_reply_for_inferior)
2441 (remove_stop_reply_of_remote_state)
2442 (remote_notif_remove_once_on_match)
2443 (stop_reply_match_ptid_and_ws)
2444 (remote_kill_child_of_pending_fork): Remove.
2445 (remote_target::remove_new_fork_children)
2446 (remote_target::check_pending_events_prevent_wildcard_vcont)
2447 (remote_target::discard_pending_stop_replies)
2448 (remote_target::discard_pending_stop_replies_in_queue)
2449 (remote_target::remote_notif_remove_queued_reply)
2450 (remote_target::queued_stop_reply)
2451 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
2452 (remote_target::wait, remote_target::kill_new_fork_children)
2453 (remote_target::async): Update.
2454
1ddbba9d
TT
24552018-06-10 Tom Tromey <tom@tromey.com>
2456
2457 * record-full.c (record_full_arch_list_cleanups): Remove.
2458 (record_full_message): Use try/catch.
2459 (record_full_wait_cleanups): Remove.
2460 (record_full_wait_1): Use try/catch.
2461 (record_full_restore): Likewise.
2462
219605fd
TT
24632018-06-10 Tom Tromey <tom@tromey.com>
2464
2465 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
2466 declare VEC. Add constructor.
2467 <in_target_beneath>: Now bool.
2468 (record_full_breakpoints): Now a std::vector, static.
2469 (record_full_sync_record_breakpoints)
2470 (record_full_init_record_breakpoints)
2471 (record_full_target::insert_breakpoint)
2472 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
2473
71b73764
SM
24742018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
2475
2476 * dwarf2read.c (process_cu_includes): Remove struct keyword.
2477 * serial.c (serial_interface_lookup): Remove struct keyword.
2478
4360561f
TT
24792018-06-10 Tom Tromey <tom@tromey.com>
2480
2481 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
2482 method.
2483 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
2484 a method.
2485 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
2486 method.
2487 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
2488 "beneath" as a method.
2489 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
2490 Use "beneath" as a method.
2491
d14b92bf
TT
24922018-06-10 Tom Tromey <tom@tromey.com>
2493
2494 * tracefile.c (struct trace_file_writer_deleter): New.
2495 <operator()>: Rename from trace_file_writer_xfree.
2496 (trace_file_writer_up): New typedef.
2497 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
2498
835dcf92
SM
24992018-06-09 Simon Marchi <simon.marchi@ericsson.com>
2500
2501 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
2502 <m_registers, m_register_status>: Change type to
2503 std::unique_ptr.
2504 * regcache.c (reg_buffer::reg_buffer): Use new instead of
2505 XCNEWVEC.
2506
aac0d564
SM
25072018-06-09 Simon Marchi <simon.marchi@ericsson.com>
2508
2509 * common/common-regcache.h (enum register_status): Add
2510 underlying type "signed char".
2511 * regcache.h (reg_buffer) <m_register_status>: Change type to
2512 register_status *.
2513 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
2514 register_status instead of signed char.
2515 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
2516 (reg_buffer::get_register_status): Remove cast.
2517 (readable_regcache::raw_read): Remove cast.
2518 (readable_regcache::cooked_read): Remove cast.
2519
77ad7394
TT
25202018-06-09 Tom Tromey <tom@tromey.com>
2521
2522 * source.c (reverse_search_command, forward_search_command): Use
2523 scoped_fd.
2524
191cca63
TT
25252018-06-09 Tom Tromey <tom@tromey.com>
2526
2527 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
2528 (serial_ops_list): Now static, std::vector.
2529 (serial_interface_lookup, serial_add_interface): Update.
2530
c5d0225d
TT
25312018-06-09 Tom Tromey <tom@tromey.com>
2532
2533 * dwarf2read.c (process_cu_includes): Update.
2534 (process_full_comp_unit): Update.
2535 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
2536 std::vector.
2537
aeab5128
PK
25382018-06-08 Paul Koning <paul_koning@dell.com>
2539
2540 PR gdb/23252
2541
2542 * python/python.c (do_start_initialization):
2543 Avoid call to internal Python API.
2544 (init__gdb_module): New function.
2545
5045b3d7
GB
25462018-06-08 Gary Benson <gbenson@redhat.com>
2547
2548 * linux-thread-db.c (valprint.h): New include.
2549 (struct check_thread_db_info): New structure.
2550 (check_thread_db_on_load, tdb_testinfo): New static globals.
2551 (check_thread_db, check_thread_db_callback): New functions.
2552 (try_thread_db_load_1): Run integrity checks if requested.
2553 (maintenance_check_libthread_db): New function.
2554 (_initialize_thread_db): Register "maint check libthread-db"
2555 and "maint set/show check-libthread-db".
2556 * NEWS: Mention the above new commands.
2557
2f4f025f
TT
25582018-06-08 Tom Tromey <tom@tromey.com>
2559
2560 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
2561 now a method.
2562
343b0027
TT
25632018-06-08 Tom Tromey <tom@tromey.com>
2564
2565 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
2566
8dcc53b3
TT
25672018-06-08 Tom Tromey <tom@tromey.com>
2568
2569 * common/btrace-common.h (struct btrace_data): Add constructor,
2570 destructor, move assignment operator.
2571 <empty, clear, fini>: New methods.
2572 <format>: Initialize.
2573 (btrace_data_init, btrace_data_fini, btrace_data_clear)
2574 (btrace_data_empty): Don't declare.
2575 * common/btrace-common.c (btrace_data_init): Remove.
2576 (btrace_data::fini): Rename from btrace_data_fini.
2577 (btrace_data::empty): Rename from btrace_data_empty.
2578 (btrace_data::clear): Rename from btrace_data_clear. Return
2579 bool.
2580 * btrace.h (make_cleanup_btrace_data): Don't declare.
2581 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
2582 (parse_xml_btrace): Update.
2583 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
2584 (maint_btrace_clear_packet_history_cmd): Update.
2585
a1740ee1
PA
25862018-06-07 Pedro Alves <palves@redhat.com>
2587
2588 * target.h (target_ops) <beneath>: Now a method. All references
2589 updated.
2590 (class target_stack): New.
2591 * target.c (g_target_stack): New.
2592 (g_current_top_target): Delete.
2593 (current_top_target): Get the top target out of g_target_stack.
2594 (target_stack::push, target_stack::unpush): New.
2595 (push_target, unpush_target): Reimplement.
2596 (target_is_pushed): Reimplement in terms of g_target_stack.
2597 (target_ops::beneath, target_stack::find_beneath): New.
2598
d6ca69cd
PA
25992018-06-07 Pedro Alves <palves@redhat.com>
2600
2601 * target.h (find_target_beneath): Delete declaration.
2602 * target.c (find_target_beneath): Delete definition.
2603 * aix-thread.c: All callers of find_target_beneath adjusted to
2604 call target_ops::beneath instead.
2605 * bsd-uthread.c: Likewise.
2606 * linux-thread-db.c: Likewise.
2607 * ravenscar-thread.c: Likewise.
2608 * sol-thread.c: Likewise.
2609 * spu-multiarch.c: Likewise.
2610
b6a8c27b
PA
26112018-06-07 Pedro Alves <palves@redhat.com>
2612
2613 * target.h (target_ops) <beneath>: Now a method. All references
2614 updated.
2615 (target_ops) <m_beneath>: New.
2616 * target.c (target_ops::beneath): New.
2617 * corelow.c: Adjust all references to target_ops::beneath.
2618 * linux-thread-db.c: Likewise.
2619 * make-target-delegates: Likewise.
2620 * record-btrace.c: Likewise.
2621 * record-full.c: Likewise.
2622 * remote.c: Likewise.
2623 * target.c: Likewise.
2624 * target-delegates.c: Regenerate.
2625
8b88a78e
PA
26262018-06-07 Pedro Alves <palves@redhat.com>
2627
2628 * target.h (target_stack): Delete.
2629 (current_top_target): Declare function.
2630 * target.c (target_stack): Delete.
2631 (g_current_top_target): New.
2632 (current_top_target): New function.
2633 * auxv.c: Use current_top_target instead of target_stack
2634 throughout.
2635 * avr-tdep.c: Likewise.
2636 * breakpoint.c: Likewise.
2637 * corefile.c: Likewise.
2638 * elfread.c: Likewise.
2639 * eval.c: Likewise.
2640 * exceptions.c: Likewise.
2641 * frame.c: Likewise.
2642 * gdbarch-selftests.c: Likewise.
2643 * gnu-v3-abi.c: Likewise.
2644 * ia64-tdep.c: Likewise.
2645 * ia64-vms-tdep.c: Likewise.
2646 * infcall.c: Likewise.
2647 * infcmd.c: Likewise.
2648 * infrun.c: Likewise.
2649 * linespec.c: Likewise.
2650 * linux-tdep.c: Likewise.
2651 * minsyms.c: Likewise.
2652 * ppc-linux-nat.c: Likewise.
2653 * ppc-linux-tdep.c: Likewise.
2654 * procfs.c: Likewise.
2655 * regcache.c: Likewise.
2656 * remote.c: Likewise.
2657 * rs6000-tdep.c: Likewise.
2658 * s390-linux-nat.c: Likewise.
2659 * s390-tdep.c: Likewise.
2660 * solib-aix.c: Likewise.
2661 * solib-darwin.c: Likewise.
2662 * solib-dsbt.c: Likewise.
2663 * solib-spu.c: Likewise.
2664 * solib-svr4.c: Likewise.
2665 * solib-target.c: Likewise.
2666 * sparc-tdep.c: Likewise.
2667 * sparc64-tdep.c: Likewise.
2668 * spu-tdep.c: Likewise.
2669 * symfile.c: Likewise.
2670 * symtab.c: Likewise.
2671 * target-descriptions.c: Likewise.
2672 * target-memory.c: Likewise.
2673 * target.c: Likewise.
2674 * target.h: Likewise.
2675 * tracefile-tfile.c: Likewise.
2676 * tracepoint.c: Likewise.
2677 * valops.c: Likewise.
2678 * valprint.c: Likewise.
2679 * value.c: Likewise.
2680 * windows-tdep.c: Likewise.
2681 * mi/mi-main.c: Likewise.
2682
c7110220
TT
26832018-06-07 Tom Tromey <tom@tromey.com>
2684
2685 * valprint.h (build_address_symbolic): Declare.
2686 * printcmd.c (print_address_symbolic): Update.
2687 (build_address_symbolic): Change "name" and "filename" to
2688 std::string.
2689 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
2690 Update.
2691 * defs.h (build_address_symbolic): Remove declaration.
2692
63bad7b6
AH
26932018-06-07 Alan Hayward <alan.hayward@arm.com>
2694
2695 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
2696 (aarch64_vnv_type): Add function.
2697 (aarch64_pseudo_register_name): Add V regs for SVE.
2698 (aarch64_pseudo_register_type): Likewise.
2699 (aarch64_pseudo_register_reggroup_p): Likewise.
2700 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
2701 (aarch64_pseudo_read_value): Add V regs for SVE.
2702 (aarch64_pseudo_write_2): Use V0 offset for SVE
2703 (aarch64_pseudo_write): Add V regs for SVE.
2704 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
2705
13e3c608
SDJ
27062018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
2707
2708 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
2709 (sve_vl_from_vq): Likewise.
2710
c61b06a1
TT
27112018-06-05 Tom Tromey <tom@tromey.com>
2712
2713 * cli/cli-cmds.c (show_version): Update.
2714 * top.c (print_gdb_version): Add "interactive" parameter.
2715 Update.
2716 * main.c (captured_main_1): Update.
2717 * top.h (print_gdb_version): Add "interactive" parameter and a
2718 comment.
2719
115f7325
DM
27202018-06-05 David Malcolm <dmalcolm@redhat.com>
2721
2722 * common/enum-flags.h: Add trailing semicolon to example in
2723 comment.
2724
eb6af809
TT
27252018-06-05 Tom Tromey <tom@tromey.com>
2726
2727 PR cli/12326:
2728 * NEWS: Add entry about pager.
2729 * utils.c (pagination_disabled_for_command): New global.
2730 (prompt_for_continue): Allow "c" response to prompt.
2731 (reinitialize_more_filter): Clear
2732 pagination_disabled_for_command.
2733 (fputs_maybe_filtered): Check pagination_disabled_for_command.
2734
54d343a2
TT
27352018-06-04 Tom Tromey <tom@tromey.com>
2736
2737 * ada-lang.h (ada_lookup_symbol_list): Update.
2738 * ada-lang.c (resolve_subexp): Update.
2739 (symbols_are_identical_enums): Change type of syms. Remove nsyms
2740 parameter.
2741 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
2742 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
2743 results parameter to std::vector.
2744 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
2745 Update.
2746 * ada-exp.y (block_lookup): Update.
2747 (select_possible_type_sym): Change type of syms. Remove nsyms
2748 parameter.
2749 (write_var_or_type, write_name_assoc): Update.
2750
178d6a63
JB
27512018-06-04 Joel Brobecker <brobecker@adacore.com>
2752
2753 * windows-nat.c (windows_nat_target::xfer_partial): Return
2754 TARGET_XFER_E_IO if we need to delegate to the target beneath
2755 but BENEATH is NULL.
2756
baf00c2d
SM
27572018-06-04 Simon Marchi <simon.marchi@ericsson.com>
2758
2759 * Makefile.in (config.status): Add configure.nat as a
2760 dependency.
2761
214b073c
TT
27622018-06-04 Tom Tromey <tom@tromey.com>
2763
2764 * cp-name-parser.y (cpname_state): Add method declarations.
2765 (HANDLE_QUAL): Update.
2766 (cpname_state::d_grab, cpname_state::fill_comp)
2767 (cpname_state::make_operator, cpname_state::make_dtor)
2768 (cpname_state::make_builtin_type, cpname_state::make_name)
2769 (cpname_state::d_qualify, cpname_state::d_int_type)
2770 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
2771 (%union): Move earlier.
2772
62b74cb8
AH
27732018-06-04 Alan Hayward <alan.hayward@arm.com>
2774
2775 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
2776
3c5cd5c3
AH
27772018-06-04 Alan Hayward <alan.hayward@arm.com>
2778
2779 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
2780 (aarch64_pseudo_write_1): Likewise.
2781 (aarch64_pseudo_read_value): Use helper.
2782 (aarch64_pseudo_write): Likewise.
2783
59f413d5
PA
27842018-06-04 Pedro Alves <palves@redhat.com>
2785
2786 * darwin-nat.c (darwin_ops): Delete.
2787 (darwin_attach_pid): Use get_native_target.
2788
1332a140
AH
27892018-06-04 Alan Hayward <alan.hayward@arm.com>
2790
2791 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
2792 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
2793
ba2d2bb2
AH
27942018-06-04 Alan Hayward <alan.hayward@arm.com>
2795
2796 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
2797 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
2798 (aarch64_gdbarch_init): Check for SVE.
2799 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
2800
28012018-06-04 Alan Hayward <alan.hayward@arm.com>
39bfb937
AH
2802
2803 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
2804 * aarch64-tdep.h (aarch64_read_description): Likewise.
2805 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2806 * arch/aarch64.h (aarch64_create_target_description): Likewise.
2807 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
2808 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
2809 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
2810
41c60b4b
SM
28112018-06-02 Simon Marchi <simon.marchi@ericsson.com>
2812
2813 * value.c (value_fetch_lazy_bitfield): New.
2814 (value_fetch_lazy_memory): New.
2815 (value_fetch_lazy_register): New.
2816 (value_fetch_lazy): Factor out to smaller functions.
2817
7b640f72
TT
28182018-06-01 Tom Tromey <tom@tromey.com>
2819
2820 * cp-name-parser.y (backslashable, represented): Now const.
2821
98e69eb3
TT
28222018-06-01 Tom Tromey <tom@tromey.com>
2823
2824 * cp-name-parser.y: Include parser-defs.h.
2825 (parser_fprintf): Remove declaration.
2826
49265499
TT
28272018-06-01 Tom Tromey <tom@tromey.com>
2828
2829 * cp-name-parser.y: Use %pure-parser, %lex-param, and
2830 %parse-param.
2831 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
2832 (global_result): Remove globals.
2833 (struct cpname_state): New.
2834 (yyparse): Don't declare.
2835 (yylex, yyerror): Move declarations after %union.
2836 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
2837 (make_name): Add state parameter.
2838 Update all callers.
2839 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
2840 parameter.
2841 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
2842 Update.
2843 (yylex): Add lvalp, state parameters.
2844 (yyerror): Add state parameter.
2845 (cp_demangled_name_to_comp): Update.
2846
55b6c984
TT
28472018-06-01 Tom Tromey <tom@tromey.com>
2848
2849 * cp-name-parser.y (parser_fprintf): Declare.
2850 (GDB_YY_REMAP_PREFIX): Define.
2851 Include yy-remap.h. Don't redefine yy* identifiers.
2852
3513a6bb
TT
28532018-06-01 Tom Tromey <tom@tromey.com>
2854
2855 * python/py-type.c (typy_legacy_template_argument): Update.
2856 * cp-support.h (cp_demangled_name_to_comp): Update.
2857 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
2858 parameter to be a "std::string *".
2859 (main): Update.
2860
e9cb46ab
L
28612018-06-01 H.J. Lu <hongjiu.lu@intel.com>
2862
2863 * ada-lex.l: Include "diagnostics.h" instead of
2864 "common/diagnostics.h".
2865 * unittests/environ-selftests.c: Likewise.
2866 * common/diagnostics.h: Moved to ../include.
2867
8e817061
JB
28682018-06-01 Joel Brobecker <brobecker@adacore.com>
2869
2870 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
2871 to language_mode_manual while calling breakpoint_re_set_one.
2872
a737d952
TT
28732018-06-01 Tom Tromey <tom@tromey.com>
2874
2875 * valops.c (value_cast_structs, destructor_name_p): Update.
2876 * symtab.c (gdb_mangle_name): Update.
2877 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
2878 Update.
2879 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
2880 (pascal_object_print_value_fields, pascal_object_print_value):
2881 Update.
2882 * p-typeprint.c (pascal_type_print_derivation_info): Update.
2883 * linespec.c (find_methods): Update.
2884 * gdbtypes.h (type_name_no_tag): Remove.
2885 (type_name_or_error): Rename from type_name_no_tag_or_error.
2886 * gdbtypes.c (type_name_no_tag): Remove.
2887 (type_name_or_error): Rename from type_name_no_tag_or_error.
2888 (lookup_struct_elt_type, check_typedef): Update.
2889 * expprint.c (print_subexp_standard): Update.
2890 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
2891 * d-namespace.c (d_lookup_nested_symbol): Update.
2892 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
2893 (cp_print_class_member): Update.
2894 * cp-namespace.c (cp_lookup_nested_symbol): Update.
2895 * completer.c (add_struct_fields): Update.
2896 * c-typeprint.c (cp_type_print_derivation_info)
2897 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
2898 Update.
2899 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
2900 (ada_prefer_type, ada_is_exception_sym): Update.
2901
e86ca25f
TT
29022018-06-01 Tom Tromey <tom@tromey.com>
2903
2904 * valops.c (enum_constant_from_type, value_namespace_elt)
2905 (value_maybe_namespace_elt): Update.
2906 * valarith.c (find_size_for_pointer_math): Update.
2907 * target-descriptions.c (make_gdb_type): Update.
2908 * symmisc.c (print_symbol): Update.
2909 * stabsread.c (define_symbol, read_type)
2910 (complain_about_struct_wipeout, add_undefined_type)
2911 (cleanup_undefined_types_1): Update.
2912 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
2913 (rust_range_type_p, val_print_struct, rust_print_struct_def)
2914 (rust_internal_print_type, rust_composite_type)
2915 (rust_evaluate_funcall, rust_evaluate_subexp)
2916 (rust_inclusive_range_type_p): Update.
2917 * python/py-type.c (typy_get_tag): Update.
2918 * p-typeprint.c (pascal_type_print_base): Update.
2919 * mdebugread.c (parse_symbol, parse_type): Update.
2920 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
2921 Update.
2922 * guile/scm-type.c (gdbscm_type_tag): Update.
2923 * go-lang.c (sixg_string_p): Update.
2924 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
2925 Update.
2926 * gdbtypes.h (struct main_type) <tag_name>: Remove.
2927 (TYPE_TAG_NAME): Remove.
2928 * gdbtypes.c (type_name_no_tag): Simplify.
2929 (check_typedef, check_types_equal, recursive_dump_type)
2930 (copy_type_recursive, arch_composite_type): Update.
2931 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
2932 in summary mode when needed.
2933 * eval.c (evaluate_funcall): Update.
2934 * dwarf2read.c (fixup_go_packaging, read_structure_type)
2935 (process_structure_scope, read_enumeration_type)
2936 (read_namespace_type, read_module_type, determine_prefix): Update.
2937 * cp-support.c (inspect_type): Update.
2938 * coffread.c (process_coff_symbol, decode_base_type): Update.
2939 * c-varobj.c (c_is_path_expr_parent): Update.
2940 * c-typeprint.c (c_type_print_base_struct_union): Update.
2941 (c_type_print_base_1): Update. Print struct/class/union/enum in
2942 summary when using C language.
2943 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
2944 (gen_maybe_namespace_elt): Update.
2945 * ada-lang.c (ada_type_name): Simplify.
2946 (empty_record, ada_template_to_fixed_record_type_1)
2947 (template_to_static_fixed_type)
2948 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
2949
c1ec8cea
TT
29502018-06-01 Tom Tromey <tom@tromey.com>
2951
2952 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
2953 c_print_type.
2954 * c-typeprint.c (c_print_type_1): Add "language" parameter.
2955 (c_print_type): Update.
2956 (c_print_type): New overload.
2957 (c_type_print_varspec_prefix, c_type_print_args)
2958 (c_type_print_varspec_suffix, c_print_type_no_offsets)
2959 (c_type_print_base_struct_union, c_type_print_base_1)
2960 (cp_type_print_method_args): Add "language" parameter.
2961 (c_type_print_base): Update.
2962 * c-lang.h (c_print_type): Add new overload.
2963
bc8453a7
TT
29642018-06-01 Tom Tromey <tom@tromey.com>
2965
2966 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
2967 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
2968
739e8682
AH
29692018-06-01 Alan Hayward <alan.hayward@arm.com>
2970
2971 * aarch64-tdep.c (aarch64_sve_register_names): New const
2972 var.
2973 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
2974 (AARCH64_SVE_Z_REGS_NUM): New define.
2975 (AARCH64_SVE_P_REGS_NUM): Likewise.
2976 (AARCH64_SVE_NUM_REGS): Likewise.
2977
8a60efe7
UB
29782018-05-31 Uros Bizjak <ubizjak@gmail.com>
2979
2980 * nat/linux-ptrace.h [__alpha__]
2981 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
2982 definitions.
2983
4b2dfa9d
MR
29842018-05-31 Maciej W. Rozycki <macro@mips.com>
2985
2986 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
2987 the endianness selected.
2988 * NEWS: Document `set endian auto' mode operation update.
2989
122394f1
AH
29902018-05-31 Alan Hayward <alan.hayward@arm.com>
2991
2992 * Makefile.in: Add new header.
2993 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
2994 (sve_vl_from_vg): Likewise.
2995 (sve_vq_from_vl): Likewise.
2996 (sve_vl_from_vq): Likewise.
2997 (sve_vq_from_vg): Likewise.
2998 (sve_vg_from_vq): Likewise.
2999 * configure.nat: Add new c file.
3000 * nat/aarch64-sve-linux-ptrace.c: New file.
3001 * nat/aarch64-sve-linux-ptrace.h: New file.
3002
95228a0d
AH
30032018-05-31 Alan Hayward <alan.hayward@arm.com>
3004
3005 * aarch64-linux-nat.c (aarch64_linux_read_description):
3006 Add parmeter zero.
3007 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
3008 Likewise.
3009 * aarch64-tdep.c (tdesc_aarch64_list): Add.
3010 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
3011 (aarch64_gdbarch_init): Add parmeter zero.
3012 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
3013 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
3014 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
3015 parmeter.
3016 * doc/gdb.texinfo: Describe SVE feature
3017 * features/aarch64-sve.c: New file.
3018
5969f0db
OJ
30192018-05-31 Omair Javaid <omair.javaid@linaro.org>
3020
3021 PR gdb/23210
3022 * gdbarch.sh (significant_addr_bit): Default to zero when
3023 not set by target architecture.
3024 * gdbarch.c: Re-generated.
3025 * utils.c (address_significant): Update.
3026
61367c61
JB
30272018-05-30 Joel Brobecker <brobecker@adacore.com>
3028
3029 * stack.c (func_command): Remove trailing newline in call to error.
3030
34a79281
SM
30312018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3032
3033 * regcache.h (regcache_raw_collect): Remove, update callers to
3034 use regcache::raw_collect.
3035 * regcache.c (regcache_raw_collect): Remove.
3036
73e1c03f
SM
30372018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3038
3039 * regcache.h (regcache_raw_supply): Remove, update callers to
3040 use detached_regcache::raw_supply.
3041 * regcache.c (regcache_raw_supply): Remove.
3042
e4c4a59b
SM
30432018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3044
3045 * regcache.h (regcache_cooked_write_part): Remove, update
3046 callers to use regcache::cooked_write_part.
3047 * regcache.c (regcache_cooked_write_part): Remove.
3048
73bb0000
SM
30492018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3050
3051 * regcache.h (regcache_cooked_read_part): Remove, update callers
3052 to use readable_regcache::cooked_read_part.
3053 * regcache.c (regcache_cooked_read_part): Remove.
3054
46a45e9d
SM
30552018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3056
3057 * regcache.h (regcache_cooked_read_value): Remove, update
3058 callers to use readable_regcache::cooked_read_value.
3059 * regcache.c (regcache_cooked_read_value): Remove.
3060
b66f5587
SM
30612018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3062
3063 * regcache.h (regcache_cooked_write): Remove, update callers to
3064 use regcache::cooked_write.
3065 * regcache.c (regcache_cooked_write): Remove.
3066
6aa7d724
SM
30672018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3068
3069 * regcache.h (regcache_invalidate): Remove, update callers to
3070 use detached_regcache::invalidate instead.
3071 * regcache.c (regcache_invalidate): Remove.
3072
4f0420fd
SM
30732018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3074
3075 * regcache.h (regcache_raw_write_part): Remove, update callers
3076 to use regcache::raw_write_part instead.
3077 * regcache.c (regcache_raw_write_part): Remove.
3078
502fe83e
SM
30792018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3080
3081 * regcache.h (regcache_raw_read_part): Remove, update callers to
3082 use readable_regcache::raw_read_part instead.
3083 * regcache.c (regcache_raw_read_part): Remove.
3084
dca08e1f
SM
30852018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3086
3087 * regcache.h (regcache_cooked_read): Remove, update callers to
3088 use readable_regcache::cooked_read instead.
3089 * regcache.c (regcache_cooked_read): Remove.
3090
10eaee5f
SM
30912018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3092
3093 * regcache.h (regcache_raw_write): Remove, update callers to use
3094 regcache::raw_write instead.
3095 * regcache.c (regcache_raw_write): Remove.
3096
0b883586
SM
30972018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3098
3099 * regcache.h (regcache_raw_read): Remove, update callers to use
3100 readable_regcache::raw_read instead.
3101 * regcache.c (regcache_raw_read): Remove.
3102
0b47d985
SM
31032018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3104
3105 * regcache.h (regcache_raw_update): Remove, update callers to
3106 use readable_regcache::raw_update instead.
3107 * regcache.c (regcache_raw_update): Remove.
3108
0ec9f114
SM
31092018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3110
3111 * regcache.h (regcache_register_status): Remove, update callers
3112 to use reg_buffer::get_register_status directly instead.
3113 * regcache.c (regcache_register_status): Remove.
3114
222312d3
SM
31152018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3116
3117 * regcache.h (regcache_get_ptid): Remove, update all callers to
3118 call regcache::ptid instead.
3119 * regcache.c (regcache_get_ptid): Remove.
3120
fdbe37e3
SM
31212018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3122
3123 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
3124
f7c6f423
PA
31252018-05-30 Pedro Alves <palves@redhat.com>
3126
3127 * common/common-exceptions.h (exception_rethrow): Use
3128 ATTRIBUTE_NORETURN.
3129
52941706
SM
31302018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
3131
3132 * breakpoint.c (print_solib_event, check_status_catch_solib):
3133 Remove struct keyword in range-based for loops.
3134 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
3135 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
3136 Likewise.
3137 * linespec.c (find_superclass_methods, search_minsyms_for_name):
3138 Likewise.
3139 * symfile.c (addr_info_make_relative): Likewise.
3140 * thread.c (value_in_thread_stack_temporaries): Likewise.
3141
bf2977b5
WP
31422018-06-12 Weimin Pan <weimin.pan@oracle.com>
3143
3144 PR gdb/16841
3145 * valops.c (value_struct_elt_for_reference): Call check_typedef on
3146 aggregate type to get its real type before accessing it.
3147
64cc34d8
WP
31482018-05-29 Weimin Pan <weimin.pan@oracle.com>
3149
3150 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
3151 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
3152 * coff-pe-read.c (add_pe_forwarded_sym): Replace
3153 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
3154 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
3155 * jit.c (jit_breakpoint_re_set_internal): Likewise.
3156 * printcmd.c (info_address_command): Likewise.
3157
e7ec8713
TT
31582018-05-29 Tom Tromey <tom@tromey.com>
3159
3160 * windows-nat.c (handle_exception): Update fall-through comment.
3161
bcb430e4
TT
31622018-05-29 Tom Tromey <tom@tromey.com>
3163
3164 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
3165 (struct program_space) <added_solibs>: Now a std::vector.
3166 * breakpoint.c (print_solib_event): Update.
3167 (check_status_catch_solib): Update.
3168 * progspace.c (clear_program_space_solib_cache): Update.
3169 * solib.c (update_solib_list): Update.
3170
894882e3
TT
31712018-05-29 Tom Tromey <tom@tromey.com>
3172
3173 * python/py-type.c (typy_richcompare): Update.
3174 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
3175 * gdbtypes.h (types_deeply_equal): Return bool.
3176 (types_equal): Likewise.
3177 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
3178 declare VEC.
3179 (check_types_equal): Change worklist to std::vector. Return
3180 bool.
3181 (struct type_equality_entry): Add constructor.
3182 (compare_maybe_null_strings): Return bool.
3183 (check_types_worklist): Return bool. Change worklist to
3184 std::vector.
3185 (types_deeply_equal): Use std::vector.
3186 (types_equal): Return bool.
3187 (compare_maybe_null_strings): Simplify.
3188
10b2ded4
TT
31892018-05-29 Tom Tromey <tom@tromey.com>
3190
3191 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
3192
4f7deebe
TT
31932018-05-29 Tom Tromey <tom@tromey.com>
3194
3195 * objc-lang.h: Don't include cp-support.h.
3196 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
3197 declare VEC.
3198
b8283aea
TT
31992018-05-27 Tom Tromey <tom@tromey.com>
3200
3201 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
3202
41a883c8
TT
32032018-05-25 Tom Tromey <tom@tromey.com>
3204
3205 * value.c (value::location): Initialize.
3206
bf259e25
TT
32072018-05-25 Tom Tromey <tom@tromey.com>
3208
3209 * dbxread.c (init_bincl_list): Remove.
3210 (bincl_list): Now a std::vector.
3211 (bincls_allocated, next_bincl): Remove.
3212 (free_bincl_list, do_free_bincl_list_cleanup)
3213 (make_cleanup_free_bincl_list): Remove.
3214 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
3215 unique_xmalloc_ptr.
3216 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
3217 (struct header_file_location): Add constructor.
3218 (add_bincl_to_list): Remove.
3219
d525a99b
TT
32202018-05-25 Tom Tromey <tom@tromey.com>
3221
3222 * tui/tui.c (tui_enable): Update.
3223 * mi/mi-interp.c (mi_interp::init): Update.
3224 * interps.h (class interp) <name>: New method.
3225 <m_name>: Rename from name.
3226 (~scoped_restore_interp): Update.
3227 * interps.c (interp::interp): Update.
3228 (interp_add, interp_set, interp_lookup_existing)
3229 (current_interp_named_p): Update.
3230
da505cff
TT
32312018-05-25 Tom Tromey <tom@tromey.com>
3232
3233 * interps.c (interp_name): Remove.
3234 * mi/mi-interp.c (mi_interp::init): Update.
3235 * interps.h (interp_name): Remove.
3236 (~scoped_restore_interp): Update.
3237 * tui/tui.c (tui_enable): Update.
3238
29f94340
TT
32392018-05-25 Tom Tromey <tom@tromey.com>
3240
3241 * utils.c (fputs_maybe_filtered): Update.
3242 * linespec.c (decode_line_full): Update.
3243 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
3244 (mi_print_breakpoint_for_event, mi_solib_loaded)
3245 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3246 (mi_user_selected_context_changed): Update.
3247 * mi/mi-main.c (mi_execute_command): Update.
3248 * cli/cli-script.c (execute_control_command): Update.
3249 * python/python.c (execute_gdb_command): Update.
3250 * solib.c (info_sharedlibrary_command): Update.
3251 * interps.c (interp_ui_out): Remove.
3252 * interps.h (interp_ui_out): Remove.
3253
716b8bc5
TT
32542018-05-25 Tom Tromey <tom@tromey.com>
3255
3256 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
3257 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
3258 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
3259
753ff9bd
TT
32602018-05-25 Tom Tromey <tom@tromey.com>
3261
3262 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
3263 * interps.c (interp_exec): Use scoped_restore.
3264
5ca3b260
TT
32652018-05-25 Tom Tromey <tom@tromey.com>
3266
3267 * remote.c (remote_target::remote_file_get): Use
3268 gdb::byte_vector.
3269 (remote_target::remote_file_put): Likewise.
3270
3173aa2f
TT
32712018-05-25 Tom Tromey <tom@tromey.com>
3272
3273 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
3274 a std::string.
3275 (get_pe_section_index, add_pe_exported_sym): Update.
3276 (read_pe_exported_syms): Use gdb::def_vector.
3277
09a5e1b5
TT
32782018-05-25 Tom Tromey <tom@tromey.com>
3279
3280 * frame.c (remove_prev_frame): Remove.
3281 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
3282
d8dab6c3
MR
32832018-05-25 Maciej W. Rozycki <macro@mips.com>
3284
3285 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
3286 Remove prototypes.
3287 * mips-linux-nat.c (supply_fpregset): Always call
3288 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
3289 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
3290 `mips_fill_fpregset'.
3291 * mips-linux-tdep.c (mips_supply_fpregset)
3292 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
3293 (mips_fill_fpregset_wrapper): Remove functions.
3294 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
3295 (mips_linux_fpregset): Remove variable.
3296 (mips_linux_iterate_over_regset_sections): Use
3297 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
3298 (mips_linux_o32_sigframe_init): Remove comment.
3299
3c69da40
PA
33002018-05-25 Pedro Alves <palves@redhat.com>
3301
3302 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
3303 (struct readahead_cache, struct packet_reg, struct
3304 remote_arch_state, class remote_state): Move higher up in the
3305 file.
3306 (remote_target::m_remote_state): Now an object instead of a pointer.
3307 (remote_target::get_remote_state): Adjust.
3308
39f0c204
AB
33092018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3310
3311 * stack.c (select_and_print_frame): Delete.
3312 (struct function_bounds): Move struct within function.
3313 (func_command): Most content moved into new function
3314 find_frame_for_function, use new function, print result, add
3315 function comment.
3316 (find_frame_for_function): New function, now returns a result.
3317
d392224a
PW
33182018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3319
3320 * stack.c (iterate_over_block_arg_vars): Fix comment.
3321 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
3322
45f25d6c
AB
33232018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3324
3325 PR gdb/23203
3326 * frame.c
3327 (scoped_restore_selected_frame::scoped_restore_selected_frame):
3328 Define.
3329 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
3330 Define.
3331 * frame.h (class scoped_restore_selected_frame): New class.
3332 * stack.c (print_frame_local_vars): Remove catching and rethrowing
3333 of any exception, use scoped_restore_selected_frame to restore the
3334 frame instead.
3335
da05d921
PA
33362018-05-24 Pedro Alves <palves@redhat.com>
3337
3338 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
3339 override.
3340
a8be540e
TT
33412018-05-23 Tom Tromey <tom@tromey.com>
3342
3343 * complaints.c (struct complaints): Remove.
3344 (symfile_complaint_book): Remove.
3345 (series): New global.
3346 (complaint_internal): Update.
3347 (clear_complaints): Update.
3348
ff1cf532
TT
33492018-05-23 Tom Tromey <tom@tromey.com>
3350
3351 * complaints.c (counters): New global.
3352 (struct complain): Remove.
3353 (struct complaints) <root>: Remove.
3354 (complaint_sentinel): Remove.
3355 (symfile_complaint_book): Update.
3356 (find_complaint) Remove.
3357 (complaint_internal, clear_complaints): Update.
3358
7ff88174
TT
33592018-05-23 Tom Tromey <tom@tromey.com>
3360
3361 * complaints.c (struct complain) <file, line>: Remove.
3362 (find_complaint): Remove file, line parameters.
3363 (complaint_internal): Update.
3364
de54e1a5
TT
33652018-05-23 Tom Tromey <tom@tromey.com>
3366
3367 * complaints.c (vcomplaint): Remove.
3368 (complaint_internal) Merge in contents of vcomplaint.
3369
2ac237e5
TT
33702018-05-23 Tom Tromey <tom@tromey.com>
3371
3372 * complaints.c (struct complaints) <explanation>: Remove.
3373 (symfile_explanations): Remove.
3374 (symfile_complaint_book): Update.
3375 (vcomplaint): Update.
3376 (struct explanation): Remove.
3377
b98664d3
TT
33782018-05-23 Tom Tromey <tom@tromey.com>
3379
3380 * complaints.c (symfile_complaints): Remove.
3381 (complaint_internal): Remove "complaints" parameter.
3382 (clear_complaints, vcomplaint): Remove "c" parameter.
3383 (get_complaints): Remove.
3384 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
3385 (dwarf2_debug_line_missing_file_complaint)
3386 (dwarf2_debug_line_missing_end_sequence_complaint)
3387 (dwarf2_complex_location_expr_complaint)
3388 (dwarf2_const_value_length_mismatch_complaint)
3389 (dwarf2_section_buffer_overflow_complaint)
3390 (dwarf2_macro_malformed_definition_complaint)
3391 (dwarf2_invalid_attrib_class_complaint)
3392 (create_addrmap_from_index, dw2_symtab_iter_next)
3393 (dw2_expand_marked_cus)
3394 (dw2_debug_names_iterator::find_vec_in_debug_names)
3395 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
3396 (create_debug_type_hash_table, init_cutu_and_read_dies)
3397 (partial_die_parent_scope, add_partial_enumeration)
3398 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
3399 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
3400 (read_import_statement, read_file_scope, create_dwo_cu_reader)
3401 (create_cus_hash_table, create_dwp_hash_table)
3402 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
3403 (dwarf2_rnglists_process, dwarf2_ranges_process)
3404 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
3405 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
3406 (handle_struct_member_die, process_structure_scope)
3407 (read_array_type, read_common_block, read_module_type)
3408 (read_tag_pointer_type, read_typedef, read_base_type)
3409 (read_subrange_type, load_partial_dies, partial_die_info::read)
3410 (partial_die_info::read, partial_die_info::read)
3411 (partial_die_info::read, read_checked_initial_length_and_offset)
3412 (dwarf2_string_attr, read_formatted_entries)
3413 (dwarf_decode_line_header)
3414 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3415 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
3416 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
3417 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3418 (get_signatured_type, get_DW_AT_signature_type)
3419 (decode_locdesc, file_file_name, consume_improper_spaces)
3420 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
3421 (dwarf_decode_macro_bytes, dwarf_decode_macros)
3422 (dwarf2_symbol_mark_computed, set_die_type)
3423 (read_attribute_value): Update.
3424 * stap-probe.c (handle_stap_probe, get_stap_base_address):
3425 Update.
3426 * dbxread.c (unknown_symtype_complaint)
3427 (lbrac_mismatch_complaint, repeated_header_complaint)
3428 (set_namestring, function_outside_compilation_unit_complaint)
3429 (read_dbx_symtab, process_one_symbol): Update.
3430 * gdbtypes.c (stub_noname_complaint): Update.
3431 * windows-nat.c (handle_unload_dll): Update.
3432 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
3433 (decode_base_type): Update.
3434 * xcoffread.c (bf_notfound_complaint, ef_complaint)
3435 (eb_complaint, record_include_begin, record_include_end)
3436 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
3437 (process_xcoff_symbol, read_symbol)
3438 (function_outside_compilation_unit_complaint)
3439 (scan_xcoff_symtab): Update.
3440 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
3441 * buildsym.c (finish_block_internal, make_blockvector)
3442 (end_symtab_get_static_block, augment_type_symtab): Update.
3443 * dtrace-probe.c (dtrace_process_dof)
3444 (dtrace_static_probe_ops::get_probes): Update.
3445 * complaints.h (struct complaint): Don't declare.
3446 (symfile_complaints): Remove.
3447 (complaint_internal): Remove "complaints" parameter.
3448 (complaint): Likewise.
3449 (clear_complaints): Likewise.
3450 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3451 (reread_symbols): Update.
3452 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
3453 (dwarf2_frame_cache, decode_frame_entry): Update.
3454 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
3455 * objc-lang.c (lookup_objc_class, lookup_child_selector)
3456 (info_selectors_command): Update.
3457 * macrotab.c (macro_include, check_for_redefinition)
3458 (macro_undef): Update.
3459 * objfiles.c (filter_overlapping_sections): Update.
3460 * stabsread.c (invalid_cpp_abbrev_complaint)
3461 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
3462 (define_symbol, error_type, read_type, rs6000_builtin_type)
3463 (stabs_method_name_from_physname, read_member_functions)
3464 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
3465 (attach_fields_to_type, complain_about_struct_wipeout)
3466 (read_range_type, read_args, common_block_start)
3467 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
3468 Update.
3469 * mdebugread.c (index_complaint, unknown_ext_complaint)
3470 (basic_type_complaint, bad_tag_guess_complaint)
3471 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
3472 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
3473 (parse_procedure, parse_lines)
3474 (function_outside_compilation_unit_complaint)
3475 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
3476 (bad_tag_guess_complaint, reg_value_complaint): Update.
3477 * cp-support.c (demangled_name_complaint): Update.
3478 * macroscope.c (sal_macro_scope): Update.
3479 * dwarf-index-write.c (class debug_names): Update.
3480
4e9668d0
TT
34812018-05-23 Tom Tromey <tom@tromey.com>
3482
3483 * complaints.c (clear_complaints): Remove "noisy" parameter.
3484 * complaints.h (clear_complaints): Update.
3485 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3486 (reread_symbols): Update.
3487
43ba33c7
TT
34882018-05-23 Tom Tromey <tom@tromey.com>
3489
3490 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
3491 SUBSEQUENT_MESSAGE.
3492 (vcomplaint, clear_complaints): Update.
3493 (symfile_explanations): Remove some messages.
3494
2b9496b2
TT
34952018-05-23 Tom Tromey <tom@tromey.com>
3496
3497 * complaints.c (internal_complaint): Remove.
3498 * complaints.h (internal_complaint): Remove.
3499
35f1fea3
MR
35002018-05-22 Maciej W. Rozycki <macro@mips.com>
3501
3502 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
3503
6b8edb51
PA
35042018-05-22 Pedro Alves <palves@redhat.com>
3505
3506 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
3507 (remote_fileio_badfd, remote_fileio_return_errno)
3508 (remote_fileio_return_success, remote_fileio_func_open)
3509 (remote_fileio_func_open, remote_fileio_func_close)
3510 (remote_fileio_func_read, remote_fileio_func_write)
3511 (remote_fileio_func_lseek, remote_fileio_func_rename)
3512 (remote_fileio_func_unlink, remote_fileio_func_stat)
3513 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
3514 (remote_fileio_func_isatty, remote_fileio_func_system): Add
3515 remote_target parameter.
3516 (remote_fio_func_map) <func>: Add remote_target parameter.
3517 (do_remote_fileio_request, remote_fileio_request):
3518 * remote-fileio.h (remote_fileio_request):
3519 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
3520 remote_target parameter.
3521 (remote_notif_process, handle_notification): Adjust to pass down
3522 the remote.
3523 (remote_notif_state_allocate): Add remote_target parameter. Save
3524 it.
3525 * remote-notif.h (struct remote_target): Forward declare.
3526 (struct notif_client) <parse, ack, can_get_pending_events>: Add
3527 remote_target parameter.
3528 (struct remote_notif_state) <remote>: New field.
3529 (remote_notif_ack, remote_notif_parse): Add remote_target
3530 parameter.
3531 (remote_notif_state_allocate, remote_notif_state_allocate): Add
3532 remote_target parameter.
3533 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
3534 (threads_listing_context, rmt_thread_action, protocol_feature)
3535 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
3536 (packet_result, struct threads_listing_context, remote_state):
3537 Move definitions and declarations higher up.
3538 (remote_target) <~remote_target>: Declare.
3539 (remote_download_command_source, remote_file_put, remote_file_get)
3540 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
3541 (remote_hostio_pread_vFile, remote_hostio_send_command)
3542 (remote_hostio_set_filesystem, remote_hostio_open)
3543 (remote_hostio_close, remote_hostio_unlink, remote_state)
3544 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
3545 (get_memory_write_packet_size, get_memory_read_packet_size)
3546 (append_pending_thread_resumptions, remote_detach_1)
3547 (append_resumption, remote_resume_with_vcont)
3548 (add_current_inferior_and_thread, wait_ns, wait_as)
3549 (process_stop_reply, remote_notice_new_inferior)
3550 (process_initial_stop_replies, remote_add_thread)
3551 (btrace_sync_conf, remote_btrace_maybe_reopen)
3552 (remove_new_fork_children, kill_new_fork_children)
3553 (discard_pending_stop_replies, stop_reply_queue_length)
3554 (check_pending_events_prevent_wildcard_vcont)
3555 (discard_pending_stop_replies_in_queue, stop_reply)
3556 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
3557 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
3558 (remote_interrupt_as, remote_interrupt_ns)
3559 (remote_get_noisy_reply, remote_query_attached)
3560 (remote_add_inferior, remote_current_thread, get_current_thread)
3561 (set_thread, set_general_thread, set_continue_thread)
3562 (set_general_process, write_ptid)
3563 (remote_unpack_thread_info_response, remote_get_threadinfo)
3564 (parse_threadlist_response, remote_get_threadlist)
3565 (remote_threadlist_iterator, remote_get_threads_with_ql)
3566 (remote_get_threads_with_qxfer)
3567 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
3568 (get_offsets, remote_check_symbols, remote_supported_packet)
3569 (remote_query_supported, remote_packet_size)
3570 (remote_serial_quit_handler, remote_detach_pid)
3571 (remote_vcont_probe, remote_resume_with_hc)
3572 (send_interrupt_sequence, interrupt_query)
3573 (remote_notif_get_pending_events, fetch_register_using_p)
3574 (send_g_packet, process_g_packet, fetch_registers_using_g)
3575 (store_register_using_P, store_registers_using_G)
3576 (set_remote_traceframe, check_binary_download)
3577 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
3578 (remote_xfer_live_readonly_partial, remote_read_bytes)
3579 (remote_send_printf, remote_flash_write, readchar)
3580 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
3581 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
3582 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
3583 (extended_remote_disable_randomization, extended_remote_run)
3584 (send_environment_packet, extended_remote_environment_support)
3585 (extended_remote_set_inferior_cwd, remote_write_qxfer)
3586 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
3587 (packet_command): Now methods of ...
3588 (remote_target): ... this class.
3589 (m_remote_state) <remote_target>: New field.
3590 (struct remote_state) <stop_reply_queue,
3591 remote_async_inferior_event_token, wait_forever_enabled_p>: New
3592 fields.
3593 (remote_state::remote_state): Allocate stop_reply_queue.
3594 (remote_state): Delete global.
3595 (get_remote_state_raw): Delete.
3596 (remote_target::get_remote_state): Allocate m_remote_state on
3597 demand.
3598 (get_current_remote_target): New.
3599 (remote_ops, extended_remote_ops): Delete.
3600 (wait_forever_enabled_p, remote_async_inferior_event_token):
3601 Delete, moved to struct remote_state.
3602 (remote_target::close): Delete self. Destruction bits split to
3603 ...
3604 (remote_target::~remote_target): ... this.
3605 (show_memory_packet_size): Adjust to use
3606 get_current_remote_target.
3607 (struct protocol_feature) <func>: Add remote_target parameter.
3608 All callers adjusted.
3609 (curr_quit_handler_target): New.
3610 (remote_serial_quit_handler): Reimplement.
3611 (remote_target::open_1): Adjust to use get_current_remote_target.
3612 Heap-allocate remote_target/extended_remote_target instances.
3613 (vcont_builder::vcont_builder): Add remote_target parameter, and
3614 save it in m_remote. All callers adjusted.
3615 (vcont_builder::m_remote): New field.
3616 (vcont_builder::restart, vcont_builder::flush)
3617 (vcont_builder::push_action): Use it.
3618 (remote_target::commit_resume): Use it.
3619 (struct queue_iter_param) <remote>: New field.
3620 (remote_target::remove_new_fork_children): Fill in 'remote' field.
3621 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
3622 (check_pending_event_prevents_wildcard_vcont_callback)
3623 (remote_target::check_pending_events_prevent_wildcard_vcont)
3624 (remote_target::discard_pending_stop_replies)
3625 (remote_target::discard_pending_stop_replies_in_queue)
3626 (remote_target::remote_notif_remove_queued_reply): Fill in
3627 'remote' field.
3628 (remote_notif_get_pending_events): New.
3629 (remote_target::readchar, remote_target::remote_serial_write):
3630 Save/restore curr_quit_handler_target.
3631 (putpkt): New.
3632 (kill_new_fork_children): Fill in 'remote' field.
3633 (packet_command): Use get_current_remote_target, defer to
3634 remote_target method of same name.
3635 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
3636 parameter, and save it in m_remote. All callers adjusted.
3637 (scoped_remote_fd::release): Use m_remote.
3638 (scoped_remote_fd::m_remote): New field.
3639 (remote_file_put, remote_file_get, remote_file_delete): Use
3640 get_current_remote_target, defer to remote_target method of same
3641 name.
3642 (remote_btrace_reset): Add remote_state paremeter. Update all
3643 callers.
3644 (remote_async_inferior_event_handler). Pass down 'data'.
3645 (remote_new_objfile): Use get_current_remote_target.
3646 (remote_target::vcont_r_supported): New.
3647 (set_range_stepping): Use get_current_remote_target and
3648 remote_target::vcont_r_supported.
3649 (_initialize_remote): Don't allocate 'remote_state' and
3650 'stop_reply_queue' globals.
3651 * remote.h (struct remote_target): Forward declare.
3652 (getpkt, putpkt, remote_notif_get_pending_events): Add
3653 'remote_target' parameter.
3654
f5db4863
PA
36552018-05-22 Pedro Alves <palves@redhat.com>
3656
3657 * remote.c (vcont_builder): Now a class. Make all data members
3658 private.
3659 (vcont_builder) <vcont_builder, restart, flush, push_action>:
3660 Declare methods.
3661 (vcont_builder_restart): Rename to ...
3662 (vcont_builder::restart): ... this.
3663 (vcont_builder_flush): Rename to ...
3664 (vcont_builder::flush): ... this.
3665 (vcont_builder_push_action): Rename to ...
3666 (vcont_builder::push_action): ... this.
3667 (remote_target::commit_resume): Adjust.
3668
cc0be08f
PA
36692018-05-22 Pedro Alves <palves@redhat.com>
3670
3671 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
3672 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
3673 (get_fixed_memory_packet_size): New.
3674 (get_memory_packet_size): Use it.
3675 (set_memory_packet_size): Don't override the config size with
3676 DEFAULT_MAX_MEMORY_PACKET_SIZE.
3677 (show_memory_packet_size): Use get_fixed_memory_packet_size.
3678 Don't refer to get_memory_packet_size if not connected to a remote
3679 target. Show "(default)" if configured size is 0.
3680
9607784a
PA
36812018-05-22 Pedro Alves <palves@redhat.com>
3682
3683 * remote.c (remote_target::mourn_inferior): Move
3684 discard_pending_stop_replies call here from ...
3685 (_initialize_remote): ... here.
3686
0e9a6b2f
PA
36872018-05-22 Pedro Alves <palves@redhat.com>
3688
3689 * remote.c (compare_section_command): Remove set_general_process
3690 call.
3691
43c3a0e4
PA
36922018-05-22 Pedro Alves <palves@redhat.com>
3693
3694 * remote.c (struct packet_reg, struct remote_arch_state):
3695 Move higher up in the file.
3696 (remote_state) <m_arch_states>: Store remote_arch_state values
3697 instead of remote_arch_state pointers.
3698 (remote_state::get_remote_arch_state): Adjust.
3699
9d6eea31
PA
37002018-05-22 Pedro Alves <palves@redhat.com>
3701
3702 * remote.c: Include <unordered_map>.
3703 (remote_state): Now a class.
3704 (remote_state) <get_remote_arch_state>: Declare method.
3705 <get_remote_arch_state>: New field.
3706 (remote_arch_state) <remote_arch_state>: Declare ctor.
3707 <regs>: Now a unique_ptr.
3708 (remote_gdbarch_data_handle): Delete.
3709 (get_remote_arch_state): Delete.
3710 (remote_state::get_remote_arch_state): New.
3711 (get_remote_state): Adjust to call remote_state's
3712 get_remote_arch_state method.
3713 (init_remote_state): Delete, bits factored out to ...
3714 (remote_arch_state::remote_arch_state): ... this new method.
3715 (get_remote_packet_size, get_memory_packet_size)
3716 (process_g_packet, remote_target::fetch_registers)
3717 (remote_target::prepare_to_store, store_registers_using_G)
3718 (remote_target::store_registers, remote_target::get_trace_status):
3719 Adjust to call remote_state's method.
3720 (_initialize_remote): Remove reference to
3721 remote_gdbarch_data_handle.
3722
dd194f6b
PA
37232018-05-22 Pedro Alves <palves@redhat.com>
3724
3725 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
3726 pread>: New method declarations.
3727 (remote_target::open_1): Adjust.
3728 (readahead_cache_invalidate): Rename to ...
3729 (readahead_cache::invalidate): ... this, and adjust to be a class
3730 method.
3731 (readahead_cache_invalidate_fd): Rename to ...
3732 (readahead_cache::invalidate_fd): ... this, and adjust to be a
3733 class method.
3734 (remote_hostio_pwrite): Adjust.
3735 (remote_hostio_pread_from_cache): Rename to ...
3736 (readahead_cache::pread): ... this, and adjust to be a class
3737 method.
3738 (remote_hostio_close): Adjust.
3739
440b7aec
PA
37402018-05-22 Pedro Alves <palves@redhat.com>
3741
3742 * remote.c (remote_hostio_close_cleanup): Delete.
3743 (class scoped_remote_fd): New.
3744 (remote_file_put, remote_file_get): Use it.
3745
de44f5a7
PA
37462018-05-22 Pedro Alves <palves@redhat.com>
3747
3748 (struct vCont_action_support): Use bool and initialize all fields.
3749 (struct readahead_cache): Initialize all fields.
3750 (remote_state): Use bool and initialize all fields.
3751 (remote_state::remote_state, remote_state::~remote_state): New.
3752 (new_remote_state): Delete.
3753 (_initialize_remote): Use new to allocate remote_state.
3754
b1b60145
PA
37552018-05-22 Pedro Alves <palves@redhat.com>
3756 張俊芝 <zjz@zjz.name>
3757
3758 PR gdb/22973
3759 * c-exp.y: Include "c-support.h".
3760 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
3761 of tolower. Use c_ident_is_alpha to scan names.
3762 * c-lang.c: Include "c-support.h".
3763 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
3764 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
3765 * c-support.h: New file, with bits factored out from ...
3766 * cp-name-parser.y: ... this file.
3767 Include "c-support.h".
3768 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
3769 c-support.h and renamed.
3770 (symbol_end, yylex): Adjust.
3771
0ec848ad
PFC
37722018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3773
3774 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
3775 parameter type to CORE_ADDR.
3776 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
3777 parameter type in declaration to CORE_ADDR.
3778 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
3779 target_auxv_search to get AT_HWCAP and use the result to get the
3780 target description.
3781 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
3782 to CORE_ADDR. Remove the cast of the return value to unsigned
3783 long. Fix error predicate of target_auxv_search.
3784 (ppc_linux_nat_target::read_description): Change the type of the
3785 hwcap variable to CORE_ADDR.
3786
0fb2aaa1
PFC
37872018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3788
3789 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
3790 if the size of fpscr is larger than 32 bits.
3791
2c3305f6
PFC
37922018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3793
3794 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
3795 (ppc32_linux_vsxregmap): New global.
3796 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
3797 regcache_supply_regset, and regcache_collect_regset.
3798 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
3799 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
3800 (fetch_vsx_register, store_vsx_register): Remove.
3801 (fetch_vsx_registers): Add regno parameter. Get regset using
3802 ppc_linux_vsxregset. Use regset to supply registers.
3803 (store_vsx_registers): Add regno parameter. Get regset using
3804 ppc_linux_vsxregset. Use regset to collect registers.
3805 (fetch_register): Call fetch_vsx_registers instead of
3806 fetch_vsx_register.
3807 (store_register): Call store_vsx_registers instead of
3808 store_vsx_register.
3809 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
3810 new regno parameter.
3811 (store_ppc_registers): Call store_vsx_registers with -1 for the
3812 new regno parameter.
3813 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
3814 (ppc_collect_vsxregset): Remove.
3815
1d75a658
PFC
38162018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3817
3818 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
3819 offset fields.
3820 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
3821 for vector register offset fields.
3822 (ppc64_fbsd_reg_offsets): Likewise.
3823 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3824 to vector register offset fields.
3825 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3826 to vector register offset fields.
3827 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
3828 vector register offset fields.
3829 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
3830 initializers for vector register offset fields.
3831 (rs6000_aix64_reg_offsets): Likewise.
3832 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
3833 (ppc_supply_vrregset): Remove.
3834 (ppc_collect_vrregset): Remove.
3835 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
3836 (ppc_linux_vrregset) : New function.
3837 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
3838 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
3839 (ppc32_linux_vrregset): Remove.
3840 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
3841 and use result instead of ppc32_linux_vrregset.
3842 (ppc32_linux_reg_offsets): Remove initializers for vector register
3843 offset fields.
3844 (ppc64_linux_reg_offsets): Likewise.
3845 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
3846 * ppc-linux-nat.c: Include regset.h.
3847 (gdb_vrregset_t): Adjust comment to account for little-endian
3848 mode.
3849 (supply_vrregset, fill_vrregset): Remove.
3850 (fetch_altivec_register, store_altivec_register): Remove.
3851 (fetch_altivec_registers): Add regno parameter. Get regset using
3852 ppc_linux_vrregset. Use regset to supply registers.
3853 (store_altivec_registers): Add regno parameter. Get regset using
3854 ppc_linux_vrregset. Use regset to collect registers.
3855 (fetch_register): Call fetch_altivec_registers instead of
3856 fetch_altivec_register.
3857 (store_register): Call store_altivec_registers instead of
3858 store_altivec_register.
3859 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
3860 the new regno parameter.
3861 (store_ppc_registers): Call store_altivec_registers with -1 for
3862 the new regno parameter.
3863
d078308a
PFC
38642018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3865
3866 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
3867 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
3868 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3869 (gdb_vrregset_t): Change array type size to
3870 PPC_LINUX_SIZEOF_VRREGSET.
3871 (gdb_vsxregset_t): Change array type size to
3872 PPC_LINUX_SIZEOF_VSXREGSET.
3873 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
3874 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
3875 PPC_LINUX_SIZEOF_VSXREGSET.
3876
2e077f5e
PFC
38772018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3878
3879 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
3880 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
3881 nat/ppc-linux.c.
3882 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
3883 ppc_linux_target_wordsize with tid.
3884 (ppc_linux_nat_target::read_description): Call ppc_linux_target
3885 wordsize with tid.
3886 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
3887 (ppc64_64bit_inferior_p): Add static and inline specifiers.
3888 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
3889 tid parameter. Remove static specifier.
3890 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
3891 (ppc_linux_target_wordsize): New declaration.
3892
bd64614e
PFC
38932018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3894
3895 * arch/ppc-linux-common.c: New file.
3896 * arch/ppc-linux-common.h: New file.
3897 * arch/ppc-linux-tdesc.h: New file.
3898 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
3899 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
3900 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
3901 arch/ppc-linux-tdesc.h.
3902 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
3903 arch/ppc-linux-tdesc.h.
3904 (ppc_linux_nat_target::read_description): Remove target
3905 description matching code. Fill a ppc_linux_features struct and
3906 call ppc_linux_match_description with it. Move comment about ISA
3907 2.05 to ppc-linux-common.c.
3908 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
3909 arch/ppc-linux-tdesc.h.
3910 (ppc_linux_core_read_description): Remove target description
3911 matching code. Fill a ppc_linux_features struct and call
3912 ppc_linux_match_description with it.
3913 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3914 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3915 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3916 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3917 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3918 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3919 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3920 (tdesc_powerpc_e500l): Remove.
3921
241db429
JB
39222018-05-22 Joel Brobecker <brobecker@adacore.com>
3923
3924 * ada-lang.c (catch_assert_command): Pass empty string instead
3925 of NULL for excep_string argument.
3926
75d74cca
MR
39272018-05-22 Maciej W. Rozycki <macro@mips.com>
3928
3929 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
3930 the width of the requested register exceeds the width of the
3931 `ptrace' data type.
3932
122b53ea
TT
39332018-05-21 Tom Tromey <tom@tromey.com>
3934
3935 * printcmd.c (output_command): Remove.
3936 (output_command_const): Rename to output_command.
3937 * valprint.h (output_command): Rename from output_command_const.
3938 * tracepoint.c (trace_dump_actions): Call output_command.
3939
bc18fbb5
TT
39402018-05-21 Tom Tromey <tom@tromey.com>
3941
3942 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3943 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
3944 * ada-lang.h (create_ada_exception_catchpoint): Update.
3945 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
3946 std::string.
3947 (create_excep_cond_exprs, ~ada_catchpoint)
3948 (should_stop_exception, print_one_exception)
3949 (print_mention_exception, print_recreate_exception): Update.
3950 (ada_get_next_arg): Remove.
3951 (catch_ada_exception_command_split): Use std::string. Change type
3952 of "excep_string", "cond_string".
3953 (catch_ada_exception_command): Update.
3954 (create_ada_exception_catchpoint): Change type of excep_string.
3955 (ada_exception_sal): Remove excep_string parameter.
3956 (~ada_catchpoint): Remove.
3957
790217f6
TT
39582018-05-21 Tom Tromey <tom@tromey.com>
3959
3960 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
3961 cleanup.
3962
6f46ac85
TT
39632018-05-21 Tom Tromey <tom@tromey.com>
3964
3965 * ada-lang.c (ada_exception_message_1, ada_exception_message):
3966 Return unique_xmalloc_ptr.
3967 (print_it_exception): Update.
3968
15b6611c
TT
39692018-05-21 Tom Tromey <tom@tromey.com>
3970
3971 * tracepoint.c (trace_dump_actions): Use std::string.
3972
c0c9f665
TT
39732018-05-21 Tom Tromey <tom@tromey.com>
3974
3975 * symfile.c (reread_symbols): Use std::string for original_name.
3976
22ca247e
TT
39772018-05-21 Tom Tromey <tom@tromey.com>
3978
3979 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
3980 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
3981 constructor.
3982
184cde75
SM
39832018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
3984
3985 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
3986 instance to...
3987 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
3988 * objfiles.c (get_objfile_bfd_data): Allocate
3989 objfile_per_bfd_storage with obstack_new when allocating on
3990 obstack.
3991
e39db4db
SM
39922018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3993
3994 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
3995 OBSTACK_ZALLOC.
3996 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
3997 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
3998 * mdebugread.c (mdebug_build_psymtabs): Likewise.
3999 (add_pending): Likewise.
4000 (parse_symbol): Likewise.
4001 (parse_partial_symbols): Likewise.
4002 (psymtab_to_symtab_1): Likewise.
4003 (new_psymtab): Likewise.
4004 (elfmdebug_build_psymtabs): Likewise.
4005 * minsyms.c (terminate_minimal_symbol_table): Likewise.
4006 * objfiles.c (get_objfile_bfd_data): Likewise.
4007 (objfile_register_static_link): Likewise.
4008 * psymtab.c (allocate_psymtab): Likewise.
4009 * stabsread.c (read_member_functions): Likewise.
4010 * xcoffread.c (xcoff_end_psymtab): Likewise.
4011
284a0e3c
SM
40122018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4013
4014 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
4015 compiler supports std::is_trivially_constructible.
4016 * common/poison.h: Include obstack.h.
4017 (IsMallocable): Define to is_trivially_constructible if the
4018 compiler supports it, define to true_type otherwise.
4019 (xobnew): New.
4020 (XOBNEW): Redefine.
4021 (xobnewvec): New.
4022 (XOBNEWVEC): Redefine.
4023 * gdb_obstack.h (obstack_zalloc): New.
4024 (OBSTACK_ZALLOC): Redefine.
4025 (obstack_calloc): New.
4026 (OBSTACK_CALLOC): Redefine.
4027 (obstack_new): New.
4028 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
4029 (gdbarch_obstack): New declaration in gdbarch.h, definition in
4030 gdbarch.c.
4031 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
4032 obstack_calloc/obstack_zalloc.
4033 (gdbarch_obstack_zalloc): Remove.
4034 * target-descriptions.c (tdesc_data_init): Use obstack_new.
4035
59f66be3
PW
40362018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4037
4038 * stack.c (backtrace_command_1): Remove useless variable int i.
4039
50c65c2d
PW
40402018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4041
4042 * stack.c (print_frame_info): Fix comment.
4043
7ff8cb8c
TT
40442018-05-18 Tom Tromey <tom@tromey.com>
4045
4046 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
4047 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
4048 (~dwarf2_per_objfile): Update
4049 (dwarf2_get_dwz_file): Use new.
4050 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
4051 unique_ptr.
4052
400174b1
TT
40532018-05-18 Tom Tromey <tom@tromey.com>
4054
4055 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
4056 unique_ptr.
4057 * dwarf2read.c (struct dwp_file): Add constructor and
4058 initializers.
4059 (open_and_init_dwp_file): Return a unique_ptr.
4060 (dwarf2_per_objfile, create_dwp_hash_table)
4061 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
4062 (lookup_dwo_unit_in_dwp): Update.
4063 (open_and_init_dwp_file, get_dwp_file): Update.
4064
3063847f
TT
40652018-05-18 Tom Tromey <tom@tromey.com>
4066
4067 * dwarf2read.c (dwarf2_per_objfile): Update.
4068 (struct mapped_index): Add initializers.
4069 (dwarf2_read_index): Use new.
4070 (dw2_symtab_iter_init): Update.
4071 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
4072 unique_ptr.
4073
d3d02dee
SM
40742018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4075
4076 * dwarf2read.c (mapped_index) <total_size>: Remove.
4077
1d143c36
SM
40782018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4079
4080 * unittests/format_pieces-selftests.c (test_format_specifier):
4081 Add ARI comments.
4082
ce1e8424
TT
40832018-05-18 Tom Tromey <tom@tromey.com>
4084
4085 * c-typeprint.c (maybe_print_hole): New function.
4086 (c_print_type_struct_field_offset): Update.
4087 (c_type_print_base_struct_union): Call maybe_print_hole.
4088
ddfe970e
KS
40892018-05-17 Keith Seitz <keiths@redhat.com>
4090
4091 * breakpoint.c (build_bpstat_chain): New function, moved from
4092 bpstat_stop_status.
4093 (bpstat_stop_status): Add optional parameter, `stop_chain'.
4094 If no stop chain is passed, call build_bpstat_chain to build it.
4095 * breakpoint.h (build_bpstat_chain): Declare.
4096 (bpstat_stop_status): Move documentation here from breakpoint.c.
4097 * infrun.c (handle_signal_stop): Before eliding inlined frames,
4098 build the stop chain and pass it to skip_inline_frames.
4099 Pass this stop chain to bpstat_stop_status.
4100 * inline-frame.c: Include breakpoint.h.
4101 (stopped_by_user_bp_inline_frame): New function.
4102 (skip_inline_frames): Add parameter `stop_chain'.
4103 Move documention to inline-frame.h.
4104 If non-NULL, use stopped_by_user_bp_inline_frame to determine
4105 whether the frame should be elided.
4106 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
4107 Add moved documentation and update for new parameter.
4108
b17992c1
SM
41092018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4110
4111 PR cli/14975
4112 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4113 unittests/format_pieces-selftests.c.
4114 * common/format.h (format_piece) <operator==>: New.
4115 (format_pieces) <operator[]>: Remove.
4116 * common/format.c (format_pieces::format_pieces): Handle \e.
4117 * unittests/format_pieces-selftests.c: New.
4118
58f0c718
TT
41192018-05-17 Tom Tromey <tom@tromey.com>
4120
4121 PR symtab/23010:
4122 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
4123 (dw2_instantiate_symtab): Add skip_partial parameter.
4124 (dw2_find_last_source_symtab, dw2_map_expand_apply)
4125 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
4126 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
4127 (dw2_expand_symtabs_matching_one)
4128 (dw2_find_pc_sect_compunit_symtab)
4129 (dw2_debug_names_lookup_symbol)
4130 (dw2_debug_names_expand_symtabs_for_function): Update.
4131 (init_cutu_and_read_dies): Add skip_partial parameter.
4132 (process_psymtab_comp_unit, build_type_psymtabs_1)
4133 (process_skeletonless_type_unit, load_partial_comp_unit)
4134 (psymtab_to_symtab_1): Update.
4135 (load_full_comp_unit): Add skip_partial parameter.
4136 (process_imported_unit_die, dwarf2_read_addr_index)
4137 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
4138 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
4139 (read_signatured_type): Update.
4140
3e618834
SM
41412018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4142
4143 * value.c (release_value): Remove unused variable.
4144 (record_latest_value): Likewise.
4145 (access_value_history): Likewise.
4146 (preserve_values): Likewise.
4147
fe10fe31
TT
41482018-05-17 Tom Tromey <tom@tromey.com>
4149
4150 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
4151 Initialize.
4152
1d761124
MR
41532018-05-16 Maciej W. Rozycki <macro@mips.com>
4154
4155 PR gdb/22286
4156 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
4157 Also handle registers whose width is not a multiple of
4158 PTRACE_TYPE_RET.
4159 (linux_nat_trad_target::store_register): Likewise.
4160
06333fea
TT
41612018-05-16 Tom Tromey <tom@tromey.com>
4162
4163 * gdbcore.h (core_bfd): Redefine.
4164 * corelow.c (core_target::close): Update.
4165 (core_target_open): Update.
4166 * progspace.h (struct program_space) <cbfd>: Now a
4167 gdb_bfd_ref_ptr.
4168
921222e2
TT
41692018-05-16 Tom Tromey <tom@tromey.com>
4170
4171 PR cli/19551:
4172 * symfile-add-flags.h (enum symfile_add_flags)
4173 <SYMFILE_NOT_FILENAME>: New constant.
4174 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
4175 objfile name from BFD.
4176 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
4177 * minidebug.c (find_separate_debug_file_in_section): Put
4178 ".gnu_debugdata" into BFD's file name.
4179
3acb7083
SM
41802018-05-16 Simon Marchi <simon.marchi@ericsson.com>
4181
4182 * regcache.c (regcache_read_ftype, regcache_write_ftype):
4183 Remove.
4184
561a72d4
TC
41852018-05-15 Tamar Christina <tamar.christina@arm.com>
4186
4187 PR binutils/21446
4188 * aarch64-tdep.c (aarch64_analyze_prologue,
4189 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
4190 Indicate not interested in errors.
4191
4e6ff0e1
MR
41922018-05-15 Maciej W. Rozycki <macro@mips.com>
4193
4194 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
4195 Supply the MIPS_ZERO_REGNUM register.
4196
ea33cd92
MR
41972018-05-15 Maciej W. Rozycki <macro@mips.com>
4198
4199 * mips-tdep.c (mask_address_var): Make variable static.
4200
2d79090e
TT
42012018-05-14 Tom Tromey <tom@tromey.com>
4202
4203 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
4204
cf4912ae
AB
42052018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
4206
4207 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
4208 FXSAVE_ADDR for the mxcsr register.
4209
67e6f569
MF
42102018-05-11 Max Filippov <jcmvbkbc@gmail.com>
4211
4212 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
4213
15244507
PA
42142018-05-11 Pedro Alves <palves@redhat.com>
4215
4216 * corelow.c (core_target) <core_target>: No longer inline.
4217 Initialize m_core_gdbarch, m_core_vec and build the section table
4218 here.
4219 <~core_target>: New.
4220 <core_gdbarch, get_core_register_section>: New methods.
4221 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
4222 factored out from ...
4223 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
4224 (core_ops): Delete.
4225 (sniff_core_bfd): Add gdbarch parameter.
4226 (core_close): Delete, merged into ...
4227 (core_target::close): ... here. Delete self.
4228 (core_close_cleanup): Delete.
4229 (core_target_open): Allocate a core_target on the heap. Use a
4230 unique_ptr instead of a cleanup. Bits moved into the core_target
4231 ctor. Adjust to use core_target methods instead of globals.
4232 (get_core_register_section): Rename to ...
4233 (core_target::get_core_register_section): ... this and adjust.
4234 (struct get_core_registers_cb_data): New.
4235 (get_core_registers_cb): Use it. Use bool.
4236 (core_target::fetch_registers, core_target::files_info)
4237 (core_target::xfer_partial, core_target::read_description)
4238 (core_target::pid_to, core_target::thread_name): Adjust to
4239 reference class fields instead of globals.
4240 * target.h (struct target_ops_deleter, target_ops_up): New.
4241
451953fa
PA
42422018-05-11 Pedro Alves <palves@redhat.com>
4243
4244 * corefile.c (core_file_command): Move to corelow.c.
4245 * corelow.c (the_core_target): Delete.
4246 (core_file_command): Moved from corefile.c. Check exec_bfd
4247 instead of the_core_target. Use target_detach instead of calling
4248 into the_core_target directly.
4249 (maybe_say_no_core_file_now): New.
4250 (core_target::detach): Use it.
4251 (_initialize_corelow): Remove references to the_core_target.
4252 * gdbcore.h (the_core_target): Delete.
4253
e540a5a2 42542018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 4255 Pedro Alves <palves@redhat.com>
e540a5a2
TT
4256
4257 * corefile.c (core_bfd): Remove.
4258 * gdbcore.h (core_bfd): Now a macro.
4259 * progspace.h (struct program_space) <cbfd>: New field.
4260
633cf254
TT
42612018-05-11 Tom Tromey <tom@tromey.com>
4262
4263 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
4264 gdb::def_vector.
4265
1a34f210
TT
42662018-05-10 Tom Tromey <tom@tromey.com>
4267
4268 * configure: Rebuild.
4269 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
4270
190852c8
JB
42712018-05-10 Joel Brobecker <brobecker@adacore.com>
4272
4273 PR server/23158:
4274 * regformats/regdat.sh: Adjust script, following the addition
4275 of the new expedite_regs parameter to init_target_desc.
4276
8727de56
OJ
42772018-05-10 Omair Javaid <omair.javaid@linaro.org>
4278
4279 PR gdb/23127
4280 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
4281 set_gdbarch_significant_addr_bit.
4282 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
4283 set_gdbarch_significant_addr_bit.
4284 * utils.c (address_significant): Update to sign extend addr.
4285
37d9e062
MF
42862018-05-09 Max Filippov <jcmvbkbc@gmail.com>
4287
4288 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
4289 (xtensa_linux_init_abi): Limit tdep->num_regs by
4290 tdep->num_nopriv_regs.
4291 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
4292 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
4293 not initialized.
4294
7402fbca
SM
42952018-05-08 Simon Marchi <simon.marchi@ericsson.com>
4296
4297 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
4298
8ee22052
AB
42992018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
4300
4301 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
4302 (I387_MXCSR_INIT_VAL): New constant.
4303 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
4304 buffer if it was supplied by the inferior.
4305 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
4306 (i387_xsave_get_clear_bv): New function.
4307 (i387_supply_xsave): Only read x87 control registers from the
4308 xsave buffer if the feature is enabled, and the state will have
4309 been written, otherwise, provide a suitable default.
4310 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
4311 including x87 control registers. Update control registers if they
4312 have changed from the default value, and mark features as enabled
4313 as required.
4314 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
4315
968ae51b
UW
43162018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
4317
4318 * spu-tdep.c (info_spu_event_command): Fix output formatting.
4319
aff689d3
TT
43202018-05-07 Tom Tromey <tom@tromey.com>
4321
4322 * configure: Rebuild.
4323 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
4324
ce887586
TT
43252018-05-07 Tom Tromey <tom@tromey.com>
4326
4327 PR tdep/20362:
4328 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
4329 bit. Use correct value for VDIV.
4330
85e26832
TT
43312018-05-04 Tom Tromey <tom@tromey.com>
4332
4333 * configure: Rebuild.
4334 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
4335
449b1ac7
TT
43362018-05-04 Tom Tromey <tom@tromey.com>
4337
4338 * linux-record.c (record_linux_system_call) <case
4339 RECORD_SYS_RECVFROM>: Add "break".
4340
15c9ffd6
TT
43412018-05-04 Tom Tromey <tom@tromey.com>
4342
4343 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
4344 Add missing "break".
4345 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
4346 Add missing "break".
4347
e3829d13
TT
43482018-05-04 Tom Tromey <tom@tromey.com>
4349
4350 * rs6000-tdep.c (ppc_process_record_op4)
4351 (ppc_process_record_op63): Add fall-through comment.
4352
da0e1563
TT
43532018-05-04 Tom Tromey <tom@tromey.com>
4354
4355 * i386-tdep.c (i386_process_record): Add fall-through comment.
4356
0019cd49
TT
43572018-05-04 Tom Tromey <tom@tromey.com>
4358
4359 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
4360 comment.
4361
565e0eda
TT
43622018-05-04 Tom Tromey <tom@tromey.com>
4363
4364 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
4365 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
4366 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
4367 comment.
4368 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
4369 comment.
4370 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
4371 comment.
4372
621846f4
TT
43732018-05-04 Tom Tromey <tom@tromey.com>
4374
4375 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
4376
86a73007
TT
43772018-05-04 Tom Tromey <tom@tromey.com>
4378
4379 * s390-tdep.c (s390_process_record): Fix fall-through comments.
4380 * xcoffread.c (scan_xcoff_symtab): Move comment later.
4381 * symfile.c (section_is_mapped): Fix fall-through comment.
4382 * stabsread.c (define_symbol, read_member_functions): Fix
4383 fall-through comment.
4384 * s390-linux-tdep.c (s390_process_record): Fix fall-through
4385 comment.
4386 * remote.c (remote_wait_as): Fix fall-through comment.
4387 * p-exp.y (yylex): Fix fall-through comment.
4388 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
4389 comment.
4390 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
4391 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
4392 * jv-exp.y (yylex): Fix fall-through comment.
4393 * go-exp.y (lex_one_token): Fix fall-through comment.
4394 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
4395 fall-through comment.
4396 * f-exp.y (yylex): Fix fall-through comment.
4397 * dwarf2read.c (process_die): Fix fall-through comments.
4398 * dbxread.c (process_one_symbol): Fix fall-through comment.
4399 * d-exp.y (lex_one_token): Fix fall-through comment.
4400 * cp-name-parser.y (yylex): Fix fall-through comment.
4401 * coffread.c (coff_symtab_read): Fix fall-through comment.
4402 * c-exp.y (lex_one_token): Fix fall-through comment.
4403 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
4404 comment.
4405 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
4406 comment.
4407
56bcdbea
TT
44082018-05-04 Tom Tromey <tom@tromey.com>
4409
4410 PR python/22730:
4411 * NEWS: Mention gdb.execute change.
4412 * gdbcmd.h (execute_control_command): Don't declare.
4413 * python/python.c (execute_gdb_command): Use read_command_lines_1,
4414 execute_control_commands, execute_control_commands_to_string.
4415 * cli/cli-script.h (execute_control_commands)
4416 (execute_control_commands_to_string): Declare.
4417 (execute_control_command): Add from_tty parameter.
4418 * cli/cli-script.c (execute_control_commands)
4419 (execute_control_commands_to_string): New functions.
4420 (execute_user_command): Use execute_control_commands.
4421 (execute_control_command_1): Add "from_tty" parameter. Update.
4422 (execute_control_command): Likewise.
4423
a913fffb
TT
44242018-05-04 Tom Tromey <tom@tromey.com>
4425
4426 PR python/22731:
4427 * NEWS: Mention that breakpoint commands are writable.
4428 * python/py-breakpoint.c (bppy_set_commands): New function.
4429 (breakpoint_object_getset) <"commands">: Use it.
4430
60b3cef2
TT
44312018-05-04 Tom Tromey <tom@tromey.com>
4432
4433 * tracepoint.c (actions_command): Update.
4434 * mi/mi-cmd-break.c (mi_command_line_array)
4435 (mi_command_line_array_cnt, mi_command_line_array_ptr)
4436 (mi_read_next_line): Remove.
4437 (mi_cmd_break_commands): Update.
4438 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
4439 function_view.
4440 * cli/cli-script.c (get_command_line): Update.
4441 (process_next_line): Use function_view. Constify.
4442 (recurse_read_control_structure, read_command_lines)
4443 (read_command_lines_1): Change argument types to function_view.
4444 (do_define_command, document_command): Update.
4445 * breakpoint.h (check_tracepoint_command): Don't declare.
4446 * breakpoint.c (check_tracepoint_command): Remove.
4447 (commands_command_1, create_tracepoint_from_upload): Update.
4448
7a2c85f2
TT
44492018-05-04 Tom Tromey <tom@tromey.com>
4450
4451 PR gdb/11750:
4452 * cli/cli-script.h (enum command_control_type) <define_control>:
4453 New constant.
4454 * cli/cli-script.c (multi_line_command_p): Handle define_control.
4455 (build_command_line, execute_control_command_1)
4456 (process_next_line): Likewise.
4457 (do_define_command): New function, extracted from define_command.
4458 (define_command): Use it.
4459
295dc222
TT
44602018-05-04 Tom Tromey <tom@tromey.com>
4461
4462 * tracepoint.c (actions_command): Update.
4463 * cli/cli-script.h (read_command_lines): Update.
4464 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
4465 (MAX_TMPBUF): Remove define.
4466 (define_command): Use string_printf.
4467 (document_command): Likewise.
4468 * breakpoint.c (commands_command_1): Update.
4469
1263a9d5
TT
44702018-05-04 Tom Tromey <tom@tromey.com>
4471
4472 * top.c (execute_command): Update.
4473 * cli/cli-script.h (print_command_lines): Now varargs.
4474 * cli/cli-script.c (print_command_lines): Now varargs.
4475 (execute_control_command_1) <case while_control, case if_control>:
4476 Update.
4477
12973681
TT
44782018-05-04 Tom Tromey <tom@tromey.com>
4479
4480 * tracepoint.c (all_tracepoint_actions): Rename from
4481 all_tracepoint_actions_and_cleanup. Change return type.
4482 (actions_command, encode_actions_1, encode_actions)
4483 (trace_dump_actions, tdump_command): Update.
4484 * remote.c (remote_download_command_source): Update.
4485 * python/python.c (gdbpy_eval_from_control_command)
4486 (python_command, python_interactive_command): Update.
4487 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
4488 * guile/guile.c (guile_command)
4489 (gdbscm_eval_from_control_command, guile_command): Update.
4490 * compile/compile.c (compile_code_command)
4491 (compile_print_command, compile_to_object): Update.
4492 * cli/cli-script.h (struct command_lines_deleter): New.
4493 (counted_command_line): New typedef.
4494 (struct command_line): Add constructor, destructor.
4495 <body_list>: Remove.
4496 <body_list_0, body_list_1>: New members.
4497 (command_line_up): Remove typedef.
4498 (read_command_lines, read_command_lines_1, get_command_line):
4499 Update.
4500 (copy_command_lines): Don't declare.
4501 * cli/cli-script.c (build_command_line): Use "new".
4502 (get_command_line): Return counted_command_line.
4503 (print_command_lines, execute_user_command)
4504 (execute_control_command_1, while_command, if_command): Update.
4505 (realloc_body_list): Remove.
4506 (process_next_line, recurse_read_control_structure): Update.
4507 (read_command_lines, read_command_lines_1): Return counted_command_line.
4508 (free_command_lines): Use "delete".
4509 (copy_command_lines): Remove.
4510 (define_command, document_command, show_user_1): Update.
4511 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
4512 a counted_command_line.
4513 * breakpoint.h (counted_command_line): Remove typedef.
4514 (breakpoint_set_commands): Update.
4515 * breakpoint.c (check_no_tracepoint_commands)
4516 (validate_commands_for_breakpoint): Update.
4517 (breakpoint_set_commands): Change commands to be a
4518 counted_command_line.
4519 (commands_command_1, update_dprintf_command_list)
4520 (create_tracepoint_from_upload): Update.
4521
e2fc72e2
TT
45222018-05-04 Tom Tromey <tom@tromey.com>
4523
4524 * cli/cli-decode.h (cmd_list_element): New constructor.
4525 (~cmd_list_element): New destructor.
4526 (struct cmd_list_element): Add initializers.
4527 * cli/cli-decode.c (do_add_cmd): Use "new".
4528 (delete_cmd): Use "delete".
4529
a3b60e45
JK
45302018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
4531 Pedro Alves <palves@redhat.com>
4532
4533 PR breakpoints/19806 and support for PR external/20207.
4534 * NEWS: Mention Aarch64 watchpoint improvements.
4535 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
4536 watchpoints and PR external/20207 watchpoints.
4537 * nat/aarch64-linux-hw-point.c
4538 (kernel_supports_any_contiguous_range): New.
4539 (aarch64_watchpoint_offset): New.
4540 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
4541 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
4542 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
4543 (aarch64_align_watchpoint): New parameters aligned_offset_p and
4544 next_addr_orig_p. Support PR external/20207 watchpoints.
4545 (aarch64_downgrade_regs): New.
4546 (aarch64_dr_state_insert_one_point): New parameters offset and
4547 addr_orig.
4548 (aarch64_dr_state_remove_one_point): Likewise.
4549 (aarch64_handle_breakpoint): Update caller.
4550 (aarch64_handle_aligned_watchpoint): Likewise.
4551 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
4552 aligned_offset.
4553 (aarch64_linux_set_debug_regs): Remove const from state. Call
4554 aarch64_downgrade_regs.
4555 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
4556 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
4557 (DR_CONTROL_MASK): ... this.
4558 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
4559 (unsigned int aarch64_watchpoint_offset): New prototype.
4560 (aarch64_linux_set_debug_regs): Remove const from state.
4561 * utils.c (align_up, align_down): Move to ...
4562 * common/common-utils.c (align_up, align_down): ... here.
4563 * utils.h (align_up, align_down): Move to ...
4564 * common/common-utils.h (align_up, align_down): ... here.
4565
05bc7456
JB
45662018-05-04 Joel Brobecker <brobecker@adacore.com>
4567
4568 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
4569 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
4570 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
4571 Re-implement to match the ABI as summarized in GCC's
4572 gcc/config/sparc/sparc.c. All callers updated.
4573 (sparc32_store_arguments): Remove assertion.
4574
2f433492
TT
45752018-05-04 Tom Tromey <tom@tromey.com>
4576
4577 * printcmd.c: Don't include tui.h.
4578 (decode_format): Use skip_spaces.
4579
9be2ae8f
TT
45802018-05-04 Tom Tromey <tom@tromey.com>
4581
4582 PR gdb/22619:
4583 * printcmd.c (last_count): New global.
4584 (x_command): Use saved count when repeating.
4585
f0b3976b
TT
45862018-05-04 Tom Tromey <tom@tromey.com>
4587
4588 * nto-procfs.c (do_closedir_cleanup): Remove.
4589 (procfs_pidlist): Use gdb_dir_up.
4590 * procfs.c (do_closedir_cleanup): Remove.
4591 (proc_update_threads): Use gdb_dir_up.
4592 * common/filestuff.h (struct gdb_dir_deleter): New.
4593 (gdb_dir_up): New typedef.
4594
862d101a
TT
45952018-05-04 Tom Tromey <tom@tromey.com>
4596
4597 * ada-lang.c (print_mention_exception): Use std::string.
4598
cb7de75e
TT
45992018-05-04 Tom Tromey <tom@tromey.com>
4600
4601 * ada-lang.c (create_excep_cond_exprs): Update.
4602 (ada_exception_catchpoint_cond_string): Use std::string.
4603
49d83361
TT
46042018-05-04 Tom Tromey <tom@tromey.com>
4605
4606 * ada-lang.c (xget_renaming_scope): Return std::string.
4607 (old_renaming_is_invisible): Update.
4608
ade72a34
TT
46092018-05-04 Tom Tromey <tom@tromey.com>
4610
4611 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
4612 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
4613
2be4d7f0
UW
46142018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
4615
4616 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
4617
69b6ecb0
TT
46182018-05-04 Tom Tromey <tom@tromey.com>
4619
4620 * remote.c (remote_query_supported_append): Change type.
4621 (remote_check_symbols): Update.
4622
bf27f0e2
PP
46232018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
4624
4625 PR gdb/11420
4626 * configure.ac: Prepend libpython.
4627 * python/python-config.py: Likewise.
4628 * configure: Regenerate.
4629
4ea17de8
SM
46302018-05-03 Simon Marchi <simon.marchi@ericsson.com>
4631
4632 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
4633
bd732259
PA
46342018-05-03 Pedro Alves <palves@redhat.com>
4635
4636 * s390-linux-nat.c
4637 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
4638 override. Write 'true' instead of '1'.
4639 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
4640 declaration.
4641
d9f719f1
PA
46422018-05-02 Pedro Alves <palves@redhat.com>
4643
4644 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
4645 add_inf_child_target.
4646 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
4647 add_inf_child_target.
4648 * aix-thread.c (aix_thread_target_info): New.
4649 (aix_thread_target) <shortname, longname, doc>: Delete.
4650 <info>: New.
4651 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
4652 add_inf_child_target.
4653 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
4654 add_inf_child_target.
4655 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
4656 add_inf_child_target.
4657 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
4658 add_inf_child_target.
4659 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
4660 add_inf_child_target.
4661 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
4662 add_inf_child_target.
4663 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
4664 add_inf_child_target.
4665 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
4666 add_inf_child_target.
4667 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
4668 add_inf_child_target.
4669 * bfd-target.c (target_bfd_target_info): New.
4670 (target_bfd) <shortname, longname, doc>: Delete.
4671 <info>: New.
4672 * bsd-kvm.c (bsd_kvm_target_info): New.
4673 (bsd_kvm_target) <shortname, longname, doc>: Delete.
4674 <info>: New.
4675 (bsd_kvm_target::open): Rename to ...
4676 (bsd_kvm_target_open): ... this. Adjust.
4677 * bsd-uthread.c (bsd_uthread_target_info): New.
4678 (bsd_uthread_target) <shortname, longname, doc>: Delete.
4679 <info>: New.
4680 * corefile.c (core_file_command): Adjust.
4681 * corelow.c (core_target_info): New.
4682 (core_target) <shortname, longname, doc>: Delete.
4683 <info>: New.
4684 (core_target::open): Rename to ...
4685 (core_target_open): ... this. Adjust.
4686 * ctf.c (ctf_target_info): New.
4687 (ctf_target) <shortname, longname, doc>: Delete.
4688 <info>: New.
4689 (ctf_target::open): Rename to ...
4690 (ctf_target_open): ... this.
4691 (_initialize_ctf): Adjust.
4692 * exec.c (exec_target_info): New.
4693 (exec_target) <shortname, longname, doc>: Delete.
4694 <info>: New.
4695 (exec_target::open): Rename to ...
4696 (exec_target_open): ... this.
4697 * gdbcore.h (core_target_open): Declare.
4698 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
4699 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
4700 add_inf_child_target.
4701 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
4702 add_inf_child_target.
4703 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
4704 add_inf_child_target.
4705 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
4706 add_inf_child_target.
4707 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
4708 add_inf_child_target.
4709 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
4710 add_inf_child_target.
4711 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
4712 add_inf_child_target.
4713 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
4714 add_inf_child_target.
4715 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
4716 add_inf_child_target.
4717 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
4718 add_inf_child_target.
4719 * inf-child.c (inf_child_target_info): New.
4720 (inf_child_target::info): New.
4721 (inf_child_open_target): Remove 'target' parameter. Use
4722 get_native_target instead.
4723 (inf_child_target::open): Delete.
4724 (add_inf_child_target): New.
4725 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
4726 Delete.
4727 <info>: New.
4728 (add_inf_child_target): Declare.
4729 (inf_child_open_target): Declare.
4730 * linux-thread-db.c (thread_db_target_info): New.
4731 (thread_db_target) <shortname, longname, doc>: Delete.
4732 <info>: New.
4733 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
4734 add_inf_child_target.
4735 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
4736 add_inf_child_target.
4737 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
4738 add_inf_child_target.
4739 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
4740 add_inf_child_target.
4741 * make-target-delegates (print_class): Adjust.
4742 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
4743 add_inf_child_target.
4744 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
4745 add_inf_child_target.
4746 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
4747 add_inf_child_target.
4748 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
4749 add_inf_child_target.
4750 * nto-procfs.c (nto_native_target_info): New.
4751 (nto_procfs_target_native) <shortname, longname, doc>:
4752 Delete.
4753 <info>: New.
4754 (nto_procfs_target_info): New.
4755 (nto_procfs_target_procfs) <shortname, longname, doc>:
4756 Delete.
4757 <info>: New.
4758 (init_procfs_targets): Adjust.
4759 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
4760 add_inf_child_target.
4761 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
4762 add_inf_child_target.
4763 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
4764 add_inf_child_target.
4765 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
4766 add_inf_child_target.
4767 * ravenscar-thread.c (ravenscar_target_info): New.
4768 (ravenscar_thread_target) <shortname, longname, doc>:
4769 Delete.
4770 <info>: New.
4771 * record-btrace.c (record_btrace_target_info):
4772 (record_btrace_target) <shortname, longname, doc>: Delete.
4773 <info>: New.
4774 (record_btrace_target::open): Rename to ...
4775 (record_btrace_target_open): ... this. Adjust.
4776 * record-full.c (record_longname, record_doc): New.
4777 (record_full_base_target) <shortname, longname, doc>: Delete.
4778 <info>: New.
4779 (record_full_target_info): New.
4780 (record_full_target): <shortname>: Delete.
4781 <info>: New.
4782 (record_full_core_open_1, record_full_open_1): Update comments.
4783 (record_full_base_target::open): Rename to ...
4784 (record_full_open): ... this.
4785 (cmd_record_full_restore): Update.
4786 (_initialize_record_full): Update.
4787 * remote-sim.c (remote_sim_target_info): New.
4788 (gdbsim_target) <shortname, longname, doc>: Delete.
4789 <info>: New.
4790 (gdbsim_target::open): Rename to ...
4791 (gdbsim_target_open): ... this.
4792 (_initialize_remote_sim): Adjust.
4793 * remote.c (remote_doc): New.
4794 (remote_target_info): New.
4795 (remote_target) <shortname, longname, doc>: Delete.
4796 <info>: New.
4797 (extended_remote_target_info): New.
4798 (extended_remote_target) <shortname, longname, doc>: Delete.
4799 <info>: New.
4800 (remote_target::open_1): Make static. Adjust.
4801 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
4802 * s390-linux-nat.c (_initialize_s390_nat): Use
4803 add_inf_child_target.
4804 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
4805 add_inf_child_target.
4806 * sol-thread.c (thread_db_target_info): New.
4807 (sol_thread_target) <shortname, longname, doc>: Delete.
4808 <info>: New.
4809 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
4810 add_inf_child_target.
4811 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
4812 add_inf_child_target.
4813 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
4814 add_inf_child_target.
4815 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
4816 add_inf_child_target.
4817 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
4818 add_inf_child_target.
4819 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
4820 add_inf_child_target.
4821 * spu-linux-nat.c (_initialize_spu_nat): Use
4822 add_inf_child_target.
4823 * spu-multiarch.c (spu_multiarch_target_info): New.
4824 (spu_multiarch_target) <shortname, longname, doc>: Delete.
4825 <info>: New.
4826 * target-delegates.c: Regenerate.
4827 * target.c: Include <unordered_map>.
4828 (target_ops_p): Delete.
4829 (DEF_VEC_P(target_ops_p)): Delete.
4830 (target_factories): New.
4831 (test_target_info): New.
4832 (test_target_ops::info): New.
4833 (open_target): Adjust to use target_factories.
4834 (add_target_with_completer): Rename to ...
4835 (add_target): ... this. Change prototype. Register target_info
4836 and open callback in target_factories. Register target_info in
4837 command context instead of target_ops.
4838 (add_target): Delete old implementation.
4839 (add_deprecated_target_alias): Change prototype. Adjust.
4840 (the_native_target): New.
4841 (set_native_target, get_native_target): New.
4842 (find_default_run_target): Use the_native_target.
4843 (find_attach_target, find_run_target): Simplify.
4844 (target_ops::open): Delete.
4845 (dummy_target_info): New.
4846 (dummy_target::shortname, dummy_target::longname)
4847 (dummy_target::doc): Delete.
4848 (dummy_target::info): New.
4849 (debug_target::shortname, debug_target::longname)
4850 (debug_target::doc): Delete.
4851 (debug_target::info): New.
4852 * target.h (struct target_info): New.
4853 (target_ops::~target_ops): Add comment.
4854 (target_ops::info): New.
4855 (target_ops::shortname, target_ops::longname, target_ops::doc): No
4856 longer virtual. Implement in terms of target_info.
4857 (set_native_target, get_native_target): Declare.
4858 (target_open_ftype): New.
4859 (add_target, add_target_with_completer)
4860 (add_deprecated_target_alias): Change prototype.
4861 (test_target) <shortname, longname, doc>: Delete.
4862 <info>: New.
4863 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
4864 add_inf_child_target.
4865 * tracefile-tfile.c (tfile_target_info): New.
4866 (tfile_target) <shortname, longname, doc>: Delete.
4867 <info>: New.
4868 (tfile_target::open): Rename to ...
4869 (tfile_target_open): ... this.
4870 (_initialize_tracefile_tfile): Adjust.
4871 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
4872 add_inf_child_target.
4873 * windows-nat.c (_initialize_windows_nat): Use
4874 add_inf_child_target.
4875 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
4876 add_inf_child_target.
4877
135340af
PA
48782018-05-02 Pedro Alves <palves@redhat.com>
4879
4880 * linux-nat.h (linux_nat_target) <low_new_thread,
4881 low_delete_thread, low_new_fork, low_forget_process,
4882 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
4883 New virtual methods.
4884 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4885 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
4886 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
4887 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4888 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
4889 Delete.
4890 * linux-fork.c (delete_fork): Adjust to call low method.
4891 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
4892 (linux_nat_new_fork, linux_nat_forget_process_hook)
4893 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
4894 (linux_nat_status_is_event):
4895 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
4896 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
4897 to call low method.
4898 (sigtrap_is_event): Rename to ...
4899 (linux_nat_target::low_status_is_event): ... this.
4900 (linux_nat_set_status_is_event): Delete.
4901 (save_stop_reason, linux_nat_wait_1)
4902 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
4903 low methods.
4904 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4905 (linux_nat_set_new_fork, linux_nat_set_forget_process)
4906 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4907 (linux_nat_set_prepare_to_resume): Delete.
4908 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
4909 low virtual methods.
4910 * amd64-linux-nat.c: Likewise.
4911 * arm-linux-nat.c: Likewise.
4912 * i386-linux-nat.c: Likewise.
4913 * ia64-linux-nat.c: Likewise.
4914 * mips-linux-nat.c: Likewise.
4915 * ppc-linux-nat.c: Likewise.
4916 * s390-linux-nat.c: Likewise.
4917 * sparc64-linux-nat.c: Likewise.
4918 * x86-linux-nat.c: Likewise.
4919 * x86-linux-nat.h: Include "nat/x86-linux.h".
4920 (x86_linux_nat_target) <low_new_fork, low_forget_process,
4921 low_prepare_to_resume, low_new_thread, low_delete_thread>:
4922 Override methods.
4923
57810aa7
PA
49242018-05-02 Pedro Alves <palves@redhat.com>
4925
4926 * target.h (target_ops)
4927 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4928 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
4929 stopped_by_watchpoint, have_continuable_watchpoint,
4930 stopped_data_address, watchpoint_addr_within_range,
4931 can_accel_watchpoint_condition, can_run, thread_alive,
4932 has_all_memory, has_memory, has_stack, has_registers,
4933 has_execution, can_async_p, is_async_p, supports_non_stop,
4934 always_non_stop_p, can_execute_reverse, supports_multi_process,
4935 supports_enable_disable_tracepoint,
4936 supports_disable_randomization, supports_string_tracing,
4937 supports_evaluation_of_breakpoint_conditions,
4938 can_run_breakpoint_commands, filesystem_is_local,
4939 can_download_tracepoint, get_trace_state_variable_value,
4940 set_trace_notes, get_tib_address, use_agent, can_use_agent,
4941 record_is_replaying, record_will_replay,
4942 augmented_libraries_svr4_read>: Adjust to return bool.
4943 * aarch64-linux-nat.c: All implementations adjusted.
4944 * aix-thread.c: All implementations adjusted.
4945 * arm-linux-nat.c: All implementations adjusted.
4946 * breakpoint.c: All implementations adjusted.
4947 * bsd-kvm.c: All implementations adjusted.
4948 * bsd-uthread.c: All implementations adjusted.
4949 * corelow.c: All implementations adjusted.
4950 * ctf.c: All implementations adjusted.
4951 * darwin-nat.c: All implementations adjusted.
4952 * darwin-nat.h: All implementations adjusted.
4953 * exec.c: All implementations adjusted.
4954 * fbsd-nat.c: All implementations adjusted.
4955 * fbsd-nat.h: All implementations adjusted.
4956 * gnu-nat.c: All implementations adjusted.
4957 * gnu-nat.h: All implementations adjusted.
4958 * go32-nat.c: All implementations adjusted.
4959 * ia64-linux-nat.c: All implementations adjusted.
4960 * inf-child.c: All implementations adjusted.
4961 * inf-child.h: All implementations adjusted.
4962 * inf-ptrace.c: All implementations adjusted.
4963 * inf-ptrace.h: All implementations adjusted.
4964 * linux-nat.c: All implementations adjusted.
4965 * linux-nat.h: All implementations adjusted.
4966 * mips-linux-nat.c: All implementations adjusted.
4967 * nto-procfs.c: All implementations adjusted.
4968 * ppc-linux-nat.c: All implementations adjusted.
4969 * procfs.c: All implementations adjusted.
4970 * ravenscar-thread.c: All implementations adjusted.
4971 * record-btrace.c: All implementations adjusted.
4972 * record-full.c: All implementations adjusted.
4973 * remote-sim.c: All implementations adjusted.
4974 * remote.c: All implementations adjusted.
4975 * s390-linux-nat.c: All implementations adjusted.
4976 * sol-thread.c: All implementations adjusted.
4977 * spu-multiarch.c: All implementations adjusted.
4978 * target-delegates.c: All implementations adjusted.
4979 * target.c: All implementations adjusted.
4980 * target.h: All implementations adjusted.
4981 * tracefile-tfile.c: All implementations adjusted.
4982 * tracefile.c: All implementations adjusted.
4983 * tracefile.h: All implementations adjusted.
4984 * windows-nat.c: All implementations adjusted.
4985 * x86-linux-nat.h: All implementations adjusted.
4986 * x86-nat.h: All implementations adjusted.
4987
ad6a4e2d
PA
49882018-05-02 Pedro Alves <palves@redhat.com>
4989
4990 * make-target-delegates (scan_target_h): Don't trim lines here.
4991 Replace sequences of tabs and/or whitespace with a single
4992 whitespace.
4993 (top level, parsing methods): Trim each line before processing it
4994 here.
4995
f6ac5f3d
PA
49962018-05-02 Pedro Alves <palves@redhat.com>
4997 John Baldwin <jhb@freebsd.org>
4998
4999 * target.h (enum strata) <debug_stratum>: New.
5000 (struct target_ops) <all delegation methods>: Replace by C++
5001 virtual methods, and drop "to_" prefix. All references updated
5002 throughout.
5003 <to_shortname, to_longname, to_doc, to_data,
5004 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
5005 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
5006 virtual methods. All references updated throughout.
5007 <can_attach, supports_terminal_ours, can_create_inferior,
5008 get_thread_control_capabilities, attach_no_wait>: New
5009 virtual methods.
5010 <insert_breakpoint, remove_breakpoint>: Now
5011 TARGET_DEFAULT_NORETURN methods.
5012 <info_proc>: Now returns bool.
5013 <to_magic>: Delete.
5014 (OPS_MAGIC): Delete.
5015 (current_target): Delete. All references replaced by references
5016 to ...
5017 (target_stack): ... this. New.
5018 (target_shortname, target_longname): Adjust.
5019 (target_can_run): Now a function declaration.
5020 (default_child_has_all_memory, default_child_has_memory)
5021 (default_child_has_stack, default_child_has_registers)
5022 (default_child_has_execution): Remove target_ops parameter.
5023 (complete_target_initialization): Delete.
5024 (memory_breakpoint_target): New template class.
5025 (test_target_ops): Refactor as a C++ class with virtual methods.
5026 * make-target-delegates (NAME_PART): Tighten.
5027 (POINTER_PART, CP_SYMBOL): New.
5028 (SIMPLE_RETURN_PART): Reimplement.
5029 (VEC_RETURN_PART): Expect less.
5030 (RETURN_PART, VIRTUAL_PART): New.
5031 (METHOD): Adjust to C++ virtual methods.
5032 (scan_target_h): Remove reference to C99.
5033 (dname): Output "target_ops::" prefix.
5034 (write_function_header): Adjust to output a C++ class method.
5035 (write_declaration): New.
5036 (write_delegator): Adjust to output a C++ class method.
5037 (tdname): Output "dummy_target::" prefix.
5038 (write_tdefault, write_debugmethod): Adjust to output a C++ class
5039 method.
5040 (tdefault_names, debug_names): Delete.
5041 (return_types, tdefaults, styles, argtypes_array): New.
5042 (top level): All methods are delegators.
5043 (print_class): New.
5044 (top level): Print dummy_target and debug_target classes.
5045 * target-delegates.c: Regenerate.
5046 * target-debug.h (target_debug_print_enum_info_proc_what)
5047 (target_debug_print_thread_control_capabilities)
5048 (target_debug_print_thread_info_p): New.
5049 * target.c (dummy_target): Delete.
5050 (the_dummy_target, the_debug_target): New.
5051 (target_stack): Now extern.
5052 (set_targetdebug): Push/unpush debug target.
5053 (default_child_has_all_memory, default_child_has_memory)
5054 (default_child_has_stack, default_child_has_registers)
5055 (default_child_has_execution): Remove target_ops parameter.
5056 (complete_target_initialization): Delete.
5057 (add_target_with_completer): No longer call
5058 complete_target_initialization.
5059 (target_supports_terminal_ours): Use regular delegation.
5060 (update_current_target): Delete.
5061 (push_target): No longer check magic number. Don't call
5062 update_current_target.
5063 (unpush_target): Don't call update_current_target.
5064 (target_is_pushed): No longer check magic number.
5065 (target_require_runnable): Skip for all stratums over
5066 process_stratum.
5067 (target_ops::info_proc): New.
5068 (target_info_proc): Use find_target_at and
5069 find_default_run_target.
5070 (target_supports_disable_randomization): Use regular delegation.
5071 (target_get_osdata): Use find_target_at.
5072 (target_ops::open, target_ops::close, target_ops::can_attach)
5073 (target_ops::attach, target_ops::can_create_inferior)
5074 (target_ops::create_inferior, target_ops::can_run)
5075 (target_can_run): New.
5076 (default_fileio_target): Use regular delegation.
5077 (target_ops::fileio_open, target_ops::fileio_pwrite)
5078 (target_ops::fileio_pread, target_ops::fileio_fstat)
5079 (target_ops::fileio_close, target_ops::fileio_unlink)
5080 (target_ops::fileio_readlink): New.
5081 (target_fileio_open_1, target_fileio_unlink)
5082 (target_fileio_readlink): Always call the target method. Handle
5083 FILEIO_ENOSYS.
5084 (return_zero, return_zero_has_execution): Delete.
5085 (init_dummy_target): Delete.
5086 (dummy_target::dummy_target, dummy_target::shortname)
5087 (dummy_target::longname, dummy_target::doc)
5088 (debug_target::debug_target, debug_target::shortname)
5089 (debug_target::longname, debug_target::doc): New.
5090 (target_supports_delete_record): Use regular delegation.
5091 (setup_target_debug): Delete.
5092 (maintenance_print_target_stack): Skip debug_stratum.
5093 (initialize_targets): Instantiate the_dummy_target and
5094 the_debug_target.
5095 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
5096 use target_stack.
5097 (target_auxv_search, fprint_target_auxv): Adjust.
5098 (info_auxv_command): Adjust to use target_stack.
5099 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
5100 * exceptions.c (print_flush): Handle a NULL target_stack.
5101 * regcache.c (target_ops_no_register): Refactor as class with
5102 virtual methods.
5103
5104 * exec.c (exec_target): New class.
5105 (exec_ops): Now an exec_target.
5106 (exec_open, exec_close_1, exec_get_section_table)
5107 (exec_xfer_partial, exec_files_info, exec_has_memory)
5108 (exec_make_note_section): Refactor as exec_target methods.
5109 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
5110 Delete.
5111 (exec_target::find_memory_regions): New.
5112 (_initialize_exec): Don't call init_exec_ops.
5113 * gdbcore.h (exec_file_clear): Delete.
5114
5115 * corefile.c (core_target): Delete.
5116 (core_file_command): Adjust.
5117 * corelow.c (core_target): New class.
5118 (the_core_target): New.
5119 (core_close): Remove target_ops parameter.
5120 (core_close_cleanup): Adjust.
5121 (core_target::close): New.
5122 (core_open, core_detach, get_core_registers, core_files_info)
5123 (core_xfer_partial, core_thread_alive, core_read_description)
5124 (core_pid_to_str, core_thread_name, core_has_memory)
5125 (core_has_stack, core_has_registers, core_info_proc): Rework as
5126 core_target methods.
5127 (ignore, core_remove_breakpoint, init_core_ops): Delete.
5128 (_initialize_corelow): Initialize the_core_target.
5129 * gdbcore.h (core_target): Delete.
5130 (the_core_target): New.
5131
5132 * ctf.c: (ctf_target): New class.
5133 (ctf_ops): Now a ctf_target.
5134 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
5135 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
5136 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
5137 methods.
5138 (init_ctf_ops): Delete.
5139 (_initialize_ctf): Don't call it.
5140 * tracefile-tfile.c (tfile_target): New class.
5141 (tfile_ops): Now a tfile_target.
5142 (tfile_open, tfile_close, tfile_files_info)
5143 (tfile_get_tracepoint_status, tfile_trace_find)
5144 (tfile_fetch_registers, tfile_xfer_partial)
5145 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
5146 Refactor as tfile_target methods.
5147 (tfile_xfer_partial_features): Remove target_ops parameter.
5148 (init_tfile_ops): Delete.
5149 (_initialize_tracefile_tfile): Don't call it.
5150 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
5151 (tracefile_has_stack, tracefile_has_registers)
5152 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
5153 tracefile_target methods.
5154 (init_tracefile_ops): Delete.
5155 (tracefile_target::tracefile_target): New.
5156 * tracefile.h: Include "target.h".
5157 (tracefile_target): New class.
5158 (init_tracefile_ops): Delete.
5159
5160 * spu-multiarch.c (spu_multiarch_target): New class.
5161 (spu_ops): Now a spu_multiarch_target.
5162 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
5163 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
5164 (spu_search_memory, spu_mourn_inferior): Refactor as
5165 spu_multiarch_target methods.
5166 (init_spu_ops): Delete.
5167 (_initialize_spu_multiarch): Remove references to init_spu_ops,
5168 complete_target_initialization.
5169
5170 * ravenscar-thread.c (ravenscar_thread_target): New class.
5171 (ravenscar_ops): Now a ravenscar_thread_target.
5172 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
5173 (ravenscar_thread_alive, ravenscar_pid_to_str)
5174 (ravenscar_fetch_registers, ravenscar_store_registers)
5175 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
5176 (ravenscar_stopped_by_hw_breakpoint)
5177 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
5178 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
5179 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
5180 methods.
5181 (init_ravenscar_thread_ops): Delete.
5182 (_initialize_ravenscar): Remove references to
5183 init_ravenscar_thread_ops and complete_target_initialization.
5184
5185 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
5186 (bsd_uthread_target): New class.
5187 (bsd_uthread_ops): Now a bsd_uthread_target.
5188 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
5189 (bsd_uthread_close, bsd_uthread_mourn_inferior)
5190 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
5191 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
5192 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
5193 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
5194 (bsd_uthread_target): Delete function.
5195 (_initialize_bsd_uthread): Remove reference to
5196 complete_target_initialization.
5197
5198 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
5199 (target_bfd): ... this new class.
5200 (target_bfd_xfer_partial, target_bfd_get_section_table)
5201 (target_bfd_close): Refactor as target_bfd methods.
5202 (target_bfd::~target_bfd): New.
5203 (target_bfd_reopen): Adjust.
5204 (target_bfd::close): New.
5205
5206 * record-btrace.c (record_btrace_target): New class.
5207 (record_btrace_ops): Now a record_btrace_target.
5208 (record_btrace_open, record_btrace_stop_recording)
5209 (record_btrace_disconnect, record_btrace_close)
5210 (record_btrace_async, record_btrace_info)
5211 (record_btrace_insn_history, record_btrace_insn_history_range)
5212 (record_btrace_insn_history_from, record_btrace_call_history)
5213 (record_btrace_call_history_range)
5214 (record_btrace_call_history_from, record_btrace_record_method)
5215 (record_btrace_is_replaying, record_btrace_will_replay)
5216 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
5217 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
5218 (record_btrace_store_registers, record_btrace_prepare_to_store)
5219 (record_btrace_to_get_unwinder)
5220 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
5221 (record_btrace_commit_resume, record_btrace_wait)
5222 (record_btrace_stop, record_btrace_can_execute_reverse)
5223 (record_btrace_stopped_by_sw_breakpoint)
5224 (record_btrace_supports_stopped_by_sw_breakpoint)
5225 (record_btrace_stopped_by_hw_breakpoint)
5226 (record_btrace_supports_stopped_by_hw_breakpoint)
5227 (record_btrace_update_thread_list, record_btrace_thread_alive)
5228 (record_btrace_goto_begin, record_btrace_goto_end)
5229 (record_btrace_goto, record_btrace_stop_replaying_all)
5230 (record_btrace_execution_direction)
5231 (record_btrace_prepare_to_generate_core)
5232 (record_btrace_done_generating_core): Refactor as
5233 record_btrace_target methods.
5234 (init_record_btrace_ops): Delete.
5235 (_initialize_record_btrace): Remove reference to
5236 init_record_btrace_ops.
5237 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
5238 the execution_direction global.
5239 (record_full_base_target, record_full_target)
5240 (record_full_core_target): New classes.
5241 (record_full_ops): Now a record_full_target.
5242 (record_full_core_ops): Now a record_full_core_target.
5243 (record_full_target::detach, record_full_target::disconnect)
5244 (record_full_core_target::disconnect)
5245 (record_full_target::mourn_inferior, record_full_target::kill):
5246 New.
5247 (record_full_open, record_full_close, record_full_async): Refactor
5248 as methods of the record_full_base_target class.
5249 (record_full_resume, record_full_commit_resume): Refactor
5250 as methods of the record_full_target class.
5251 (record_full_wait, record_full_stopped_by_watchpoint)
5252 (record_full_stopped_data_address)
5253 (record_full_stopped_by_sw_breakpoint)
5254 (record_full_supports_stopped_by_sw_breakpoint)
5255 (record_full_stopped_by_hw_breakpoint)
5256 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
5257 methods of the record_full_base_target class.
5258 (record_full_store_registers, record_full_xfer_partial)
5259 (record_full_insert_breakpoint, record_full_remove_breakpoint):
5260 Refactor as methods of the record_full_target class.
5261 (record_full_can_execute_reverse, record_full_get_bookmark)
5262 (record_full_goto_bookmark, record_full_execution_direction)
5263 (record_full_record_method, record_full_info, record_full_delete)
5264 (record_full_is_replaying, record_full_will_replay)
5265 (record_full_goto_begin, record_full_goto_end, record_full_goto)
5266 (record_full_stop_replaying): Refactor as methods of the
5267 record_full_base_target class.
5268 (record_full_core_resume, record_full_core_kill)
5269 (record_full_core_fetch_registers)
5270 (record_full_core_prepare_to_store)
5271 (record_full_core_store_registers, record_full_core_xfer_partial)
5272 (record_full_core_insert_breakpoint)
5273 (record_full_core_remove_breakpoint)
5274 (record_full_core_has_execution): Refactor
5275 as methods of the record_full_core_target class.
5276 (record_full_base_target::supports_delete_record): New.
5277 (init_record_full_ops): Delete.
5278 (init_record_full_core_ops): Delete.
5279 (record_full_save): Refactor as method of the
5280 record_full_base_target class.
5281 (_initialize_record_full): Remove references to
5282 init_record_full_ops and init_record_full_core_ops.
5283
5284 * remote.c (remote_target, extended_remote_target): New classes.
5285 (remote_ops): Now a remote_target.
5286 (extended_remote_ops): Now an extended_remote_target.
5287 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
5288 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
5289 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
5290 (remote_pass_signals, remote_set_syscall_catchpoint)
5291 (remote_program_signals, )
5292 (remote_thread_always_alive): Remove target_ops parameter.
5293 (remote_thread_alive, remote_thread_name)
5294 (remote_update_thread_list, remote_threads_extra_info)
5295 (remote_static_tracepoint_marker_at)
5296 (remote_static_tracepoint_markers_by_strid)
5297 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
5298 (remote_open): Refactor as methods of remote_target.
5299 (extended_remote_open, extended_remote_detach)
5300 (extended_remote_attach, extended_remote_post_attach):
5301 (extended_remote_supports_disable_randomization)
5302 (extended_remote_create_inferior): : Refactor as method of
5303 extended_remote_target.
5304 (remote_set_permissions, remote_open_1, remote_detach)
5305 (remote_follow_fork, remote_follow_exec, remote_disconnect)
5306 (remote_resume, remote_commit_resume, remote_stop)
5307 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
5308 (remote_terminal_ours, remote_wait, remote_fetch_registers)
5309 (remote_prepare_to_store, remote_store_registers)
5310 (remote_flash_erase, remote_flash_done, remote_files_info)
5311 (remote_kill, remote_mourn, remote_insert_breakpoint)
5312 (remote_remove_breakpoint, remote_insert_watchpoint)
5313 (remote_watchpoint_addr_within_range)
5314 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
5315 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
5316 (remote_supports_stopped_by_sw_breakpoint)
5317 (remote_stopped_by_hw_breakpoint)
5318 (remote_supports_stopped_by_hw_breakpoint)
5319 (remote_stopped_by_watchpoint, remote_stopped_data_address)
5320 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
5321 (remote_verify_memory): Refactor as methods of remote_target.
5322 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
5323 parameter.
5324 (remote_xfer_partial, remote_get_memory_xfer_limit)
5325 (remote_search_memory, remote_rcmd, remote_memory_map)
5326 (remote_pid_to_str, remote_get_thread_local_address)
5327 (remote_get_tib_address, remote_read_description): Refactor as
5328 methods of remote_target.
5329 (remote_target::fileio_open, remote_target::fileio_pwrite)
5330 (remote_target::fileio_pread, remote_target::fileio_close): New.
5331 (remote_hostio_readlink, remote_hostio_fstat)
5332 (remote_filesystem_is_local, remote_can_execute_reverse)
5333 (remote_supports_non_stop, remote_supports_disable_randomization)
5334 (remote_supports_multi_process, remote_supports_cond_breakpoints)
5335 (remote_supports_enable_disable_tracepoint)
5336 (remote_supports_string_tracing)
5337 (remote_can_run_breakpoint_commands, remote_trace_init)
5338 (remote_download_tracepoint, remote_can_download_tracepoint)
5339 (remote_download_trace_state_variable, remote_enable_tracepoint)
5340 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
5341 (remote_trace_start, remote_get_trace_status)
5342 (remote_get_tracepoint_status, remote_trace_stop)
5343 (remote_trace_find, remote_get_trace_state_variable_value)
5344 (remote_save_trace_data, remote_get_raw_trace_data)
5345 (remote_set_disconnected_tracing, remote_core_of_thread)
5346 (remote_set_circular_trace_buffer, remote_traceframe_info)
5347 (remote_get_min_fast_tracepoint_insn_len)
5348 (remote_set_trace_buffer_size, remote_set_trace_notes)
5349 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
5350 (remote_disable_btrace, remote_teardown_btrace)
5351 (remote_read_btrace, remote_btrace_conf)
5352 (remote_augmented_libraries_svr4_read, remote_load)
5353 (remote_pid_to_exec_file, remote_can_do_single_step)
5354 (remote_execution_direction, remote_thread_handle_to_thread_info):
5355 Refactor as methods of remote_target.
5356 (init_remote_ops, init_extended_remote_ops): Delete.
5357 (remote_can_async_p, remote_is_async_p, remote_async)
5358 (remote_thread_events, remote_upload_tracepoints)
5359 (remote_upload_trace_state_variables): Refactor as methods of
5360 remote_target.
5361 (_initialize_remote): Remove references to init_remote_ops and
5362 init_extended_remote_ops.
5363
5364 * remote-sim.c (gdbsim_target): New class.
5365 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
5366 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
5367 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
5368 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
5369 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
5370 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
5371 Refactor as methods of gdbsim_target.
5372 (gdbsim_ops): Now a gdbsim_target.
5373 (init_gdbsim_ops): Delete.
5374 (gdbsim_cntrl_c): Adjust.
5375 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
5376
5377 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
5378 (the_amd64_linux_nat_target): New.
5379 (amd64_linux_fetch_inferior_registers)
5380 (amd64_linux_store_inferior_registers): Refactor as methods of
5381 amd64_linux_nat_target.
5382 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
5383 * i386-linux-nat.c: Don't include "linux-nat.h".
5384 (i386_linux_nat_target): New class.
5385 (the_i386_linux_nat_target): New.
5386 (i386_linux_fetch_inferior_registers)
5387 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
5388 as methods of i386_linux_nat_target.
5389 (_initialize_i386_linux_nat): Adjust. Set linux_target.
5390 * inf-child.c (inf_child_ops): Delete.
5391 (inf_child_fetch_inferior_registers)
5392 (inf_child_store_inferior_registers): Delete.
5393 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
5394 methods of inf_child_target.
5395 (inf_child_target::supports_terminal_ours)
5396 (inf_child_target::terminal_init)
5397 (inf_child_target::terminal_inferior)
5398 (inf_child_target::terminal_ours_for_output)
5399 (inf_child_target::terminal_ours, inf_child_target::interrupt)
5400 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
5401 New.
5402 (inf_child_open, inf_child_disconnect, inf_child_close)
5403 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
5404 (inf_child_post_startup_inferior, inf_child_can_run)
5405 (inf_child_pid_to_exec_file): Refactor as methods of
5406 inf_child_target.
5407 (inf_child_follow_fork): Delete.
5408 (inf_child_target::can_create_inferior)
5409 (inf_child_target::can_attach): New.
5410 (inf_child_target::has_all_memory, inf_child_target::has_memory)
5411 (inf_child_target::has_stack, inf_child_target::has_registers)
5412 (inf_child_target::has_execution): New.
5413 (inf_child_fileio_open, inf_child_fileio_pwrite)
5414 (inf_child_fileio_pread, inf_child_fileio_fstat)
5415 (inf_child_fileio_close, inf_child_fileio_unlink)
5416 (inf_child_fileio_readlink, inf_child_use_agent)
5417 (inf_child_can_use_agent): Refactor as methods of
5418 inf_child_target.
5419 (return_zero, inf_child_target): Delete.
5420 (inf_child_target::inf_child_target): New.
5421 * inf-child.h: Include "target.h".
5422 (inf_child_target): Delete function prototype.
5423 (inf_child_target): New class.
5424 (inf_child_open_target, inf_child_mourn_inferior)
5425 (inf_child_maybe_unpush_target): Delete.
5426 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
5427 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
5428 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
5429 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
5430 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
5431 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
5432 (inf_ptrace_wait, inf_ptrace_xfer_partial)
5433 (inf_ptrace_thread_alive, inf_ptrace_files_info)
5434 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
5435 methods of inf_ptrace_target.
5436 (inf_ptrace_target): Delete function.
5437 * inf-ptrace.h: Include "inf-child.h".
5438 (inf_ptrace_target): Delete function declaration.
5439 (inf_ptrace_target): New class.
5440 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
5441 * linux-nat.c (linux_target): New.
5442 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
5443 (linux_nat_target::~linux_nat_target): New.
5444 (linux_child_post_attach, linux_child_post_startup_inferior)
5445 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
5446 (linux_child_remove_fork_catchpoint)
5447 (linux_child_insert_vfork_catchpoint)
5448 (linux_child_remove_vfork_catchpoint)
5449 (linux_child_insert_exec_catchpoint)
5450 (linux_child_remove_exec_catchpoint)
5451 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
5452 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
5453 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
5454 (linux_nat_stopped_data_address)
5455 (linux_nat_stopped_by_sw_breakpoint)
5456 (linux_nat_supports_stopped_by_sw_breakpoint)
5457 (linux_nat_stopped_by_hw_breakpoint)
5458 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
5459 (linux_nat_kill, linux_nat_mourn_inferior)
5460 (linux_nat_xfer_partial, linux_nat_thread_alive)
5461 (linux_nat_update_thread_list, linux_nat_pid_to_str)
5462 (linux_nat_thread_name, linux_child_pid_to_exec_file)
5463 (linux_child_static_tracepoint_markers_by_strid)
5464 (linux_nat_is_async_p, linux_nat_can_async_p)
5465 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
5466 (linux_nat_supports_multi_process)
5467 (linux_nat_supports_disable_randomization, linux_nat_async)
5468 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
5469 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
5470 (linux_nat_fileio_open, linux_nat_fileio_readlink)
5471 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
5472 methods of linux_nat_target.
5473 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
5474 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
5475 parameter.
5476 (check_stopped_by_watchpoint): Adjust.
5477 (linux_xfer_partial): Delete.
5478 (linux_target_install_ops, linux_target, linux_nat_add_target):
5479 Delete.
5480 (linux_nat_target::linux_nat_target): New.
5481 * linux-nat.h: Include "inf-ptrace.h".
5482 (linux_nat_target): New.
5483 (linux_target, linux_target_install_ops, linux_nat_add_target):
5484 Delete function declarations.
5485 (linux_target): Declare global.
5486 * linux-thread-db.c (thread_db_target): New.
5487 (thread_db_target::thread_db_target): New.
5488 (thread_db_ops): Delete.
5489 (the_thread_db_target): New.
5490 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
5491 (thread_db_update_thread_list, thread_db_pid_to_str)
5492 (thread_db_extra_thread_info)
5493 (thread_db_thread_handle_to_thread_info)
5494 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
5495 (thread_db_resume): Refactor as methods of thread_db_target.
5496 (init_thread_db_ops): Delete.
5497 (_initialize_thread_db): Remove reference to init_thread_db_ops.
5498 * x86-linux-nat.c: Don't include "linux-nat.h".
5499 (super_post_startup_inferior): Delete.
5500 (x86_linux_nat_target::~x86_linux_nat_target): New.
5501 (x86_linux_child_post_startup_inferior)
5502 (x86_linux_read_description, x86_linux_enable_btrace)
5503 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
5504 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
5505 methods of x86_linux_nat_target.
5506 (x86_linux_create_target): Delete. Bits folded ...
5507 (x86_linux_add_target): ... here. Now takes a linux_nat_target
5508 pointer.
5509 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
5510 (x86_linux_nat_target): New class.
5511 (x86_linux_create_target): Delete.
5512 (x86_linux_add_target): Now takes a linux_nat_target pointer.
5513 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
5514 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
5515 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
5516 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
5517 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
5518 make extern.
5519 (x86_use_watchpoints): Delete.
5520 * x86-nat.h: Include "breakpoint.h" and "target.h".
5521 (x86_use_watchpoints): Delete.
5522 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
5523 (x86_stopped_by_watchpoint, x86_stopped_data_address)
5524 (x86_insert_watchpoint, x86_remove_watchpoint)
5525 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
5526 (x86_stopped_by_hw_breakpoint): New declarations.
5527 (x86_nat_target): New template class.
5528
5529 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
5530 (the_ppc_linux_nat_target): New.
5531 (ppc_linux_fetch_inferior_registers)
5532 (ppc_linux_can_use_hw_breakpoint)
5533 (ppc_linux_region_ok_for_hw_watchpoint)
5534 (ppc_linux_ranged_break_num_registers)
5535 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
5536 (ppc_linux_insert_mask_watchpoint)
5537 (ppc_linux_remove_mask_watchpoint)
5538 (ppc_linux_can_accel_watchpoint_condition)
5539 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
5540 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
5541 (ppc_linux_watchpoint_addr_within_range)
5542 (ppc_linux_masked_watch_num_registers)
5543 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
5544 (ppc_linux_read_description): Refactor as methods of
5545 ppc_linux_nat_target.
5546 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
5547
5548 * procfs.c (procfs_xfer_partial): Delete forward declaration.
5549 (procfs_target): New class.
5550 (the_procfs_target): New.
5551 (procfs_target): Delete function.
5552 (procfs_auxv_parse, procfs_attach, procfs_detach)
5553 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
5554 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
5555 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
5556 (procfs_create_inferior, procfs_update_thread_list)
5557 (procfs_thread_alive, procfs_pid_to_str)
5558 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
5559 (procfs_stopped_data_address, procfs_insert_watchpoint)
5560 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
5561 (proc_find_memory_regions, procfs_info_proc)
5562 (procfs_make_note_section): Refactor as methods of procfs_target.
5563 (_initialize_procfs): Adjust.
5564 * sol-thread.c (sol_thread_target): New class.
5565 (sol_thread_ops): Now a sol_thread_target.
5566 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
5567 (sol_thread_fetch_registers, sol_thread_store_registers)
5568 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
5569 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
5570 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
5571 (init_sol_thread_ops): Delete.
5572 (_initialize_sol_thread): Adjust. Remove references to
5573 init_sol_thread_ops and complete_target_initialization.
5574
5575 * windows-nat.c (windows_nat_target): New class.
5576 (windows_fetch_inferior_registers)
5577 (windows_store_inferior_registers, windows_resume, windows_wait)
5578 (windows_attach, windows_detach, windows_pid_to_exec_file)
5579 (windows_files_info, windows_create_inferior)
5580 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
5581 (windows_close, windows_pid_to_str, windows_xfer_partial)
5582 (windows_get_tib_address, windows_get_ada_task_ptid)
5583 (windows_thread_name, windows_thread_alive): Refactor as
5584 windows_nat_target methods.
5585 (do_initial_windows_stuff): Adjust.
5586 (windows_target): Delete function.
5587 (_initialize_windows_nat): Adjust.
5588
5589 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
5590 (darwin_mourn_inferior, darwin_kill_inferior)
5591 (darwin_create_inferior, darwin_attach, darwin_detach)
5592 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
5593 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
5594 (darwin_supports_multi_process): Refactor as darwin_nat_target
5595 methods.
5596 (darwin_resume_to, darwin_files_info): Delete.
5597 (_initialize_darwin_inferior): Rename to ...
5598 (_initialize_darwin_nat): ... this. Adjust to C++ification.
5599 * darwin-nat.h: Include "inf-child.h".
5600 (darwin_nat_target): New class.
5601 (darwin_complete_target): Delete.
5602 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
5603 (darwin_target): New.
5604 (i386_darwin_fetch_inferior_registers)
5605 (i386_darwin_store_inferior_registers): Refactor as methods of
5606 darwin_nat_target.
5607 (darwin_complete_target): Delete, with ...
5608 (_initialize_i386_darwin_nat): ... bits factored out here.
5609
5610 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
5611 (the_alpha_linux_nat_target): New.
5612 (alpha_linux_register_u_offset): Refactor as
5613 alpha_linux_nat_target method.
5614 (_initialize_alpha_linux_nat): Adjust.
5615 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
5616 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
5617 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
5618 methods of linux_nat_trad_target.
5619 (linux_trad_target): Delete.
5620 * linux-nat-trad.h (linux_trad_target): Delete function.
5621 (linux_nat_trad_target): New class.
5622 * mips-linux-nat.c (mips_linux_nat_target): New class.
5623 (super_fetch_registers, super_store_registers, super_close):
5624 Delete.
5625 (the_mips_linux_nat_target): New.
5626 (mips64_linux_regsets_fetch_registers)
5627 (mips64_linux_regsets_store_registers)
5628 (mips64_linux_fetch_registers, mips64_linux_store_registers)
5629 (mips_linux_register_u_offset, mips_linux_read_description)
5630 (mips_linux_can_use_hw_breakpoint)
5631 (mips_linux_stopped_by_watchpoint)
5632 (mips_linux_stopped_data_address)
5633 (mips_linux_region_ok_for_hw_watchpoint)
5634 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
5635 (mips_linux_close): Refactor as methods of mips_linux_nat.
5636 (_initialize_mips_linux_nat): Adjust to C++ification.
5637
5638 * aix-thread.c (aix_thread_target): New class.
5639 (aix_thread_ops): Now an aix_thread_target.
5640 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
5641 (aix_thread_fetch_registers, aix_thread_store_registers)
5642 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
5643 (aix_thread_thread_alive, aix_thread_pid_to_str)
5644 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
5645 Refactor as methods of aix_thread_target.
5646 (init_aix_thread_ops): Delete.
5647 (_initialize_aix_thread): Remove references to init_aix_thread_ops
5648 and complete_target_initialization.
5649 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
5650 (rs6000_nat_target): New class.
5651 (the_rs6000_nat_target): New.
5652 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
5653 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
5654 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
5655 (super_create_inferior): Delete.
5656 (_initialize_rs6000_nat): Adjust to C++ification.
5657
5658 * arm-linux-nat.c (arm_linux_nat_target): New class.
5659 (the_arm_linux_nat_target): New.
5660 (arm_linux_fetch_inferior_registers)
5661 (arm_linux_store_inferior_registers, arm_linux_read_description)
5662 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
5663 (arm_linux_remove_hw_breakpoint)
5664 (arm_linux_region_ok_for_hw_watchpoint)
5665 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
5666 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
5667 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
5668 arm_linux_nat_target.
5669 (_initialize_arm_linux_nat): Adjust to C++ification.
5670
5671 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
5672 (the_aarch64_linux_nat_target): New.
5673 (aarch64_linux_fetch_inferior_registers)
5674 (aarch64_linux_store_inferior_registers)
5675 (aarch64_linux_child_post_startup_inferior)
5676 (aarch64_linux_read_description)
5677 (aarch64_linux_can_use_hw_breakpoint)
5678 (aarch64_linux_insert_hw_breakpoint)
5679 (aarch64_linux_remove_hw_breakpoint)
5680 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
5681 (aarch64_linux_region_ok_for_hw_watchpoint)
5682 (aarch64_linux_stopped_data_address)
5683 (aarch64_linux_stopped_by_watchpoint)
5684 (aarch64_linux_watchpoint_addr_within_range)
5685 (aarch64_linux_can_do_single_step): Refactor as methods of
5686 aarch64_linux_nat_target.
5687 (super_post_startup_inferior): Delete.
5688 (_initialize_aarch64_linux_nat): Adjust to C++ification.
5689
5690 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
5691 (the_hppa_linux_nat_target): New.
5692 (hppa_linux_fetch_inferior_registers)
5693 (hppa_linux_store_inferior_registers): Refactor as methods of
5694 hppa_linux_nat_target.
5695 (_initialize_hppa_linux_nat): Adjust to C++ification.
5696
5697 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
5698 (the_ia64_linux_nat_target): New.
5699 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
5700 (ia64_linux_stopped_data_address)
5701 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
5702 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
5703 ia64_linux_nat_target methods.
5704 (super_xfer_partial): Delete.
5705 (_initialize_ia64_linux_nat): Adjust to C++ification.
5706
5707 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
5708 (the_m32r_linux_nat_target): New.
5709 (m32r_linux_fetch_inferior_registers)
5710 (m32r_linux_store_inferior_registers): Refactor as
5711 m32r_linux_nat_target methods.
5712 (_initialize_m32r_linux_nat): Adjust to C++ification.
5713
5714 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
5715 (the_m68k_linux_nat_target): New.
5716 (m68k_linux_fetch_inferior_registers)
5717 (m68k_linux_store_inferior_registers): Refactor as
5718 m68k_linux_nat_target methods.
5719 (_initialize_m68k_linux_nat): Adjust to C++ification.
5720
5721 * s390-linux-nat.c (s390_linux_nat_target): New class.
5722 (the_s390_linux_nat_target): New.
5723 (s390_linux_fetch_inferior_registers)
5724 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
5725 (s390_insert_watchpoint, s390_remove_watchpoint)
5726 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
5727 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
5728 (s390_auxv_parse, s390_read_description): Refactor as methods of
5729 s390_linux_nat_target.
5730 (_initialize_s390_nat): Adjust to C++ification.
5731
5732 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
5733 (the_sparc_linux_nat_target): New.
5734 (_initialize_sparc_linux_nat): Adjust to C++ification.
5735 * sparc-nat.c (sparc_fetch_inferior_registers)
5736 (sparc_store_inferior_registers): Remove target_ops parameter.
5737 * sparc-nat.h (sparc_fetch_inferior_registers)
5738 (sparc_store_inferior_registers): Remove target_ops parameter.
5739 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
5740 (the_sparc64_linux_nat_target): New.
5741 (_initialize_sparc64_linux_nat): Adjust to C++ification.
5742
5743 * spu-linux-nat.c (spu_linux_nat_target): New class.
5744 (the_spu_linux_nat_target): New.
5745 (spu_child_post_startup_inferior, spu_child_post_attach)
5746 (spu_child_wait, spu_fetch_inferior_registers)
5747 (spu_store_inferior_registers, spu_xfer_partial)
5748 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
5749 methods.
5750 (_initialize_spu_nat): Adjust to C++ification.
5751
5752 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
5753 (the_tilegx_linux_nat_target): New.
5754 (fetch_inferior_registers, store_inferior_registers):
5755 Refactor as methods.
5756 (_initialize_tile_linux_nat): Adjust to C++ification.
5757
5758 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
5759 (the_xtensa_linux_nat_target): New.
5760 (xtensa_linux_fetch_inferior_registers)
5761 (xtensa_linux_store_inferior_registers): Refactor as
5762 xtensa_linux_nat_target methods.
5763 (_initialize_xtensa_linux_nat): Adjust to C++ification.
5764
5765 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
5766 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
5767 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
5768 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
5769 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
5770 (fbsd_stopped_by_sw_breakpoint)
5771 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
5772 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
5773 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
5774 (fbsd_post_startup_inferior, fbsd_post_attach)
5775 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
5776 (fbsd_set_syscall_catchpoint)
5777 (super_xfer_partial, super_resume, super_wait)
5778 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
5779 (fbsd_handle_debug_trap): Remove target_ops parameter.
5780 (fbsd_nat_add_target): Delete.
5781 * fbsd-nat.h: Include "inf-ptrace.h".
5782 (fbsd_nat_add_target): Delete.
5783 (USE_SIGTRAP_SIGINFO): Define.
5784 (fbsd_nat_target): New class.
5785
5786 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
5787 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
5788 (amd64bsd_target): Delete.
5789 * amd64-bsd-nat.h: New file.
5790 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
5791 "x86-bsd-nat.h".
5792 (amd64_fbsd_nat_target): New class.
5793 (the_amd64_fbsd_nat_target): New.
5794 (amd64fbsd_read_description): Refactor as method of
5795 amd64_fbsd_nat_target.
5796 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5797 (_initialize_amd64fbsd_nat): Adjust to C++ification.
5798 * amd64-nat.h (amd64bsd_target): Delete function declaration.
5799 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
5800 (i386bsd_store_inferior_registers): Remove target_ops parameter.
5801 (i386bsd_target): Delete.
5802 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
5803 (i386bsd_fetch_inferior_registers)
5804 (i386bsd_store_inferior_registers): Declare.
5805 (i386_bsd_nat_target): New class.
5806 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
5807 (the_i386_fbsd_nat_target): New.
5808 (i386fbsd_resume, i386fbsd_read_description): Refactor as
5809 i386_fbsd_nat_target methods.
5810 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5811 (_initialize_i386fbsd_nat): Adjust to C++ification.
5812 * x86-bsd-nat.c (super_mourn_inferior): Delete.
5813 (x86bsd_mourn_inferior, x86bsd_target): Delete.
5814 (_initialize_x86_bsd_nat): Adjust to C++ification.
5815 * x86-bsd-nat.h: Include "x86-nat.h".
5816 (x86bsd_target): Delete declaration.
5817 (x86bsd_nat_target): New class.
5818
5819 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
5820 (the_aarch64_fbsd_nat_target): New.
5821 (aarch64_fbsd_fetch_inferior_registers)
5822 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
5823 aarch64_fbsd_nat_target.
5824 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
5825 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
5826 (the_alpha_bsd_nat_target): New.
5827 (alphabsd_fetch_inferior_registers)
5828 (alphabsd_store_inferior_registers): Refactor as
5829 alpha_bsd_nat_target methods.
5830 (_initialize_alphabsd_nat): Refactor as methods of
5831 alpha_bsd_nat_target.
5832 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
5833 (the_amd64_nbsd_nat_target): New.
5834 (_initialize_amd64nbsd_nat): Adjust to C++ification.
5835 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
5836 (the_amd64_obsd_nat_target): New.
5837 (_initialize_amd64obsd_nat): Adjust to C++ification.
5838 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
5839 (the_arm_fbsd_nat_target): New.
5840 (arm_fbsd_fetch_inferior_registers)
5841 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
5842 (_initialize_arm_fbsd_nat): Refactor as methods of
5843 arm_fbsd_nat_target.
5844 (_initialize_arm_fbsd_nat): Adjust to C++ification.
5845 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
5846 (the_arm_netbsd_nat_target): New.
5847 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
5848 arm_netbsd_nat_target.
5849 (_initialize_arm_netbsd_nat): Adjust to C++ification.
5850 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
5851 (the_hppa_nbsd_nat_target): New.
5852 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
5853 hppa_nbsd_nat_target methods.
5854 (_initialize_hppanbsd_nat): Adjust to C++ification.
5855 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
5856 (the_hppa_obsd_nat_target): New.
5857 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
5858 methods of hppa_obsd_nat_target.
5859 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
5860 add_target.
5861 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
5862 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
5863 add_target.
5864 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
5865 (_initialize_i386obsd_nat): Use add_target.
5866 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
5867 (the_m68k_bsd_nat_target): New.
5868 (m68kbsd_fetch_inferior_registers)
5869 (m68kbsd_store_inferior_registers): Refactor as methods of
5870 m68k_bsd_nat_target.
5871 (_initialize_m68kbsd_nat): Adjust to C++ification.
5872 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
5873 (the_mips_fbsd_nat_target): New.
5874 (mips_fbsd_fetch_inferior_registers)
5875 (mips_fbsd_store_inferior_registers): Refactor as methods of
5876 mips_fbsd_nat_target.
5877 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
5878 add_target.
5879 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
5880 (the_mips_nbsd_nat_target): New.
5881 (mipsnbsd_fetch_inferior_registers)
5882 (mipsnbsd_store_inferior_registers): Refactor as methods of
5883 mips_nbsd_nat_target.
5884 (_initialize_mipsnbsd_nat): Adjust to C++ification.
5885 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
5886 (the_mips64_obsd_nat_target): New.
5887 (mips64obsd_fetch_inferior_registers)
5888 (mips64obsd_store_inferior_registers): Refactor as methods of
5889 mips64_obsd_nat_target.
5890 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
5891 add_target.
5892 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
5893 nbsd_nat_target.
5894 * nbsd-nat.h: Include "inf-ptrace.h".
5895 (nbsd_nat_target): New class.
5896 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
5897 (obsd_wait): Refactor as methods of obsd_nat_target.
5898 (obsd_add_target): Delete.
5899 * obsd-nat.h: Include "inf-ptrace.h".
5900 (obsd_nat_target): New class.
5901 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
5902 (the_ppc_fbsd_nat_target): New.
5903 (ppcfbsd_fetch_inferior_registers)
5904 (ppcfbsd_store_inferior_registers): Refactor as methods of
5905 ppc_fbsd_nat_target.
5906 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
5907 add_target.
5908 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
5909 (the_ppc_nbsd_nat_target): New.
5910 (ppcnbsd_fetch_inferior_registers)
5911 (ppcnbsd_store_inferior_registers): Refactor as methods of
5912 ppc_nbsd_nat_target.
5913 (_initialize_ppcnbsd_nat): Adjust to C++ification.
5914 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
5915 (the_ppc_obsd_nat_target): New.
5916 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
5917 methods of ppc_obsd_nat_target.
5918 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
5919 add_target.
5920 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
5921 (the_sh_nbsd_nat_target): New.
5922 (shnbsd_fetch_inferior_registers)
5923 (shnbsd_store_inferior_registers): Refactor as methods of
5924 sh_nbsd_nat_target.
5925 (_initialize_shnbsd_nat): Adjust to C++ification.
5926 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
5927 (inf_ptrace_xfer_partial): Delete.
5928 (sparc_xfer_partial, sparc_target): Delete.
5929 * sparc-nat.h (sparc_fetch_inferior_registers)
5930 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
5931 (sparc_target): Delete function declaration.
5932 (sparc_target): New template class.
5933 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
5934 (_initialize_sparcnbsd_nat): Adjust to C++ification.
5935 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
5936 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
5937 add_target.
5938 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
5939 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
5940 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
5941 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
5942 add_target.
5943 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
5944 (the_vax_bsd_nat_target): New.
5945 (vaxbsd_fetch_inferior_registers)
5946 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
5947 methods.
5948 (_initialize_vaxbsd_nat): Adjust to C++ification.
5949
5950 * bsd-kvm.c (bsd_kvm_target): New class.
5951 (bsd_kvm_ops): Now a bsd_kvm_target.
5952 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
5953 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
5954 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
5955 bsd_kvm_target.
5956 (bsd_kvm_return_one): Delete.
5957 (bsd_kvm_add_target): Adjust to C++ification.
5958
5959 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
5960 (nto_procfs_target_procfs): New classes.
5961 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
5962 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
5963 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
5964 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
5965 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
5966 (procfs_remove_hw_breakpoint, procfs_resume)
5967 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
5968 (procfs_kill_inferior, procfs_store_registers)
5969 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
5970 as methods of nto_procfs_target.
5971 (nto_procfs_ops): Now an nto_procfs_target_procfs.
5972 (nto_native_ops): Delete.
5973 (procfs_open, procfs_native_open): Delete.
5974 (nto_native_ops): Now an nto_procfs_target_native.
5975 (init_procfs_targets): Adjust to C++ification.
5976 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
5977 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
5978 Refactor as methods of nto_procfs_target.
5979
5980 * go32-nat.c (go32_nat_target): New class.
5981 (the_go32_nat_target): New.
5982 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
5983 (go32_store_registers, go32_xfer_partial, go32_files_info)
5984 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
5985 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
5986 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
5987 (go32_pid_to_str): Refactor as methods of go32_nat_target.
5988 (go32_target): Delete.
5989 (_initialize_go32_nat): Adjust to C++ification.
5990
5991 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
5992 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
5993 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
5994 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
5995 gnu_nat_target.
5996 (gnu_target): Delete.
5997 * gnu-nat.h (gnu_target): Delete.
5998 (gnu_nat_target): New class.
5999 * i386-gnu-nat.c (gnu_base_target): New.
6000 (i386_gnu_nat_target): New class.
6001 (the_i386_gnu_nat_target): New.
6002 (_initialize_i386gnu_nat): Adjust to C++ification.
6003
3fffc070
PA
60042018-05-02 Pedro Alves <palves@redhat.com>
6005
6006 * bfd-target.c (target_bfd_xclose): Rename to ...
6007 (target_bfd_close): ... this.
6008 (target_bfd_reopen): Adjust.
6009 * target.c (target_close): Remove references to to_xclose.
6010 * target.h (target_ops::to_xclose): Delete.
6011 (target_ops::to_close): Update comments.
6012
6798487f
PA
60132018-05-02 Pedro Alves <palves@redhat.com>
6014
6015 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
6016 "linux-nat.h".
6017 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
6018 * inf-ptrace.c (inf_ptrace_register_u_offset)
6019 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6020 (inf_ptrace_store_register, inf_ptrace_store_registers)
6021 (inf_ptrace_trad_target): Move to ...
6022 * linux-nat-trad.c: ... this new file.
6023 * linux-nat-trad.h: New file.
6024 * linux-nat.c (linux_target_install_ops): Make extern.
6025 (linux_trad_target): Delete.
6026 * linux-nat.h (linux_trad_target): Delete declaration.
6027 (linux_target_install_ops): Declare.
6028 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
6029 "linux-nat.h".
6030
c1955e17
PA
60312018-05-02 Pedro Alves <palves@redhat.com>
6032
6033 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6034 procfs_target/add_target here.
6035 * procfs.c (procfs_target): Make static.
6036 (_initialize_procfs): Call add_target here.
6037 * procfs.h (struct target_ops): Remove forward declaration.
6038 (procfs_target): Remove declaration.
6039 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
6040
b5c8fcb1
PA
60412018-05-02 Pedro Alves <palves@redhat.com>
6042
6043 * procfs.c (procfs_stopped_by_watchpoint)
6044 (procfs_insert_watchpoint, procfs_remove_watchpoint)
6045 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
6046 Forward declare.
6047 (procfs_use_watchpoints): Delete, move contents...
6048 (procfs_target): ... here.
6049 * procfs.h (procfs_use_watchpoints): Delete declaration.
6050 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6051 procfs_use_watchpoints.
6052 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
6053 procfs_use_watchpoints.
6054
0489430a
TT
60552018-05-02 Tom Tromey <tom@tromey.com>
6056
6057 PR python/20084:
6058 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
6059 and var_zuinteger_unlimited.
6060 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
6061 and PARAM_ZUINTEGER_UNLIMITED.
6062 (set_parameter_value): Handle var_zuinteger and
6063 var_zuinteger_unlimited.
6064 (add_setshow_generic): Likewise.
6065 (parmpy_init): Likewise.
6066
1632f8ba
DR
60672018-04-28 Dan Robertson <danlrobertson89@gmail.com>
6068
6069 PR rust/23124
6070 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
6071 pointer is not null before dereferencing it.
6072
76761936
TT
60732018-04-30 Tom Tromey <tom@tromey.com>
6074
6075 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
6076 is_mi_like_p.
6077
2d33446d
TT
60782018-04-30 Tom Tromey <tom@tromey.com>
6079
6080 * breakpoint.c (mention): Remove use of is_mi_like_p.
6081 (print_mention_ranged_breakpoint): Likewise.
6082 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
6083 of is_mi_like_p.
6084
f3c6abab
TT
60852018-04-30 Tom Tromey <tom@tromey.com>
6086
6087 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
6088
40c03530
TT
60892018-04-30 Tom Tromey <tom@tromey.com>
6090
6091 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
6092 (info_spu_event_command): Remove some uses of is_mi_like_p.
6093
2038b7fd
TT
60942018-04-30 Tom Tromey <tom@tromey.com>
6095
6096 * python/py-framefilter.c (py_print_single_arg)
6097 (enumerate_locals, py_print_args, py_print_frame): Remove some
6098 uses of is_mi_like_p.
6099
4904c3c6
TT
61002018-04-30 Tom Tromey <tom@tromey.com>
6101
6102 * ui-out.c: Update.
6103 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
6104 * ui-out.h (ui_out::is_mi_like_p): Now const.
6105 (ui_out::do_is_mi_like_p): Now const.
6106 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
6107
7c66fffc
TT
61082018-04-30 Tom Tromey <tom@tromey.com>
6109
6110 * varobj.c (varobj_set_visualizer): Use new_reference.
6111 * python/python.c (gdbpy_decode_line): Use new_reference.
6112 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
6113 new_reference.
6114
bbfa6f00
TT
61152018-04-30 Tom Tromey <tom@tromey.com>
6116
6117 * varobj.c (install_new_value): Use new_reference.
6118 * value.h (value_incref): Return void. Swap intro comment with
6119 value_decref.
6120 * value.c (set_value_parent): Use new_reference.
6121 (value_incref): Return void. Update intro comment.
6122 (release_value): Use new_reference.
6123 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
6124
1831a9f9
TT
61252018-04-30 Tom Tromey <tom@tromey.com>
6126
6127 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
6128 * gdb_bfd.h (new_bfd_ref): Remove.
6129 (gdb_bfd_open): Update comment.
6130 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
6131 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
6132 (gdb_bfd_fdopenr): Use new_reference.
6133 * exec.c (exec_file_attach): Use new_reference.
6134
7c1b5f3d
TT
61352018-04-30 Tom Tromey <tom@tromey.com>
6136
6137 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
6138 method.
6139
e11fb955
TT
61402018-04-30 Tom Tromey <tom@tromey.com>
6141
6142 * jit.c (jit_read_code_entry): Use type_align.
6143 * i386-tdep.c (i386_gdbarch_init): Don't call
6144 set_gdbarch_long_long_align_bit.
6145 * gdbarch.sh: Remove long_long_align_bit.
6146 * gdbarch.c, gdbarch.h: Rebuild.
6147 * arc-tdep.c (arc_type_align): New function.
6148 (arc_gdbarch_init): Use arc_type_align. Don't call
6149 set_gdbarch_long_long_align_bit.
6150
2fff16dd
TT
61512018-04-30 Tom Tromey <tom@tromey.com>
6152
6153 * rust-lang.c (rust_type_alignment): Remove.
6154 (rust_composite_type): Use type_align.
6155
6d7bb824
TT
61562018-04-30 Tom Tromey <tom@tromey.com>
6157
6158 * NEWS: Mention Type.align.
6159 * python/py-type.c (typy_get_alignof): New function.
6160 (type_object_getset): Add "alignof".
6161
007e1530
TT
61622018-04-30 Tom Tromey <tom@tromey.com>
6163
6164 PR exp/17095:
6165 * NEWS: Update.
6166 * std-operator.def (UNOP_ALIGNOF): New operator.
6167 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
6168 New.
6169 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
6170 * c-lang.c (c_op_print_tab): Add alignof.
6171 * c-exp.y (ALIGNOF): New token.
6172 (exp): Add "ALIGNOF" production.
6173 (ident_tokens): Add _Alignof and alignof.
6174
2b4424c3
TT
61752018-04-30 Tom Tromey <tom@tromey.com>
6176
6177 * i386-tdep.c (i386_type_align): New function.
6178 (i386_gdbarch_init): Update.
6179 * gdbarch.sh (type_align): New method.
6180 * gdbarch.c, gdbarch.h: Rebuild.
6181 * arch-utils.h (default_type_align): Declare.
6182 * arch-utils.c (default_type_align): New function.
6183 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
6184 (struct type) <align_log2>: New field.
6185 <instance_flags>: Now a bitfield.
6186 (TYPE_RAW_ALIGN): New macro.
6187 (type_align, type_raw_align, set_type_align): Declare.
6188 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
6189 functions.
6190 * dwarf2read.c (quirk_rust_enum): Set type alignment.
6191 (get_alignment, maybe_set_alignment): New functions.
6192 (read_structure_type, read_enumeration_type, read_array_type)
6193 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
6194 (read_subrange_type, read_base_type): Set type alignment.
6195
d33bc52e
SM
61962018-04-30 Simon Marchi <simon.marchi@ericsson.com>
6197
6198 * dwarf2read.c (read_index_from_section): Use bool.
6199
e28b63a9
FG
62002018-04-29 Fabian Groffen <grobian@gentoo.org>
6201
6202 PR gdb/22950
6203 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
6204 with #ifdef.
6205
cd8c76e4
JR
62062018-04-29 John Reiser <jreiser@BitWagon.com>
6207
6208 PR build/22873
6209 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
6210 last step, and do it atomically.
6211
476d250e
AO
62122018-04-27 Alexandre Oliva <aoliva@redhat.com>
6213
6214 * compile/compile-c-types.c (convert_int, convert_float):
6215 Update for C FE v1.
6216
6873858b
TT
62172018-04-27 Tom Tromey <tom@tromey.com>
6218
6219 PR rust/22545:
6220 * rust-lang.c (rust_inclusive_range_type_p): New function.
6221 (rust_range): Handle inclusive ranges.
6222 (rust_compute_range): Likewise.
6223 * rust-exp.y (struct rust_op) <inclusive>: New field.
6224 (DOTDOTEQ): New constant.
6225 (range_expr): Add "..=" productions.
6226 (operator_tokens): Add "..=" token.
6227 (ast_range): Add "inclusive" parameter.
6228 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
6229 ranges.
6230 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
6231 bounds values.
6232 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
6233 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
6234 Update comments.
6235 * expprint.c (print_subexp_standard): Handle new bounds values.
6236 (dump_subexp_body_standard): Likewise.
6237
632e107b
TT
62382018-04-27 Tom Tromey <tom@tromey.com>
6239
6240 * configure: Rebuild.
6241 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
6242 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
6243 "OVERRIDE".
6244 (class symbol_needs_eval_context): Likewise.
6245 * dwarf2read.c (mock_mapped_index::symbol_name_count)
6246 (mock_mapped_index::symbol_name_at): Use "override". Remove
6247 "virtual".
6248 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
6249 "override".
6250 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
6251 * aarch64-tdep.c (instruction_reader::read): Use "override".
6252 (instruction_reader_test::read): Likewise.
6253 * arm-tdep.c (instruction_reader::read): Use "override".
6254 (instruction_reader_thumb::read): Likewise.
6255
b75abf5b
AK
62562018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
6257
6258 PR remote/9665
6259 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
6260 instead of remote_send.
6261 (remote_send): Remove.
6262
79188d8d
PA
62632018-04-26 Pedro Alves <palves@redhat.com>
6264
6265 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
6266 find_function_start_sal instead of find_pc_line.
6267
f50776aa
PA
62682018-04-26 Pedro Alves <palves@redhat.com>
6269
6270 * breakpoint.c (set_breakpoint_location_function): Handle
6271 mst_data_gnu_ifunc.
6272 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
6273 * elfread.c (elf_symtab_read): Give data symbols with
6274 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
6275 (elf_rel_plt_read): Update comment.
6276 * linespec.c (convert_linespec_to_sals): Handle
6277 mst_data_gnu_ifunc.
6278 (minsym_found): Handle mst_data_gnu_ifunc.
6279 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
6280 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
6281 * parse.c (find_minsym_type_and_address): Handle
6282 mst_data_gnu_ifunc.
6283 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
6284 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
6285 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
6286 comment.
6287 <mst_data_gnu_ifunc>: New enumerator.
6288
20944a6e
PA
62892018-04-26 Pedro Alves <palves@redhat.com>
6290
6291 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
6292 (lookup_minimal_symbol_by_pc_section): ... this. Replace
6293 'want_trampoline' parameter by a lookup_msym_prefer parameter.
6294 Handle it.
6295 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
6296 (lookup_minimal_symbol_by_pc): Adjust.
6297 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
6298 (lookup_solib_trampoline_symbol_by_pc): Adjust.
6299 * minsyms.h (lookup_msym_prefer): New enum.
6300 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6301 parameter by a lookup_msym_prefer parameter.
6302
1adeb822
PA
63032018-04-26 Pedro Alves <palves@redhat.com>
6304
6305 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
6306 ends in "@plt" instead of looking at the symbol's section.
6307
a0aca7b0
PA
63082018-04-26 Pedro Alves <palves@redhat.com>
6309
6310 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
6311 all references.
6312 (find_pc_partial_function_gnu_ifunc): Rename to ...
6313 (find_pc_partial_function): ... this, and remove references to
6314 'is_gnu_ifunc_p'.
6315 (find_pc_partial_function): Delete old implementation.
6316 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
6317
76af0f26
PA
63182018-04-26 Pedro Alves <palves@redhat.com>
6319
6320 * linespec.c (struct bound_minimal_symbol_search_key): New.
6321 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
6322 skip first line if we found a GNU ifunc minimal symbol by name.
6323 (compare_msymbols): Change parameters to work with a destructured
6324 lhs minsym.
6325 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
6326 functions.
6327
3467ec66
PA
63282018-04-26 Pedro Alves <palves@redhat.com>
6329
6330 * breakpoint.c (set_breakpoint_location_function): Don't resolve
6331 ifunc targets here. Instead, if we have an ifunc minsym, use its
6332 address/name.
6333 (add_location_to_breakpoint): Store the minsym and the objfile in
6334 the breakpoint location.
6335 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
6336 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
6337 Record the minsym in the sal.
6338 * symtab.h (symtab_and_line) <msymbol>: New field.
6339
28f4fa4d
PA
63402018-04-26 Pedro Alves <palves@redhat.com>
6341
6342 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
6343 unless we actually resolved the ifunc.
6344
ca31ab1d
PA
63452018-04-26 Pedro Alves <palves@redhat.com>
6346
6347 * c-exp.y (variable production): Prefer ifunc minsyms over
6348 regular function symbols.
6349 * symtab.c (find_gnu_ifunc): New function.
6350 * minsyms.h (lookup_msym_prefer): New enum.
6351 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6352 parameter by a lookup_msym_prefer parameter.
6353 * symtab.h (find_gnu_ifunc): New declaration.
6354
8388016d
PA
63552018-04-26 Pedro Alves <palves@redhat.com>
6356
6357 * blockframe.c (find_gnu_ifunc_target_type): New function.
6358 (find_function_type): New.
6359 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
6360 return a value with a memory address.
6361 (eval_call): For calls to GNU ifunc functions, try to find the
6362 type of the target function from the type that the resolver
6363 returns.
6364 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
6365 symbols.
6366 * infcall.c (find_function_return_type): Delete.
6367 (find_function_addr): Add 'function_type' parameter. For calls to
6368 GNU ifunc functions, try to find the type of the target function
6369 from the type that the resolver returns, and return it via
6370 FUNCTION_TYPE.
6371 (call_function_by_hand_dummy): Adjust to use the function type
6372 returned by find_function_addr.
6373 (find_function_addr): Add 'function_type' parameter and move
6374 description here.
6375 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
6376 declarations.
6377
a376e11d
PA
63782018-04-26 Pedro Alves <palves@redhat.com>
6379
6380 * c-exp.y (variable production): Skip finding an alias for ifunc
6381 symbols.
6382
02e169e2
PA
63832018-04-26 Pedro Alves <palves@redhat.com>
6384
6385 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
6386
249b5733
PA
63872018-04-25 Pedro Alves <palves@redhat.com>
6388
6389 * infcmd.c (kill_command): Print the pid as string, not the whole
6390 thread's ptid. Add comment. s/has been killed/killed/ in output
6391 message.
6392 * remote.c (remote_detach_1): Print the pid as string, not the
6393 whole thread's ptid.
6394
f67c0c91
SDJ
63952018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6396 Sergio Durigan Junior <sergiodj@redhat.com>
6397 Pedro Alves <palves@redhat.com>
6398
6399 * infcmd.c (kill_command): Print message when inferior has
6400 been killed.
6401 * inferior.c (print_inferior_events): Remove 'static'. Set as
6402 '1'.
6403 (add_inferior): Improve message printed when
6404 'print_inferior_events' is on.
6405 (exit_inferior): Remove message printed when
6406 'print_inferior_events' is on.
6407 (detach_inferior): Improve message printed when
6408 'print_inferior_events' is on.
6409 (initialize_inferiors): Use 'add_inferior_silent' to set
6410 'current_inferior_'.
6411 * inferior.h (print_inferior_events): Declare here as
6412 'extern'.
6413 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
6414 '[Detaching...]' messages when 'print_inferior_events' is on.
6415 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
6416 as prefix/suffix for messages. Remove periods. Fix erroneous
6417 'Detaching after fork from child...', replace it by '... from
6418 parent...'.
6419 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
6420 prefix/suffix when printing 'Detaching...' messages. Print
6421 them when 'print_inferior_events' is on.
6422 * remote.c (remote_detach_1): Print message when detaching
6423 from inferior and '!is_fork_parent'.
6424
e427af18
TT
64252018-04-24 Tom Tromey <tom@tromey.com>
6426
6427 * cli-out.h: Reindent.
6428
05b1d8d6
TT
64292018-04-24 Tom Tromey <tom@tromey.com>
6430
6431 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
6432 (cli_ui_out::do_field_string): Use fputs_filtered.
6433 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
6434
a95c7dab
TT
64352018-04-23 Tom Tromey <tom@tromey.com>
6436
6437 * guile/scm-frame.c (gdbscm_frame_read_var): Use
6438 gdb::unique_xmalloc_ptr.
6439
458412c3
TT
64402018-04-23 Tom Tromey <tom@tromey.com>
6441
6442 * configure: Rebuild.
6443
db86b02b
RS
64442018-04-22 Rajendra SY <rajendra.sy@gmail.com>
6445
6446 PR gdb/23095
6447 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
6448 prepare_for_testing. Set normal_bp to r_debug_state if target
6449 is bsd.
6450
00aecdcf
PA
64512018-04-21 Pedro Alves <palves@redhat.com>
6452 Rajendra SY <rajendra.sy@gmail.com>
6453
6454 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
6455 * remote.c (extended_remote_attach): In all-stop mode, mark the
6456 thread as executing.
6457
224608c3
PW
64582018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6459
6460 * thread.c (thread_apply_all_command): Fix comment.
6461 (thread_command): Fix comment.
6462
3b74854b
AH
64632018-04-10 Alan Hayward <alan.hayward@arm.com>
6464
6465 * common/tdesc.h (tdesc_create_feature): Remove xml filename
6466 parameter.
6467 * features/aarch64-core.c (create_feature_aarch64_core):
6468 Regenerate.
6469 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
6470 Likewise.
6471 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
6472 Likewise.
6473 * features/i386/32bit-avx512.c
6474 (create_feature_i386_32bit_avx512): Likewise.
6475 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
6476 Likewise.
6477 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
6478 Likewise.
6479 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
6480 Likewise.
6481 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
6482 Likewise.
6483 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
6484 Likewise.
6485 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
6486 Likewise.
6487 * features/i386/64bit-avx512.c
6488 (create_feature_i386_64bit_avx512): Likewise.
6489 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
6490 Likewise.
6491 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
6492 Likewise.
6493 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
6494 Likewise.
6495 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
6496 Likewise.
6497 * features/i386/64bit-segments.c
6498 (create_feature_i386_64bit_segments): Likewise.
6499 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
6500 Likewise.
6501 * features/i386/x32-core.c
6502 (create_feature_i386_x32_core): Likewise.
6503 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
6504 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
6505 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
6506 * target-descriptions.c: In generated code, don't pass xml
6507 filename.
6508
e98577a9
AH
65092018-04-18 Alan Hayward <alan.hayward@arm.com>
6510
6511 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
6512 (print_xml_feature::visit_post): Likewise.
6513 (print_xml_feature::visit): Likewise.
6514 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
6515 (print_xml_feature): Add new class.
6516 * regformats/regdat.sh: Null xmltarget on feature targets.
6517 * target-descriptions.c (struct target_desc): Add xmltarget.
6518 (maintenance_check_tdesc_xml_convert): Add unittest function.
6519 (tdesc_get_features_xml): Add function to get xml.
6520 (maintenance_check_xml_descriptions): Test xml generation.
6521 * xml-tdesc.c (string_read_description_xml): Add function.
6522 * xml-tdesc.h (string_read_description_xml): Add declaration.
6523
ad7fc756
AH
65242018-04-18 Alan Hayward <alan.hayward@arm.com>
6525
6526 * features/Makefile: Add feature marker to targets with new style
6527 target descriptions.
6528 * regformats/aarch64.dat: Regenerate.
6529 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
6530 * regformats/i386/amd64-avx-linux.dat: Likewise.
6531 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
6532 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
6533 * regformats/i386/amd64-linux.dat: Likewise.
6534 * regformats/i386/amd64-mpx-linux.dat: Likewise.
6535 * regformats/i386/amd64.dat: Likewise.
6536 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
6537 * regformats/i386/i386-avx-linux.dat: Likewise.
6538 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
6539 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
6540 * regformats/i386/i386-linux.dat: Likewise.
6541 * regformats/i386/i386-mmx-linux.dat: Likewise.
6542 * regformats/i386/i386-mpx-linux.dat: Likewise.
6543 * regformats/i386/i386.dat: Likewise.
6544 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
6545 * regformats/i386/x32-avx-linux.dat: Likewise.
6546 * regformats/i386/x32-linux.dat: Likewise.
6547 * regformats/tic6x-c62x-linux.dat: Likewise.
6548 * regformats/tic6x-c64x-linux.dat: Likewise.
6549 * regformats/tic6x-c64xp-linux.dat: Likewise.
6550 * regformats/regdat.sh: Parse feature marker.
6551
d278f585
AH
65522018-04-18 Alan Hayward <alan.hayward@arm.com>
6553
6554 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
6555 (tdesc_osabi_name): Likewise.
6556 * target-descriptions.c (tdesc_architecture_name): Add new
6557 function.
6558 (tdesc_osabi_name): Likewise.
6559
eee8a18d
AH
65602018-04-18 Alan Hayward <alan.hayward@arm.com>
6561
6562 * common/tdesc.c (tdesc_predefined_type): Move to here.
6563 (tdesc_named_type): Likewise.
6564 (tdesc_create_vector): Likewise.
6565 (tdesc_create_struct): Likewise.
6566 (tdesc_set_struct_size): Likewise.
6567 (tdesc_create_union): Likewise.
6568 (tdesc_create_flags): Likewise.
6569 (tdesc_create_enum): Likewise.
6570 (tdesc_add_field): Likewise.
6571 (tdesc_add_typed_bitfield): Likewise.
6572 (tdesc_add_bitfield): Likewise.
6573 (tdesc_add_flag): Likewise.
6574 (tdesc_add_enum_value): Likewise.
6575 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
6576 (struct tdesc_type_vector): Likewise.
6577 (struct tdesc_type_field): Likewise.
6578 (struct tdesc_type_with_fields): Likewise.
6579 (tdesc_create_enum): Add declaration.
6580 (tdesc_add_typed_bitfield): Likewise.
6581 (tdesc_add_enum_value): Likewise.
6582 * target-descriptions.c (tdesc_type_field): Move from here.
6583 (tdesc_type_builtin): Likewise.
6584 (tdesc_type_vector): Likewise.
6585 (tdesc_type_with_fields): Likewise.
6586 (tdesc_predefined_types): Likewise.
6587 (tdesc_named_type): Likewise.
6588 (tdesc_create_vector): Likewise.
6589 (tdesc_create_struct): Likewise.
6590 (tdesc_set_struct_size): Likewise.
6591 (tdesc_create_union): Likewise.
6592 (tdesc_create_flags): Likewise.
6593 (tdesc_create_enum): Likewise.
6594 (tdesc_add_field): Likewise.
6595 (tdesc_add_typed_bitfield): Likewise.
6596 (tdesc_add_bitfield): Likewise.
6597 (tdesc_add_flag): Likewise.
6598 (tdesc_add_enum_value): Likewise.
6599 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
6600 (tdesc_add_typed_bitfield): Likewise.
6601 (tdesc_add_enum_value): Likewise.
6602
82ec9bc7
AH
66032018-04-18 Alan Hayward <alan.hayward@arm.com>
6604
6605 * common/tdesc.c (tdesc_feature::accept): Move to here.
6606 (tdesc_feature::operator==): Likewise.
6607 (tdesc_create_reg): Likewise.
6608 * common/tdesc.h (tdesc_type_kind): Likewise.
6609 (struct tdesc_type): Likewise.
6610 (struct tdesc_feature): Likewise.
6611 * regformats/regdat.sh: Create a feature.
6612 * target-descriptions.c (tdesc_type_kind): Move from here.
6613 (tdesc_type): Likewise.
6614 (tdesc_type_up): Likewise.
6615 (tdesc_feature): Likewise.
6616 (tdesc_create_reg): Likewise.
6617
ea3e7d71
AH
66182018-04-18 Alan Hayward <alan.hayward@arm.com>
6619
6620 * Makefile.in: Add arch/tdesc.c
6621 * common/tdesc.c: New file.
6622 * common/tdesc.h (tdesc_element_visitor): Move to here.
6623 (tdesc_element): Likewise.
6624 (tdesc_reg): Likewise.
6625 (tdesc_reg_up): Likewise.
6626 * regformats/regdef.h (reg): Add offset to constructors.
6627 * target-descriptions.c (tdesc_element_visitor): Move from here.
6628 (tdesc_element): Likewise.
6629 (tdesc_reg): Likewise.
6630 (tdesc_reg_up): Likewise.
6631
bedda9ac
TT
66322018-04-17 Tom Tromey <tom@tromey.com>
6633
6634 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
6635 discriminant field.
6636
a037790e
TT
66372018-04-17 Tom Tromey <tom@tromey.com>
6638
6639 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
6640
c7dcbf88
AA
66412018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
6642
6643 * symtab.c (print_symbol_info): Skip printing filename and line
6644 number when `last' is NULL.
6645 (symtab_symbol_info): Use empty string instead of NULL for first
6646 invocation of print_symbol_info.
6647 (rbreak_command): Pass NULL to `last' parameter of
6648 print_symbol_info.
6649
07d28c77
SM
66502018-04-16 Simon Marchi <simon.marchi@ericsson.com>
6651
6652 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
6653 instead of nullptr.
6654
8a3de5e1
PA
66552018-04-16 Pedro Alves <palves@redhat.com>
6656
6657 * MAINTAINERS (sh): Remove.
6658 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
6659 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
6660 (ALLDEPFILES): Remove sh64-tdep.c.
6661 * NEWS: Mentions that support for SH-5/SH64 is removed.
6662 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
6663 (sh*-*-openbsd*): Ditto.
6664 (sh64-*-elf*): Remove.
6665 (sh*): Remove.
6666 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
6667 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
6668 * sh-tdep.c: No longer include "sh64-tdep.h".
6669 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
6670 * sh64-tdep.c, sh64-tdep.h: Remove files.
6671
a2a79012
PA
66722018-04-16 Pedro Alves <palves@redhat.com>
6673
6674 * MAINTAINERS: Remove m88k.
6675 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
6676 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
6677 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
6678 * NEWS: Mention that support for m88k was removed.
6679 * configure.host (m88*-*-*): Remove support.
6680 * configure.nat (m88k-*-*): Remove support.
6681 * configure.tgt (m88*-*-openbsd*): Remove.
6682 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
6683
eda4efb1
SM
66842018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
6685
6686 * configure.tgt (x86_tobjs): New variable.
6687 (amd64_tobjs, i386_tobjs): Use it.
6688
b744723f
AA
66892018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6690
6691 * symtab.c (print_symbol_info): Precede the symbol definition by
6692 the line number when available.
6693 * NEWS: Advertise this enhancement.
6694
4a4495d6
MM
66952018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6696
6697 * NEWS (New options): announce set/show record btrace cpu.
6698 * btrace.c: Include record-btrace.h.
6699 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
6700 the vendor is unknown.
6701 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
6702 Maybe overwrite the btrace configuration's cpu.
6703 (btrace_compute_ftrace): Add cpu parameter. Update callers.
6704 (btrace_fetch): Add cpu parameter. Update callers.
6705 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
6706 Maybe overwrite the btrace configuration's cpu. Skip enabling
6707 errata workarounds if the vendor is unknown.
6708 * python/py-record-btrace.c: Include record-btrace.h.
6709 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
6710 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
6711 * record-btrace.c (record_btrace_cpu_state_kind): New.
6712 (record_btrace_cpu): New.
6713 (set_record_btrace_cpu_cmdlist): New.
6714 (record_btrace_get_cpu): New.
6715 (require_btrace_thread, record_btrace_info)
6716 (record_btrace_resume_thread): Call record_btrace_get_cpu.
6717 (cmd_set_record_btrace_cpu_none): New.
6718 (cmd_set_record_btrace_cpu_auto): New.
6719 (cmd_set_record_btrace_cpu): New.
6720 (cmd_show_record_btrace_cpu): New.
6721 (_initialize_record_btrace): Initialize set/show record btrace cpu
6722 commands.
6723 * record-btrace.h (record_btrace_get_cpu): New.
6724
69f90c75
MM
67252018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6726
6727 * record.c (set_record_command): Fix typo in message.
6728
b85310e1
MM
67292018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6730
6731 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
6732
1d509aa6
MM
67332018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6734
6735 * infrun.c (process_event_stop_test): Call
6736 gdbarch_in_indirect_branch_thunk.
6737 * gdbarch.sh (in_indirect_branch_thunk): New.
6738 * gdbarch.c: Regenerated.
6739 * gdbarch.h: Regenerated.
6740 * x86-tdep.h: New.
6741 * x86-tdep.c: New.
6742 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
6743 (HFILES_NO_SRCDIR): Add x86-tdep.h.
6744 (ALLDEPFILES): Add x86-tdep.c.
6745 * arch-utils.h (default_in_indirect_branch_thunk): New.
6746 * arch-utils.c (default_in_indirect_branch_thunk): New.
6747 * i386-tdep: Include x86-tdep.h.
6748 (i386_in_indirect_branch_thunk): New.
6749 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
6750 function.
6751 * amd64-tdep: Include x86-tdep.h.
6752 (amd64_in_indirect_branch_thunk): New.
6753 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
6754
b4be9bfd
JK
67552018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6756
6757 PR gdb/23053
6758 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
6759 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
6760 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
6761 regression.
6762
53d7df28
TT
67632018-04-12 Tom Tromey <tom@tromey.com>
6764
6765 * rust-lang.c (rust_print_struct_def): Remove univariant code.
6766 (rust_evaluate_subexp): Likewise.
6767
70b33f19
PA
67682018-04-12 Pedro Alves <palves@redhat.com>
6769
6770 * procfs.c (procfs_detach): Make forward declaration's prototype
6771 match definition's protototype.
6772 (proc_get_LDT_entry): Remove stale do_cleanups call.
6773
436411b1
PA
67742018-04-12 Pedro Alves <palves@redhat.com>
6775
6776 * target.h (target_ops::to_has_exited): Delete.
6777 (target_has_exited): Delete.
6778 * target-delegates.c: Regenerate.
6779
20db9c52
PA
67802018-04-11 Pedro Alves <palves@redhat.com>
6781
6782 * target.c (fileio_fh_t::t): Add comment.
6783 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6784 (target_fileio_close): Handle a NULL target.
6785 (invalidate_fileio_fh): New.
6786 (target_close): Call it.
6787 * remote.c (remote_hostio_send_command): No longer check whether
6788 remote_desc is open.
6789
5ff79300
PA
67902018-04-11 Pedro Alves <palves@redhat.com>
6791
6792 * target.c (fileio_fh_t): Make it a named struct instead of a
6793 typedef.
6794 (fileio_fh_t::is_closed): New method.
6795 (DEF_VEC_O (fileio_fh_t)): Remove.
6796 (fileio_fhandles): Now a std::vector.
6797 (is_closed_fileio_fh): Delete.
6798 (acquire_fileio_fd): Adjust. Rename parameters.
6799 (release_fileio_fd): Adjust.
6800 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
6801 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6802 (target_fileio_close): Adjust.
6803
6e22e10d
SM
68042018-04-10 Simon Marchi <simon.marchi@ericsson.com>
6805
6806 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
6807 index.
6808
731f534f
PA
68092018-04-10 Pedro Alves <palves@redhat.com>
6810
6811 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
6812 (scoped_finish_thread_state): New class.
6813 * infcmd.c (run_command_1): Use it instead of finish_thread_state
6814 cleanup.
6815 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
6816 (fetch_inferior_event, normal_stop): Likewise.
6817 * thread.c (finish_thread_state_cleanup): Delete.
6818
d5f4488f
SM
68192018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6820 Pedro Alves <palves@redhat.com>
6821
6822 * value.c: Include "selftest.h" and "common/array-view.h".
6823 (struct range) <operator ==>: New.
6824 (test_ranges_contain): New.
6825 (check_ranges_vector): New.
6826 (test_insert_into_bit_range_vector): New.
6827 (_initialize_values): Register selftests.
6828 * common/array-view.h (operator==, operator!=): New.
6829
b24531ed
SM
68302018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6831
6832 * common/gdb_vecs.h (unordered_remove): Add overload that takes
6833 an iterator.
6834 * inline-frame.c: Include <algorithm>.
6835 (struct inline_state): Add constructor.
6836 (inline_state_s): Remove.
6837 (DEF_VEC_O(inline_state_s)): Remove.
6838 (inline_states): Change type to std::vector.
6839 (find_inline_frame_state): Adjust to std::vector.
6840 (allocate_inline_frame_state): Remove.
6841 (clear_inline_frame_state): Adjust to std::vector.
6842 (skip_inline_frames): Adjust to std::vector.
6843
c252925c
SM
68442018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6845
6846 * tracepoint.h (struct trace_state_variable): Add constructor.
6847 <name>: Change type to std::string.
6848 * tracepoint.c (tsv_s): Remove.
6849 (DEF_VEC_O(tsv_s)): Remove.
6850 (tvariables): Change to std::vector.
6851 (create_trace_state_variable): Adjust to std::vector.
6852 (find_trace_state_variable): Likewise.
6853 (find_trace_state_variable_by_number): Likewise.
6854 (delete_trace_state_variable): Likewise.
6855 (trace_variable_command): Adjust to std::string.
6856 (delete_trace_variable_command): Likewise.
6857 (tvariables_info_1): Adjust to std::vector.
6858 (save_trace_state_variables): Likewise.
6859 (start_tracing): Likewise.
6860 (merge_uploaded_trace_state_variables): Adjust to std::vector
6861 and std::string.
6862 * target.h (struct target_ops)
6863 <to_download_trace_state_variable>: Pass reference to
6864 trace_state_variable.
6865 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
6866 * target-delegates.c: Re-generate.
6867 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
6868 (mi_tsv_deleted): Likewise.
6869 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
6870 * remote.c (remote_download_trace_state_variable): Change
6871 pointer to reference and adjust.
6872 * make-target-delegates (parse_argtypes): Handle references.
6873 (write_function_header): Likewise.
6874 (munge_type): Likewise.
6875
c9638d26
SM
68762018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6877
6878 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6879 string_view-selftests.c.
6880 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
6881 testsuite.
6882 * unittests/basic_string_view/cons/char/1.cc: Likewise.
6883 * unittests/basic_string_view/cons/char/2.cc: Likewise.
6884 * unittests/basic_string_view/cons/char/3.cc: Likewise.
6885 * unittests/basic_string_view/element_access/char/1.cc:
6886 Likewise.
6887 * unittests/basic_string_view/element_access/char/empty.cc:
6888 Likewise.
6889 * unittests/basic_string_view/element_access/char/front_back.cc:
6890 Likewise.
6891 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
6892 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
6893 Likewise.
6894 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
6895 Likewise.
6896 * unittests/basic_string_view/modifiers/swap/char/1.cc:
6897 Likewise.
6898 * unittests/basic_string_view/operations/compare/char/1.cc:
6899 Likewise.
6900 * unittests/basic_string_view/operations/compare/char/13650.cc:
6901 Likewise.
6902 * unittests/basic_string_view/operations/copy/char/1.cc:
6903 Likewise.
6904 * unittests/basic_string_view/operations/data/char/1.cc:
6905 Likewise.
6906 * unittests/basic_string_view/operations/find/char/1.cc:
6907 Likewise.
6908 * unittests/basic_string_view/operations/find/char/2.cc:
6909 Likewise.
6910 * unittests/basic_string_view/operations/find/char/3.cc:
6911 Likewise.
6912 * unittests/basic_string_view/operations/find/char/4.cc:
6913 Likewise.
6914 * unittests/basic_string_view/operations/rfind/char/1.cc:
6915 Likewise.
6916 * unittests/basic_string_view/operations/rfind/char/2.cc:
6917 Likewise.
6918 * unittests/basic_string_view/operations/rfind/char/3.cc:
6919 Likewise.
6920 * unittests/basic_string_view/operations/substr/char/1.cc:
6921 Likewise.
6922 * unittests/basic_string_view/operators/char/2.cc: Likewise.
6923 * unittests/string_view-selftests.c: New file.
6924
fdc11678
SM
69252018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6926
6927 * unittests/basic_string_view/capacity/1.cc: New file.
6928 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
6929 * unittests/basic_string_view/cons/char/1.cc: New file.
6930 * unittests/basic_string_view/cons/char/2.cc: New file.
6931 * unittests/basic_string_view/cons/char/3.cc: New file.
6932 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
6933 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
6934 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
6935 * unittests/basic_string_view/element_access/char/1.cc: New file.
6936 * unittests/basic_string_view/element_access/char/2.cc: New file.
6937 * unittests/basic_string_view/element_access/char/empty.cc: New file.
6938 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
6939 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
6940 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
6941 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
6942 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
6943 * unittests/basic_string_view/include.cc: New file.
6944 * unittests/basic_string_view/inserters/char/1.cc: New file.
6945 * unittests/basic_string_view/inserters/char/2.cc: New file.
6946 * unittests/basic_string_view/inserters/char/3.cc: New file.
6947 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
6948 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
6949 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
6950 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
6951 * unittests/basic_string_view/literals/types.cc: New file.
6952 * unittests/basic_string_view/literals/values.cc: New file.
6953 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
6954 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
6955 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
6956 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
6957 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
6958 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
6959 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
6960 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
6961 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
6962 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
6963 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
6964 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
6965 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
6966 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
6967 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
6968 * unittests/basic_string_view/operations/data/char/1.cc: New file.
6969 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
6970 * unittests/basic_string_view/operations/find/char/1.cc: New file.
6971 * unittests/basic_string_view/operations/find/char/2.cc: New file.
6972 * unittests/basic_string_view/operations/find/char/3.cc: New file.
6973 * unittests/basic_string_view/operations/find/char/4.cc: New file.
6974 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
6975 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
6976 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
6977 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
6978 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
6979 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
6980 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
6981 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
6982 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
6983 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
6984 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
6985 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
6986 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
6987 * unittests/basic_string_view/operators/char/2.cc: New file.
6988 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
6989 * unittests/basic_string_view/range_access/char/1.cc: New file.
6990 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
6991 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
6992 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
6993 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
6994 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
6995 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
6996 * unittests/basic_string_view/requirements/typedefs.cc: New file.
6997 * unittests/basic_string_view/typedefs.cc: New file.
6998 * unittests/basic_string_view/types/1.cc: New file.
6999
8345c4a2
SM
70002018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7001
7002 * common/gdb_string_view.h: Remove libstdc++ implementation
7003 details, adjust to gdb reality.
7004 * common/gdb_string_view.tcc: Likewise.
7005 * cli/cli-script.c (struct string_view): Remove.
7006 (user_args) <m_args>: Change element type to gdb::string_view.
7007 (user_args::insert_args): Adjust.
7008
7adcdf08
SM
70092018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7010
7011 * common/gdb_string_view.h: New file.
7012 * common/gdb_string_view.tcc: New file.
7013
41260ac2
SM
70142018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7015
7016 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
7017 * configure: Re-generate.
7018
0bee6dd4
PA
70192018-04-09 Pedro Alves <palves@redhat.com>
7020
7021 * gdbarch.sh: Include "observable.h" instead of "observer.h".
7022 (set_target_gdbarch): Call
7023 gdb::observers::architecture_changed.notify instead of
7024 observer_notify_architecture_changed.
7025
6f14adc5
SM
70262018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7027
7028 * tracepoint.c (struct current_traceframe_cleanup): Remove.
7029 (do_restore_current_traceframe_cleanup): Remove.
7030 (restore_current_traceframe_cleanup_dtor): Remove.
7031 (make_cleanup_restore_current_traceframe): Remove.
7032 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
7033 New.
7034 * tracepoint.h (struct scoped_restore_current_traceframe): New.
7035 * infrun.c (fetch_inferior_event): Use
7036 scoped_restore_current_traceframe.
7037
b2bdb8cf
SM
70382018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7039
7040 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
7041 Remove.
7042 <n_allocated_type_units>: Remove.
7043 <all_type_units>: Change to std::vector.
7044 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7045 to std::vector change.
7046 (dwarf2_per_objfile::get_cutu): Likewise.
7047 (dwarf2_per_objfile::get_tu): Likewise.
7048 (create_signatured_type_table_from_index): Likewise.
7049 (create_signatured_type_table_from_debug_names): Likewise.
7050 (dw2_symtab_iter_next): Likewise.
7051 (dw2_print_stats): Likewise.
7052 (dw2_expand_all_symtabs): Likewise.
7053 (dw2_expand_marked_cus): Likewise.
7054 (dw2_debug_names_iterator::next): Likewise.
7055 (dwarf2_initialize_objfile): Likewise.
7056 (add_signatured_type_cu_to_table): Likewise.
7057 (create_all_type_units): Likewise.
7058 (add_type_unit): Likewise.
7059 (struct tu_abbrev_offset): Add constructor.
7060 (build_type_psymtabs_1): Adjust to std::vector change.
7061 (print_tu_stats): Likewise.
7062 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7063 (write_debug_names): Likewise.
7064
b76e467d
SM
70652018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7066
7067 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
7068 Make an std::vector.
7069 <n_comp_units>: Remove.
7070 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7071 to std::vector change.
7072 (dwarf2_per_objfile::get_cutu): Likewise.
7073 (dwarf2_per_objfile::get_cu): Likewise.
7074 (create_cus_from_index): Likewise.
7075 (create_addrmap_from_index): Likewise.
7076 (create_addrmap_from_aranges): Likewise.
7077 (dwarf2_read_index): Likewise.
7078 (dw2_find_last_source_symtab): Likewise.
7079 (dw2_map_symtabs_matching_filename): Likewise.
7080 (dw2_symtab_iter_next): Likewise.
7081 (dw2_print_stats): Likewise.
7082 (dw2_expand_all_symtabs): Likewise.
7083 (dw2_expand_symtabs_with_fullname): Likewise.
7084 (dw2_expand_marked_cus): Likewise.
7085 (dw2_map_symbol_filenames): Likewise.
7086 (create_cus_from_debug_names): Likewise.
7087 (dwarf2_read_debug_names): Likewise.
7088 (dw2_debug_names_iterator::next): Likewise.
7089 (dwarf2_initialize_objfile): Likewise.
7090 (set_partial_user): Likewise.
7091 (dwarf2_build_psymtabs_hard): Likewise.
7092 (read_comp_units_from_section): Remove arguments, adjust to
7093 std::vector change.
7094 (create_all_comp_units): Adjust to std::vector and
7095 read_comp_units_from_section changes.
7096 (dwarf2_find_containing_comp_unit): Adjust to std::vector
7097 change.
7098 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7099 (psyms_seen_size): Likewise.
7100 (write_gdbindex): Likewise.
7101 (write_debug_names): Likewise.
7102
12359b5e
SM
71032018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7104
7105 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
7106 with dwarf2_per_objfile.
7107 (create_cus_from_index): Likewise.
7108 (create_signatured_type_table_from_index): Likewise.
7109 (dwarf2_read_index): Likewise.
7110 (dwarf2_initialize_objfile): Likewise.
7111 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
7112 per_cu rather than get_dwarf2_per_objfile.
7113
ff4c9fec
SM
71142018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7115
7116 * dwarf2read.h (struct signatured_type): Forward declare.
7117 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
7118 New methods.
7119 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
7120 (dw2_get_cutu): ...this.
7121 (dwarf2_per_objfile::get_cu): Rename from...
7122 (dw2_get_cu): ...this.
7123 (dwarf2_per_objfile::get_tu): New.
7124 (create_addrmap_from_index): Adjust.
7125 (create_addrmap_from_aranges): Adjust.
7126 (dw2_find_last_source_symtab): Adjust.
7127 (dw2_map_symtabs_matching_filename): Adjust.
7128 (dw2_symtab_iter_next): Adjust.
7129 (dw2_print_stats): Adjust.
7130 (dw2_expand_all_symtabs): Adjust.
7131 (dw2_expand_symtabs_with_fullname): Adjust.
7132 (dw2_expand_marked_cus): Adjust.
7133 (dw_expand_symtabs_matching_file_matcher): Adjust.
7134 (dw2_map_symbol_filenames): Adjust.
7135 (dw2_debug_names_iterator::next): Adjust.
7136 (dwarf2_initialize_objfile): Adjust.
7137 (set_partial_user): Adjust.
7138 (dwarf2_build_psymtabs_hard): Adjust.
7139
5ca3fcb6
SM
71402018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7141
7142 * dwarf2read.c (create_signatured_type_table_from_debug_names):
7143 Remove unused variables.
7144 (dw2_map_symtabs_matching_filename): Likewise.
7145 (dwarf2_record_block_ranges): Likewise.
7146 (dwarf2_read_addr_index): Likewise.
7147 (follow_die_offset): Likewise.
7148
b2e586e8
SM
71492018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7150
7151 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
7152 to symbol_file_add_main.
7153
7c4e78cf
SM
71542018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7155
7156 PR mi/22299
7157 * mi/mi-console.c (do_fputc_async_safe): New.
7158 (mi_console_file::write_async_safe): New.
7159 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
7160 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
7161 New.
7162 * ui-file.c (ui_file::putstrn): Adjust call to
7163 fputstrn_unfiltered.
7164 * utils.c (printchar): Replace do_fputs and do_fprintf
7165 parameters by do_fputc.
7166 (fputstr_filtered): Adjust call to printchar.
7167 (fputstr_unfiltered): Likewise.
7168 (fputstrn_filtered): Likewise.
7169 (fputstrn_unfiltered): Add do_fputc parameter, pass to
7170 printchar.
7171 * utils.h (do_fputc_ftype): New typedef.
7172 (fputstrn_unfiltered): Add do_fputc parameter.
7173
5dc026d3
SM
71742018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7175
7176 * regformats/i386/i386-avx.dat: Remove.
7177
c912f608
SM
71782018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7179
7180 PR gdb/22979
7181 * amd64-tdep.c (amd64_none_init_abi): New function.
7182 (amd64_x32_none_init_abi): New function.
7183 (_initialize_amd64_tdep): Register handlers for x86-64 and
7184 x64_32 with GDB_OSABI_NONE.
7185 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
7186 GDB_OSABI_NONE osabi.
7187
26540402
SM
71882018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7189
7190 PR gdb/22980
7191 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
7192 GDB_OSABI_NONE.
7193 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
7194 * osabi.c (gdb_osabi_names): Add "unknown" entry.
7195
9018be22
SM
71962018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7197
7198 * common/byte-vector.h (char_vector): New type.
7199 * target.h (target_read_alloc): Return
7200 gdb::optional<byte_vector>.
7201 (target_read_stralloc): Return gdb::optional<char_vector>.
7202 (target_get_osdata): Return gdb::optional<char_vector>.
7203 * target.c (target_read_alloc_1): Templatize. Replacement
7204 manual memory management with vector.
7205 (target_read_alloc): Change return type, adjust.
7206 (target_read_stralloc): Change return type, adjust.
7207 (target_get_osdata): Change return type, adjust.
7208 * auxv.c (struct auxv_info) <length>: Remove.
7209 <data>: Change type to gdb::optional<byte_vector>.
7210 (auxv_inferior_data_cleanup): Free auxv_info with delete.
7211 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
7212 (target_auxv_search): Adjust.
7213 (fprint_target_auxv): Adjust.
7214 * avr-tdep.c (avr_io_reg_read_command): Adjust.
7215 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
7216 (linux_make_corefile_notes): Adjust.
7217 * osdata.c (get_osdata): Adjust.
7218 * remote.c (remote_get_threads_with_qxfer): Adjust.
7219 (remote_memory_map): Adjust.
7220 (remote_traceframe_info): Adjust.
7221 (btrace_read_config): Adjust.
7222 (remote_read_btrace): Adjust.
7223 (remote_pid_to_exec_file): Adjust.
7224 * solib-aix.c (solib_aix_get_library_list): Adjust.
7225 * solib-dsbt.c (decode_loadmap): Don't free buf.
7226 (dsbt_get_initial_loadmaps): Adjust.
7227 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
7228 * solib-target.c (solib_target_current_sos): Adjust.
7229 * tracepoint.c (sdata_make_value): Adjust.
7230 * xml-support.c (xinclude_start_include): Adjust.
7231 (xml_fetch_content_from_file): Adjust.
7232 * xml-support.h (xml_fetch_another): Change return type.
7233 (xml_fetch_content_from_file): Change return type.
7234 * xml-syscall.c (xml_init_syscalls_info): Adjust.
7235 * xml-tdesc.c (file_read_description_xml): Adjust.
7236 (fetch_available_features_from_target): Change return type.
7237 (target_fetch_description_xml): Adjust.
7238 (target_read_description_xml): Adjust.
7239
14c88955
TT
72402018-04-06 Tom Tromey <tom@tromey.com>
7241
7242 * value.c (~value): Update.
7243 (struct value) <contents>: Now unique_xmalloc_ptr.
7244 (value_contents_bits_eq, allocate_value_contents)
7245 (value_contents_raw, value_contents_all_raw)
7246 (value_contents_for_printing, value_contents_for_printing_const)
7247 (set_value_enclosing_type): Update.
7248
0c7e6dd8
TT
72492018-04-06 Tom Tromey <tom@tromey.com>
7250
7251 * value.c (range_s): Remove typedef, VEC.
7252 (struct range): Add operator<.
7253 (range_lessthan): Remove.
7254 (ranges_contain): Change type.
7255 (~value): Update.
7256 (struct value) <unavailable, optimized_out>: Now std::vector.
7257 (value_entirely_available)
7258 (value_entirely_covered_by_range_vector)
7259 (value_entirely_unavailable, value_entirely_optimized_out):
7260 Update.
7261 (insert_into_bit_range_vector): Change argument type.
7262 (find_first_range_overlap): Likewise.
7263 (struct ranges_and_idx, value_contents_bits_eq)
7264 (require_not_optimized_out, require_available): Update.
7265 (ranges_copy_adjusted): Change argument types.
7266 (value_optimized_out, value_copy, value_fetch_lazy): Update.
7267
2c8331b9
TT
72682018-04-06 Tom Tromey <tom@tromey.com>
7269
7270 * value.c (~value): Update.
7271 (struct value) <parent>: Now a value_ref_ptr.
7272 (value_parent, set_value_parent, value_address, value_copy):
7273 Update.
7274
466ce3ae
TT
72752018-04-06 Tom Tromey <tom@tromey.com>
7276
7277 * value.c (struct value): Add constructor, destructor, and member
7278 initializers.
7279 (allocate_value_lazy, value_decref): Update.
7280
062d818d
TT
72812018-04-06 Tom Tromey <tom@tromey.com>
7282
7283 * value.c (struct value) <released, next>: Remove.
7284 (all_values): Now a std::vector.
7285 (allocate_value_lazy): Update.
7286 (value_next): Remove.
7287 (value_mark, value_free_to_mark, release_value)
7288 (value_release_to_mark): Update.
7289
a6535de1
TT
72902018-04-06 Tom Tromey <tom@tromey.com>
7291
7292 * value.h (fetch_subexp_value, value_release_to_mark): Update.
7293 (free_value_chain): Remove.
7294 * value.c (free_value_chain): Remove.
7295 (value_release_to_mark): Return a std::vector.
7296 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
7297 std::vector.
7298 (check_condition): Update.
7299 * eval.c (fetch_subexp_value): Change "val_chain" to a
7300 std::vector.
7301 * breakpoint.c (update_watchpoint): Update.
7302 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
7303
b5621201
TT
73042018-04-06 Tom Tromey <tom@tromey.com>
7305
7306 * value.h (free_all_values): Remove.
7307 * value.c (free_all_values): Remove.
7308
4d0266a0
TT
73092018-04-06 Tom Tromey <tom@tromey.com>
7310
7311 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
7312 (value_history_chain, value_history_count): Remove.
7313 (value_history): New global.
7314 (record_latest_value, access_value_history, show_values)
7315 (preserve_values): Update.
7316
b4d61099
TT
73172018-04-06 Tom Tromey <tom@tromey.com>
7318
7319 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
7320 * varobj.c (varobj_set_display_format, varobj_set_value)
7321 (install_default_visualizer, construct_visualizer)
7322 (install_new_value, ~varobj, varobj_get_value_type)
7323 (my_value_of_variable, varobj_editable_p): Update.
7324 * c-varobj.c (c_describe_child, c_value_of_variable)
7325 (cplus_number_of_children, cplus_describe_child): Update.
7326 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
7327 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
7328 (ada_value_of_variable, ada_value_is_changeable_p): Update.
7329
9b558729
TT
73302018-04-06 Tom Tromey <tom@tromey.com>
7331
7332 * printcmd.c (last_examine_address): Change type to
7333 value_ref_ptr.
7334 (do_examine, x_command): Update.
7335
850645cf
TT
73362018-04-06 Tom Tromey <tom@tromey.com>
7337
7338 * value.c (release_value): Update.
7339 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
7340 (struct bpstats) <val>: Now a value_ref_ptr.
7341 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7342 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7343 (~watchpoint, print_it_watchpoint, watch_command_1)
7344 (invalidate_bp_value_on_memory_change): Update.
7345
22bc8444
TT
73462018-04-06 Tom Tromey <tom@tromey.com>
7347
7348 * varobj.c (varobj_clear_saved_item)
7349 (update_dynamic_varobj_children, install_new_value, ~varobj):
7350 Update.
7351 * value.h (value_incref): Move declaration earlier.
7352 (value_decref): Rename from value_free.
7353 (struct value_ref_policy): New.
7354 (value_ref_ptr): New typedef.
7355 (struct value_deleter): Remove.
7356 (gdb_value_up): Remove typedef.
7357 (release_value): Change return type.
7358 (release_value_or_incref): Remove.
7359 * value.c (set_value_parent): Update.
7360 (value_incref): Change return type.
7361 (value_decref): Rename from value_free.
7362 (value_free_to_mark, free_all_values, free_value_chain): Update.
7363 (release_value): Return value_ref_ptr.
7364 (release_value_or_incref): Remove.
7365 (record_latest_value, set_internalvar, clear_internalvar):
7366 Update.
7367 * stack.c (info_frame_command): Don't call value_free.
7368 * python/py-value.c (valpy_dealloc, valpy_new)
7369 (value_to_value_object): Update.
7370 * printcmd.c (do_examine): Update.
7371 * opencl-lang.c (lval_func_free_closure): Update.
7372 * mi/mi-main.c (register_changed_p): Don't call value_free.
7373 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
7374 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
7375 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
7376 value_free.
7377 * guile/scm-value.c (vlscm_free_value_smob)
7378 (vlscm_scm_from_value): Update.
7379 * frame.c (frame_register_unwind, frame_unwind_register_signed)
7380 (frame_unwind_register_unsigned, get_frame_register_bytes)
7381 (put_frame_register_bytes): Don't call value_free.
7382 * findvar.c (address_from_register): Don't call value_free.
7383 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
7384 * dwarf2loc.c (entry_data_value_free_closure)
7385 (value_of_dwarf_reg_entry, free_pieced_value_closure)
7386 (dwarf2_evaluate_loc_desc_full): Update.
7387 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7388 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7389 (~watchpoint, watch_command_1)
7390 (invalidate_bp_value_on_memory_change): Update.
7391 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
7392
7f8a5d38
SM
73932018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
7394
7395 PR gdb/23022
7396 * warning.m4: Add -Wno-error=deprecated-register.
7397 * configure: Re-generate.
7398
8a76bd3b
TT
73992018-04-05 Tom Tromey <tom@tromey.com>
7400
7401 * linespec.h: Remove include of "vec.h".
7402
8e8d776e
TT
74032018-04-05 Tom Tromey <tom@tromey.com>
7404
7405 * linespec.c (typep): Remove typedef.
7406 (find_methods, find_superclass_methods): Take a std::vector.
7407 (find_method): Use std::vector.
7408
9b2f8581
TT
74092018-04-05 Tom Tromey <tom@tromey.com>
7410
7411 * utils.c (compare_strings): Remove.
7412 * utils.h (compare_strings): Remove.
7413 * objc-lang.h (find_imps): Update.
7414 * objc-lang.c (find_methods): Take a std::vector.
7415 (uniquify_strings, find_imps): Likewise.
7416 * linespec.c (find_methods): Take a std::vector.
7417 (decode_objc): Use std::vector.
7418 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
7419 a std::vector.
7420 (find_method, find_function_symbols): Use std::vector.
7421
459a2e4c
TT
74222018-04-05 Tom Tromey <tom@tromey.com>
7423
7424 * completer.c (completion_tracker::completion_tracker): Remove
7425 cast.
7426 (completion_tracker::discard_completions): Likewise.
7427 * breakpoint.c (ambiguous_names_p): Remove cast.
7428 * ada-lang.c (_initialize_ada_language): Remove cast.
7429 * utils.h (streq): Update.
7430 (streq_hash): Add new declaration.
7431 * utils.c (streq): Return bool.
7432 (streq_hash): New function.
7433
9be2c17a
TT
74342018-04-05 Tom Tromey <tom@tromey.com>
7435
7436 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
7437 Remove a string copy.
7438
f73c6ece
TT
74392018-04-05 Tom Tromey <tom@tromey.com>
7440
7441 * linespec.c (filter_results): Use std::vector.
7442 (decode_line_2, decode_line_full): Update.
7443
53a0f8a2
TT
74442018-04-05 Tom Tromey <tom@tromey.com>
7445
7446 * linespec.c (canonical_to_fullform): Return std::string.
7447 (filter_results): Update.
7448 (struct decode_line_2_item): Add constructor.
7449 <fullform, displayform>: Now std::string.
7450 (decode_line_2_compare_items): Now a std::sort comparator.
7451 (decode_line_2): Update.
7452
a5b5adf5
TT
74532018-04-05 Tom Tromey <tom@tromey.com>
7454
7455 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
7456 (unexpected_linespec_error): Update.
7457 (linespec_parse_basic, parse_linespec): Update.
7458
6a307fc5
TT
74592018-04-05 Tom Tromey <tom@tromey.com>
7460
7461 * linespec.c (linespec_parse_basic): Reindent.
7462
41c1efc6
TT
74632018-04-05 Tom Tromey <tom@tromey.com>
7464
7465 * minsyms.h (iterate_over_minimal_symbols): Update.
7466 * minsyms.c (iterate_over_minimal_symbols): Take a
7467 gdb::function_view.
7468 * linespec.c (struct collect_minsyms): Remove.
7469 (compare_msyms): Now a std::sort comparator.
7470 (add_minsym): Add parameters.
7471 (search_minsyms_for_name): Update. Use std::vector.
7472
c5edbf3d
TT
74732018-04-03 Tom Tromey <tom@tromey.com>
7474
7475 * mipsread.c (read_alphacoff_dynamic_symtab): Use
7476 gdb::byte_vector.
7477
b39efc48
WP
74782018-04-02 Weimin Pan <weimin.pan@oracle.com>
7479
7480 * MAINTAINERS (Write After Approval): Add Weimin Pan.
7481
121ad66c 74822018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
7483
7484 PR gdb/16959
7485 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
7486 printing static type.
7487
09473be8
TT
74882018-04-01 Tom Tromey <tom@tromey.com>
7489
7490 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
7491 (rs6000_xfer_shared_libraries): Update.
7492
ec1f2d91
SM
74932018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
7494
7495 * common/gdb_vecs.h (char_ptr): Remove.
7496 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
7497
d8611974
SM
74982018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
7499
7500 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
7501 with std::vector.
7502 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
7503
a18ba4e4
SM
75042018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
7505
7506 * tracepoint.h (struct uploaded_tp): Initialize fields.
7507 <actions, step_actions, cmd_strings>: Change type to
7508 std::vector<char *>.
7509 * tracepoint.c (get_uploaded_tp): Allocate with new.
7510 (free_uploaded_tps): Free with delete.
7511 (parse_tracepoint_definition): Adjust to std::vector change.
7512 * breakpoint.c (read_uploaded_action): Likewise.
7513 (create_tracepoint_from_upload): Likewise.
7514 * ctf.c (ctf_write_uploaded_tp): Likewise.
7515 (SET_ARRAY_FIELD): Likewise.
7516 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
7517
a7961323
TT
75182018-03-30 Tom Tromey <tom@tromey.com>
7519
7520 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
7521 std::unique_ptr.
7522 (svr4_keep_data_in_core): Update.
7523 (svr4_read_so_list): Update.
7524
e83e4e24
TT
75252018-03-30 Tom Tromey <tom@tromey.com>
7526
7527 * windows-nat.c (handle_output_debug_string, handle_exception):
7528 Update.
7529 * target.h (target_read_string): Update.
7530 * target.c (target_read_string): Change "string" to
7531 unique_xmalloc_ptr.
7532 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
7533 Update.
7534 * solib-frv.c (frv_current_sos): Update.
7535 * solib-dsbt.c (dsbt_current_sos): Update.
7536 * solib-darwin.c (darwin_current_sos): Update.
7537 * linux-thread-db.c (inferior_has_bug): Update.
7538 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
7539 Update. Remove alloca.
7540 * ada-lang.c (ada_main_name): Update.
7541
263db9a1
TT
75422018-03-30 Tom Tromey <tom@tromey.com>
7543
7544 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
7545 (struct dwo_file_deleter): New.
7546 (dwo_file_up): New typedef.
7547 (open_and_init_dwo_file): Use dwo_file_up.
7548 (free_dwo_file_cleanup): Remove.
7549
5dafb3d1
TT
75502018-03-30 Tom Tromey <tom@tromey.com>
7551
7552 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
7553 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
7554
11ed8cad
TT
75552018-03-30 Tom Tromey <tom@tromey.com>
7556
7557 * dwarf2read.c (class free_cached_comp_units): New class.
7558 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
7559 (free_cached_comp_units): Remove function.
7560
9ae79dac
TT
75612018-03-30 Tom Tromey <tom@tromey.com>
7562
7563 * utils.h (make_cleanup_unpush_target): Remove.
7564 * inf-ptrace.c (struct target_unpusher): New.
7565 (target_unpush_up) New typedef.
7566 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
7567 target_unpush_up.
7568 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
7569
5aa89276
TT
75702018-03-27 Tom Tromey <tom@tromey.com>
7571
7572 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
7573
1dbeed45
TT
75742018-03-27 Pedro Alves <palves@redhat.com>
7575 Tom Tromey <tom@tromey.com>
7576
7577 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
7578 destructor. Now a class.
7579 (gdb_readline_wrapper_cleanup): Remove function.
7580 (gdb_readline_wrapper): Remove cleanups.
7581
c819b2c0
TT
75822018-03-27 Tom Tromey <tom@tromey.com>
7583
7584 * typeprint.h (struct type_print_options) <local_typedefs,
7585 global_typedefs>: Remove "struct" keyword.
7586 (class typedef_hash_table): New class.
7587 (recursively_update_typedef_hash, add_template_parameters)
7588 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
7589 (find_typedef_in_hash): Don't declare.
7590 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
7591 (typedef_hash_table::recursively_update): Rename from
7592 recursively_update_typedef_hash. Now a member.
7593 (typedef_hash_table::add_template_parameters): Rename from
7594 add_template_parameters. Now a member.
7595 (typedef_hash_table::typedef_hash_table): Now a constructor;
7596 rename from create_typedef_hash.
7597 (typedef_hash_table::~typedef_hash_table): Now a destructor;
7598 rename from free_typedef_hash.
7599 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
7600 (do_free_global_table): Remove.
7601 (typedef_hash_table::typedef_hash_table): New constructor; renamed
7602 from copy_type_recursive.
7603 (create_global_typedef_table): Remove.
7604 (typedef_hash_table::find_global_typedef): Now a member of
7605 typedef_hash_table.
7606 (typedef_hash_table::find_typedef): Rename from
7607 find_typedef_in_hash; now a member.
7608 (whatis_exp): Update.
7609 * extension.h (struct ext_lang_type_printers): Add constructor and
7610 destructor.
7611 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
7612 declare.
7613 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
7614 Now a constructor; rename from start_ext_lang_type_printers.
7615 (ext_lang_type_printers): Now a destructor; rename from
7616 free_ext_lang_type_printers.
7617 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
7618 Update.
7619 (c_type_print_base_struct_union): Update. Remove cleanups.
7620
608219fb
TT
76212018-03-27 Tom Tromey <tom@tromey.com>
7622
7623 * dwarf-index-write.c: Include <cmath>.
7624
3fcded8f
JB
76252018-03-27 Joel Brobecker <brobecker@adacore.com>
7626
7627 * NEWS: Add entry describing new "set|show varsize-limit" command.
7628 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
7629 command.
7630 * printcmd.c (_initialize_printcmd): Add "set var" alias of
7631 "set variable".
7632
cd4fb1b2
SM
76332018-03-27 Simon Marchi <simon.marchi@ericsson.com>
7634
7635 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
7636 dwarf-index-write.c
7637 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
7638 * dwarf-index-common.c: New file.
7639 * dwarf-index-common.h: New file.
7640 * dwarf-index-write.c: New file.
7641 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
7642 (struct dwarf2_section_info): Move from here.
7643 (dwarf2_section_info_def): Likewise.
7644 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
7645 (offset_type): Likewise.
7646 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
7647 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
7648 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
7649 (byte_swap): Likewise.
7650 (MAYBE_SWAP): Likewise.
7651 (dwarf2_per_cu_ptr): Likewise.
7652 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
7653 (struct tu_stats): Likewise.
7654 (struct dwarf2_per_objfile): Likewise.
7655 (struct dwarf2_per_cu_data): Likewise.
7656 (struct signatured_type): Likewise.
7657 (sig_type_ptr): Likewise.
7658 (DEF_VEC_P (sig_type_ptr)): Likewise.
7659 (INDEX4_SUFFIX): Likewise.
7660 (INDEX5_SUFFIX): Likewise.
7661 (DEBUG_STR_SUFFIX): Likewise.
7662 (dwarf2_read_section): Make non-static.
7663 (mapped_index_string_hash): Move from here.
7664 (dwarf5_djb_hash): Likewise.
7665 (file_write): Likewise.
7666 (class data_buf): Likewise.
7667 (struct symtab_index_entry): Likewise.
7668 (struct mapped_symtab): Likewise.
7669 (find_slot): Likewise.
7670 (hash_expand): Likewise.
7671 (add_index_entry): Likewise.
7672 (uniquify_cu_indices): Likewise.
7673 (class c_str_view): Likewise.
7674 (class c_str_view_hasher): Likewise.
7675 (class vector_hasher): Likewise.
7676 (write_hash_table): Likewise.
7677 (psym_index_map): Likewise.
7678 (struct addrmap_index_data): Likewise.
7679 (add_address_entry): Likewise.
7680 (add_address_entry_worker): Likewise.
7681 (write_address_map): Likewise.
7682 (symbol_kind): Likewise.
7683 (write_psymbols): Likewise.
7684 (struct signatured_type_index_data): Likewise.
7685 (write_one_signatured_type): Likewise.
7686 (recursively_count_psymbols): Likewise.
7687 (recursively_write_psymbols): Likewise.
7688 (class debug_names): Likewise.
7689 (check_dwarf64_offsets): Likewise.
7690 (psyms_seen_size): Likewise.
7691 (write_gdbindex): Likewise.
7692 (write_debug_names): Likewise.
7693 (assert_file_size): Likewise.
7694 (write_psymtabs_to_index): Likewise.
7695 (save_gdb_index_command): Likewise.
7696 (_initialize_dwarf2_read): Don't register the "save gdb-index"
7697 command.
7698 * dwarf2read.h: New file.
7699
59cc4834
JB
77002018-03-27 Joel Brobecker <brobecker@adacore.com>
7701
7702 PR gdb/22670
7703 * dwarf2read.c (dwarf2_physname): Do not return the demangled
7704 symbol name if the CU's language stores symbol names in linkage
7705 format.
7706 * language.h (struct language_defn)
7707 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
7708 all instances of this struct.
7709
67501539
TT
77102018-03-26 Tom Tromey <tom@tromey.com>
7711
7712 * stack.c (backtrace_command_1): Remove verbose code.
7713
76c939ac
TT
77142018-03-26 Tom Tromey <tom@tromey.com>
7715
7716 * python/py-framefilter.c (py_print_type): Don't catch
7717 exceptions. Return void.
7718 (py_print_value): Likewise.
7719 (py_print_single_arg): Likewise.
7720 (enumerate_args): Don't catch exceptions.
7721 (py_print_args): Likewise.
7722 (py_print_frame): Likewise.
7723 (gdbpy_apply_frame_filter): Catch exceptions here.
7724
9507b29c
TT
77252018-03-26 Tom Tromey <tom@tromey.com>
7726
7727 * stack.c (_initialize_stack): Remove trailing newlines from help
7728 text. Add "Usage" line to "backtrace" help.
7729
eb68e487
TT
77302018-03-26 Tom Tromey <tom@tromey.com>
7731
7732 PR python/16486:
7733 * python/py-framefilter.c (py_print_args): Call wrap_hint.
7734
1f111921
TT
77352018-03-26 Tom Tromey <tom@tromey.com>
7736
7737 * python/py-framefilter.c (py_print_single_arg): Return
7738 EXT_LANG_BT_ERROR from catch.
7739
fb7eb8b5
TT
77402018-03-26 Tom Tromey <tom@tromey.com>
7741
7742 PR backtrace/15584:
7743 * stack.c (backtrace_command_1): Move some code into no-filters
7744 "if".
7745
4ca59a9f
TT
77462018-03-26 Tom Tromey <tom@tromey.com>
7747
7748 * python/py-framefilter.c (throw_quit_or_print_exception): New
7749 function.
7750 (gdbpy_apply_frame_filter): Use it.
7751
92256134
TT
77522018-03-26 Tom Tromey <tom@tromey.com>
7753
7754 PR cli/17716:
7755 * python/py-framefilter.c (py_print_type, py_print_value)
7756 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
7757 RETURN_MASK_ERROR.
7758
7a630bc2
TT
77592018-03-26 Tom Tromey <tom@tromey.com>
7760
7761 * python/py-framefilter.c (enumerate_args): Use
7762 gdb::unique_xmalloc_ptr.
7763
63283d4a
TT
77642018-03-26 Tom Tromey <tom@tromey.com>
7765
7766 * python/py-framefilter.c (py_print_frame): Return
7767 EXT_LANG_BT_OK.
7768 (gdbpy_apply_frame_filter): Update comment.
7769 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
7770 Remove.
7771 <EXT_LANG_BT_NO_FILTERS>: Change value.
7772
978d6c75
TT
77732018-03-26 Tom Tromey <tom@tromey.com>
7774
7775 PR backtrace/15582:
7776 * stack.c (backtrace_command): Parse "hide" argument.
7777 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
7778 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
7779 constant.
7780
1cf7e640
TT
77812018-03-26 Tom Tromey <tom@tromey.com>
7782
7783 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
7784 add "flags".
7785 (backtrace_command): Remove "fulltrace", add "flags".
7786
ea3b0687
TT
77872018-03-26 Tom Tromey <tom@tromey.com>
7788
7789 * stack.c (backtrace_command): Rewrite command line parsing.
7790
9f034d75
SM
77912018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7792
7793 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
7794
ce1459e5
SM
77952018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7796
7797 * filename-seen-cache.h: Add include guard.
7798
4f7ae6f5
KS
77992018-03-26 Keith Seitz <keiths@redhat.com>
7800
7801 * symfile.c (place_section): Remove "struct" from section_addr_info
7802 in comment.
7803 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
7804 "struct" keyword from section_addr_info.
7805
5cd3e386
AH
78062018-03-26 Alan Hayward <alan.hayward@arm.com>
7807
7808 * regformats/regdef.h (reg): Add constructors.
7809
3e5ef9a4
PA
78102018-03-25 Pedro Alves <palves@redhat.com>
7811
7812 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
7813 if then/else bodies in var_func_name extraction.
7814
c88d2fcc 78152018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
7816
7817 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
7818 lookup_minimal_symbol() to find symbol entry.
7819 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
7820
b7fee5a3
KS
78212018-03-23 Keith Seitz <keiths@redhat.com>
7822
7823 PR c++/22968
7824 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
7825 nested type definitions for C++, too.
7826
2cc9b304
TT
78272018-03-23 Tom Tromey <tom@tromey.com>
7828
7829 * machoread.c (struct oso_el): Add a constructor. Don't define as
7830 a typedef.
7831 (macho_register_oso): Remove.
7832 (macho_symtab_read): Take a std::vector.
7833 (oso_el_compare_name): Now a std::sort comparator.
7834 (macho_symfile_read_all_oso): Take a std::vector.
7835 (macho_symfile_read): Use std::vector. Remove cleanups.
7836
a2b2bc12
TT
78372018-03-22 Tom Tromey <tom@tromey.com>
7838
7839 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
7840 (record_full_goto_bookmark): Use std::string.
7841
7a8f494c
PFC
78422018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7843
7844 PR tdep/18295
7845 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
7846 a single mask.
7847
dd6d677f
PFC
78482018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7849
7850 * rs6000-tdep.c (store_insn_p): New function.
7851 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
7852 and cr_reg to their unshifted values. Use store_insn_p to
7853 match LR saves using either R1 or fdata->alloca_reg. Use
7854 store_insn_p to match CR saves. Set alloca_reg_offset
7855 when alloca_reg and framep are set. Remove lr_reg shift
7856 when assigning to fdata->lr_register.
7857
26d6cec4
AA
78582018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
7859
7860 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
7861 command line args instead of emitting a warning.
7862
5d9310c4
SM
78632018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7864
7865 * tracepoint.h (struct static_tracepoint_marker): Initialize
7866 fields, define default constructor, move constructor and move
7867 assignment, disable the rest.
7868 <str_id, extra>: Make std::string.
7869 (release_static_tracepoint_marker): Remove.
7870 (free_current_marker): Remove.
7871 * tracepoint.c (free_current_marker): Remove.
7872 (parse_static_tracepoint_marker_definition): Adjust to
7873 std::string, use new hex2str overload.
7874 (release_static_tracepoint_marker): Remove.
7875 (print_one_static_tracepoint_marker): Get marker by reference
7876 and adjust to std::string.
7877 (info_static_tracepoint_markers_command): Adjust to std::vector
7878 changes
7879 * target.h (static_tracepoint_marker_p): Remove typedef.
7880 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
7881 (struct target_ops) <to_static_tracepoint_marker_at>: Return
7882 bool.
7883 <to_static_tracepoint_markers_by_strid>: Return std::vector.
7884 * target-debug.h
7885 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
7886 (target_debug_print_std_vector_static_tracepoint_marker): New.
7887 (target_debug_print_struct_static_tracepoint_marker_p): Rename
7888 to...
7889 (target_debug_print_static_tracepoint_marker_p): ... this.
7890 * target-delegates.c: Re-generate.
7891 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
7892 Make std::string.
7893 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
7894 (decode_static_tracepoint_spec): Adjust to std::vector.
7895 (tracepoint_print_one_detail): Adjust to std::string.
7896 (strace_marker_decode_location): Adjust to std::string.
7897 (update_static_tracepoint): Adjust to std::string, remove call
7898 to release_static_tracepoint_marker.
7899 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
7900 Adjust to std::vector.
7901 * remote.c (remote_static_tracepoint_marker_at): Return bool.
7902 (remote_static_tracepoint_markers_by_strid): Adjust to
7903 std::vector.
7904 * common/rsp-low.h (hex2str): New overload with explicit count
7905 of bytes.
7906 * common/rsp-low.c (hex2str): New overload with explicit count
7907 of bytes.
7908 * unittests/rsp-low-selftests.c (test_hex2str): New function.
7909 (_initialize_rsp_low_selftests): Add test_hex2str test.
7910 * unittests/tracepoint-selftests.c
7911 (test_parse_static_tracepoint_marker_definition): Adjust to
7912 std::string.
7913
62c222b6
SM
79142018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7915
7916 * tracepoint.c (parse_static_tracepoint_marker_definition):
7917 Consider case where the definition is followed by more
7918 definitions.
7919 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7920 tracepoint-selftests.c.
7921 * unittests/tracepoint-selftests.c: New.
7922
7eb2418f
PFC
79232018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7924
7925 * MAINTAINERS (Write After Approval): Add Pedro Franco de
7926 Carvalho.
7927
7cbe16e9
SR
79282018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7929
3d6b3b82 7930 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 7931
4ee89e90
SR
79322018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7933
3d6b3b82 7934 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 7935
92630041
TT
79362018-03-19 Tom Tromey <tom@tromey.com>
7937
7938 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
7939 "IDENT" production.
7940
76727919
TT
79412018-03-19 Pedro Alves <palves@redhat.com>
7942 Tom Tromey <tom@tromey.com>
7943
7944 * unittests/observable-selftests.c: New file.
7945 * common/observable.h: New file.
7946 * observable.h: New file.
7947 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
7948 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
7949 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
7950 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
7951 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
7952 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
7953 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
7954 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
7955 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
7956 python/py-breakpoint.c, python/py-finishbreakpoint.c,
7957 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
7958 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
7959 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
7960 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
7961 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
7962 tui/tui-interp.c, valops.c: Update all users.
7963 * tui/tui-hooks.c (tui_bp_created_observer)
7964 (tui_bp_deleted_observer, tui_bp_modified_observer)
7965 (tui_inferior_exit_observer, tui_before_prompt_observer)
7966 (tui_normal_stop_observer, tui_register_changed_observer):
7967 Remove.
7968 (tui_observers_token): New global.
7969 (attach_or_detach, tui_attach_detach_observers): New functions.
7970 (tui_install_hooks, tui_remove_hooks): Use
7971 tui_attach_detach_observers.
7972 * record-btrace.c (record_btrace_thread_observer): Remove.
7973 (record_btrace_thread_observer_token): New global.
7974 * observer.sh: Remove.
7975 * observer.c: Rename to observable.c.
7976 * observable.c (namespace gdb_observers): Define new objects.
7977 (observer_debug): Move into gdb_observers namespace.
7978 (struct observer, struct observer_list, xalloc_observer_list_node)
7979 (xfree_observer_list_node, generic_observer_attach)
7980 (generic_observer_detach, generic_observer_notify): Remove.
7981 (_initialize_observer): Update.
7982 Don't include observer.inc.
7983 * Makefile.in (generated_files): Remove observer.h, observer.inc.
7984 (clean mostlyclean): Likewise.
7985 (observer.h, observer.inc): Remove targets.
7986 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
7987 (COMMON_SFILES): Use observable.c, not observer.c.
7988 * .gitignore: Remove observer.h.
7989
1cb1f3da
TT
79902018-03-18 Tom Tromey <tom@tromey.com>
7991
7992 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
7993 gdb::def_vector.
7994 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
7995
a06ab151
TT
79962018-03-17 Tom Tromey <tom@tromey.com>
7997
7998 * auto-load.c (auto_load_objfile_script_1): Use std::string.
7999
770623f7
TT
80002018-03-17 Tom Tromey <tom@tromey.com>
8001
8002 * target.c (class scoped_target_fd): New.
8003 (target_fileio_close_cleanup): Remove.
8004 (target_fileio_read_alloc_1): Use scoped_target_fd.
8005
39be3c7e
SM
80062018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
8007
8008 * silent-rules.mk: New.
8009 * Makefile.in: Include silent-rules.mk
8010 (srcdir, VPATH, top_srcdir): Move up.
8011 (COMPILE): Add ECHO_CXX.
8012 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
8013 (init.c): Add ECHO_INIT_C.
8014 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
8015 (version.c): Add ECHO_GEN.
8016 (printcmd.o): Add ECHO_CXX.
8017 (target-float.o): Add ECHO_CXX.
8018 (ada-exp.o): Add ECHO_CXX.
8019 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
8020 (insight$(EXEEXT)): Add ECHO_CXXLD.
8021 * gnulib/configure.ac: Add AM_SILENT_RULES.
8022 * gnulib/aclocal.m4: Re-generate.
8023 * gnulib/configure: Re-generate.
8024 * gnulib/import/Makefile.in: Re-generate.
8025
37e136b1
TT
80262018-03-16 Tom Tromey <tom@tromey.com>
8027
8028 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
8029 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
8030 * utils.c (do_free_section_addr_info)
8031 (make_cleanup_free_section_addr_info): Remove.
8032 * symfile.h (struct other_sections): Add constructor.
8033 (struct section_addr_info): Remove.
8034 (section_addr_info): New typedef.
8035 (struct sym_fns) <sym_offsets>: Change type of parameter.
8036 (build_section_addr_info_from_objfile)
8037 (relative_addr_info_to_section_offsets, addr_info_make_relative)
8038 (default_symfile_offsets, symbol_file_add)
8039 (symbol_file_add_from_bfd)
8040 (build_section_addr_info_from_section_table): Update.
8041 (alloc_section_addr_info, free_section_addr_info): Don't declare.
8042 * symfile.c (alloc_section_addr_info): Remove.
8043 (build_section_addr_info_from_section_table): Change return type.
8044 Update.
8045 (build_section_addr_info_from_bfd)
8046 (build_section_addr_info_from_objfile): Likewise.
8047 (free_section_addr_info): Remove.
8048 (relative_addr_info_to_section_offsets): Change type of "addrs".
8049 (addrs_section_compar): Now a std::sort comparator.
8050 (addrs_section_sort): Change return type.
8051 (addr_info_make_relative): Change type of "addrs". Update.
8052 (default_symfile_offsets, syms_from_objfile_1)
8053 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
8054 (symbol_file_add_separate): Update.
8055 (symbol_file_add): Change type of "addrs". Update.
8056 (add_symbol_file_command): Update. Remove cleanups.
8057 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
8058 cleanups.
8059 * symfile-debug.c (debug_sym_offsets): Change type of "info".
8060 * solib.c (solib_read_symbols): Update.
8061 * objfiles.c (objfile_relocate): Update. Remove cleanups.
8062 * machoread.c (macho_symfile_offsets): Update.
8063 * jit.c (jit_bfd_try_read_symtab): Update.
8064
03afa6ef
SM
80652018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
8066
8067 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8068 unittests/utils-selftests.c.
8069 * unittests/utils-selftests.c: New file.
8070
3ae9ce5d
TT
80712018-03-14 Tom Tromey <tom@tromey.com>
8072
8073 PR cli/14977:
8074 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
8075 for NULL.
8076
b8c2339b
TT
80772018-03-14 Tom Tromey <tom@tromey.com>
8078
8079 PR cli/19918:
8080 * printcmd.c (printf_pointer): Allow "-" in format.
8081
80ae639d
TT
80822018-03-14 Tom Tromey <tom@tromey.com>
8083
8084 * printcmd.c (_initialize_printcmd): Add usage to printf.
8085
0d671d99
YQ
80862018-03-14 Yao Qi <qiyao@sourceware.org>
8087
8088 * MAINTAINERS: Update my email address.
8089
b577b6af
TT
80902018-03-13 Tom Tromey <tom@tromey.com>
8091
8092 * machoread.c (macho_check_dsym): Change filenamep to a
8093 std::string*.
8094 (macho_symfile_read): Update.
8095 * symfile.c (load_command): Use std::string.
8096
89a3b63e
AB
80972018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
8098
8099 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
8100 to error message string.
8101 (riscv_register_name): Use xsnprintf instead of sprintf.
8102 (riscv_insn::fetch_instruction): Use gdb_assert instead of
8103 internal_error.
8104 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
8105 error.
8106 (riscv_push_dummy_call): Likewise.
8107
984c7238
TT
81082018-03-12 Tom Tromey <tom@tromey.com>
8109
8110 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
8111 Use gdb::byte_vector.
8112 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
8113
933522d1
YQ
81142018-03-12 Yao Qi <yao.qi@linaro.org>
8115
8116 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
8117 parameter type to readable_regcache.
8118 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
8119 the declaration.
8120
be2daae6
TT
81212018-03-11 Tom Tromey <tom@tromey.com>
8122
8123 * dwarf2read.c (struct nextfield): Add initializers.
8124 (struct nextfnfield): Remove.
8125 (struct fnfieldlist): Add initializers. Remove "length" and
8126 "head", use std::vector.
8127 (struct decl_field_list): Remove.
8128 (struct field_info): Add initializers.
8129 <fields, baseclasses>: Now std::vector.
8130 <nbaseclasses, nfnfields, typedef_field_list_count,
8131 nested_types_list_count>: Remove.
8132 (dwarf2_add_field, dwarf2_add_type_defn)
8133 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
8134 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
8135 (process_structure_scope): Update.
8136
484cf504
TT
81372018-03-11 Tom Tromey <tom@tromey.com>
8138
8139 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
8140 for use by std::sort.
8141 (build_type_psymtabs_1): Use std::vector.
8142
9bd8e0b0
EZ
81432018-03-09 Eli Zaretskii <eliz@gnu.org>
8144
8145 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
8146 and LIBMPFR in the printed configuration.
8147
5dc1a704
TT
81482018-03-08 Tom Tromey <tom@tromey.com>
8149
8150 * source.c (get_filename_and_charpos): Use scoped_fd.
8151 * nto-procfs.c (procfs_open_1): Use scoped_fd.
8152 (procfs_pidlist): Likewise.
8153 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
8154 (iterate_over_mappings): Likewise.
8155
fdf07f3a
TT
81562018-03-08 Tom Tromey <tom@tromey.com>
8157
8158 * infcall.c (struct call_return_meta_info)
8159 <stack_temporaries_enabled>: Remove.
8160 (get_call_return_value, call_function_by_hand_dummy): Update.
8161 * thread.c (disable_thread_stack_temporaries): Remove.
8162 (enable_thread_stack_temporaries): Remove.
8163 (thread_stack_temporaries_enabled_p): Return bool.
8164 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
8165 (get_last_thread_stack_temporary): Update.
8166 * eval.c (evaluate_subexp): Update.
8167 * gdbthread.h (class enable_thread_stack_temporaries): Now a
8168 class, not a function.
8169 (value_ptr, value_vec): Remove typedefs.
8170 (class thread_info) <stack_temporaries_enabled>: Now bool.
8171 <stack_temporaries>: Now a std::vector.
8172 (thread_stack_temporaries_enabled_p)
8173 (value_in_thread_stack_temporaries): Return bool.
8174
567a3e54
SM
81752018-03-08 Simon Marchi <simon.marchi@ericsson.com>
8176
8177 * remote.c (putpkt_binary): Fix omitted bytes reporting.
8178 (getpkt_or_notif_sane_1): Likewise.
8179
00b40057
SM
81802018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8181
8182 * build-id.c (build_id_to_debug_bfd): Use std::string.
8183
a8dbfd58
SM
81842018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8185
8186 * build-id.c (find_separate_debug_file_by_buildid): Return
8187 std::string.
8188 * build-id.h (find_separate_debug_file_by_buildid): Return
8189 std::string.
8190 * coffread.c (coff_symfile_read): Adjust to std::string.
8191 * elfread.c (elf_symfile_read): Adjust to std::string.
8192 * symfile.c (separate_debug_file_exists): Change parameter to
8193 std::string.
8194 (find_separate_debug_file): Return std::string.
8195 (find_separate_debug_file_by_debuglink): Return std::string.
8196 * symfile.h (find_separate_debug_file_by_debuglink): Return
8197 std::string.
8198
e6a58aa8
SM
81992018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8200
8201 * common/xml-utils.c (xml_escape_text): Move code to...
8202 (xml_escape_text_append): ... this new function.
8203 * common/xml-utils.h (xml_escape_text_append): New declaration.
8204 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
8205 New function.
8206 (_initialize_xml_utils): register test_xml_escape_text_append as
8207 a selftest.
8208
4ef0bef6
AH
82092018-03-07 Alan Hayward <alan.hayward@arm.com>
8210
8211 * defs.h: Remove MAX_REGISTER_SIZE.
8212 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
8213 asserts.
8214 * python/py-unwind.c (pyuw_sniffer): Likewise.
8215
e0d3522b
TT
82162018-03-07 Tom Tromey <tom@tromey.com>
8217
8218 * linux-tdep.c (linux_info_proc): Update.
8219 * target.h (struct target_ops) <to_fileio_readlink>: Return
8220 optional<string>.
8221 (target_fileio_readlink): Return optional<string>.
8222 * remote.c (remote_hostio_readlink): Return optional<string>.
8223 * inf-child.c (inf_child_fileio_readlink): Return
8224 optional<string>.
8225 * target.c (target_fileio_readlink): Return optional<string>.
8226
ea005f31
AB
82272018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
8228
8229 * regcache.c (cooked_read_test): Add riscv to the list of
8230 architectures that have a save_reggroup.
8231
e95a97d4
AA
82322018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
8233
8234 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
8235 value is not a dynamic class object.
8236
d8344f3d
TT
82372018-03-06 Tom Tromey <tom@tromey.com>
8238
8239 * rust-exp.y: Formatting fixes.
8240
9add17f2
AB
82412018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8242
8243 * riscv-tdep.c (riscv_register_name): Remove target description
8244 support.
8245 (riscv_gdbarch_init): Remove target description check.
8246
c9486dfe
AB
82472018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8248
8249 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
8250 comment.
8251 * riscv-tdep.h: Likewise.
8252
d74aff3d
AB
82532018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8254
8255 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
8256 (riscv_pseudo_register_write): Delete.
8257 (riscv_gdbarch_init): Remove all use of pseudo registers.
8258
7ea78b59
SM
82592018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8260
8261 * record-btrace.c (btrace_print_lines): Replace cleanup
8262 parameter with RAII equivalents.
8263 (btrace_insn_history): Replace cleanup with RAII equivalents.
8264 * ui-out.h (make_cleanup_ui_out_list_begin_end,
8265 make_cleanup_ui_out_tuple_begin_end): Remove.
8266 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
8267 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
8268 make_cleanup_ui_out_list_begin_end): Remove.
8269
53127008
SM
82702018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8271
8272 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
8273 parameter types to std::vector. Use bool.
8274 (record_btrace_wait): Replace VEC(tp_t) with
8275 std::vector<thread_info *>.
8276 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
8277
228f1508
SM
82782018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8279
8280 * record-btrace.c (record_btrace_disable_callback): Remove.
8281 (struct scoped_btrace_disable): New.
8282 (record_btrace_open): Use scoped_btrace_disable.
8283
b2970c23
AB
82842018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8285
8286 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
8287 reading values from registers.
8288
fb294655
AB
82892018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8290
8291 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
8292 where appropriate.
8293
cab5bb9d
AB
82942018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8295
8296 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
8297 change parameter type. Use GDB's print functions, and use
8298 core_addr_to_string where appropriate.
8299 (riscv_push_dummy_call): Use core_addr_to_string where
8300 appropriate, update call to riscv_print_arg_location, and reindent
8301 a few lines.
8302 (riscv_return_value): Update call to riscv_print_arg_location.
8303
dbbb1059
AB
83042018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8305 Tim Newsome <tim@sifive.com>
8306 Albert Ou <a0u@eecs.berkeley.edu>
8307 Darius Rad <darius@bluespec.com>
8308
8309 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
8310 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
8311 (ALLDEPFILES): Add riscv-tdep.c
8312 * configure.tgt: Add riscv support.
8313 * riscv-tdep.c: New file.
8314 * riscv-tdep.h: New file.
8315 * NEWS: Mention new target.
8316 * MAINTAINERS: Add entry for riscv.
8317
5dc43913
AB
83182018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8319
8320 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
8321 fields within aggregates.
8322
3dea1ef7
SM
83232018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
8324
8325 * record-btrace.c (btrace_print_lines): Change type of flags to
8326 gdb_disassembly_flags.
8327
7efba073
JB
83282018-03-04 John Baldwin <jhb@FreeBSD.org>
8329
8330 * fbsd-nat.c: Include "inf-ptrace.h".
8331 (USE_SIGTRAP_SIGINFO): Conditionally define.
8332 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
8333 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
8334 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
8335 function.
8336 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
8337 Likewise.
8338 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
8339 Likewise.
8340 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
8341 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
8342 "supports_stopped_by_hw_breakpoint" target methods.
8343
386a8676
JB
83442018-03-04 John Baldwin <jhb@FreeBSD.org>
8345
8346 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
8347 * fbsd-nat.c (debug_fbsd_nat): New variable.
8348 (show_fbsd_nat_debug): New function.
8349 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
8350 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
8351
12279366
JB
83522018-03-04 John Baldwin <jhb@FreeBSD.org>
8353
8354 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
8355 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
8356 prototype.
8357 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
8358 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
8359 method.
8360
54693cf5
SM
83612018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8362
8363 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
8364 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
8365
ccb2231c
SM
83662018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8367
8368 * charset.c (struct charset_vector): New.
8369 (charsets): Change type to charset_vector.
8370 (find_charset_names): Adjust.
8371 (add_one): Adjust.
8372 (_initialize_charset): Adjust.
8373
6fb16ce6
SM
83742018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8375
8376 * progspace.h (struct program_space) <deleted_solibs>: Change
8377 type to std::vector<std::string>.
8378 * progspace.c (clear_program_space_solib_cache): Adjust.
8379 * breakpoint.c (print_solib_event): Adjust.
8380 (check_status_catch_solib): Adjust.
8381 * solib.c (update_solib_list): Adjust.
8382 * ui-out.h (class ui_out) <field_string>: New overload.
8383 * ui-out.c (ui_out::field_string): New overload.
8384
564b1e3f
SM
83852018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8386
8387 * progspace.h (struct program_space): Add constructor and
8388 destructor, initialize fields.
8389 (add_program_space): Remove.
8390 * progspace.c (add_program_space): Rename to...
8391 (program_space::program_space): ... this.
8392 (release_program_space): Rename to...
8393 (program_space::~program_space): ... this.
8394 (delete_program_space): Use delete to delete program_space.
8395 (initialize_progspace): Use new to allocate program_space.
8396 * inferior.c (add_inferior_with_spaces): Likewise.
8397 (clone_inferior_command): Likewise.
8398 * infrun.c (follow_fork_inferior): Likewise.
8399 (handle_vfork_child_exec_or_exit): Likewise.
8400
e80aaf61
SM
84012018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8402
8403 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
8404 (delim_string_to_char_ptr_vec): Return std::vector of
8405 gdb::unique_xmalloc_ptr.
8406 (dirnames_to_char_ptr_vec_append): Take std::vector of
8407 gdb::unique_xmalloc_ptr.
8408 (dirnames_to_char_ptr_vec): Return std::vector of
8409 gdb::unique_xmalloc_ptr.
8410 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
8411 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
8412 (delim_string_to_char_ptr_vec): Return an std::vector of
8413 gdb::unique_xmalloc_ptr, adjust the code.
8414 (dirnames_to_char_ptr_vec_append): Take an std::vector of
8415 gdb::unique_xmalloc_ptr, adjust the code.
8416 (dirnames_to_char_ptr_vec): Return an std::vector of
8417 gdb::unique_xmalloc_ptr, adjust the code.
8418 * auto-load.c (auto_load_safe_path_vec): Change type to
8419 std::vector of gdb::unique_xmalloc_ptr.
8420 (auto_load_expand_dir_vars): Return an std::vector of
8421 gdb::unique_xmalloc_ptr, adjust the code.
8422 (auto_load_safe_path_vec_update): Adjust.
8423 (filename_is_in_auto_load_safe_path_vec): Adjust.
8424 (auto_load_objfile_script_1): Adjust.
8425 * build-id.c (build_id_to_debug_bfd): Adjust.
8426 * linux-thread-db.c (thread_db_load_search): Adjust.
8427 * source.c (add_path): Adjust.
8428 (openp): Adjust.
8429 * symfile.c (find_separate_debug_file): Adjust.
8430 * utils.c (do_free_char_ptr_vec): Remove.
8431 (make_cleanup_free_char_ptr_vec): Remove.
8432
ab818ade
SDJ
84332018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
8434
8435 PR gdb/22907
8436 * common/pathstuff.c: Conditionally include "<windows.h>".
8437
e1e6f073
GS
84382018-03-01 Georg Sauthoff <mail@georg.so>
8439
8440 PR gdb/22888
8441 * gcore.in: Quote variables and switch interpreter to bash.
8442
c7b15a66
TT
84432018-03-01 Tom Tromey <tom@tromey.com>
8444
8445 * dwarf2read.c (alloc_discriminant_info): Fix default_index
8446 assertion. Add assertion for discriminant_index.
8447 (quirk_rust_enum): Use correct base type name in univariant case.
8448
0cb7c7b0
SM
84492018-03-01 Simon Marchi <simon.marchi@ericsson.com>
8450
8451 * record.c (get_call_history_modifiers): Return a
8452 record_print_flags.
8453 (cmd_record_call_history): Adjust.
8454 * record-btrace.c (record_btrace_call_history): Adjust.
8455 (record_btrace_call_history_range): Adjust.
8456 (record_btrace_call_history_from): Adjust.
8457 * target-debug.h (target_debug_print_record_print_flags): New.
8458 * target-delegates.c: Re-generate.
8459 * target.c (target_call_history): Change flags type.
8460 (target_call_history_from): Likewise.
8461 (target_call_history_range): Likewise.
8462 * target.h (struct target_ops) <target_call_history>: Likewise.
8463 (target_call_history_from): Likewise.
8464 (target_call_history_range): Likewise.
8465
25e3c82c
SDJ
84662018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
8467 Simon Marchi <simon.marchi@polymtl.ca>
8468
8469 * common/common-utils.c: Include "sys/stat.h".
8470 (is_regular_file): Move here from "source.c"; change return
8471 type to "bool".
8472 * common/common-utils.h (is_regular_file): New prototype.
8473 * common/pathstuff.c (contains_dir_separator): New function.
8474 * common/pathstuff.h (contains_dir_separator): New prototype.
8475 * source.c: Don't include "sys/stat.h".
8476 (is_regular_file): Move to "common/common-utils.c".
8477
b4987c95
SDJ
84782018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
8479
8480 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
8481 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
8482 * auto-load.c: Include "common/pathstuff.h".
8483 * common/common-def.h (current_directory): Move here.
8484 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
8485 function.
8486 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
8487 prototype.
8488 * common/pathstuff.c: New file.
8489 * common/pathstuff.h: New file.
8490 * compile/compile.c: Include "common/pathstuff.h".
8491 * defs.h (current_directory): Move to "common/common-defs.h".
8492 * dwarf2read.c: Include "common/pathstuff.h".
8493 * exec.c: Likewise.
8494 * guile/scm-safe-call.c: Likewise.
8495 * linux-thread-db.c: Likewise.
8496 * main.c: Likewise.
8497 * nto-tdep.c: Likewise.
8498 * objfiles.c: Likewise.
8499 * source.c: Likewise.
8500 * symtab.c: Likewise.
8501 * utils.c: Include "common/pathstuff.h".
8502 (gdb_realpath): Move to "common/pathstuff.c".
8503 (gdb_realpath_keepfile): Likewise.
8504 (gdb_abspath): Likewise.
8505 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
8506 (gdb_realpath_keepfile): Likewise.
8507 (gdb_abspath): Likewise.
8508
f169cfdc
JB
85092018-02-28 John Baldwin <jhb@FreeBSD.org>
8510
8511 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
8512 wildcard process pid for super_resume for kernels with a
8513 specific bug.
8514
e05cac70
PM
85152018-02-27 Phil Muldoon <pmuldoon@redhat.com>
8516
8517 * compile/compile.c (get_args): Add additional comments
8518 explaining function.
8519
55089490
TT
85202018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
8521 Tom Tromey <tom@tromey.com>
8522
8523 * target.h (memory_write_request_s): Remove typedef. Don't define
8524 VEC.
8525 (target_write_memory_blocks): Change argument to std::vector.
8526 (struct memory_write_request): Add constructor.
8527 * target-memory.c (compare_block_starting_address): Return bool.
8528 Change argument types.
8529 (claim_memory): Change arguments to use std::vector.
8530 (split_regular_and_flash_blocks, blocks_to_erase)
8531 (compute_garbled_blocks): Likewise.
8532 (cleanup_request_data, cleanup_write_requests_vector): Remove.
8533 (target_write_memory_blocks): Change argument to std::vector.
8534 * symfile.c (struct load_section_data): Add constructor and
8535 destructor. Use std::vector for "requests".
8536 (struct load_progress_data): Add initializers.
8537 (load_section_callback): Update. Use "new".
8538 (clear_memory_write_data): Remove.
8539 (generic_load): Update.
8540
0c305b61
AH
85412018-02-27 Alan Hayward <alan.hayward@arm.com>
8542
8543 * arch/aarch64.h: Use common/tdesc.h.
8544
c5196c92
MR
85452018-02-26 Maciej W. Rozycki <macro@mips.com>
8546
8547 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
8548 architecture with a 64-bit ABI.
8549
37c33887
MR
85502018-02-26 Maciej W. Rozycki <macro@mips.com>
8551
8552 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
8553 ahead of target description loading.
8554
d4dd3282
TT
85552018-02-26 Tom Tromey <tom@tromey.com>
8556
8557 * stack.c (backtrace_command_1): Update.
8558 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
8559 of "flags".
8560 * python/py-framefilter.c (py_print_frame)
8561 (gdbpy_apply_frame_filter): Change type of "flags".
8562 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
8563 of "flags".
8564 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
8565 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
8566 * extension.h (enum frame_filter_flag): Rename from
8567 frame_filter_flags.
8568 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
8569 (apply_ext_lang_frame_filter): Change type of "flags".
8570 * extension.c (apply_ext_lang_frame_filter): Change type of
8571 "flags".
8572 * extension-priv.h (struct extension_language_ops)
8573 <apply_frame_filter>: Change type of "flags".
8574
6893c19a
TT
85752018-02-26 Tom Tromey <tom@tromey.com>
8576
8577 PR python/16497:
8578 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
8579 off-by-one in py_end computation.
8580 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
8581 PRINT_MORE_FRAMES.
8582 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
8583 constant.
8584
2ddeaf8a
TT
85852018-02-26 Tom Tromey <tom@tromey.com>
8586
8587 * dwarf2read.c (struct variant_field): New.
8588 (struct nextfield) <variant>: New field.
8589 (dwarf2_add_field): Handle DW_TAG_variant_part.
8590 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
8591 discriminated union.
8592 (read_structure_type): Handle DW_TAG_variant_part.
8593 (handle_struct_member_die): New function, extracted from
8594 process_structure_scope. Handle DW_TAG_variant.
8595 (process_structure_scope): Handle discriminated unions. Call
8596 handle_struct_member_die.
8597
c9317f21
TT
85982018-02-26 Tom Tromey <tom@tromey.com>
8599
8600 * rust-lang.h (rust_last_path_segment): Declare.
8601 * rust-lang.c (rust_last_path_segment): Now public. Change
8602 contract.
8603 (struct disr_info): Remove.
8604 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
8605 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
8606 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
8607 (rust_enum_p, rust_enum_variant): New function.
8608 (rust_underscore_fields): Remove "offset" parameter.
8609 (rust_print_enum): New function.
8610 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
8611 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
8612 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
8613 enums.
8614 (rust_internal_print_type): New function, from rust_print_type.
8615 Remove enum code.
8616 (rust_print_type): Call rust_internal_print_type.
8617 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
8618 Update enum handling.
8619 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
8620 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
8621 (rust_union_quirks): New functions.
8622 (process_full_comp_unit, process_full_type_unit): Call
8623 rust_union_quirks.
8624 (process_structure_scope): Update rust_unions if necessary.
8625
7c22600a
TT
86262018-02-26 Tom Tromey <tom@tromey.com>
8627
8628 * value.h (value_union_variant): Declare.
8629 * valops.c (value_union_variant): New function.
8630 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
8631 (struct discriminant_info): New.
8632 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
8633 enumerator.
8634 (struct main_type) <flag_discriminated_union>: New field.
8635
15ce8941
TT
86362018-02-26 Tom Tromey <tom@tromey.com>
8637
8638 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8639 unittests/unpack-selftests.c.
8640 * unittests/unpack-selftests.c: New file.
8641 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
8642
48fbe735
YQ
86432018-02-26 Yao Qi <yao.qi@linaro.org>
8644
8645 * dwarf2read.c (struct partial_die_info) <read>: New method.
8646 (read_partial_die): Remove the declaration.
8647 (load_partial_dies): Update.
8648 (partial_die_info::partial_die_info):
8649 (read_partial_die): Change it to partial_die_info::read.
8650
52356b79
YQ
86512018-02-26 Yao Qi <yao.qi@linaro.org>
8652
8653 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
8654 (fixup_partial_die): Remove declaration.
8655 (scan_partial_symbols): Update.
8656 (partial_die_parent_scope): Likewise.
8657 (partial_die_full_name): Likewise.
8658 (fixup_partial_die): Change it to partial_die_info::fixup.
8659
35cc7ed7
YQ
86602018-02-26 Yao Qi <yao.qi@linaro.org>
8661
8662 * dwarf2read.c (read_partial_die): Update the declaration.
8663 (load_partial_dies): Caller update.
8664 (read_partial_die): Remove one argument abbrev_len.
8665
6f06d47b
YQ
86662018-02-26 Yao Qi <yao.qi@linaro.org>
8667
8668 * dwarf2read.c (struct partial_die_info): Add ctor, delete
8669 assignment operator.
8670 (load_partial_dies): Use ctor and copy ctor.
8671 (read_partial_die): Update.
8672 (dwarf2_cu::find_partial_die): Use ctor.
8673
d590ff25
YQ
86742018-02-26 Yao Qi <yao.qi@linaro.org>
8675
8676 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
8677 (find_partial_die_in_comp_unit): Change it to
8678 dwarf2_cu::find_partial_die.
8679 (find_partial_die): Update.
8680
fd0a254f
YQ
86812018-02-26 Yao Qi <yao.qi@linaro.org>
8682
8683 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
8684 is NULL.
8685
cd9983dd
YQ
86862018-02-26 Yao Qi <yao.qi@linaro.org>
8687
8688 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
8689
f46cd62a
AH
86902018-02-26 Alan Hayward <alan.hayward@arm.com>
8691
8692 * arch/amd64.h: Use common/tdesc.h.
8693 * arch/i386.c: Likewise.
8694 * arch/i386.h: Likewise.
8695 * arch/tic6x.c: Likewise.
8696 * arch/tdesc.h: Move file from here...
8697 * common/tdesc.h: ...to here.
8698 * features/aarch64-core.c: Regenerate.
8699 * features/aarch64-fpu.c: Regenerate.
8700 * features/i386/32bit-avx.c: Regenerate.
8701 * features/i386/32bit-avx512.c: Regenerate.
8702 * features/i386/32bit-core.c: Regenerate.
8703 * features/i386/32bit-linux.c: Regenerate.
8704 * features/i386/32bit-mpx.c: Regenerate.
8705 * features/i386/32bit-pkeys.c: Regenerate.
8706 * features/i386/32bit-sse.c: Regenerate.
8707 * features/i386/64bit-avx.c: Regenerate.
8708 * features/i386/64bit-avx512.c: Regenerate.
8709 * features/i386/64bit-core.c: Regenerate.
8710 * features/i386/64bit-linux.c: Regenerate.
8711 * features/i386/64bit-mpx.c: Regenerate.
8712 * features/i386/64bit-pkeys.c: Regenerate.
8713 * features/i386/64bit-segments.c: Regenerate.
8714 * features/i386/64bit-sse.c: Regenerate.
8715 * features/i386/x32-core.c: Regenerate.
8716 * features/tic6x-c6xp.c: Regenerate.
8717 * features/tic6x-core.c: Regenerate.
8718 * features/tic6x-gp.c: Regenerate.
8719 * target-descriptions.c: Use common/tdesc.h.
8720 * target-descriptions.h: Likewise.
8721
9b292f68
TT
87222018-02-24 Tom Tromey <tom@tromey.com>
8723
8724 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
8725 (try_thread_db_load_from_dir, thread_db_load_search): Use
8726 std::string.
8727 (info_auto_load_libthread_db_compare): Return bool. Change
8728 argument types.
8729 (info_auto_load_libthread_db): Use std::vector, std::string.
8730 Remove cleanups.
8731
281d762b
TT
87322018-02-24 Tom Tromey <tom@tromey.com>
8733
8734 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
8735 std::string.
8736 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
8737 std::string*.
8738 * gdbarch.c: Rebuild.
8739 * gdbarch.h: Rebuild.
8740 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
8741 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
8742 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
8743 std::string*.
8744
9d8780f0
SM
87452018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
8746
8747 * gdbtypes.h (sect_offset): Change type to uint64_t.
8748 (sect_offset_str): New function.
8749 * dwarf2read.c (create_addrmap_from_aranges): Use
8750 sect_offset_str.
8751 (error_check_comp_unit_head): Likewise.
8752 (create_debug_type_hash_table): Likewise.
8753 (read_cutu_die_from_dwo): Likewise.
8754 (init_cutu_and_read_dies): Likewise.
8755 (init_cutu_and_read_dies_no_follow): Likewise.
8756 (process_psymtab_comp_unit_reader): Likewise.
8757 (partial_die_parent_scope): Likewise.
8758 (peek_die_abbrev): Likewise.
8759 (process_queue): Likewise.
8760 (dwarf2_physname): Likewise.
8761 (read_namespace_alias): Likewise.
8762 (read_import_statement): Likewise.
8763 (create_dwo_cu_reader): Likewise.
8764 (create_cus_hash_table): Likewise.
8765 (lookup_dwo_cutu): Likewise.
8766 (inherit_abstract_dies): Likewise.
8767 (read_func_scope): Likewise.
8768 (read_call_site_scope): Likewise.
8769 (dwarf2_add_member_fn): Likewise.
8770 (read_common_block): Likewise.
8771 (read_module_type): Likewise.
8772 (read_typedef): Likewise.
8773 (read_subrange_type): Likewise.
8774 (load_partial_dies): Likewise.
8775 (read_partial_die): Likewise.
8776 (find_partial_die): Likewise.
8777 (read_str_index): Likewise.
8778 (dwarf2_string_attr): Likewise.
8779 (build_error_marker_type): Likewise.
8780 (lookup_die_type): Likewise.
8781 (dump_die_shallow): Likewise.
8782 (follow_die_ref): Likewise.
8783 (dwarf2_fetch_die_loc_sect_off): Likewise.
8784 (dwarf2_fetch_constant_bytes): Likewise.
8785 (follow_die_sig): Likewise.
8786 (get_signatured_type): Likewise.
8787 (get_DW_AT_signature_type): Likewise.
8788 (dwarf2_find_containing_comp_unit): Likewise.
8789 (set_die_type): Likewise.
8790
8ec57239
JB
87912018-02-21 John Baldwin <jhb@FreeBSD.org>
8792
8793 * arch/aarch64.c: Include "common-defs.h".
8794 * arch/amd64.c: Likewise.
8795 * arch/i386.c: Likewise.
8796
3eac2b65
TT
87972018-02-21 Tom Tromey <tom@tromey.com>
8798
8799 * value.h: (extract_field_op): Update.
8800 * eval.c (extract_field_op): Return a const char *.
8801 * expression.h (parse_expression_for_completion): Update.
8802 * completer.c (complete_expression): Update.
8803 (add_struct_fields): Make fieldname const.
8804 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
8805 (mark_completion_tag, parse_exp_in_context_1): Update.
8806 (parse_expression_for_completion): Change "name" to
8807 unique_xmalloc_ptr*.
8808
6ccb583f
TT
88092018-02-21 Tom Tromey <tom@tromey.com>
8810
8811 * infcall.c (call_function_by_hand_dummy): Use std::vector.
8812
c113ed0c
YQ
88132018-02-21 Yao Qi <yao.qi@linaro.org>
8814
8815 * avr-tdep.c (avr_read_pc): Change parameter type to
8816 readable_regcache.
8817 * gdbarch.sh (read_pc): Likewise.
8818 * gdbarch.c: Re-generated.
8819 * gdbarch.h: Re-generated.
8820 * hppa-tdep.c (hppa_read_pc): Change parameter type to
8821 readable_regcache.
8822 * ia64-tdep.c (ia64_read_pc): Likewise.
8823 * mips-tdep.c (mips_read_pc): Likewise.
8824 * spu-tdep.c (spu_read_pc): Likewise.
8825
4c74fe6b
YQ
88262018-02-21 Yao Qi <yao.qi@linaro.org>
8827
8828 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
8829 * regcache-dump.c: New file.
8830 * regcache.c: Move register_dump to regcache-dump.c.
8831 (maintenance_print_registers): Likewise.
8832 (maintenance_print_raw_registers): Likewise.
8833 (maintenance_print_cooked_registers): Likewise.
8834 (maintenance_print_register_groups): Likewise.
8835 (maintenance_print_remote_registers): Likewise.
8836 (_initialize_regcache): Likewise.
8837 * regcache.h (register_dump): Moved from regcache.c.
8838
796bb026
YQ
88392018-02-21 Yao Qi <yao.qi@linaro.org>
8840
8841 * regcache.c (regcache::regcache): Update.
8842 (regcache::invalidate): Move it to detached_regcache::invalidate.
8843 (get_thread_arch_aspace_regcache): Update.
8844 (regcache::raw_update): Update.
8845 (regcache::cooked_read): Remove some code.
8846 (regcache::cooked_read_value): Likewise.
8847 (regcache::raw_write): Remove assert on m_readonly_p.
8848 (regcache::raw_supply_integer): Move it to
8849 detached_regcache::raw_supply_integer.
8850 (regcache::raw_supply_zeroed): Likewise.
8851 * regcache.h (detached_regcache) <raw_supply_integer>: New
8852 declaration.
8853 <raw_supply_zeroed, invalidate>: Likewise.
8854 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
8855 <invalidate>: Likewise.
8856 <m_readonly_p>: Removed.
8857
215c69dc
YQ
88582018-02-21 Yao Qi <yao.qi@linaro.org>
8859
8860 * infcmd.c (get_return_value): Let stop_regs point to
8861 get_current_regcache.
8862 * regcache.c (regcache::regcache): Remove.
8863 (register_dump_reg_buffer): New class.
8864 (regcache_print): Adjust.
8865 * regcache.h (regcache): Remove constructors.
8866
f3384e66
YQ
88672018-02-21 Yao Qi <yao.qi@linaro.org>
8868
8869 * regcache.c (class register_dump): New class.
8870 (register_dump_regcache, register_dump_none): New class.
8871 (register_dump_remote, register_dump_groups): New class.
8872 (regcache_print): Update.
8873 * regcache.h (regcache_dump_what): Move it to regcache.c.
8874 (regcache) <dump>: Remove.
8875
c8ec2f33
YQ
88762018-02-21 Yao Qi <yao.qi@linaro.org>
8877
8878 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
8879 reg_buffer_rw *.
8880 (jit_unwind_reg_set_impl): Call raw_supply.
8881 (jit_frame_sniffer): Use reg_buffer_rw.
8882 * record-full.c (record_full_core_regbuf): Change its type.
8883 (record_full_core_open_1): Use reg_buffer_rw.
8884 (record_full_close): Likewise.
8885 (record_full_core_fetch_registers): Use regcache->raw_supply.
8886 (record_full_core_store_registers): Likewise.
8887 * regcache.c (regcache::get_register_status): Move it to
8888 reg_buffer.
8889 (regcache_raw_set_cached_value): Remove.
8890 (regcache::raw_set_cached_value): Remove.
8891 (regcache::raw_write): Call raw_supply.
8892 (regcache::raw_supply): Move it to reg_buffer_rw.
8893 * regcache.h (regcache_raw_set_cached_value): Remove.
8894 (reg_buffer_rw): New class.
8895
daf6667d
YQ
88962018-02-21 Yao Qi <yao.qi@linaro.org>
8897
8898 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
8899 readonly_detached_regcache.
8900 (dummy_frame_prev_register): Use regcache->cooked_read.
8901 * frame.c (frame_save_as_regcache): Change return type.
8902 (frame_pop): Update.
8903 * frame.h (frame_save_as_regcache): Update declaration.
8904 * inferior.h (get_infcall_suspend_state_regcache): Update
8905 declaration.
8906 * infrun.c (infcall_suspend_state) <registers>: use
8907 readonly_detached_regcache.
8908 (save_infcall_suspend_state): Don't use regcache_dup.
8909 (get_infcall_suspend_state_regcache): Change return type.
8910 * linux-fork.c (struct fork_info) <savedregs>: Change to
8911 readonly_detached_regcache.
8912 <pc>: New field.
8913 (fork_save_infrun_state): Don't use regcache_dup.
8914 (info_checkpoints_command): Adjust.
8915 * mi/mi-main.c (register_changed_p): Update declaration.
8916 (mi_cmd_data_list_changed_registers): Use
8917 readonly_detached_regcache.
8918 (register_changed_p): Change parameter type to
8919 readonly_detached_regcache.
8920 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
8921 readonly_detached_regcache.
8922 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
8923 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
8924 New.
8925 (regcache::save): Move it to reg_buffer.
8926 (regcache::restore): Change parameter type.
8927 (regcache_dup): Remove.
8928 * regcache.h (reg_buffer) <save>: New method.
8929 (readonly_detached_regcache): New class.
8930 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
8931 readonly_detached_regcache.
8932 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
8933
fc5b8736
YQ
89342018-02-21 Yao Qi <yao.qi@linaro.org>
8935
8936 * frame.c (frame_save_as_regcache): Use regcache method save.
8937 (frame_pop): Use regcache method restore.
8938 * infrun.c (restore_infcall_suspend_state): Likewise.
8939 * linux-fork.c (fork_load_infrun_state): Likewise.
8940 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
8941 save.
8942 * regcache.c (regcache_save): Remove.
8943 (regcache::restore): More asserts.
8944 (regcache_cpy): Remove.
8945 * regcache.h (regcache_save): Remove the declaration.
8946 (regcache::restore): Move from private to public.
8947 Remove the friend declaration of regcache_cpy.
8948 (regcache_cpy): Remove declaration.
8949
849d0ba8
YQ
89502018-02-21 Yao Qi <yao.qi@linaro.org>
8951
8952 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
8953 parameter type to 'readable_regcache *'.
8954 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
8955 * arm-tdep.c (arm_neon_quad_read): Likewise.
8956 (arm_pseudo_read): Likewise.
8957 * avr-tdep.c (avr_pseudo_register_read): Likewise.
8958 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
8959 * frv-tdep.c (frv_pseudo_register_read): Likewise.
8960 * gdbarch.c: Re-generated.
8961 * gdbarch.h: Re-generated.
8962 * gdbarch.sh (pseudo_register_read): Change parameter type to
8963 'readable_regcache *'.
8964 (pseudo_register_read_value): Likewise.
8965 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
8966 (h8300_pseudo_register_read): Likewise.
8967 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
8968 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
8969 (i386_pseudo_register_read_into_value): Likewise.
8970 (i386_pseudo_register_read_value): Likewise.
8971 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
8972 declaration.
8973 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
8974 * m32c-tdep.c (m32c_raw_read): Likewise.
8975 (m32c_read_flg): Likewise.
8976 (m32c_banked_register): Likewise.
8977 (m32c_banked_read): Likewise.
8978 (m32c_sb_read): Likewise.
8979 (m32c_part_read): Likewise.
8980 (m32c_cat_read): Likewise.
8981 (m32c_r3r2r1r0_read): Likewise.
8982 (m32c_pseudo_register_read): Likewise.
8983 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
8984 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
8985 (mep_pseudo_cr64_read): Likewise.
8986 (mep_pseudo_register_read): Likewise.
8987 * mips-tdep.c (mips_pseudo_register_read): Likewise.
8988 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
8989 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
8990 * regcache.c (regcache::raw_read): Move it to readable_regcache.
8991 (regcache::cooked_read): Likewise.
8992 (regcache::cooked_read_value): Likewise.
8993 (regcache_cooked_read_signed):
8994 (regcache::cooked_read): Likewise.
8995 * regcache.h (readable_regcache): New class.
8996 (regcache): Inherit readable_regcache. Move some methods to
8997 readable_regcache.
8998 * rl78-tdep.c (rl78_pseudo_register_read): Change
8999 parameter type to 'readable_regcache *'.
9000 * rs6000-tdep.c (do_regcache_raw_read): Remove.
9001 (e500_pseudo_register_read): Change parameter type to
9002 'readable_regcache *'.
9003 (dfp_pseudo_register_read): Likewise.
9004 (vsx_pseudo_register_read): Likewise.
9005 (efpr_pseudo_register_read): Likewise.
9006 * s390-tdep.c (s390_pseudo_register_read): Likewise.
9007 * sh-tdep.c (sh_pseudo_register_read): Likewise.
9008 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
9009 (sh64_pseudo_register_read): Likewise.
9010 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9011 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9012 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9013 (spu_pseudo_register_read): Likewise.
9014 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9015 (xtensa_pseudo_register_read): Likewise.
9016
31716595
YQ
90172018-02-21 Yao Qi <yao.qi@linaro.org>
9018
9019 * regcache.c (regcache::regcache): Call reg_buffer ctor.
9020 (regcache::arch): Move it to reg_buffer::arch.
9021 (regcache::register_buffer): Likewise.
9022 (regcache::assert_regnum): Likewise.
9023 (regcache::num_raw_registers): Likewise.
9024 * regcache.h (reg_buffer): New class.
9025 (regcache): Inherit reg_buffer.
9026
7104e59b
SM
90272018-02-20 Simon Marchi <simon.marchi@ericsson.com>
9028
9029 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
9030 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
9031
2d8adcbd
MM
90322018-02-20 Markus Metzger <markus.t.metzger@intel.com>
9033
9034 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
9035
b5884fa7
AH
90362018-02-19 Alan Hayward <alan.hayward@arm.com>
9037
9038 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
9039 (SFILES): Remove common/*.c files.
9040 (COMMON_OBS): Remove some *.o files built from common/*.c files.
9041 * common/common.host: Add common reference.
9042 * configure.ac: Likewise.
9043 * configure: Regenerate.
9044
fd90ace4
YQ
90452018-02-16 Yao Qi <yao.qi@linaro.org>
9046
9047 * block.c (block_namespace_info): Inherit allocate_on_obstack.
9048 (block_initialize_namespace): Use new.
9049 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
9050 (dwarf2_free_objfile): Use delete.
9051 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
9052 (copy_type_recursive): Use new.
9053 * gdb_obstack.h (allocate_on_obstack): New.
9054
85046ae2
YQ
90552018-02-15 Yao Qi <yao.qi@linaro.org>
9056
9057 PR gdb/22849
9058 * inferior.c (exit_inferior_1): Reset inf->control.
9059
355c559b
JB
90602018-02-15 Joel Brobecker <brobecker@adacore.com>
9061
9062 * ada-lang.c (ada_to_fixed_value_create): Delete advance
9063 declaration.
9064
980548fd
PA
90652018-02-14 Pedro Alves <palves@redhat.com>
9066
9067 * frame-unwind.c (frame_unwind_try_unwinder): Always call
9068 frame_cleanup_after_sniffer on exception.
9069
692d6f97
TT
90702018-02-14 Tom Tromey <tom@tromey.com>
9071
9072 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
9073 const.
9074 (solib_bfd_open): Make pathname const.
9075 * solib.c (solib_bfd_open): Make pathname const.
9076 * solib-spu.c (spu_bfd_fopen): Make name const.
9077 (spu_bfd_open): Make pathname const.
9078 * solib-darwin.c (darwin_bfd_open): Make pathname const.
9079 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
9080
e0cc99a6
TT
90812018-02-14 Tom Tromey <tom@tromey.com>
9082
9083 * symfile.c (symfile_bfd_open): Update.
9084 * source.h (openp, source_full_path_of, find_and_open_source):
9085 Change argument type to unique_xmalloc_ptr.
9086 * source.c (openp): Take a unique_xmalloc_ptr.
9087 (source_full_path_of, find_and_open_source): Likewise.
9088 (open_source_file, symtab_to_fullname): Update.
9089 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
9090 unique_xmalloc_ptr.
9091 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
9092 (exec_file_find): Update.
9093 * psymtab.c (psymtab_to_fullname): Update.
9094 * nto-tdep.h (nto_find_and_open_solib): Update.
9095 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
9096 unique_xmalloc_ptr.
9097 * exec.c (exec_file_attach): Update.
9098 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
9099 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
9100
b46a8d7c
TT
91012018-02-14 Tom Tromey <tom@tromey.com>
9102
9103 * solib.c: Include source.h.
9104 * nto-tdep.c: Include source.h.
9105 * mi/mi-cmd-env.c: Include source.h.
9106 * infcmd.c: Include source.h.
9107 * exec.c: Include source.h.
9108 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
9109 (add_path, directory_switch, source_path, init_source_path): Move
9110 declarations...
9111 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
9112 (add_path, directory_switch, source_path, init_source_path):
9113 ...here.
9114
797bc1cb
TT
91152018-02-14 Tom Tromey <tom@tromey.com>
9116
9117 * solist.h (exec_file_find, solib_find): Return
9118 unique_xmalloc_ptr.
9119 (solib_bfd_fopen): Take a const char *.
9120 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
9121 (exec_file_find, solib_find): Likewise.
9122 (solib_bfd_fopen): Do not take ownership of "pathname".
9123 (solib_bfd_open): Use unique_xmalloc_ptr.
9124 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
9125 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
9126 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
9127 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
9128
f98b2e33
JB
91292018-02-14 Joel Brobecker <brobecker@adacore.com>
9130
9131 * ada-lang.c (name_match_type_from_name): Remove reference to
9132 ada_name_for_lookup in function's documentation.
9133 * ada-lang.h (ada_name_for_lookup): Delete declaration.
9134
24b9144d
SM
91352018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9136
9137 * defs.h (enum openp_flags): New enum.
9138 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
9139 Move to enum openp_flags.
9140 (openp_flags): New enum flags.
9141 (openp): Change parameter type to openp_flags.
9142 * source.c (openp): Change parameter type to openp_flags.
9143 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
9144 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
9145
387cd15b
SM
91462018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9147
9148 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
9149 per-command.
9150
b303c6f6
AB
91512018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
9152
9153 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
9154 into...
9155 (class dwarf2_queue_guard): ...the destructor of this new class.
9156 (dw2_do_instantiate_symtab): Create instance of the new class
9157 dwarf2_queue_guard, remove cleanup.
9158
9c3630e9
TT
91592018-02-09 Tom Tromey <tom@tromey.com>
9160
9161 * source.c (find_source_lines): Don't reference past the end of
9162 the vector.
9163
c4e12631
MM
91642018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9165
9166 * remote.c (remote_btrace_maybe_reopen): Change error message.
9167 * btrace.c (btrace_enable): Likewise.
9168 (parse_xml_btrace): Likewise.
9169 (parse_xml_btrace_conf): Likewise.
9170
88711fbf
MM
91712018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9172
9173 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
9174 (linux_enable_pt, linux_enable_bts): Call
9175 diagnose_perf_event_open_fail.
9176
17ad2a4f
MM
91772018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9178
9179 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
9180 Remove parameter and change return type. Update callers. Move it.
9181 (linux_enable_bts, linux_enable_pt): Improve error message.
9182 (linux_enable_pt): Remove zero buffer size check.
9183 (linux_enable_btrace): Improve error messages. Remove NULL return
9184 check.
9185
de6242d3
MM
91862018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9187
9188 * btrace.c (btrace_enable): Remove target_supports_btrace call.
9189 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
9190 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
9191 (linux_supports_pt, linux_supports_btrace): Remove.
9192 (linux_enable_bts): Call cpu_supports_bts.
9193 * nat/linux-btrace.h (linux_supports_btrace): Remove.
9194 * remote.c (remote_supports_btrace): Remove.
9195 (init_remote_ops): Remove remote_supports_btrace.
9196 * target-delegates.c: Regenerated.
9197 * target.c (target_supports_btrace): Remove.
9198 * target.h (target_ops) <to_supports_btrace>: Remove
9199 (target_supports_btrace): Remove.
9200 * x86-linux-nat.c (x86_linux_create_target): Remove
9201 linux_supports_btrace.
9202
9ee23a85
MM
92032018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9204
9205 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
9206 btrace failed.
9207 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
9208 exception and use message in own exception.
9209
5c3284c1
MM
92102018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9211
9212 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
9213 (perf_event_pt_event_type): Use gdb_file_up.
9214 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
9215 scoped_fd, and scoped_mmap.
9216
84696f37
MM
92172018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9218
9219 * common/scoped_mmap.h: New.
9220 * unittests/scoped_mmap-selftest.c: New.
9221 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9222 unittests/scoped_mmap-selftest.c.
9223
ea4a0888
MM
92242018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9225
9226 * common/scoped_fd.h: New.
9227 * unittests/scoped_fd-selftest.c: New.
9228 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9229 unittests/scoped_fd-selftest.c.
9230
869e8290
TT
92312018-02-09 Tom Tromey <tom@tromey.com>
9232
9233 * auto-load.c (auto_load_section_scripts): Use
9234 gdb::unique_xmalloc_ptr.
9235
a37a2ae7
TT
92362018-02-09 Tom Tromey <tom@tromey.com>
9237
9238 * auto-load.c (execute_script_contents): Use std::string.
9239
4e725347
JB
92402018-02-09 Joel Brobecker <brobecker@adacore.com>
9241
9242 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
9243 Python function, rather than a new command.
9244
9a897d43
TT
92452018-02-08 Tom Tromey <tom@tromey.com>
9246
9247 * solib.c (solib_find_1): Use std::string.
9248 (solib_bfd_fopen): Use unique_xmalloc_ptr.
9249
58ef3771
TT
92502018-02-08 Tom Tromey <tom@tromey.com>
9251
9252 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
9253
a9abc434
TT
92542018-02-08 Tom Tromey <tom@tromey.com>
9255
9256 * source.c (find_source_lines): Use gdb::def_vector.
9257
84f27c6f
TT
92582018-02-08 Tom Tromey <tom@tromey.com>
9259
9260 * macrocmd.c (struct temporary_macro_definition): New.
9261 (macro_define_command): Use temporary_macro_definition. Remove
9262 cleanups.
9263 (free_macro_definition_ptr): Remove.
9264
0354904b
TT
92652018-02-08 Tom Tromey <tom@tromey.com>
9266
9267 * macroexp.c (maybe_expand): Use std::string.
9268
1739cf24
TT
92692018-02-08 Tom Tromey <tom@tromey.com>
9270
9271 * macroexp.c (struct macro_buffer): Add initializers for some
9272 members.
9273 (init_buffer, init_shared_buffer, free_buffer)
9274 (free_buffer_return_text): Remove.
9275 (macro_buffer): New constructors.
9276 (~macro_buffer): New destructor.
9277 (macro_buffer::set_shared): New method.
9278 (macro_buffer::resize_buffer, macro_buffer::appendc)
9279 (macro_buffer::appendmem): Now methods, not free functions.
9280 (set_token, append_tokens_without_splicing, stringify)
9281 (macro_stringify): Update.
9282 (gather_arguments): Change return type. Remove argc_p argument,
9283 add args_ptr argument. Use std::vector.
9284 (substitute_args): Remove argc argument. Accept std::vector.
9285 (expand): Update. Use std::vector.
9286 (scan, macro_expand, macro_expand_next): Update.
9287
f6c2623e
TT
92882018-02-08 Tom Tromey <tom@tromey.com>
9289
9290 * symtab.c (default_collect_symbol_completion_matches_break_on):
9291 Use unique_xmalloc_ptr.
9292 * macroscope.h: (sal_macro_scope, user_macro_scope)
9293 (default_macro_scope): Return unique_xmalloc_ptr.
9294 * macroscope.c (sal_macro_scope, user_macro_scope)
9295 (default_macro_scope): Return unique_xmalloc_ptr.
9296 * macroexp.h (macro_expand, macro_expand_once): Return
9297 unique_xmalloc_ptr.
9298 * macroexp.c (macro_expand, macro_expand_once): Return
9299 unique_xmalloc_ptr.
9300 * macrocmd.c (macro_expand_command, macro_expand_once_command)
9301 (info_macro_command, info_macros_command): Use
9302 unique_xmalloc_ptr.
9303 * compile/compile-c-support.c (write_macro_definitions): Use
9304 unique_xmalloc_ptr.
9305 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
9306
c2e0e465
SM
93072018-02-07 Simon Marchi <simon.marchi@ericsson.com>
9308
9309 * value.c (value_static_field): Assign field type instead of
9310 containing type when returning an optimized out value.
9311
3f8c94b4
YQ
93122018-02-06 Yao Qi <yao.qi@linaro.org>
9313
9314 * ft32-tdep.c (ft32_read_pc): Remove.
9315 (ft32_write_pc): Remove.
9316 (ft32_gdbarch_init): Update.
9317 * m32r-tdep.c (m32r_read_pc): Remove.
9318 (m32r_gdbarch_init): Update.
9319 * mep-tdep.c (mep_read_pc): Remove.
9320 (mep_gdbarch_init): Update.
9321 * microblaze-tdep.c (microblaze_write_pc): Remove.
9322 (microblaze_gdbarch_init): Update.
9323 * mn10300-tdep.c (mn10300_read_pc): Remove.
9324 (mn10300_write_pc): Remove.
9325 (mn10300_gdbarch_init): Update.
9326 * moxie-tdep.c (moxie_read_pc): Remove.
9327 (moxie_write_pc): Remove.
9328 (moxie_gdbarch_init): Update.
9329
bca65a23
YQ
93302018-02-06 Yao Qi <yao.qi@linaro.org>
9331
9332 * expprint.c (print_subexp_standard): Handle
9333 OP_F77_UNDETERMINED_ARGLIST.
9334 (dump_subexp_body_standard): Likewise.
9335
583e3f90 93362018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 9337
583e3f90
YQ
9338 * target-descriptions.c (tdesc_element_visitor) Add empty
9339 implementations.
b8df6ca7
AH
9340 (tdesc_type): Move make_gdb_type from here.
9341 (tdesc_type_builtin): Likewise.
9342 (tdesc_type_vector): Likewise.
9343 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
9344 (make_gdb_type_struct): Move from tdesc_type_with_fields.
9345 (make_gdb_type_union): Likewise.
9346 (make_gdb_type_flags): Likewise.
9347 (make_gdb_type_enum): Likewise.
9348 (make_gdb_type): New function.
9349 (tdesc_register_type): Use static make_gdb_type.
9350
e813d34a
RK
93512018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
9352
9353 * infcmd.c (default_print_one_register_info): Align natural-format
9354 column values consistently one under another.
9355 (pad_to_column): New function.
9356
0eb876f5
JB
93572018-02-05 Joel Brobecker <brobecker@adacore.com>
9358
9359 * dwarf2read.c (dwarf2_physname): Move commment.
9360
0625771b
LS
93612018-02-01 Leszek Swirski <leszeks@google.com>
9362
9363 * varobj.c (varobj_formatted_print_options): Allow recursive
9364 pretty printing if pretty printing is enabled.
9365
59498c30
LS
93662018-02-01 Leszek Swirski <leszeks@google.com>
9367
9368 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
9369 names after a structop as a filename.
9370
2d9e6acb
YQ
93712018-02-01 Yao Qi <yao.qi@linaro.org>
9372
9373 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
9374 (arm_record_coproc_data_proc): Likewise.
9375
df95a9cf
YQ
93762018-02-01 Yao Qi <yao.qi@linaro.org>
9377
9378 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
9379
07e5f5cf
NP
93802018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
9381
9382 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
9383 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
9384
3045b475
PA
93852018-01-31 Pedro Alves <palves@redhat.com>
9386
9387 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
9388 * inflow.c (child_terminal_save_inferior): Wrap reference to
9389 tcgetpgrp in HAVE_TERMIOS_H.
9390 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
9391 _WIN32.
9392 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
9393 always iterate over all inferiors.
9394 (gdbsim_cntrl_c): Adjust.
9395 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
9396
929b5ad4
JB
93972018-01-31 Joel Brobecker <brobecker@adacore.com>
9398
9399 * gdbtypes.c (lookup_array_range_type): Make sure the array's
9400 index type is objfile-owned if the element type is as well.
9401
29236ca2
JB
94022018-01-31 Joel Brobecker <brobecker@adacore.com>
9403
9404 GDB 8.1 released.
9405
c81e8879
PR
94062018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
9407
9408 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
9409 "features/s390x-linux64.c".
9410 (_initialize_s390_linux_tdep): Remove initialization of tdescs
9411 s390_linux32 and s390x_linux64.
9412 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
9413 default tdesc.
9414 * s390-tdep.c: Include "features/s390-linux32.c" and
9415 "features/s390x-linux64.c".
9416 (s390_tdesc_valid): Add check for tdesc_has_registers.
9417 (s390_gdbarch_init): Make sure there is always a valid tdesc.
9418 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
9419 tdesc_s390x_linux64.
9420 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
9421 tdesc_s390x_linux64 to...
9422 * s390-tdep.h: ...here.
9423
e671cd59
PA
94242018-01-30 Pedro Alves <palves@redhat.com>
9425
9426 PR gdb/13211
9427 * config.in, configure: Regenerate.
9428 * configure.ac: Check for getpgid.
9429 * go32-nat.c (go32_pass_ctrlc): New.
9430 (go32_target): Install it.
9431 * inf-child.c (inf_child_target): Install
9432 child_terminal_save_inferior, child_pass_ctrlc and
9433 child_interrupt.
9434 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
9435 (inf_ptrace_target): No longer install it.
9436 * infcmd.c (interrupt_target_1): Adjust.
9437 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
9438 (child_interrupt): Declare.
9439 (inferior::terminal_state): New.
9440 * inflow.c (struct terminal_info): Update comments.
9441 (inferior_process_group): Delete.
9442 (terminal_is_ours): Delete.
9443 (gdb_tty_state): New.
9444 (child_terminal_init): Adjust.
9445 (is_gdb_terminal, sharing_input_terminal_1)
9446 (sharing_input_terminal): New functions.
9447 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
9448 Set the process's actual process group in the foreground if
9449 possible. Handle is_ours_for_output/is_ours distinction. Don't
9450 mark terminal as the inferior's if not sharing GDB's terminal.
9451 Don't check attach_flag.
9452 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
9453 pass down a target_terminal_state.
9454 (child_terminal_save_inferior): New, factored out from ...
9455 (child_terminal_ours_1): ... this. Handle
9456 target_terminal_state::is_ours_for_output.
9457 (child_interrupt, child_pass_ctrlc): New.
9458 (inflow_inferior_exit): Clear the inferior's terminal_state.
9459 (copy_terminal_info): Copy the inferior's terminal state.
9460 (_initialize_inflow): Remove reference to terminal_is_ours.
9461 * inflow.h (inferior_process_group): Delete.
9462 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
9463 * procfs.c (procfs_target): Don't install procfs_interrupt.
9464 (procfs_interrupt): Delete.
9465 * remote.c (remote_serial_quit_handler): Adjust.
9466 (remote_interrupt): Remove ptid parameter. Adjust.
9467 * target-delegates.c: Regenerate.
9468 * target.c: Include "terminal.h".
9469 (target_terminal::terminal_state): Rename to ...
9470 (target_terminal::m_terminal_state): ... this.
9471 (target_terminal::init): Adjust.
9472 (target_terminal::inferior): Adjust to per-inferior
9473 terminal_state.
9474 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
9475 (target_terminal::ours, target_terminal::ours_for_output): Use
9476 target_terminal_is_ours_kind.
9477 (target_interrupt): Remove ptid parameter. Adjust.
9478 (default_target_pass_ctrlc): Adjust.
9479 * target.h (target_ops::to_terminal_save_inferior): New field.
9480 (target_ops::to_interrupt): Remove ptid_t parameter.
9481 (target_interrupt): Remove ptid_t parameter. Update comment.
9482 (target_pass_ctrlc): Update comment.
9483 * target/target.h (target_terminal_state): New scoped enum,
9484 factored out of ...
9485 (target_terminal::terminal_state): ... here.
9486 (target_terminal::inferior): Update comments.
9487 (target_terminal::restore_inferior): New.
9488 (target_terminal::is_inferior, target_terminal::is_ours)
9489 (target_terminal::is_ours_for_output): Adjust.
9490 (target_terminal::scoped_restore_terminal_state): Adjust to
9491 rename, and call restore_inferior() instead of inferior().
9492 (target_terminal::scoped_restore_terminal_state::m_state): Change
9493 type.
9494 (target_terminal::terminal_state): Rename to ...
9495 (target_terminal::m_terminal_state): ... this and change type.
9496
9c3a5d93
PA
94972018-01-30 Pedro Alves <palves@redhat.com>
9498
9499 * linux-nat.c (wait_for_signal): New function.
9500 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
9501 directly.
9502 (async_terminal_is_ours)
9503 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
9504 (linux_nat_add_target): Don't override
9505 to_terminal_inferior/to_terminal_ours.
9506
69ab5edb
SDJ
95072018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
9508
9509 * remote.c (remote_follow_fork): Don't call "detach_inferior".
9510
fc8e7e75
SM
95112018-01-28 Simon Marchi <simon.marchi@ericsson.com>
9512
9513 * dwarf2read.c (free_dwo_files): Add forward-declaration.
9514 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
9515 dwarf2_per_objfile_free here.
9516 (dwarf2_per_objfile_free): Remove.
9517 (_initialize_dwarf2_read): Don't register
9518 dwarf2_per_objfile_free as a registry cleanup.
9519
b2a426e2
EZ
95202018-01-27 Eli Zaretskii <eliz@gnu.org>
9521
9522 Avoid compilation errors in MinGW native builds
9523
9524 The error is triggered by including python-internal.h, and the
9525 error message is:
9526
9527 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
9528 from build-gnulib/import/math.h:27,
9529 from d:/usr/Python26/include/pyport.h:235,
9530 from d:/usr/Python26/include/Python.h:58,
9531 from python/python-internal.h:94,
9532 from python/py-arch.c:24:
9533 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
9534 using ::hypot;
9535 ^~~~~
9536
9537 This happens because Python headers define 'hypot' to expand t
9538 '_hypot' in the Windows builds.
9539 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
9540 'hypoth'. This avoids a compilation error.
9541
0bdd8eac
AH
95422018-01-26 Alan Hayward <alan.hayward@arm.com>
9543
9544 * MAINTAINERS (Write After Approval): Fix ordering.
9545
56ae9dc3
AH
95462018-01-26 Alan Hayward <alan.hayward@arm.com>
9547
9548 * MAINTAINERS (Write After Approval): Add Alan Hayward.
9549
7433498b
AM
95502018-01-26 Alan Modra <amodra@gmail.com>
9551
9552 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
9553 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
9554 Remove nop. Make const. Comment.
9555 (powerpc32_plt_stub_so_2): New.
9556 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
9557 Correct count. Update uses.
9558 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
9559 Move common code reading PLT entry word. Correct
9560 powerpc32_plt_stub PLT address calculation.
9561 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
9562 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
9563 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
9564 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
9565 (ppc64_standard_linkage8): Likewise.
9566 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
9567 Correct insns description.
9568 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
9569
0f59d5fc
PA
95702018-01-24 Pedro Alves <palves@redhat.com>
9571
9572 GCC PR libstdc++/83906
9573 * gdbtypes.c (operator==(const dynamic_prop &,
9574 const dynamic_prop &)): New.
9575 (operator==(const range_bounds &, const range_bounds &)): New.
9576 (check_types_equal): Use them instead of memcmp.
9577 * gdbtypes.h (operator==(const dynamic_prop &,
9578 const dynamic_prop &)): Declare.
9579 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
9580 (operator==(const range_bounds &, const range_bounds &)): Declare.
9581 (operator!=(const range_bounds &, const range_bounds &)): Declare.
9582
ef8914a4
PR
95832018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9584
9585 * s390-linux-tdep.c (s390_record_address_mask)
9586 (s390_record_calc_disp_common, s390_record_calc_disp)
9587 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
9588 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
9589 (s390_process_record): Move to s390-tdep.c.
9590 (s390_linux_init_abi_any): Adjust.
9591 * s390-tdep.c (s390_record_address_mask)
9592 (s390_record_calc_disp_common, s390_record_calc_disp)
9593 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
9594 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
9595 (s390_process_record): Moved from s390-linux-tdep.c
9596 (s390_gdbarch_init): Adjust.
9597
d6e58945
PR
95982018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9599
9600 * s390-linux-nat.c (s390-tdep.h): New include.
9601 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
9602 (HFILES_NO_SRCDIR): Add s390-tdep.h.
9603 (ALLDEPFILES): Add s390-tdep.c.
9604 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
9605 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
9606 * s390-tdep.h: ...this. New file.
9607 * s390-linux-tdep.c (s390-tdep.h): New include.
9608 (_initialize_s390_tdep): Rename to...
9609 (_initialize_s390_linux_tdep): ...this and adjust.
9610 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
9611 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
9612 s390-tdep.h.
9613 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
9614 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
9615 (s390_is_partial_instruction, s390_software_single_step)
9616 (is_non_branch_ril, s390_displaced_step_copy_insn)
9617 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
9618 (s390_prologue_data, s390_addr, s390_store, s390_load)
9619 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
9620 (s390_register_call_saved, s390_guess_tracepoint_registers)
9621 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
9622 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
9623 (s390_pseudo_register_name, s390_pseudo_register_type)
9624 (s390_pseudo_register_read, s390_pseudo_register_write)
9625 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
9626 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
9627 (s390_addr_bits_remove, s390_address_class_type_flags)
9628 (s390_address_class_type_flags_to_name)
9629 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
9630 (s390_function_arg_float, s390_function_arg_vector)
9631 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
9632 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
9633 (s390_frame_align, s390_register_return_value, s390_return_value)
9634 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
9635 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
9636 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
9637 (s390_trad_frame_prev_register, s390_unwind_cache)
9638 (s390_prologue_frame_unwind_cache)
9639 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
9640 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
9641 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
9642 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
9643 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
9644 (s390_frame_base_address, s390_local_base_address)
9645 (s390_frame_base, s390_gcc_target_options)
9646 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
9647 (s390_validate_reg_range, s390_tdesc_valid)
9648 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
9649 * s390-tdep.c: ...this. New file.
9650
9c0b896e
PR
96512018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9652
9653 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
9654 (s390_process_record, s390_gdbarch_tdep_alloc)
9655 (s390_linux_init_abi_any): Use/set new hook.
9656
7042632b
PR
96572018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9658
9659 * s390-linux-tdep.c (osabi.h): New include.
9660 (s390_linux_init_abi_31, s390_linux_init_abi_64)
9661 (s390_linux_init_abi_any): New functions.
9662 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
9663
650f5e13
PR
96642018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9665
9666 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
9667 tdesc_has_registers check
9668
47c9317e
PR
96692018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9670
9671 * s390-linux-tdep.c (s390_tdesc_valid): New function.
9672 (s390_validate_reg_range): New macro.
9673 (s390_gdbarch_init): Adjust.
9674
095085d8
PR
96752018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9676
9677 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
9678 (s390_gdbarch_tdep_alloc): Adjust.
9679 (s390_gdbarch_init): Adjust.
9680
ab9bcc67
PR
96812018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9682
9683 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
9684 <have_tdb>: Change type to bool.
9685 (s390_gdbarch_tdep_alloc): Adjust.
9686 (s390_gdbarch_init): Adjust.
9687
21f6f5ff
PR
96882018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9689
9690 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
9691 (gdbarch_tdep) <have_upper, have_vx>: New fields.
9692 (s390_gdbarch_tdep_alloc): New function.
9693 (s390_gdbarch_init): Allocate tdep at start and use its fields
9694 instead of separate variables.
9695
0eb97953
PR
96962018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9697
9698 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
9699 when looking for cached gdbarch and add comment for remaining.
9700
5c319bb2
PA
97012018-01-22 Pedro Alves <palves@redhat.com>
9702 Sergio Durigan Junior <sergiodj@redhat.com>
9703
9704 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
9705 case.
9706
d65ce302
MR
97072018-01-22 Maciej W. Rozycki <macro@mips.com>
9708
9709 * MAINTAINERS: Update my company e-mail address.
9710
ec7a5fcb
YQ
97112018-01-22 Yao Qi <yao.qi@linaro.org>
9712
9713 * regcache.c (cooked_write_test): New function.
9714 (_initialize_regcache): Register the test.
9715
11f57cb6
YQ
97162018-01-22 Yao Qi <yao.qi@linaro.org>
9717
9718 * ia64-tdep.c (ia64_pseudo_register_read): Call
9719 regcache->cooked_read instead of regcache_cooked_read_unsigned.
9720 * m32c-tdep.c (m32c_cat_read): Likewise.
9721 (m32c_r3r2r1r0_read): Likewise.
9722 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9723 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9724
03f50fc8
YQ
97252018-01-22 Yao Qi <yao.qi@linaro.org>
9726
9727 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
9728 method raw_read instead of regcache_raw_read.
9729 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9730 * arm-tdep.c (arm_neon_quad_read): Likewise.
9731 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9732 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9733 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9734 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
9735 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9736 (i386_pseudo_register_read_into_value): Likewise.
9737 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9738 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9739 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9740 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
9741 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
9742 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9743 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9744 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9745 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
9746
dc711524
YQ
97472018-01-22 Yao Qi <yao.qi@linaro.org>
9748
9749 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
9750 * configure.tgt: Remove target mt.
9751 * mt-tdep.c: Remove.
9752 * regcache.c (cooked_read_test): Remove the check for mt.
9753
3f5a868b
YQ
97542018-01-22 Yao Qi <yao.qi@linaro.org>
9755
9756 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
9757 instead of gdbarch_pseudo_register_read_value.
9758
de4cb04a
JB
97592018-01-22 Joel Brobecker <brobecker@adacore.com>
9760
9761 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
9762 language is Ada.
9763
a9e40818
JB
97642018-01-22 Joel Brobecker <brobecker@adacore.com>
9765
9766 * linespec.c (create_sals_line_offset): Remove code that preserved
9767 the symtab_and_line's line number.
9768
e707fc44
AB
97692018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9770
9771 * varobj.c (varobj_create): Don't set valid_block when creating a
9772 floating varobj.
9773
03d0bf7b
AB
97742018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9775
9776 * varobj.c (varobj_create): Remove out of date comment.
9777
ae451627
AB
97782018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9779
9780 PR mi/20395
9781 * ada-exp.y (write_var_from_sym): Pass extra parameter when
9782 updating innermost block.
9783 * parse.c (innermost_block_tracker::update): Take extra type
9784 parameter, and check types match before updating innermost block.
9785 (write_dollar_variable): Update innermost block for registers.
9786 * parser-defs.h (enum innermost_block_tracker_type): New enum.
9787 (innermost_block_tracker::innermost_block_tracker): Initialise
9788 m_types member.
9789 (innermost_block_tracker::reset): Take type parameter.
9790 (innermost_block_tracker::update): Take type parameter, and pass
9791 type through as needed.
9792 (innermost_block_tracker::m_types): New member.
9793 * varobj.c (varobj_create): Pass type when reseting innermost
9794 block.
9795
aee1fcdf
AB
97962018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9797
9798 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
9799 * ada-lang.c (resolve_subexp): Likewise.
9800 * breakpoint.c (set_breakpoint_condition) Likewise.
9801 (watch_command_1) Likewise.
9802 * c-exp.y (variable): Likewise.
9803 * d-exp.y (PrimaryExpression): Likewise.
9804 * f-exp.y (variable): Likewise.
9805 * go-exp.y (variable): Likewise.
9806 * m2-exp.y (variable): Likewise.
9807 * objfiles.c (objfile::~objfile): Likewise.
9808 * p-exp.y (variable): Likewise.
9809 * parse.c (innermost_block): Change type.
9810 * parser-defs.h (class innermost_block_tracker): New.
9811 (innermost_block): Change to innermost_block_tracker.
9812 * printcmd.c (display_command): Switch to innermost_block API.
9813 (do_one_display): Likewise.
9814 * rust-exp.y (do_one_display): Likewise.
9815 * symfile.c (clear_symtab_users): Likewise.
9816 * varobj.c (varobj_create): Switch to innermost_block API, replace
9817 use of innermost_block with block stored on varobj object.
9818
396af9a1
AB
98192018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9820
9821 * expression.h (innermost_block): Remove declaration.
9822 * varobj.c: Add 'parser-defs.h' include.
9823
fcfcc376
TT
98242018-01-19 Tom Tromey <tom@tromey.com>
9825
9826 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
9827 symbols in the static and global blocks.
9828
5a6c3296
JC
98292018-01-19 James Clarke <jrtc27@jrtc27.com>
9830
9831 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
9832 gdb_ptrace.h, and move including gdb_wait.h ...
9833 * nat/linux-ptrace.h: ... to here.
9834
bc09b0c1
SM
98352018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9836
9837 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
9838 inf_ptrace_detach_success.
9839 (inf_ptrace_detach_success): Add inferior parameter, use it
9840 instead of inferior_ptid, pass it to detach_inferior.
9841 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
9842 parameter.
9843 * inferior.c (detach_inferior): Add overload that takes an
9844 inferior object.
9845 * inferior.h (detach_inferior): Likewise.
9846 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
9847 use inferior_ptid, adjust call to inf_ptrace_detach_success.
9848 * linux-thread-db.c (thread_db_detach): Use inf parameter.
9849
6e1e1966
SM
98502018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9851
9852 * target.h (struct target_ops) <to_detach>: Add inferior
9853 parameter.
9854 (target_detach): Likewise.
9855 * target.c (dispose_inferior): Pass inferior down.
9856 (target_detach): Pass inferior down. Assert that it is equal to
9857 the current inferior.
9858 * aix-thread.c (aix_thread_detach): Pass inferior down.
9859 * corefile.c (core_file_command): Pass current_inferior() down.
9860 * corelow.c (core_detach): Add inferior parameter.
9861 * darwin-nat.c (darwin_detach): Likewise.
9862 * gnu-nat.c (gnu_detach): Likewise.
9863 * inf-ptrace.c (inf_ptrace_detach): Likewise.
9864 * infcmd.c (detach_command): Pass current_inferior() down to
9865 target_detach.
9866 * infrun.c (follow_fork_inferior): Pass parent_inf to
9867 target_detach.
9868 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
9869 target_detach.
9870 * linux-nat.c (linux_nat_detach): Add inferior parameter.
9871 * linux-thread-db.c (thread_db_detach): Likewise.
9872 * nto-procfs.c (procfs_detach): Likewise.
9873 * procfs.c (procfs_detach): Likewise.
9874 * record.c (record_detach): Likewise.
9875 * record.h (struct inferior): Forward-declare.
9876 (record_detach): Add inferior parameter.
9877 * remote-sim.c (gdbsim_detach): Likewise.
9878 * remote.c (remote_detach_1): Likewise.
9879 (remote_detach): Likewise.
9880 (extended_remote_detach): Likewise.
9881 * sol-thread.c (sol_thread_detach): Likewise.
9882 * target-debug.h (target_debug_print_inferior_p): New macro.
9883 * target-delegates.c: Re-generate.
9884 * top.c (kill_or_detach): Pass inferior down to target_detach.
9885 * windows-nat.c (windows_detach): Add inferior parameter.
9886
6bd6f3b6
SM
98872018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9888
9889 * target.h (struct target_ops) <to_detach>: Remove args
9890 parameter.
9891 (target_detach): Likewise.
9892 * target.c (dispose_inferior): Adjust.
9893 (target_detach): Remove args parameter, adjust.
9894 * aix-thread.c (aix_thread_detach): Adjust.
9895 * corefile.c (core_file_command): Adjust.
9896 * corelow.c (core_detach): Adjust.
9897 * darwin-nat.c (darwin_detach): Adjust.
9898 * gnu-nat.c (gnu_detach): Adjust.
9899 * inf-ptrace.c (inf_ptrace_detach): Adjust.
9900 * infcmd.c (detach_command): Adjust
9901 * infrun.c (follow_fork_inferior): Adjust.
9902 (handle_vfork_child_exec_or_exit): Adjust.
9903 * linux-fork.c (linux_fork_detach): Remove args parameter.
9904 * linux-fork.h (linux_fork_detach): Likewise.
9905 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
9906 * linux-thread-db.c (thread_db_detach): Likewise.
9907 * nto-procfs.c (procfs_detach): Likewise.
9908 * procfs.c (procfs_detach): Likewise.
9909 (do_detach): Remove signo parameter.
9910 * record.c (record_detach): Remove args parameter.
9911 * record.h (record_detach): Likewise.
9912 * remote-sim.c (gdbsim_detach): Likewise.
9913 * remote.c (remote_detach_1): Likewise.
9914 (remote_detach): Likewise.
9915 (extended_remote_detach): Likewise.
9916 * sol-thread.c (sol_thread_detach): Likewise.
9917 * target-delegates.c: Re-generate.
9918 * top.c (struct qt_args) <args>: Remove field.
9919 (kill_or_detach): Don't pass args.
9920 (quit_force): Don't set args.
9921 * windows-nat.c (windows_detach): Remove args parameter.
9922
88af8ea8
YQ
99232018-01-19 Yao Qi <yao.qi@linaro.org>
9924
9925 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
9926 (arm_linux_init_abi): Install it.
9927
dea445b9
YQ
99282018-01-19 Yao Qi <yao.qi@linaro.org>
9929
9930 * osabi.c (gdb_osabi_names): Extend the regexp for
9931 arm-linux-gnueabihf.
9932
4a17f768
YQ
99332018-01-18 Yao Qi <yao.qi@linaro.org>
9934
9935 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
9936 m_abbrevs.
9937 (abbrev_table::add_abbrev): Update.
9938 (abbrev_table::lookup_abbrev): Update.
9939
d679c21a
YQ
99402018-01-18 Yao Qi <yao.qi@linaro.org>
9941
9942 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
9943
7d937cad
SDJ
99442018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
9945
9946 * compile/compile.c (compile_to_object): Convert "triplet_rx"
9947 to "std::string".
9948
9e14690d
TT
99492018-01-17 Tom Tromey <tom@tromey.com>
9950
9951 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
9952
50a82047
TT
99532018-01-17 Tom Tromey <tom@tromey.com>
9954
9955 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
9956 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
9957 (create_array_type_with_stride): Update.
9958 * dwarf2read.c (set_die_type): Update.
9959
c89b44cd
TT
99602018-01-17 Tom Tromey <tom@tromey.com>
9961
9962 * dwarf2read.c (delayed_method_info): Remove typedef.
9963 (dwarf2_cu::method_info): Now a std::vector.
9964 (add_to_method_list): Update.
9965 (free_delayed_list): Remove.
9966 (compute_delayed_physnames): Update.
9967 (process_full_comp_unit, process_full_type_unit): Clear the method
9968 list. Remove cleanups.
9969 (psymtab_include_file_name): Add name_holder parameter. Use
9970 unique_xmalloc_ptr.
9971 (dwarf_decode_lines): Update.
9972
fcd3b13d
SM
99732018-01-17 Tom Tromey <tom@tromey.com>
9974 Simon Marchi <simon.marchi@ericsson.com>
9975
9976 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
9977 (dwarf2_per_objfile::free_cached_comp_units)
9978 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9979 (init_cutu_and_read_dies_no_follow): Update.
9980 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
9981 (dwarf2_cu::~dwarf2_cu): New.
9982 (free_heap_comp_unit, free_stack_comp_unit): Remove.
9983 (age_cached_comp_units, free_one_cached_comp_unit): Update.
9984
685af9cd
TT
99852018-01-17 Tom Tromey <tom@tromey.com>
9986 Simon Marchi <simon.marchi@ericsson.com>
9987
9988 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
9989 (struct die_reader_specs) <abbrev_table>: New member.
9990 (struct abbrev_table): Add constructor.
9991 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
9992 <abbrev_obstack>: Now an auto_obstack.
9993 (abbrev_table_up): New typedef.
9994 (init_cu_die_reader): Add abbrev_table parameter.
9995 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
9996 Add result_dwo_abbrev_table.
9997 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9998 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
9999 Update.
10000 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
10001 parameter.
10002 (skip_children): Update.
10003 (abbrev_table::alloc_abbrev): Rename from
10004 abbrev_table_alloc_abbrev.
10005 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
10006 (abbrev_table::lookup_abbrev): Rename from
10007 abbrev_table_lookup_abbrev.
10008 (abbrev_table_read_table): Return abbrev_table_up.
10009 (abbrev_table_free, abbrev_table_free_cleanup)
10010 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
10011 (load_partial_dies): Update.
10012
5e2db402
TT
100132018-01-17 Tom Tromey <tom@tromey.com>
10014
10015 * dwarf2read.c (dwarf2_compute_name): Update comment.
10016 (read_func_scope, read_variable): Update.
10017 (new_symbol): Remove.
10018 (new_symbol_full): Rename to new_symbol.
10019
ee7f689e 100202018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
10021
10022 PR gdb/16577
10023 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
10024 a warning instead of throwing an error, set section size to 0 and return
10025 NULL.
10026 * gdb_bfd.h (gdb_bfd_map_section): Update description.
10027
4d9b86e1
SM
100282018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10029
10030 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
10031 std::string.
10032 (linux_ptrace_attach_fail_reason_string): Likewise.
10033 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
10034 Likewise.
10035 (linux_ptrace_attach_fail_reason_string): Likewise.
10036 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
10037
a7b2d0fb
SM
100382018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10039
10040 * linux-nat.c (linux_nat_attach): Remove xstrdup.
10041
f517c180
EA
100422018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
10043
10044 PR gdb/21559
10045 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
10046 checking for fs_base/gs_base fields in struct user_regs_struct.
10047 * configure: Regenerate.
10048
7045b1ca
YQ
100492018-01-17 Yao Qi <yao.qi@linaro.org>
10050
10051 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
10052 function.
10053 (aarch64_linux_init_abi): Install it to gdbarch hook
10054 gcc_target_options.
10055
db422fb2
PA
100562018-01-15 Pedro Alves <palves@redhat.com>
10057
10058 * common/signals-state-save-restore.c
10059 (save_original_signals_state): Fix typos.
10060
ba643918
SDJ
100612017-01-12 Tom Tromey <tom@tromey.com>
10062 Sergio Durigan Junior <sergiodj@redhat.com>
10063
10064 * Makefile.in (install-only): Install gdb-add-index.
10065
906b4aac
JB
100662018-01-12 John Baldwin <jhb@FreeBSD.org>
10067
10068 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
10069
bdf2a94a
AA
100702018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10071
10072 * infrun.c (keep_going_pass_signal): Clear step-over info when
10073 insert_breakpoints fails.
10074
71d378ae
PA
100752018-01-11 Pedro Alves <palves@redhat.com>
10076
10077 PR gdb/22583
10078 * infrun.c (resume): Rename to ...
10079 (resume_1): ... this.
10080 (resume): Reimplement as wrapper around resume_1.
10081
3cada740
PA
100822018-01-11 Pedro Alves <palves@redhat.com>
10083
10084 PR remote/22597
10085 * remote.c (remote_parse_stop_reply): Default to the last-set
10086 general thread instead of to 'magic_null_ptid'.
10087
618daa93
PA
100882018-01-10 Pedro Alves <palves@redhat.com>
10089
10090 * language.h (language_get_symbol_name_matcher): Rename ...
10091 (get_symbol_name_matcher): ... this.
10092 * language.c (language_get_symbol_name_matcher): Ditto.
10093 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
10094 callers adjusted.
10095
c63d3e8d
PA
100962018-01-10 Pedro Alves <palves@redhat.com>
10097
10098 PR gdb/22670
10099 * dwarf2read.c
10100 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
10101 Adjust to use language_get_symbol_name_matcher instead of
10102 language_defn::la_get_symbol_name_matcher.
10103 * language.c (language_get_symbol_name_matcher): If in Ada mode
10104 and the lookup name is a verbatim match, return Ada's matcher.
10105 * language.h (language_get_symbol_name_matcher): Adjust comment.
10106 (ada_lookup_name_info::verbatim_p):: New method.
10107
d4c2a405
PA
101082018-01-10 Pedro Alves <palves@redhat.com>
10109
10110 PR gdb/22670
10111 * ada-lang.c (ada_collect_symbol_completion_matches): If the
10112 minsym's language is language_auto or language_cplus, pass down
10113 language_ada instead.
10114 * symtab.c (compare_symbol_name): Don't frob symbol language here.
10115
8825213e
PA
101162018-01-10 Pedro Alves <palves@redhat.com>
10117
10118 PR gdb/22670
10119 * minsyms.c (linkage_name_str): New function.
10120 (iterate_over_minimal_symbols): Use it.
10121
2d97a5d9
JB
101222018-01-09 John Baldwin <jhb@FreeBSD.org>
10123
10124 * NEWS: Document that 'info proc' now works on FreeBSD.
10125
92fce24d
JB
101262018-01-09 John Baldwin <jhb@FreeBSD.org>
10127
10128 * configure.ac: Check for kinfo_getfile in libutil.
10129 * configure: Regenerate.
10130 * config.in: Regenerate.
10131 * fbsd-nat.c: Include "fbsd-tdep.h".
10132 (fbsd_fetch_cmdline): New.
10133 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
10134 rather than calling error.
10135 (fbsd_info_proc): New.
10136 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
10137 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
10138 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
10139
262f62f5
JB
101402018-01-09 John Baldwin <jhb@FreeBSD.org>
10141
10142 * fbsd-nat.c (struct free_deleter): Remove.
10143 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
10144
b999e203
JB
101452018-01-09 John Baldwin <jhb@FreeBSD.org>
10146
10147 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
10148 NULL for an empty pathname.
10149
d2176225
JB
101502018-01-09 John Baldwin <jhb@FreeBSD.org>
10151
10152 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
10153 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
10154 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
10155 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
10156 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
10157 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
10158 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
10159 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
10160 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
10161 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
10162 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
10163 (fbsd_core_fetch_timeval, fbsd_print_sigset)
10164 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
10165 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
10166 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
10167
9c4ac400
ST
101682018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
10169
10170 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
10171 (gnu_xfer_auxv): New function.
10172 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
10173 TARGET_OBJECT_AUXV.
10174
1e5ded6c
YQ
101752018-01-08 Yao Qi <yao.qi@linaro.org>
10176 Simon Marchi <simon.marchi@ericsson.com>
10177
10178 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
10179 common/selftest.c.
10180 (COMMON_OBS): Remove selftest.o.
10181 * configure.ac: Append selftest-arch.c and common/selftest.c to
10182 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
10183 * configure: Re-generated.
10184 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
10185 GDB_SELF_TEST.
10186 (maintenance_info_selftests): Likewise.
10187
04bafb1e
XR
101882018-01-08 Xavier Roirand <roirand@adacore.com>
10189
10190 * ada-valprint.c (val_print_packed_array_elements): Use
10191 proper number of elements when printing an array indexed
10192 by an enumeration type.
10193
518817b3
SM
101942018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10195
10196 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
10197 (dw2_get_file_names_reader): Adjust.
10198 (lookup_dwo_signatured_type): Adjust.
10199 (lookup_dwp_signatured_type): Adjust.
10200 (lookup_signatured_type): Adjust.
10201 (create_type_unit_group): Adjust.
10202 (get_type_unit_group): Adjust.
10203 (process_psymtab_comp_unit_reader): Adjust.
10204 (build_type_psymtabs_reader): Adjust.
10205 (scan_partial_symbols): Adjust.
10206 (add_partial_symbol): Adjust.
10207 (add_partial_subprogram): Adjust.
10208 (peek_die_abbrev): Adjust.
10209 (fixup_go_packaging): Adjust.
10210 (process_imported_unit_die): Adjust.
10211 (dwarf2_compute_name): Adjust.
10212 (dwarf2_physname): Adjust.
10213 (read_import_statement): Adjust.
10214 (handle_DW_AT_stmt_list): Adjust.
10215 (read_file_scope): Adjust.
10216 (read_func_scope): Adjust.
10217 (read_lexical_block_scope): Adjust.
10218 (read_call_site_scope): Adjust.
10219 (read_variable): Adjust.
10220 (dwarf2_rnglists_process): Adjust.
10221 (dwarf2_ranges_process): Adjust.
10222 (dwarf2_ranges_read): Adjust.
10223 (dwarf2_get_pc_bounds): Adjust.
10224 (dwarf2_record_block_ranges): Adjust.
10225 (dwarf2_add_field): Adjust.
10226 (dwarf2_add_member_fn): Adjust.
10227 (read_structure_type): Adjust.
10228 (process_structure_scope): Adjust.
10229 (read_enumeration_type): Adjust.
10230 (read_array_type): Adjust.
10231 (mark_common_block_symbol_computed): Adjust.
10232 (read_common_block): Adjust.
10233 (read_namespace_type): Adjust.
10234 (read_namespace): Adjust.
10235 (read_module_type): Adjust.
10236 (read_tag_pointer_type): Adjust.
10237 (read_tag_ptr_to_member_type): Adjust.
10238 (read_tag_string_type): Adjust.
10239 (read_subroutine_type): Adjust.
10240 (read_typedef): Adjust.
10241 (read_base_type): Adjust.
10242 (attr_to_dynamic_prop): Adjust.
10243 (read_subrange_type): Adjust.
10244 (read_unspecified_type): Adjust.
10245 (dwarf2_read_abbrevs): Adjust.
10246 (load_partial_dies): Adjust.
10247 (read_partial_die): Adjust.
10248 (find_partial_die): Adjust.
10249 (guess_partial_die_structure_name): Adjust.
10250 (fixup_partial_die): Adjust.
10251 (read_attribute_value): Adjust.
10252 (read_addr_index): Adjust.
10253 (read_addr_index_from_leb128): Adjust.
10254 (read_str_index): Adjust.
10255 (dwarf2_string_attr): Adjust.
10256 (get_debug_line_section): Adjust.
10257 (dwarf_decode_line_header): Adjust.
10258 (lnp_state_machine::check_line_address): Adjust.
10259 (dwarf_decode_lines_1): Adjust.
10260 (dwarf_decode_lines): Adjust.
10261 (dwarf2_start_symtab): Adjust.
10262 (var_decode_location): Adjust.
10263 (new_symbol_full): Adjust.
10264 (dwarf2_const_value_data): Adjust.
10265 (dwarf2_const_value_attr): Adjust.
10266 (dwarf2_const_value): Adjust.
10267 (die_type): Adjust.
10268 (die_containing_type): Adjust.
10269 (build_error_marker_type): Adjust.
10270 (lookup_die_type): Adjust.
10271 (guess_full_die_structure_name): Adjust.
10272 (anonymous_struct_prefix): Adjust.
10273 (determine_prefix): Adjust.
10274 (dwarf2_name): Adjust.
10275 (follow_die_ref_or_sig): Adjust.
10276 (follow_die_offset): Adjust.
10277 (follow_die_ref): Adjust.
10278 (follow_die_sig_1): Adjust.
10279 (follow_die_sig): Adjust.
10280 (get_signatured_type): Adjust.
10281 (get_DW_AT_signature_type): Adjust.
10282 (decode_locdesc): Adjust.
10283 (dwarf_decode_macros): Adjust.
10284 (cu_debug_loc_section): Adjust.
10285 (fill_in_loclist_baton): Adjust.
10286 (dwarf2_symbol_mark_computed): Adjust.
10287 (init_one_comp_unit): Don't assign
10288 dwarf2_cu::dwarf2_per_objfile.
10289 (set_die_type): Adjust.
10290
ed2dc618
SM
102912018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10292
10293 * dwarf2read.c (struct mapped_debug_names): Add constructor.
10294 <dwarf2_per_objfile>: New field.
10295 (dwarf2_per_objfile): Remove global.
10296 (get_dwarf2_per_objfile): New function.
10297 (set_dwarf2_per_objfile): New function.
10298 (dwarf2_build_psymtabs_hard): Change objfile parameter to
10299 dwarf2_per_objfile.
10300 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10301 (read_abbrev_offset): Likewise.
10302 (read_indirect_string): Likewise.
10303 (read_indirect_line_string): Likewise.
10304 (read_indirect_string_at_offset): Likewise.
10305 (read_indirect_string_from_dwz): Likewise.
10306 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10307 dwarf2_per_objfile.
10308 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10309 (create_all_comp_units): Change objfile parameter to
10310 dwarf2_per_objfile.
10311 (create_all_type_units): Likewise.
10312 (process_queue): Add dwarf2_per_objfile parameter.
10313 (read_and_check_comp_unit_head): Likewise.
10314 (lookup_dwo_unit_in_dwp): Likewise.
10315 (get_dwp_file): Likewise.
10316 (process_cu_includes): Likewise.
10317 (struct free_dwo_file_cleanup_data): New struct.
10318 (dwarf2_has_info): Use get_dwarf2_per_objfile and
10319 set_dwarf2_per_objfile.
10320 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
10321 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
10322 context, adjust calls.
10323 (dw2_instantiate_symtab): Likewise.
10324 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
10325 (dw2_get_cu): Likewise.
10326 (create_cu_from_index_list): Change objfile parameter to
10327 dwarf2_per_objfile.
10328 (create_cus_from_index_list): Get dwarf2_per_objfile from
10329 context, adjust calls.
10330 (create_cus_from_index): Likewise.
10331 (create_signatured_type_table_from_index): Change objfile
10332 parameter to dwarf2_per_objfile.
10333 (create_signatured_type_table_from_debug_names): Change objfile
10334 parameter to dwarf2_per_objfile.
10335 (create_addrmap_from_index): Likewise.
10336 (create_addrmap_from_aranges): Likewise.
10337 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
10338 (dw2_setup): Remove.
10339 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
10340 context.
10341 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
10342 get_dwarf2_per_objfile.
10343 (dw2_forget_cached_source_info): Likewise.
10344 (dw2_map_symtabs_matching_filename): Likewise.
10345 (struct dw2_symtab_iterator) <index>: Remove.
10346 <dwarf2_per_objfile>: New field.
10347 (dw2_symtab_iter_init): Replace index parameter with
10348 dwarf2_per_objfile.
10349 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
10350 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
10351 (dw2_print_stats): Likewise.
10352 (dw2_dump): Likewise.
10353 (dw2_expand_symtabs_for_function): Likewise.
10354 (dw2_expand_all_symtabs): Likewise.
10355 (dw2_expand_symtabs_with_fullname): Likewise.
10356 (dw2_expand_marked_cus): Replace index and objfile parameters
10357 with dwarf2_per_objfile.
10358 (dw_expand_symtabs_matching_file_matcher): Add
10359 dwarf2_per_objfile parameter and adjust calls.
10360 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
10361 adjust calls.
10362 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
10363 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
10364 adjust calls.
10365 (create_cus_from_debug_names_list): Replace objfile parameter
10366 with dwarf2_per_objfile and adjust calls.
10367 (create_cus_from_debug_names): Likewise.
10368 (dwarf2_read_debug_names): Likewise.
10369 (mapped_debug_names::namei_to_name): Adjust call.
10370 (dw2_debug_names_iterator::next): Likewise.
10371 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
10372 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
10373 (dw2_debug_names_dump): Likewise.
10374 (dw2_debug_names_expand_symtabs_for_function): Likewise.
10375 (dw2_debug_names_expand_symtabs_matching): Likewise.
10376 (dwarf2_initialize_objfile): Likewise.
10377 (dwarf2_build_psymtabs): Likewise.
10378 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
10379 this_cu.
10380 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
10381 (read_and_check_comp_unit_head): Likewise.
10382 (read_abbrev_offset): Likewise.
10383 (create_debug_type_hash_table): Likewise.
10384 (create_debug_types_hash_table): Likewise.
10385 (create_all_type_units): Replace objfile parameter with
10386 dwarf2_per_objfile.
10387 (add_type_unit): Add dwarf2_per_objfile parameter.
10388 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
10389 with dwarf2_per_objfile.
10390 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
10391 (lookup_dwp_signatured_type): Likewise.
10392 (lookup_signatured_type): Likewise.
10393 (read_cutu_die_from_dwo): Likewise.
10394 (init_tu_and_read_dwo_dies): Likewise.
10395 (init_cutu_and_read_dies): Likewise.
10396 (init_cutu_and_read_dies_no_follow): Likewise.
10397 (allocate_type_unit_groups_table): Add objfile parameter.
10398 (create_type_unit_group): Use dwarf2_per_objfile from cu.
10399 (get_type_unit_group): Likewise.
10400 (process_psymtab_comp_unit): Update call.
10401 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
10402 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
10403 (print_tu_stats): Likewise.
10404 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
10405 in void* parameter.
10406 (build_type_psymtabs): Change objfile parameter to
10407 dwarf2_per_objfile.
10408 (process_skeletonless_type_unit): Use dwarf2_per_objfile
10409 passed in void* parameter.
10410 (process_skeletonless_type_units): Change objfile parameter to
10411 dwarf2_per_objfile.
10412 (set_partial_user): Likewise.
10413 (dwarf2_build_psymtabs_hard): Likewise.
10414 (read_comp_units_from_section): Likewise.
10415 (create_all_comp_units): Likewise.
10416 (scan_partial_symbols): Update calls.
10417 (add_partial_symbol): Likewise.
10418 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
10419 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
10420 (process_queue): Add dwarf2_per_objfile parameter.
10421 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
10422 (compute_compunit_symtab_includes): Likewise.
10423 (process_cu_includes): Add dwarf2_per_objfile parameter.
10424 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
10425 (process_full_type_unit): Likewise.
10426 (process_imported_unit_die): Update call.
10427 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
10428 (read_file_scope): Likewise.
10429 (allocate_dwo_file_hash_table): Add objfile parameter.
10430 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
10431 (create_cus_hash_table): Likewise.
10432 (create_dwp_hash_table): Likewise.
10433 (create_dwo_unit_in_dwp_v1): Likewise.
10434 (create_dwp_v2_section): Likewise.
10435 (create_dwo_unit_in_dwp_v2): Likewise.
10436 (lookup_dwo_unit_in_dwp): Likewise.
10437 (try_open_dwop_file): Likewise.
10438 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
10439 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
10440 cleanup to include a reference to dwarf2_per_objfile.
10441 (open_dwp_file): Add dwarf2_per_objfile parameter.
10442 (open_and_init_dwp_file): Likewise.
10443 (get_dwp_file): Likewise.
10444 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
10445 (queue_and_load_all_dwo_tus): Update call.
10446 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
10447 data.
10448 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
10449 (dwarf2_ranges_process): Likewise.
10450 (dwarf2_get_pc_bounds): Likewise.
10451 (mark_common_block_symbol_computed): Likewise.
10452 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10453 (dwarf2_read_abbrevs): Update call.
10454 (read_partial_die): Use dwarf2_per_objfile from cu.
10455 (find_partial_die): Likewise.
10456 (fixup_partial_die): Likewise.
10457 (read_attribute_value): Likewise.
10458 (read_indirect_string_at_offset_from): Add objfile parameter.
10459 (read_indirect_string_at_offset): Add dwarf2_per_objfile
10460 parameter.
10461 (read_indirect_string_from_dwz): Add objfile parameter.
10462 (read_indirect_string): Add objfile parameter.
10463 (read_addr_index_1): Add dwarf2_per_objfile parameter.
10464 (read_addr_index): Use dwarf2_per_objfile from cu.
10465 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
10466 call dw2_setup.
10467 (read_str_index): Use dwarf2_per_objfile from cu.
10468 (get_debug_line_section): Likewise.
10469 (read_formatted_entries): Add dwarf2_per_objfile parameter.
10470 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
10471 (new_symbol_full): Use dwarf2_per_objfile from cu.
10472 (build_error_marker_type): Likewise.
10473 (lookup_die_type): Likewise.
10474 (determine_prefix): Likewise.
10475 (follow_die_offset): Likewise.
10476 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
10477 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
10478 (dwarf2_fetch_die_type_sect_off): Likewise.
10479 (dwarf2_get_die_type): Likewise.
10480 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
10481 (get_signatured_type): Likewise.
10482 (get_DW_AT_signature_type): Likewise.
10483 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
10484 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
10485 (cu_debug_loc_section): Likewise.
10486 (fill_in_loclist_baton): Likewise.
10487 (dwarf2_symbol_mark_computed): Likewise.
10488 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10489 dwarf2_per_objfile.
10490 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
10491 parameter.
10492 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10493 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
10494 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
10495 (set_die_type): Use dwarf2_free_objfile from cu.
10496 (get_die_type_at_offset): Likewise.
10497 (dwarf2_per_objfile_free): Don't assign global variable.
10498 (debug_names) <constructor>: Add dwarf2_per_objfile
10499 parameter, update m_debugstrlookup construction.
10500 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
10501 parameter.
10502 <m_dwarf2_per_objfile>: New field.
10503 <lookup>: Use m_dwarf2_per_objfile.
10504 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
10505 (psyms_seen_size): Likewise.
10506 (write_gdbindex): Replace objfile parameter with
10507 dwarf2_per_objfile.
10508 (write_debug_names): Likewise.
10509 (write_psymtabs_to_index): Likewise.
10510 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
10511 calls.
10512
e3b94546
SM
105132018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10514
10515 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
10516 <dwarf2_per_objfile>: New field.
10517 (struct dwarf2_per_cu_data) <objfile>: Remove.
10518 <dwarf2_per_objfile>: New field.
10519 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
10520 of objfile.
10521 (create_signatured_type_table_from_index): Likewise.
10522 (create_debug_type_hash_table): Likewise.
10523 (fill_in_sig_entry_from_dwo_entry): Likewise.
10524 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
10525 (create_type_unit_group): Assign dwarf2_per_objfile instead of
10526 objfile.
10527 (create_partial_symtab): Access objfile through
10528 dwarf2_per_objfile.
10529 (process_psymtab_comp_unit_reader): Likewise.
10530 (read_comp_units_from_section): Likewise.
10531 (scan_partial_symbols): Likewise.
10532 (add_partial_symbol): Likewise.
10533 (add_partial_subprogram): Likewise.
10534 (peek_die_abbrev): Likewise.
10535 (fixup_go_packaging): Likewise.
10536 (process_full_comp_unit): Likewise.
10537 (process_full_type_unit): Likewise.
10538 (process_imported_unit_die): Likewise.
10539 (dwarf2_compute_name): Likewise.
10540 (dwarf2_physname): Likewise.
10541 (read_import_statement): Likewise.
10542 (create_cus_hash_table): Assign dwarf2_physname instead of
10543 objfile.
10544 (read_func_scope): Access objfile through dwarf2_per_objfile.
10545 (read_lexical_block_scope): Likewise.
10546 (read_call_site_scope): Likewise.
10547 (read_variable): Likewise.
10548 (dwarf2_rnglists_process): Likewise.
10549 (dwarf2_ranges_process): Likewise.
10550 (dwarf2_ranges_read): Likewise.
10551 (dwarf2_record_block_ranges): Likewise.
10552 (dwarf2_add_field): Likewise.
10553 (dwarf2_add_member_fn): Likewise.
10554 (read_structure_type): Likewise.
10555 (process_structure_scope): Likewise.
10556 (read_enumeration_type): Likewise.
10557 (read_array_type): Likewise.
10558 (read_common_block): Likewise.
10559 (read_namespace_type): Likewise.
10560 (read_namespace): Likewise.
10561 (read_module_type): Likewise.
10562 (read_tag_pointer_type): Likewise.
10563 (read_tag_ptr_to_member_type): Likewise.
10564 (read_tag_string_type): Likewise.
10565 (read_subroutine_type): Likewise.
10566 (read_typedef): Likewise.
10567 (read_base_type): Likewise.
10568 (attr_to_dynamic_prop): Likewise.
10569 (read_subrange_type): Likewise.
10570 (read_unspecified_type): Likewise.
10571 (load_partial_dies): Likewise.
10572 (read_partial_die): Likewise.
10573 (find_partial_die): Likewise.
10574 (guess_partial_die_structure_name): Likewise.
10575 (fixup_partial_die): Likewise.
10576 (read_attribute_value): Likewise.
10577 (read_addr_index_from_leb128): Likewise.
10578 (dwarf2_read_addr_index): Likewise.
10579 (dwarf2_string_attr): Likewise.
10580 (lnp_state_machine::check_line_address): Likewise.
10581 (dwarf_decode_lines_1): Likewise.
10582 (dwarf_decode_lines): Likewise.
10583 (dwarf2_start_symtab): Likewise.
10584 (var_decode_location): Likewise.
10585 (new_symbol_full): Likewise.
10586 (dwarf2_const_value_data): Likewise.
10587 (dwarf2_const_value_attr): Likewise.
10588 (dwarf2_const_value): Likewise.
10589 (die_type): Likewise.
10590 (die_containing_type): Likewise.
10591 (lookup_die_type): Likewise.
10592 (guess_full_die_structure_name): Likewise.
10593 (anonymous_struct_prefix): Likewise.
10594 (dwarf2_name): Likewise.
10595 (follow_die_ref_or_sig): Likewise.
10596 (follow_die_offset): Likewise.
10597 (follow_die_ref): Likewise.
10598 (dwarf2_fetch_die_loc_sect_off): Likewise.
10599 (dwarf2_fetch_constant_bytes): Likewise.
10600 (dwarf2_fetch_die_type_sect_off): Likewise.
10601 (dwarf2_get_die_type): Likewise.
10602 (follow_die_sig): Likewise.
10603 (decode_locdesc): Likewise.
10604 (dwarf2_per_cu_objfile): Likewise.
10605 (dwarf2_per_cu_text_offset): Likewise.
10606 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
10607 objfile.
10608 (set_die_type): Access objfile through
10609 dwarf2_per_objfile.
10610
b01ba14d
SM
106112018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10612
10613 * valprint.c (converted_character_d): Remove typedef.
10614 (DEF_VEC_O (converted_character_d)): Remove.
10615 (count_next_character): Use std::vector.
10616 (print_converted_chars_to_obstack): Likewise.
10617 (generic_printstr): Likewise.
10618
4d0fdd9b
SM
106192018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10620
10621 * xml-support.h (struct gdb_xml_value): Add constructor.
10622 <value>: Change type to unique_xmalloc_ptr.
10623 (gdb_xml_value_s): Remove typedef.
10624 (DEF_VEC_O (gdb_xml_value_s)): Remove.
10625 (gdb_xml_element_start_handler): Change parameter type to
10626 std::vector.
10627 (xml_find_attribute): Likewise.
10628 * xml-support.c (xml_find_attribute): Change parameter type to
10629 std::vector and adjust.
10630 (gdb_xml_values_cleanup): Remove.
10631 (gdb_xml_parser::start_element): Adjust to std::vector.
10632 (xinclude_start_include): Change paraeter type to std::vector
10633 and adjust.
10634 * btrace.c (check_xml_btrace_version): Likewise.
10635 (parse_xml_btrace_block): Likewise.
10636 (parse_xml_btrace_pt_config_cpu): Likewise.
10637 (parse_xml_btrace_pt): Likewise.
10638 (parse_xml_btrace_conf_bts): Likewise.
10639 (parse_xml_btrace_conf_pt): Likewise.
10640 * memory-map.c (memory_map_start_memory): Likewise.
10641 (memory_map_start_property): Likewise.
10642 * osdata.c (osdata_start_osdata): Likewise.
10643 (osdata_start_item): Likewise.
10644 (osdata_start_column): Likewise.
10645 * remote.c (start_thread): Likewise.
10646 * solib-aix.c (library_list_start_library): Likewise.
10647 (library_list_start_list): Likewise.
10648 * solib-svr4.c (library_list_start_library): Likewise.
10649 (svr4_library_list_start_list): Likewise.
10650 * solib-target.c (library_list_start_segment): Likewise.
10651 (library_list_start_section): Likewise.
10652 (library_list_start_library): Likewise.
10653 (library_list_start_list): Likewise.
10654 * tracepoint.c (traceframe_info_start_memory): Likewise.
10655 (traceframe_info_start_tvar): Likewise.
10656 * xml-syscall.c (syscall_start_syscall): Likewise.
10657 * xml-tdesc.c (tdesc_start_target): Likewise.
10658 (tdesc_start_feature): Likewise.
10659 (tdesc_start_reg): Likewise.
10660 (tdesc_start_union): Likewise.
10661 (tdesc_start_struct): Likewise.
10662 (tdesc_start_flags): Likewise.
10663 (tdesc_start_enum): Likewise.
10664 (tdesc_start_field): Likewise.
10665 (tdesc_start_enum_value): Likewise.
10666 (tdesc_start_vector): Likewise.
10667
f979c73f
SM
106682018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10669
10670 * extension.h (struct xmethod_worker) <clone>: Remove.
10671 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
10672 Remove.
10673 (python_xmethod_worker::clone): Remove.
10674 * valops.c (find_overload_match): Use std::move instead of
10675 clone.
10676
ba18742c
SM
106772018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10678
10679 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
10680 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
10681 <free_xmethod_worker_data>: Remove.
10682 <get_matching_xmethod_workers>: Chance VEC to std::vector.
10683 <get_xmethod_arg_types>: Remove.
10684 <get_xmethod_result_type>: Remove.
10685 <invoke_xmethod>: Remove.
10686 * extension.c (new_xmethod_worker): Remove.
10687 (clone_xmethod_worker): Remove.
10688 (get_matching_xmethod_workers): Return void, pass std::vector by
10689 pointer.
10690 (get_xmethod_arg_types): Rename to...
10691 (xmethod_worker::get_arg_types): ... this, and adjust.
10692 (get_xmethod_result_type): Rename to...
10693 (xmethod_worker::get_result_type): ... this, and adjust.
10694 (invoke_xmethod): Remove.
10695 (free_xmethod_worker): Remove.
10696 (free_xmethod_worker_vec): Remove.
10697 * extension.h (enum ext_lang_rc): Move here from
10698 extension-priv.h.
10699 (struct xmethod_worker): Add constructor and destructor.
10700 <data>: Remove.
10701 <value>: Remove.
10702 <invoke, clone, do_get_result_type, do_get_arg_types>: New
10703 virtual pure methods.
10704 <get_arg_types, get_result_type>: New methods.
10705 (xmethod_worker_ptr): Remove typedef.
10706 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
10707 (xmethod_worker_vec): Remove typedef.
10708 (xmethod_worker_up): New typedef.
10709 (invoke_xmethod): Remove.
10710 (clone_xmethod_worker): Remove.
10711 (free_xmethod_worker): Remove.
10712 (free_xmethod_worker_vec): Remove.
10713 (get_xmethod_arg_types): Remove.
10714 (get_xmethod_result_type): Remove.
10715 * valops.c (find_method_list): Use std::vector, don't use
10716 intermediate vector.
10717 (value_find_oload_method_list): Use std::vector.
10718 (find_overload_match): Use std::vector.
10719 (find_oload_champ): Use std::vector.
10720 * value.c (value_free): Use operator delete.
10721 (value_of_xmethod): Rename to...
10722 (value_from_xmethod): ... this. Don't assign
10723 xmethod_worker::value, take rvalue-reference.
10724 (result_type_of_xmethod): Adjust.
10725 (call_xmethod): Adjust.
10726 * value.h: Include extension.h.
10727 (struct xmethod_worker): Don't forward-declare.
10728 (value_of_xmethod): Rename to...
10729 (value_from_xmethod): ... this, take rvalue-reference.
10730 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
10731 (struct python_xmethod_worker): ... this, add constructor and
10732 destructor.
10733 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
10734 (gdbpy_free_xmethod_worker_data): Rename to...
10735 (python_xmethod_worker::~python_xmethod_worker): ... this and
10736 adjust.
10737 (gdbpy_clone_xmethod_worker_data): Rename to...
10738 (python_xmethod_worker::clone): ... this and adjust.
10739 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
10740 temporary vector.
10741 (gdbpy_get_xmethod_arg_types): Rename to...
10742 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
10743 (gdbpy_get_xmethod_result_type): Rename to...
10744 (python_xmethod_worker::do_get_result_type): ... this and
10745 adjust.
10746 (gdbpy_invoke_xmethod): Rename to...
10747 (python_xmethod_worker::invoke): ... this and adjust.
10748 (new_python_xmethod_worker): Rename to...
10749 (python_xmethod_worker::python_xmethod_worker): ... this and
10750 adjust.
10751 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
10752 Remove.
10753 (gdbpy_free_xmethod_worker_data): Remove.
10754 (gdbpy_get_matching_xmethod_workers): Use std::vector.
10755 (gdbpy_get_xmethod_arg_types): Remove.
10756 (gdbpy_get_xmethod_result_type): Remove.
10757 (gdbpy_invoke_xmethod): Remove.
10758 * python/python.c (python_extension_ops): Remove obsolete
10759 callbacks.
10760
e379cee6
PA
107612018-01-05 Pedro Alves <palves@redhat.com>
10762
10763 PR gdb/18653
10764 * common/signals-state-save-restore.c
10765 (save_original_signals_state): New parameter 'quiet'. Warn if we
10766 find a custom handler preinstalled, instead of internal erroring.
10767 But only warn if !quiet.
10768 * common/signals-state-save-restore.h
10769 (save_original_signals_state): New parameter 'quiet'.
10770 * main.c (captured_main_1): Move save_original_signals_state call
10771 after option handling, and pass QUIET.
10772
a655456c
PA
107732018-01-05 Pedro Alves <palves@redhat.com>
10774
10775 * spu-tdep.c (spu_catch_start): Pass
10776 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
10777
de63c46b
PA
107782018-01-05 Pedro Alves <palves@redhat.com>
10779
10780 PR gdb/22670
10781 * ada-lang.c (literal_symbol_name_matcher): New function.
10782 (ada_get_symbol_name_matcher): Use it for
10783 symbol_name_match_type::SEARCH_NAME.
10784 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
10785 it down instead of assuming symbol_name_match_type::FULL.
10786 * block.h (block_lookup_symbol): New parameter 'match_type'.
10787 * c-valprint.c (print_unpacked_pointer): Use
10788 lookup_symbol_search_name instead of lookup_symbol.
10789 * compile/compile-object-load.c (get_out_value_type): Pass down
10790 symbol_name_match_type::SEARCH_NAME.
10791 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
10792 symbol_name_match_type::FULL.
10793 * cp-support.c (cp_get_symbol_name_matcher): Handle
10794 symbol_name_match_type::SEARCH_NAME.
10795 * infrun.c (insert_exception_resume_breakpoint): Use
10796 lookup_symbol_search_name.
10797 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
10798 * psymtab.c (maintenance_check_psymtabs): Use
10799 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
10800 * stack.c (print_frame_args): Use lookup_symbol_search_name and
10801 SYMBOL_SEARCH_NAME.
10802 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
10803 if symbol_name_match_type::SEARCH_NAME.
10804 (lookup_symbol_in_language): Pass down
10805 symbol_name_match_type::FULL.
10806 (lookup_symbol_search_name): New.
10807 (lookup_language_this): Pass down
10808 symbol_name_match_type::SEARCH_NAME.
10809 (lookup_symbol_aux, lookup_local_symbol): New parameter
10810 'match_type'. Pass it down.
10811 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
10812 (lookup_symbol_search_name): New declaration.
10813 (lookup_symbol_in_block): New 'match_type' parameter.
10814
f98fc17b
PA
108152018-01-05 Pedro Alves <palves@redhat.com>
10816
10817 PR gdb/22670
10818 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
10819 ada_lookup_symbol.
10820 (ada_lookup_symbol): Reimplement in terms of
10821 ada_lookup_symbol_list, bits factored out from
10822 ada_lookup_encoded_symbol.
10823
342f8240
JB
108242018-01-05 Joel Brobecker <brobecker@adacore.com>
10825
10826 * ada-exp.y (write_object_renaming): When subscripting an array
10827 using a symbol as the index, pass the block in call to
10828 ada_lookup_encoded_symbol when looking that symbol up.
10829
7150d33c
JG
108302018-01-05 Jerome Guitton <guitton@adacore.com>
10831
10832 * ada-lang.c (ada_array_length): Use ada_index_type instead of
10833 TYPE_INDEX_TYPE.
10834
cc0e770c
JB
108352018-01-05 Joel Brobecker <brobecker@adacore.com>
10836
10837 * ada-lang.c (ada_to_fixed_value_create): Add handling of
10838 the case where VALUE_LVAL (val0) is not lval_memory.
10839
f79da888 108402018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
10841
10842 * ada-valprint.c (print_optional_low_bound): Handle
10843 character-indexed array printing like boolean-indexed array
10844 printing.
10845
cd385f94
JB
108462018-01-05 Joel Brobecker <brobecker@adacore.com>
10847
10848 * NEWS: Create a new section for the next release branch.
10849 Rename the section of the current branch, now that it has
10850 been cut.
10851
09aca949
JB
108522018-01-05 Joel Brobecker <brobecker@adacore.com>
10853
10854 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
10855 * version.in: Bump version to 8.1.50.DATE-git.
10856
9f757bf7
XR
108572018-01-03 Xavier Roirand <roirand@adacore.com>
10858
10859 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
10860 Add field.
10861 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
10862 Add field.
10863 (default_exception_support_info) <catch_handlers_sym>: Add field.
10864 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
10865 (ada_exception_name_addr_1): Add "catch handlers" handling.
10866 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
10867 Update all callers.
10868 (create_excep_cond_exprs) <ex>: Add parameter.
10869 (re_set_exception): Update create_excep_cond_exprs call.
10870 (print_it_exception, print_one_exception, print_mention_exception)
10871 (print_recreate_exception): Add "catch handler" handling.
10872 (allocate_location_catch_handlers, re_set_catch_handlers)
10873 (check_status_catch_handlers, print_it_catch_handlers)
10874 (print_one_catch_handlers, print_mention_catch_handlers)
10875 (print_recreate_catch_handlers): New function.
10876 (catch_handlers_breakpoint_ops): New variable.
10877 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
10878 Add parameter. Add "catch handler" handling.
10879 (ada_exception_sym_name, ada_exception_breakpoint_ops):
10880 Add "catch handler" handling.
10881 (ada_exception_catchpoint_cond_string): Add "catch handler"
10882 handling.
10883 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
10884 call.
10885 (catch_ada_handlers_command): New function.
10886 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
10887 operations structure.
10888 (_initialize_ada_language): Add "catch handlers" command entry.
10889 * NEWS: Document "catch handlers" feature.
10890
9fe561ab
JB
108912018-01-02 Joel Brobecker <brobecker@adacore.com>
10892
10893 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
10894 account when creating the array type of the slice.
10895 (ada_value_slice): Likewise.
10896
a405673c
JB
108972018-01-02 Joel Brobecker <brobecker@adacore.com>
10898
10899 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
10900 New enum value.
10901 (create_array_type_with_stride): Add byte_stride_prop parameter.
10902 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
10903 New parameter. Update all callers in this file.
10904 (array_type_has_dynamic_stride): New function.
10905 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
10906 of arrays with dynamic byte strides.
10907 * dwarf2read.c (read_array_type): Add support for dynamic
10908 DW_AT_byte_stride attributes.
10909
74a2f8ff
JB
109102018-01-02 Joel Brobecker <brobecker@adacore.com>
10911
10912 * dwarf2read.c (read_unspecified_type): Treat
10913 DW_TAG_enumeration_type DIEs from Ada units as stubs.
10914
e2882c85
JB
109152018-01-01 Joel Brobecker <brobecker@adacore.com>
10916
10917 Update copyright year range in all GDB files.
10918
1690bb24
JB
109192018-01-01 Joel Brobecker <brobecker@adacore.com>
10920
10921 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
10922 and gdb/testsuite/gdb.base/step-line.c.
10923
0f0c98a8
JB
109242018-01-01 Joel Brobecker <brobecker@adacore.com>
10925
10926 * copyright.py (main): Dump the contents of
10927 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
10928 even if BY_HAND is empty.
10929
82e1e79a
JB
109302018-01-01 Joel Brobecker <brobecker@adacore.com>
10931
10932 * top.c (print_gdb_version): Update Copyright year in version
10933 message.
10934
053f54e5 109352018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 10936
053f54e5 10937 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 10938
053f54e5 10939For older changes see ChangeLog-2017.
c906108c
SS
10940\f
10941Local Variables:
10942mode: change-log
10943left-margin: 8
10944fill-column: 74
10945version-control: never
57da7796 10946coding: utf-8
c906108c 10947End:
This page took 3.840788 seconds and 4 git commands to generate.