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