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