]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Remove regcache_cooked_read
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
dca08e1f
SM
12018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2
3 * regcache.h (regcache_cooked_read): Remove, update callers to
4 use readable_regcache::cooked_read instead.
5 * regcache.c (regcache_cooked_read): Remove.
6
10eaee5f
SM
72018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8
9 * regcache.h (regcache_raw_write): Remove, update callers to use
10 regcache::raw_write instead.
11 * regcache.c (regcache_raw_write): Remove.
12
0b883586
SM
132018-05-30 Simon Marchi <simon.marchi@ericsson.com>
14
15 * regcache.h (regcache_raw_read): Remove, update callers to use
16 readable_regcache::raw_read instead.
17 * regcache.c (regcache_raw_read): Remove.
18
0b47d985
SM
192018-05-30 Simon Marchi <simon.marchi@ericsson.com>
20
21 * regcache.h (regcache_raw_update): Remove, update callers to
22 use readable_regcache::raw_update instead.
23 * regcache.c (regcache_raw_update): Remove.
24
0ec9f114
SM
252018-05-30 Simon Marchi <simon.marchi@ericsson.com>
26
27 * regcache.h (regcache_register_status): Remove, update callers
28 to use reg_buffer::get_register_status directly instead.
29 * regcache.c (regcache_register_status): Remove.
30
222312d3
SM
312018-05-30 Simon Marchi <simon.marchi@ericsson.com>
32
33 * regcache.h (regcache_get_ptid): Remove, update all callers to
34 call regcache::ptid instead.
35 * regcache.c (regcache_get_ptid): Remove.
36
fdbe37e3
SM
372018-05-30 Simon Marchi <simon.marchi@ericsson.com>
38
39 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
40
f7c6f423
PA
412018-05-30 Pedro Alves <palves@redhat.com>
42
43 * common/common-exceptions.h (exception_rethrow): Use
44 ATTRIBUTE_NORETURN.
45
52941706
SM
462018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
47
48 * breakpoint.c (print_solib_event, check_status_catch_solib):
49 Remove struct keyword in range-based for loops.
50 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
51 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
52 Likewise.
53 * linespec.c (find_superclass_methods, search_minsyms_for_name):
54 Likewise.
55 * symfile.c (addr_info_make_relative): Likewise.
56 * thread.c (value_in_thread_stack_temporaries): Likewise.
57
64cc34d8
WP
582018-05-29 Weimin Pan <weimin.pan@oracle.com>
59
60 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
61 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
62 * coff-pe-read.c (add_pe_forwarded_sym): Replace
63 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
64 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
65 * jit.c (jit_breakpoint_re_set_internal): Likewise.
66 * printcmd.c (info_address_command): Likewise.
67
e7ec8713
TT
682018-05-29 Tom Tromey <tom@tromey.com>
69
70 * windows-nat.c (handle_exception): Update fall-through comment.
71
bcb430e4
TT
722018-05-29 Tom Tromey <tom@tromey.com>
73
74 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
75 (struct program_space) <added_solibs>: Now a std::vector.
76 * breakpoint.c (print_solib_event): Update.
77 (check_status_catch_solib): Update.
78 * progspace.c (clear_program_space_solib_cache): Update.
79 * solib.c (update_solib_list): Update.
80
894882e3
TT
812018-05-29 Tom Tromey <tom@tromey.com>
82
83 * python/py-type.c (typy_richcompare): Update.
84 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
85 * gdbtypes.h (types_deeply_equal): Return bool.
86 (types_equal): Likewise.
87 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
88 declare VEC.
89 (check_types_equal): Change worklist to std::vector. Return
90 bool.
91 (struct type_equality_entry): Add constructor.
92 (compare_maybe_null_strings): Return bool.
93 (check_types_worklist): Return bool. Change worklist to
94 std::vector.
95 (types_deeply_equal): Use std::vector.
96 (types_equal): Return bool.
97 (compare_maybe_null_strings): Simplify.
98
10b2ded4
TT
992018-05-29 Tom Tromey <tom@tromey.com>
100
101 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
102
4f7deebe
TT
1032018-05-29 Tom Tromey <tom@tromey.com>
104
105 * objc-lang.h: Don't include cp-support.h.
106 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
107 declare VEC.
108
b8283aea
TT
1092018-05-27 Tom Tromey <tom@tromey.com>
110
111 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
112
41a883c8
TT
1132018-05-25 Tom Tromey <tom@tromey.com>
114
115 * value.c (value::location): Initialize.
116
bf259e25
TT
1172018-05-25 Tom Tromey <tom@tromey.com>
118
119 * dbxread.c (init_bincl_list): Remove.
120 (bincl_list): Now a std::vector.
121 (bincls_allocated, next_bincl): Remove.
122 (free_bincl_list, do_free_bincl_list_cleanup)
123 (make_cleanup_free_bincl_list): Remove.
124 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
125 unique_xmalloc_ptr.
126 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
127 (struct header_file_location): Add constructor.
128 (add_bincl_to_list): Remove.
129
d525a99b
TT
1302018-05-25 Tom Tromey <tom@tromey.com>
131
132 * tui/tui.c (tui_enable): Update.
133 * mi/mi-interp.c (mi_interp::init): Update.
134 * interps.h (class interp) <name>: New method.
135 <m_name>: Rename from name.
136 (~scoped_restore_interp): Update.
137 * interps.c (interp::interp): Update.
138 (interp_add, interp_set, interp_lookup_existing)
139 (current_interp_named_p): Update.
140
da505cff
TT
1412018-05-25 Tom Tromey <tom@tromey.com>
142
143 * interps.c (interp_name): Remove.
144 * mi/mi-interp.c (mi_interp::init): Update.
145 * interps.h (interp_name): Remove.
146 (~scoped_restore_interp): Update.
147 * tui/tui.c (tui_enable): Update.
148
29f94340
TT
1492018-05-25 Tom Tromey <tom@tromey.com>
150
151 * utils.c (fputs_maybe_filtered): Update.
152 * linespec.c (decode_line_full): Update.
153 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
154 (mi_print_breakpoint_for_event, mi_solib_loaded)
155 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
156 (mi_user_selected_context_changed): Update.
157 * mi/mi-main.c (mi_execute_command): Update.
158 * cli/cli-script.c (execute_control_command): Update.
159 * python/python.c (execute_gdb_command): Update.
160 * solib.c (info_sharedlibrary_command): Update.
161 * interps.c (interp_ui_out): Remove.
162 * interps.h (interp_ui_out): Remove.
163
716b8bc5
TT
1642018-05-25 Tom Tromey <tom@tromey.com>
165
166 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
167 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
168 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
169
753ff9bd
TT
1702018-05-25 Tom Tromey <tom@tromey.com>
171
172 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
173 * interps.c (interp_exec): Use scoped_restore.
174
5ca3b260
TT
1752018-05-25 Tom Tromey <tom@tromey.com>
176
177 * remote.c (remote_target::remote_file_get): Use
178 gdb::byte_vector.
179 (remote_target::remote_file_put): Likewise.
180
3173aa2f
TT
1812018-05-25 Tom Tromey <tom@tromey.com>
182
183 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
184 a std::string.
185 (get_pe_section_index, add_pe_exported_sym): Update.
186 (read_pe_exported_syms): Use gdb::def_vector.
187
09a5e1b5
TT
1882018-05-25 Tom Tromey <tom@tromey.com>
189
190 * frame.c (remove_prev_frame): Remove.
191 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
192
d8dab6c3
MR
1932018-05-25 Maciej W. Rozycki <macro@mips.com>
194
195 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
196 Remove prototypes.
197 * mips-linux-nat.c (supply_fpregset): Always call
198 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
199 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
200 `mips_fill_fpregset'.
201 * mips-linux-tdep.c (mips_supply_fpregset)
202 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
203 (mips_fill_fpregset_wrapper): Remove functions.
204 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
205 (mips_linux_fpregset): Remove variable.
206 (mips_linux_iterate_over_regset_sections): Use
207 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
208 (mips_linux_o32_sigframe_init): Remove comment.
209
3c69da40
PA
2102018-05-25 Pedro Alves <palves@redhat.com>
211
212 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
213 (struct readahead_cache, struct packet_reg, struct
214 remote_arch_state, class remote_state): Move higher up in the
215 file.
216 (remote_target::m_remote_state): Now an object instead of a pointer.
217 (remote_target::get_remote_state): Adjust.
218
39f0c204
AB
2192018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
220
221 * stack.c (select_and_print_frame): Delete.
222 (struct function_bounds): Move struct within function.
223 (func_command): Most content moved into new function
224 find_frame_for_function, use new function, print result, add
225 function comment.
226 (find_frame_for_function): New function, now returns a result.
227
d392224a
PW
2282018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
229
230 * stack.c (iterate_over_block_arg_vars): Fix comment.
231 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
232
45f25d6c
AB
2332018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
234
235 PR gdb/23203
236 * frame.c
237 (scoped_restore_selected_frame::scoped_restore_selected_frame):
238 Define.
239 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
240 Define.
241 * frame.h (class scoped_restore_selected_frame): New class.
242 * stack.c (print_frame_local_vars): Remove catching and rethrowing
243 of any exception, use scoped_restore_selected_frame to restore the
244 frame instead.
245
da05d921
PA
2462018-05-24 Pedro Alves <palves@redhat.com>
247
248 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
249 override.
250
a8be540e
TT
2512018-05-23 Tom Tromey <tom@tromey.com>
252
253 * complaints.c (struct complaints): Remove.
254 (symfile_complaint_book): Remove.
255 (series): New global.
256 (complaint_internal): Update.
257 (clear_complaints): Update.
258
ff1cf532
TT
2592018-05-23 Tom Tromey <tom@tromey.com>
260
261 * complaints.c (counters): New global.
262 (struct complain): Remove.
263 (struct complaints) <root>: Remove.
264 (complaint_sentinel): Remove.
265 (symfile_complaint_book): Update.
266 (find_complaint) Remove.
267 (complaint_internal, clear_complaints): Update.
268
7ff88174
TT
2692018-05-23 Tom Tromey <tom@tromey.com>
270
271 * complaints.c (struct complain) <file, line>: Remove.
272 (find_complaint): Remove file, line parameters.
273 (complaint_internal): Update.
274
de54e1a5
TT
2752018-05-23 Tom Tromey <tom@tromey.com>
276
277 * complaints.c (vcomplaint): Remove.
278 (complaint_internal) Merge in contents of vcomplaint.
279
2ac237e5
TT
2802018-05-23 Tom Tromey <tom@tromey.com>
281
282 * complaints.c (struct complaints) <explanation>: Remove.
283 (symfile_explanations): Remove.
284 (symfile_complaint_book): Update.
285 (vcomplaint): Update.
286 (struct explanation): Remove.
287
b98664d3
TT
2882018-05-23 Tom Tromey <tom@tromey.com>
289
290 * complaints.c (symfile_complaints): Remove.
291 (complaint_internal): Remove "complaints" parameter.
292 (clear_complaints, vcomplaint): Remove "c" parameter.
293 (get_complaints): Remove.
294 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
295 (dwarf2_debug_line_missing_file_complaint)
296 (dwarf2_debug_line_missing_end_sequence_complaint)
297 (dwarf2_complex_location_expr_complaint)
298 (dwarf2_const_value_length_mismatch_complaint)
299 (dwarf2_section_buffer_overflow_complaint)
300 (dwarf2_macro_malformed_definition_complaint)
301 (dwarf2_invalid_attrib_class_complaint)
302 (create_addrmap_from_index, dw2_symtab_iter_next)
303 (dw2_expand_marked_cus)
304 (dw2_debug_names_iterator::find_vec_in_debug_names)
305 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
306 (create_debug_type_hash_table, init_cutu_and_read_dies)
307 (partial_die_parent_scope, add_partial_enumeration)
308 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
309 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
310 (read_import_statement, read_file_scope, create_dwo_cu_reader)
311 (create_cus_hash_table, create_dwp_hash_table)
312 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
313 (dwarf2_rnglists_process, dwarf2_ranges_process)
314 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
315 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
316 (handle_struct_member_die, process_structure_scope)
317 (read_array_type, read_common_block, read_module_type)
318 (read_tag_pointer_type, read_typedef, read_base_type)
319 (read_subrange_type, load_partial_dies, partial_die_info::read)
320 (partial_die_info::read, partial_die_info::read)
321 (partial_die_info::read, read_checked_initial_length_and_offset)
322 (dwarf2_string_attr, read_formatted_entries)
323 (dwarf_decode_line_header)
324 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
325 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
326 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
327 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
328 (get_signatured_type, get_DW_AT_signature_type)
329 (decode_locdesc, file_file_name, consume_improper_spaces)
330 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
331 (dwarf_decode_macro_bytes, dwarf_decode_macros)
332 (dwarf2_symbol_mark_computed, set_die_type)
333 (read_attribute_value): Update.
334 * stap-probe.c (handle_stap_probe, get_stap_base_address):
335 Update.
336 * dbxread.c (unknown_symtype_complaint)
337 (lbrac_mismatch_complaint, repeated_header_complaint)
338 (set_namestring, function_outside_compilation_unit_complaint)
339 (read_dbx_symtab, process_one_symbol): Update.
340 * gdbtypes.c (stub_noname_complaint): Update.
341 * windows-nat.c (handle_unload_dll): Update.
342 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
343 (decode_base_type): Update.
344 * xcoffread.c (bf_notfound_complaint, ef_complaint)
345 (eb_complaint, record_include_begin, record_include_end)
346 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
347 (process_xcoff_symbol, read_symbol)
348 (function_outside_compilation_unit_complaint)
349 (scan_xcoff_symtab): Update.
350 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
351 * buildsym.c (finish_block_internal, make_blockvector)
352 (end_symtab_get_static_block, augment_type_symtab): Update.
353 * dtrace-probe.c (dtrace_process_dof)
354 (dtrace_static_probe_ops::get_probes): Update.
355 * complaints.h (struct complaint): Don't declare.
356 (symfile_complaints): Remove.
357 (complaint_internal): Remove "complaints" parameter.
358 (complaint): Likewise.
359 (clear_complaints): Likewise.
360 * symfile.c (syms_from_objfile_1, finish_new_objfile)
361 (reread_symbols): Update.
362 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
363 (dwarf2_frame_cache, decode_frame_entry): Update.
364 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
365 * objc-lang.c (lookup_objc_class, lookup_child_selector)
366 (info_selectors_command): Update.
367 * macrotab.c (macro_include, check_for_redefinition)
368 (macro_undef): Update.
369 * objfiles.c (filter_overlapping_sections): Update.
370 * stabsread.c (invalid_cpp_abbrev_complaint)
371 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
372 (define_symbol, error_type, read_type, rs6000_builtin_type)
373 (stabs_method_name_from_physname, read_member_functions)
374 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
375 (attach_fields_to_type, complain_about_struct_wipeout)
376 (read_range_type, read_args, common_block_start)
377 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
378 Update.
379 * mdebugread.c (index_complaint, unknown_ext_complaint)
380 (basic_type_complaint, bad_tag_guess_complaint)
381 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
382 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
383 (parse_procedure, parse_lines)
384 (function_outside_compilation_unit_complaint)
385 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
386 (bad_tag_guess_complaint, reg_value_complaint): Update.
387 * cp-support.c (demangled_name_complaint): Update.
388 * macroscope.c (sal_macro_scope): Update.
389 * dwarf-index-write.c (class debug_names): Update.
390
4e9668d0
TT
3912018-05-23 Tom Tromey <tom@tromey.com>
392
393 * complaints.c (clear_complaints): Remove "noisy" parameter.
394 * complaints.h (clear_complaints): Update.
395 * symfile.c (syms_from_objfile_1, finish_new_objfile)
396 (reread_symbols): Update.
397
43ba33c7
TT
3982018-05-23 Tom Tromey <tom@tromey.com>
399
400 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
401 SUBSEQUENT_MESSAGE.
402 (vcomplaint, clear_complaints): Update.
403 (symfile_explanations): Remove some messages.
404
2b9496b2
TT
4052018-05-23 Tom Tromey <tom@tromey.com>
406
407 * complaints.c (internal_complaint): Remove.
408 * complaints.h (internal_complaint): Remove.
409
35f1fea3
MR
4102018-05-22 Maciej W. Rozycki <macro@mips.com>
411
412 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
413
6b8edb51
PA
4142018-05-22 Pedro Alves <palves@redhat.com>
415
416 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
417 (remote_fileio_badfd, remote_fileio_return_errno)
418 (remote_fileio_return_success, remote_fileio_func_open)
419 (remote_fileio_func_open, remote_fileio_func_close)
420 (remote_fileio_func_read, remote_fileio_func_write)
421 (remote_fileio_func_lseek, remote_fileio_func_rename)
422 (remote_fileio_func_unlink, remote_fileio_func_stat)
423 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
424 (remote_fileio_func_isatty, remote_fileio_func_system): Add
425 remote_target parameter.
426 (remote_fio_func_map) <func>: Add remote_target parameter.
427 (do_remote_fileio_request, remote_fileio_request):
428 * remote-fileio.h (remote_fileio_request):
429 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
430 remote_target parameter.
431 (remote_notif_process, handle_notification): Adjust to pass down
432 the remote.
433 (remote_notif_state_allocate): Add remote_target parameter. Save
434 it.
435 * remote-notif.h (struct remote_target): Forward declare.
436 (struct notif_client) <parse, ack, can_get_pending_events>: Add
437 remote_target parameter.
438 (struct remote_notif_state) <remote>: New field.
439 (remote_notif_ack, remote_notif_parse): Add remote_target
440 parameter.
441 (remote_notif_state_allocate, remote_notif_state_allocate): Add
442 remote_target parameter.
443 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
444 (threads_listing_context, rmt_thread_action, protocol_feature)
445 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
446 (packet_result, struct threads_listing_context, remote_state):
447 Move definitions and declarations higher up.
448 (remote_target) <~remote_target>: Declare.
449 (remote_download_command_source, remote_file_put, remote_file_get)
450 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
451 (remote_hostio_pread_vFile, remote_hostio_send_command)
452 (remote_hostio_set_filesystem, remote_hostio_open)
453 (remote_hostio_close, remote_hostio_unlink, remote_state)
454 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
455 (get_memory_write_packet_size, get_memory_read_packet_size)
456 (append_pending_thread_resumptions, remote_detach_1)
457 (append_resumption, remote_resume_with_vcont)
458 (add_current_inferior_and_thread, wait_ns, wait_as)
459 (process_stop_reply, remote_notice_new_inferior)
460 (process_initial_stop_replies, remote_add_thread)
461 (btrace_sync_conf, remote_btrace_maybe_reopen)
462 (remove_new_fork_children, kill_new_fork_children)
463 (discard_pending_stop_replies, stop_reply_queue_length)
464 (check_pending_events_prevent_wildcard_vcont)
465 (discard_pending_stop_replies_in_queue, stop_reply)
466 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
467 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
468 (remote_interrupt_as, remote_interrupt_ns)
469 (remote_get_noisy_reply, remote_query_attached)
470 (remote_add_inferior, remote_current_thread, get_current_thread)
471 (set_thread, set_general_thread, set_continue_thread)
472 (set_general_process, write_ptid)
473 (remote_unpack_thread_info_response, remote_get_threadinfo)
474 (parse_threadlist_response, remote_get_threadlist)
475 (remote_threadlist_iterator, remote_get_threads_with_ql)
476 (remote_get_threads_with_qxfer)
477 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
478 (get_offsets, remote_check_symbols, remote_supported_packet)
479 (remote_query_supported, remote_packet_size)
480 (remote_serial_quit_handler, remote_detach_pid)
481 (remote_vcont_probe, remote_resume_with_hc)
482 (send_interrupt_sequence, interrupt_query)
483 (remote_notif_get_pending_events, fetch_register_using_p)
484 (send_g_packet, process_g_packet, fetch_registers_using_g)
485 (store_register_using_P, store_registers_using_G)
486 (set_remote_traceframe, check_binary_download)
487 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
488 (remote_xfer_live_readonly_partial, remote_read_bytes)
489 (remote_send_printf, remote_flash_write, readchar)
490 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
491 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
492 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
493 (extended_remote_disable_randomization, extended_remote_run)
494 (send_environment_packet, extended_remote_environment_support)
495 (extended_remote_set_inferior_cwd, remote_write_qxfer)
496 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
497 (packet_command): Now methods of ...
498 (remote_target): ... this class.
499 (m_remote_state) <remote_target>: New field.
500 (struct remote_state) <stop_reply_queue,
501 remote_async_inferior_event_token, wait_forever_enabled_p>: New
502 fields.
503 (remote_state::remote_state): Allocate stop_reply_queue.
504 (remote_state): Delete global.
505 (get_remote_state_raw): Delete.
506 (remote_target::get_remote_state): Allocate m_remote_state on
507 demand.
508 (get_current_remote_target): New.
509 (remote_ops, extended_remote_ops): Delete.
510 (wait_forever_enabled_p, remote_async_inferior_event_token):
511 Delete, moved to struct remote_state.
512 (remote_target::close): Delete self. Destruction bits split to
513 ...
514 (remote_target::~remote_target): ... this.
515 (show_memory_packet_size): Adjust to use
516 get_current_remote_target.
517 (struct protocol_feature) <func>: Add remote_target parameter.
518 All callers adjusted.
519 (curr_quit_handler_target): New.
520 (remote_serial_quit_handler): Reimplement.
521 (remote_target::open_1): Adjust to use get_current_remote_target.
522 Heap-allocate remote_target/extended_remote_target instances.
523 (vcont_builder::vcont_builder): Add remote_target parameter, and
524 save it in m_remote. All callers adjusted.
525 (vcont_builder::m_remote): New field.
526 (vcont_builder::restart, vcont_builder::flush)
527 (vcont_builder::push_action): Use it.
528 (remote_target::commit_resume): Use it.
529 (struct queue_iter_param) <remote>: New field.
530 (remote_target::remove_new_fork_children): Fill in 'remote' field.
531 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
532 (check_pending_event_prevents_wildcard_vcont_callback)
533 (remote_target::check_pending_events_prevent_wildcard_vcont)
534 (remote_target::discard_pending_stop_replies)
535 (remote_target::discard_pending_stop_replies_in_queue)
536 (remote_target::remote_notif_remove_queued_reply): Fill in
537 'remote' field.
538 (remote_notif_get_pending_events): New.
539 (remote_target::readchar, remote_target::remote_serial_write):
540 Save/restore curr_quit_handler_target.
541 (putpkt): New.
542 (kill_new_fork_children): Fill in 'remote' field.
543 (packet_command): Use get_current_remote_target, defer to
544 remote_target method of same name.
545 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
546 parameter, and save it in m_remote. All callers adjusted.
547 (scoped_remote_fd::release): Use m_remote.
548 (scoped_remote_fd::m_remote): New field.
549 (remote_file_put, remote_file_get, remote_file_delete): Use
550 get_current_remote_target, defer to remote_target method of same
551 name.
552 (remote_btrace_reset): Add remote_state paremeter. Update all
553 callers.
554 (remote_async_inferior_event_handler). Pass down 'data'.
555 (remote_new_objfile): Use get_current_remote_target.
556 (remote_target::vcont_r_supported): New.
557 (set_range_stepping): Use get_current_remote_target and
558 remote_target::vcont_r_supported.
559 (_initialize_remote): Don't allocate 'remote_state' and
560 'stop_reply_queue' globals.
561 * remote.h (struct remote_target): Forward declare.
562 (getpkt, putpkt, remote_notif_get_pending_events): Add
563 'remote_target' parameter.
564
f5db4863
PA
5652018-05-22 Pedro Alves <palves@redhat.com>
566
567 * remote.c (vcont_builder): Now a class. Make all data members
568 private.
569 (vcont_builder) <vcont_builder, restart, flush, push_action>:
570 Declare methods.
571 (vcont_builder_restart): Rename to ...
572 (vcont_builder::restart): ... this.
573 (vcont_builder_flush): Rename to ...
574 (vcont_builder::flush): ... this.
575 (vcont_builder_push_action): Rename to ...
576 (vcont_builder::push_action): ... this.
577 (remote_target::commit_resume): Adjust.
578
cc0be08f
PA
5792018-05-22 Pedro Alves <palves@redhat.com>
580
581 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
582 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
583 (get_fixed_memory_packet_size): New.
584 (get_memory_packet_size): Use it.
585 (set_memory_packet_size): Don't override the config size with
586 DEFAULT_MAX_MEMORY_PACKET_SIZE.
587 (show_memory_packet_size): Use get_fixed_memory_packet_size.
588 Don't refer to get_memory_packet_size if not connected to a remote
589 target. Show "(default)" if configured size is 0.
590
9607784a
PA
5912018-05-22 Pedro Alves <palves@redhat.com>
592
593 * remote.c (remote_target::mourn_inferior): Move
594 discard_pending_stop_replies call here from ...
595 (_initialize_remote): ... here.
596
0e9a6b2f
PA
5972018-05-22 Pedro Alves <palves@redhat.com>
598
599 * remote.c (compare_section_command): Remove set_general_process
600 call.
601
43c3a0e4
PA
6022018-05-22 Pedro Alves <palves@redhat.com>
603
604 * remote.c (struct packet_reg, struct remote_arch_state):
605 Move higher up in the file.
606 (remote_state) <m_arch_states>: Store remote_arch_state values
607 instead of remote_arch_state pointers.
608 (remote_state::get_remote_arch_state): Adjust.
609
9d6eea31
PA
6102018-05-22 Pedro Alves <palves@redhat.com>
611
612 * remote.c: Include <unordered_map>.
613 (remote_state): Now a class.
614 (remote_state) <get_remote_arch_state>: Declare method.
615 <get_remote_arch_state>: New field.
616 (remote_arch_state) <remote_arch_state>: Declare ctor.
617 <regs>: Now a unique_ptr.
618 (remote_gdbarch_data_handle): Delete.
619 (get_remote_arch_state): Delete.
620 (remote_state::get_remote_arch_state): New.
621 (get_remote_state): Adjust to call remote_state's
622 get_remote_arch_state method.
623 (init_remote_state): Delete, bits factored out to ...
624 (remote_arch_state::remote_arch_state): ... this new method.
625 (get_remote_packet_size, get_memory_packet_size)
626 (process_g_packet, remote_target::fetch_registers)
627 (remote_target::prepare_to_store, store_registers_using_G)
628 (remote_target::store_registers, remote_target::get_trace_status):
629 Adjust to call remote_state's method.
630 (_initialize_remote): Remove reference to
631 remote_gdbarch_data_handle.
632
dd194f6b
PA
6332018-05-22 Pedro Alves <palves@redhat.com>
634
635 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
636 pread>: New method declarations.
637 (remote_target::open_1): Adjust.
638 (readahead_cache_invalidate): Rename to ...
639 (readahead_cache::invalidate): ... this, and adjust to be a class
640 method.
641 (readahead_cache_invalidate_fd): Rename to ...
642 (readahead_cache::invalidate_fd): ... this, and adjust to be a
643 class method.
644 (remote_hostio_pwrite): Adjust.
645 (remote_hostio_pread_from_cache): Rename to ...
646 (readahead_cache::pread): ... this, and adjust to be a class
647 method.
648 (remote_hostio_close): Adjust.
649
440b7aec
PA
6502018-05-22 Pedro Alves <palves@redhat.com>
651
652 * remote.c (remote_hostio_close_cleanup): Delete.
653 (class scoped_remote_fd): New.
654 (remote_file_put, remote_file_get): Use it.
655
de44f5a7
PA
6562018-05-22 Pedro Alves <palves@redhat.com>
657
658 (struct vCont_action_support): Use bool and initialize all fields.
659 (struct readahead_cache): Initialize all fields.
660 (remote_state): Use bool and initialize all fields.
661 (remote_state::remote_state, remote_state::~remote_state): New.
662 (new_remote_state): Delete.
663 (_initialize_remote): Use new to allocate remote_state.
664
b1b60145
PA
6652018-05-22 Pedro Alves <palves@redhat.com>
666 張俊芝 <zjz@zjz.name>
667
668 PR gdb/22973
669 * c-exp.y: Include "c-support.h".
670 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
671 of tolower. Use c_ident_is_alpha to scan names.
672 * c-lang.c: Include "c-support.h".
673 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
674 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
675 * c-support.h: New file, with bits factored out from ...
676 * cp-name-parser.y: ... this file.
677 Include "c-support.h".
678 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
679 c-support.h and renamed.
680 (symbol_end, yylex): Adjust.
681
0ec848ad
PFC
6822018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
683
684 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
685 parameter type to CORE_ADDR.
686 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
687 parameter type in declaration to CORE_ADDR.
688 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
689 target_auxv_search to get AT_HWCAP and use the result to get the
690 target description.
691 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
692 to CORE_ADDR. Remove the cast of the return value to unsigned
693 long. Fix error predicate of target_auxv_search.
694 (ppc_linux_nat_target::read_description): Change the type of the
695 hwcap variable to CORE_ADDR.
696
0fb2aaa1
PFC
6972018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
698
699 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
700 if the size of fpscr is larger than 32 bits.
701
2c3305f6
PFC
7022018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
703
704 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
705 (ppc32_linux_vsxregmap): New global.
706 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
707 regcache_supply_regset, and regcache_collect_regset.
708 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
709 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
710 (fetch_vsx_register, store_vsx_register): Remove.
711 (fetch_vsx_registers): Add regno parameter. Get regset using
712 ppc_linux_vsxregset. Use regset to supply registers.
713 (store_vsx_registers): Add regno parameter. Get regset using
714 ppc_linux_vsxregset. Use regset to collect registers.
715 (fetch_register): Call fetch_vsx_registers instead of
716 fetch_vsx_register.
717 (store_register): Call store_vsx_registers instead of
718 store_vsx_register.
719 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
720 new regno parameter.
721 (store_ppc_registers): Call store_vsx_registers with -1 for the
722 new regno parameter.
723 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
724 (ppc_collect_vsxregset): Remove.
725
1d75a658
PFC
7262018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
727
728 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
729 offset fields.
730 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
731 for vector register offset fields.
732 (ppc64_fbsd_reg_offsets): Likewise.
733 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
734 to vector register offset fields.
735 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
736 to vector register offset fields.
737 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
738 vector register offset fields.
739 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
740 initializers for vector register offset fields.
741 (rs6000_aix64_reg_offsets): Likewise.
742 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
743 (ppc_supply_vrregset): Remove.
744 (ppc_collect_vrregset): Remove.
745 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
746 (ppc_linux_vrregset) : New function.
747 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
748 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
749 (ppc32_linux_vrregset): Remove.
750 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
751 and use result instead of ppc32_linux_vrregset.
752 (ppc32_linux_reg_offsets): Remove initializers for vector register
753 offset fields.
754 (ppc64_linux_reg_offsets): Likewise.
755 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
756 * ppc-linux-nat.c: Include regset.h.
757 (gdb_vrregset_t): Adjust comment to account for little-endian
758 mode.
759 (supply_vrregset, fill_vrregset): Remove.
760 (fetch_altivec_register, store_altivec_register): Remove.
761 (fetch_altivec_registers): Add regno parameter. Get regset using
762 ppc_linux_vrregset. Use regset to supply registers.
763 (store_altivec_registers): Add regno parameter. Get regset using
764 ppc_linux_vrregset. Use regset to collect registers.
765 (fetch_register): Call fetch_altivec_registers instead of
766 fetch_altivec_register.
767 (store_register): Call store_altivec_registers instead of
768 store_altivec_register.
769 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
770 the new regno parameter.
771 (store_ppc_registers): Call store_altivec_registers with -1 for
772 the new regno parameter.
773
d078308a
PFC
7742018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
775
776 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
777 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
778 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
779 (gdb_vrregset_t): Change array type size to
780 PPC_LINUX_SIZEOF_VRREGSET.
781 (gdb_vsxregset_t): Change array type size to
782 PPC_LINUX_SIZEOF_VSXREGSET.
783 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
784 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
785 PPC_LINUX_SIZEOF_VSXREGSET.
786
2e077f5e
PFC
7872018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
788
789 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
790 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
791 nat/ppc-linux.c.
792 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
793 ppc_linux_target_wordsize with tid.
794 (ppc_linux_nat_target::read_description): Call ppc_linux_target
795 wordsize with tid.
796 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
797 (ppc64_64bit_inferior_p): Add static and inline specifiers.
798 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
799 tid parameter. Remove static specifier.
800 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
801 (ppc_linux_target_wordsize): New declaration.
802
bd64614e
PFC
8032018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
804
805 * arch/ppc-linux-common.c: New file.
806 * arch/ppc-linux-common.h: New file.
807 * arch/ppc-linux-tdesc.h: New file.
808 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
809 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
810 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
811 arch/ppc-linux-tdesc.h.
812 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
813 arch/ppc-linux-tdesc.h.
814 (ppc_linux_nat_target::read_description): Remove target
815 description matching code. Fill a ppc_linux_features struct and
816 call ppc_linux_match_description with it. Move comment about ISA
817 2.05 to ppc-linux-common.c.
818 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
819 arch/ppc-linux-tdesc.h.
820 (ppc_linux_core_read_description): Remove target description
821 matching code. Fill a ppc_linux_features struct and call
822 ppc_linux_match_description with it.
823 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
824 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
825 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
826 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
827 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
828 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
829 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
830 (tdesc_powerpc_e500l): Remove.
831
241db429
JB
8322018-05-22 Joel Brobecker <brobecker@adacore.com>
833
834 * ada-lang.c (catch_assert_command): Pass empty string instead
835 of NULL for excep_string argument.
836
75d74cca
MR
8372018-05-22 Maciej W. Rozycki <macro@mips.com>
838
839 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
840 the width of the requested register exceeds the width of the
841 `ptrace' data type.
842
122b53ea
TT
8432018-05-21 Tom Tromey <tom@tromey.com>
844
845 * printcmd.c (output_command): Remove.
846 (output_command_const): Rename to output_command.
847 * valprint.h (output_command): Rename from output_command_const.
848 * tracepoint.c (trace_dump_actions): Call output_command.
849
bc18fbb5
TT
8502018-05-21 Tom Tromey <tom@tromey.com>
851
852 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
853 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
854 * ada-lang.h (create_ada_exception_catchpoint): Update.
855 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
856 std::string.
857 (create_excep_cond_exprs, ~ada_catchpoint)
858 (should_stop_exception, print_one_exception)
859 (print_mention_exception, print_recreate_exception): Update.
860 (ada_get_next_arg): Remove.
861 (catch_ada_exception_command_split): Use std::string. Change type
862 of "excep_string", "cond_string".
863 (catch_ada_exception_command): Update.
864 (create_ada_exception_catchpoint): Change type of excep_string.
865 (ada_exception_sal): Remove excep_string parameter.
866 (~ada_catchpoint): Remove.
867
790217f6
TT
8682018-05-21 Tom Tromey <tom@tromey.com>
869
870 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
871 cleanup.
872
6f46ac85
TT
8732018-05-21 Tom Tromey <tom@tromey.com>
874
875 * ada-lang.c (ada_exception_message_1, ada_exception_message):
876 Return unique_xmalloc_ptr.
877 (print_it_exception): Update.
878
15b6611c
TT
8792018-05-21 Tom Tromey <tom@tromey.com>
880
881 * tracepoint.c (trace_dump_actions): Use std::string.
882
c0c9f665
TT
8832018-05-21 Tom Tromey <tom@tromey.com>
884
885 * symfile.c (reread_symbols): Use std::string for original_name.
886
22ca247e
TT
8872018-05-21 Tom Tromey <tom@tromey.com>
888
889 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
890 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
891 constructor.
892
184cde75
SM
8932018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
894
895 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
896 instance to...
897 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
898 * objfiles.c (get_objfile_bfd_data): Allocate
899 objfile_per_bfd_storage with obstack_new when allocating on
900 obstack.
901
e39db4db
SM
9022018-05-20 Simon Marchi <simon.marchi@ericsson.com>
903
904 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
905 OBSTACK_ZALLOC.
906 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
907 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
908 * mdebugread.c (mdebug_build_psymtabs): Likewise.
909 (add_pending): Likewise.
910 (parse_symbol): Likewise.
911 (parse_partial_symbols): Likewise.
912 (psymtab_to_symtab_1): Likewise.
913 (new_psymtab): Likewise.
914 (elfmdebug_build_psymtabs): Likewise.
915 * minsyms.c (terminate_minimal_symbol_table): Likewise.
916 * objfiles.c (get_objfile_bfd_data): Likewise.
917 (objfile_register_static_link): Likewise.
918 * psymtab.c (allocate_psymtab): Likewise.
919 * stabsread.c (read_member_functions): Likewise.
920 * xcoffread.c (xcoff_end_psymtab): Likewise.
921
284a0e3c
SM
9222018-05-20 Simon Marchi <simon.marchi@ericsson.com>
923
924 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
925 compiler supports std::is_trivially_constructible.
926 * common/poison.h: Include obstack.h.
927 (IsMallocable): Define to is_trivially_constructible if the
928 compiler supports it, define to true_type otherwise.
929 (xobnew): New.
930 (XOBNEW): Redefine.
931 (xobnewvec): New.
932 (XOBNEWVEC): Redefine.
933 * gdb_obstack.h (obstack_zalloc): New.
934 (OBSTACK_ZALLOC): Redefine.
935 (obstack_calloc): New.
936 (OBSTACK_CALLOC): Redefine.
937 (obstack_new): New.
938 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
939 (gdbarch_obstack): New declaration in gdbarch.h, definition in
940 gdbarch.c.
941 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
942 obstack_calloc/obstack_zalloc.
943 (gdbarch_obstack_zalloc): Remove.
944 * target-descriptions.c (tdesc_data_init): Use obstack_new.
945
59f66be3
PW
9462018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
947
948 * stack.c (backtrace_command_1): Remove useless variable int i.
949
50c65c2d
PW
9502018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
951
952 * stack.c (print_frame_info): Fix comment.
953
7ff8cb8c
TT
9542018-05-18 Tom Tromey <tom@tromey.com>
955
956 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
957 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
958 (~dwarf2_per_objfile): Update
959 (dwarf2_get_dwz_file): Use new.
960 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
961 unique_ptr.
962
400174b1
TT
9632018-05-18 Tom Tromey <tom@tromey.com>
964
965 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
966 unique_ptr.
967 * dwarf2read.c (struct dwp_file): Add constructor and
968 initializers.
969 (open_and_init_dwp_file): Return a unique_ptr.
970 (dwarf2_per_objfile, create_dwp_hash_table)
971 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
972 (lookup_dwo_unit_in_dwp): Update.
973 (open_and_init_dwp_file, get_dwp_file): Update.
974
3063847f
TT
9752018-05-18 Tom Tromey <tom@tromey.com>
976
977 * dwarf2read.c (dwarf2_per_objfile): Update.
978 (struct mapped_index): Add initializers.
979 (dwarf2_read_index): Use new.
980 (dw2_symtab_iter_init): Update.
981 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
982 unique_ptr.
983
d3d02dee
SM
9842018-05-18 Simon Marchi <simon.marchi@ericsson.com>
985
986 * dwarf2read.c (mapped_index) <total_size>: Remove.
987
1d143c36
SM
9882018-05-18 Simon Marchi <simon.marchi@ericsson.com>
989
990 * unittests/format_pieces-selftests.c (test_format_specifier):
991 Add ARI comments.
992
ce1e8424
TT
9932018-05-18 Tom Tromey <tom@tromey.com>
994
995 * c-typeprint.c (maybe_print_hole): New function.
996 (c_print_type_struct_field_offset): Update.
997 (c_type_print_base_struct_union): Call maybe_print_hole.
998
ddfe970e
KS
9992018-05-17 Keith Seitz <keiths@redhat.com>
1000
1001 * breakpoint.c (build_bpstat_chain): New function, moved from
1002 bpstat_stop_status.
1003 (bpstat_stop_status): Add optional parameter, `stop_chain'.
1004 If no stop chain is passed, call build_bpstat_chain to build it.
1005 * breakpoint.h (build_bpstat_chain): Declare.
1006 (bpstat_stop_status): Move documentation here from breakpoint.c.
1007 * infrun.c (handle_signal_stop): Before eliding inlined frames,
1008 build the stop chain and pass it to skip_inline_frames.
1009 Pass this stop chain to bpstat_stop_status.
1010 * inline-frame.c: Include breakpoint.h.
1011 (stopped_by_user_bp_inline_frame): New function.
1012 (skip_inline_frames): Add parameter `stop_chain'.
1013 Move documention to inline-frame.h.
1014 If non-NULL, use stopped_by_user_bp_inline_frame to determine
1015 whether the frame should be elided.
1016 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
1017 Add moved documentation and update for new parameter.
1018
b17992c1
SM
10192018-05-17 Simon Marchi <simon.marchi@ericsson.com>
1020
1021 PR cli/14975
1022 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1023 unittests/format_pieces-selftests.c.
1024 * common/format.h (format_piece) <operator==>: New.
1025 (format_pieces) <operator[]>: Remove.
1026 * common/format.c (format_pieces::format_pieces): Handle \e.
1027 * unittests/format_pieces-selftests.c: New.
1028
58f0c718
TT
10292018-05-17 Tom Tromey <tom@tromey.com>
1030
1031 PR symtab/23010:
1032 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
1033 (dw2_instantiate_symtab): Add skip_partial parameter.
1034 (dw2_find_last_source_symtab, dw2_map_expand_apply)
1035 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
1036 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
1037 (dw2_expand_symtabs_matching_one)
1038 (dw2_find_pc_sect_compunit_symtab)
1039 (dw2_debug_names_lookup_symbol)
1040 (dw2_debug_names_expand_symtabs_for_function): Update.
1041 (init_cutu_and_read_dies): Add skip_partial parameter.
1042 (process_psymtab_comp_unit, build_type_psymtabs_1)
1043 (process_skeletonless_type_unit, load_partial_comp_unit)
1044 (psymtab_to_symtab_1): Update.
1045 (load_full_comp_unit): Add skip_partial parameter.
1046 (process_imported_unit_die, dwarf2_read_addr_index)
1047 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
1048 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
1049 (read_signatured_type): Update.
1050
3e618834
SM
10512018-05-17 Simon Marchi <simon.marchi@ericsson.com>
1052
1053 * value.c (release_value): Remove unused variable.
1054 (record_latest_value): Likewise.
1055 (access_value_history): Likewise.
1056 (preserve_values): Likewise.
1057
fe10fe31
TT
10582018-05-17 Tom Tromey <tom@tromey.com>
1059
1060 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
1061 Initialize.
1062
1d761124
MR
10632018-05-16 Maciej W. Rozycki <macro@mips.com>
1064
1065 PR gdb/22286
1066 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
1067 Also handle registers whose width is not a multiple of
1068 PTRACE_TYPE_RET.
1069 (linux_nat_trad_target::store_register): Likewise.
1070
06333fea
TT
10712018-05-16 Tom Tromey <tom@tromey.com>
1072
1073 * gdbcore.h (core_bfd): Redefine.
1074 * corelow.c (core_target::close): Update.
1075 (core_target_open): Update.
1076 * progspace.h (struct program_space) <cbfd>: Now a
1077 gdb_bfd_ref_ptr.
1078
921222e2
TT
10792018-05-16 Tom Tromey <tom@tromey.com>
1080
1081 PR cli/19551:
1082 * symfile-add-flags.h (enum symfile_add_flags)
1083 <SYMFILE_NOT_FILENAME>: New constant.
1084 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
1085 objfile name from BFD.
1086 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
1087 * minidebug.c (find_separate_debug_file_in_section): Put
1088 ".gnu_debugdata" into BFD's file name.
1089
3acb7083
SM
10902018-05-16 Simon Marchi <simon.marchi@ericsson.com>
1091
1092 * regcache.c (regcache_read_ftype, regcache_write_ftype):
1093 Remove.
1094
561a72d4
TC
10952018-05-15 Tamar Christina <tamar.christina@arm.com>
1096
1097 PR binutils/21446
1098 * aarch64-tdep.c (aarch64_analyze_prologue,
1099 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
1100 Indicate not interested in errors.
1101
4e6ff0e1
MR
11022018-05-15 Maciej W. Rozycki <macro@mips.com>
1103
1104 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
1105 Supply the MIPS_ZERO_REGNUM register.
1106
ea33cd92
MR
11072018-05-15 Maciej W. Rozycki <macro@mips.com>
1108
1109 * mips-tdep.c (mask_address_var): Make variable static.
1110
2d79090e
TT
11112018-05-14 Tom Tromey <tom@tromey.com>
1112
1113 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
1114
cf4912ae
AB
11152018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
1116
1117 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
1118 FXSAVE_ADDR for the mxcsr register.
1119
67e6f569
MF
11202018-05-11 Max Filippov <jcmvbkbc@gmail.com>
1121
1122 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
1123
15244507
PA
11242018-05-11 Pedro Alves <palves@redhat.com>
1125
1126 * corelow.c (core_target) <core_target>: No longer inline.
1127 Initialize m_core_gdbarch, m_core_vec and build the section table
1128 here.
1129 <~core_target>: New.
1130 <core_gdbarch, get_core_register_section>: New methods.
1131 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
1132 factored out from ...
1133 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
1134 (core_ops): Delete.
1135 (sniff_core_bfd): Add gdbarch parameter.
1136 (core_close): Delete, merged into ...
1137 (core_target::close): ... here. Delete self.
1138 (core_close_cleanup): Delete.
1139 (core_target_open): Allocate a core_target on the heap. Use a
1140 unique_ptr instead of a cleanup. Bits moved into the core_target
1141 ctor. Adjust to use core_target methods instead of globals.
1142 (get_core_register_section): Rename to ...
1143 (core_target::get_core_register_section): ... this and adjust.
1144 (struct get_core_registers_cb_data): New.
1145 (get_core_registers_cb): Use it. Use bool.
1146 (core_target::fetch_registers, core_target::files_info)
1147 (core_target::xfer_partial, core_target::read_description)
1148 (core_target::pid_to, core_target::thread_name): Adjust to
1149 reference class fields instead of globals.
1150 * target.h (struct target_ops_deleter, target_ops_up): New.
1151
451953fa
PA
11522018-05-11 Pedro Alves <palves@redhat.com>
1153
1154 * corefile.c (core_file_command): Move to corelow.c.
1155 * corelow.c (the_core_target): Delete.
1156 (core_file_command): Moved from corefile.c. Check exec_bfd
1157 instead of the_core_target. Use target_detach instead of calling
1158 into the_core_target directly.
1159 (maybe_say_no_core_file_now): New.
1160 (core_target::detach): Use it.
1161 (_initialize_corelow): Remove references to the_core_target.
1162 * gdbcore.h (the_core_target): Delete.
1163
e540a5a2 11642018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 1165 Pedro Alves <palves@redhat.com>
e540a5a2
TT
1166
1167 * corefile.c (core_bfd): Remove.
1168 * gdbcore.h (core_bfd): Now a macro.
1169 * progspace.h (struct program_space) <cbfd>: New field.
1170
633cf254
TT
11712018-05-11 Tom Tromey <tom@tromey.com>
1172
1173 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
1174 gdb::def_vector.
1175
1a34f210
TT
11762018-05-10 Tom Tromey <tom@tromey.com>
1177
1178 * configure: Rebuild.
1179 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
1180
190852c8
JB
11812018-05-10 Joel Brobecker <brobecker@adacore.com>
1182
1183 PR server/23158:
1184 * regformats/regdat.sh: Adjust script, following the addition
1185 of the new expedite_regs parameter to init_target_desc.
1186
8727de56
OJ
11872018-05-10 Omair Javaid <omair.javaid@linaro.org>
1188
1189 PR gdb/23127
1190 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
1191 set_gdbarch_significant_addr_bit.
1192 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
1193 set_gdbarch_significant_addr_bit.
1194 * utils.c (address_significant): Update to sign extend addr.
1195
37d9e062
MF
11962018-05-09 Max Filippov <jcmvbkbc@gmail.com>
1197
1198 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
1199 (xtensa_linux_init_abi): Limit tdep->num_regs by
1200 tdep->num_nopriv_regs.
1201 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
1202 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
1203 not initialized.
1204
7402fbca
SM
12052018-05-08 Simon Marchi <simon.marchi@ericsson.com>
1206
1207 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
1208
8ee22052
AB
12092018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1210
1211 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
1212 (I387_MXCSR_INIT_VAL): New constant.
1213 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
1214 buffer if it was supplied by the inferior.
1215 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
1216 (i387_xsave_get_clear_bv): New function.
1217 (i387_supply_xsave): Only read x87 control registers from the
1218 xsave buffer if the feature is enabled, and the state will have
1219 been written, otherwise, provide a suitable default.
1220 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
1221 including x87 control registers. Update control registers if they
1222 have changed from the default value, and mark features as enabled
1223 as required.
1224 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
1225
968ae51b
UW
12262018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
1227
1228 * spu-tdep.c (info_spu_event_command): Fix output formatting.
1229
aff689d3
TT
12302018-05-07 Tom Tromey <tom@tromey.com>
1231
1232 * configure: Rebuild.
1233 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
1234
ce887586
TT
12352018-05-07 Tom Tromey <tom@tromey.com>
1236
1237 PR tdep/20362:
1238 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
1239 bit. Use correct value for VDIV.
1240
85e26832
TT
12412018-05-04 Tom Tromey <tom@tromey.com>
1242
1243 * configure: Rebuild.
1244 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
1245
449b1ac7
TT
12462018-05-04 Tom Tromey <tom@tromey.com>
1247
1248 * linux-record.c (record_linux_system_call) <case
1249 RECORD_SYS_RECVFROM>: Add "break".
1250
15c9ffd6
TT
12512018-05-04 Tom Tromey <tom@tromey.com>
1252
1253 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
1254 Add missing "break".
1255 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
1256 Add missing "break".
1257
e3829d13
TT
12582018-05-04 Tom Tromey <tom@tromey.com>
1259
1260 * rs6000-tdep.c (ppc_process_record_op4)
1261 (ppc_process_record_op63): Add fall-through comment.
1262
da0e1563
TT
12632018-05-04 Tom Tromey <tom@tromey.com>
1264
1265 * i386-tdep.c (i386_process_record): Add fall-through comment.
1266
0019cd49
TT
12672018-05-04 Tom Tromey <tom@tromey.com>
1268
1269 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
1270 comment.
1271
565e0eda
TT
12722018-05-04 Tom Tromey <tom@tromey.com>
1273
1274 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
1275 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
1276 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
1277 comment.
1278 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
1279 comment.
1280 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
1281 comment.
1282
621846f4
TT
12832018-05-04 Tom Tromey <tom@tromey.com>
1284
1285 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
1286
86a73007
TT
12872018-05-04 Tom Tromey <tom@tromey.com>
1288
1289 * s390-tdep.c (s390_process_record): Fix fall-through comments.
1290 * xcoffread.c (scan_xcoff_symtab): Move comment later.
1291 * symfile.c (section_is_mapped): Fix fall-through comment.
1292 * stabsread.c (define_symbol, read_member_functions): Fix
1293 fall-through comment.
1294 * s390-linux-tdep.c (s390_process_record): Fix fall-through
1295 comment.
1296 * remote.c (remote_wait_as): Fix fall-through comment.
1297 * p-exp.y (yylex): Fix fall-through comment.
1298 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
1299 comment.
1300 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
1301 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
1302 * jv-exp.y (yylex): Fix fall-through comment.
1303 * go-exp.y (lex_one_token): Fix fall-through comment.
1304 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
1305 fall-through comment.
1306 * f-exp.y (yylex): Fix fall-through comment.
1307 * dwarf2read.c (process_die): Fix fall-through comments.
1308 * dbxread.c (process_one_symbol): Fix fall-through comment.
1309 * d-exp.y (lex_one_token): Fix fall-through comment.
1310 * cp-name-parser.y (yylex): Fix fall-through comment.
1311 * coffread.c (coff_symtab_read): Fix fall-through comment.
1312 * c-exp.y (lex_one_token): Fix fall-through comment.
1313 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
1314 comment.
1315 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
1316 comment.
1317
56bcdbea
TT
13182018-05-04 Tom Tromey <tom@tromey.com>
1319
1320 PR python/22730:
1321 * NEWS: Mention gdb.execute change.
1322 * gdbcmd.h (execute_control_command): Don't declare.
1323 * python/python.c (execute_gdb_command): Use read_command_lines_1,
1324 execute_control_commands, execute_control_commands_to_string.
1325 * cli/cli-script.h (execute_control_commands)
1326 (execute_control_commands_to_string): Declare.
1327 (execute_control_command): Add from_tty parameter.
1328 * cli/cli-script.c (execute_control_commands)
1329 (execute_control_commands_to_string): New functions.
1330 (execute_user_command): Use execute_control_commands.
1331 (execute_control_command_1): Add "from_tty" parameter. Update.
1332 (execute_control_command): Likewise.
1333
a913fffb
TT
13342018-05-04 Tom Tromey <tom@tromey.com>
1335
1336 PR python/22731:
1337 * NEWS: Mention that breakpoint commands are writable.
1338 * python/py-breakpoint.c (bppy_set_commands): New function.
1339 (breakpoint_object_getset) <"commands">: Use it.
1340
60b3cef2
TT
13412018-05-04 Tom Tromey <tom@tromey.com>
1342
1343 * tracepoint.c (actions_command): Update.
1344 * mi/mi-cmd-break.c (mi_command_line_array)
1345 (mi_command_line_array_cnt, mi_command_line_array_ptr)
1346 (mi_read_next_line): Remove.
1347 (mi_cmd_break_commands): Update.
1348 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
1349 function_view.
1350 * cli/cli-script.c (get_command_line): Update.
1351 (process_next_line): Use function_view. Constify.
1352 (recurse_read_control_structure, read_command_lines)
1353 (read_command_lines_1): Change argument types to function_view.
1354 (do_define_command, document_command): Update.
1355 * breakpoint.h (check_tracepoint_command): Don't declare.
1356 * breakpoint.c (check_tracepoint_command): Remove.
1357 (commands_command_1, create_tracepoint_from_upload): Update.
1358
7a2c85f2
TT
13592018-05-04 Tom Tromey <tom@tromey.com>
1360
1361 PR gdb/11750:
1362 * cli/cli-script.h (enum command_control_type) <define_control>:
1363 New constant.
1364 * cli/cli-script.c (multi_line_command_p): Handle define_control.
1365 (build_command_line, execute_control_command_1)
1366 (process_next_line): Likewise.
1367 (do_define_command): New function, extracted from define_command.
1368 (define_command): Use it.
1369
295dc222
TT
13702018-05-04 Tom Tromey <tom@tromey.com>
1371
1372 * tracepoint.c (actions_command): Update.
1373 * cli/cli-script.h (read_command_lines): Update.
1374 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
1375 (MAX_TMPBUF): Remove define.
1376 (define_command): Use string_printf.
1377 (document_command): Likewise.
1378 * breakpoint.c (commands_command_1): Update.
1379
1263a9d5
TT
13802018-05-04 Tom Tromey <tom@tromey.com>
1381
1382 * top.c (execute_command): Update.
1383 * cli/cli-script.h (print_command_lines): Now varargs.
1384 * cli/cli-script.c (print_command_lines): Now varargs.
1385 (execute_control_command_1) <case while_control, case if_control>:
1386 Update.
1387
12973681
TT
13882018-05-04 Tom Tromey <tom@tromey.com>
1389
1390 * tracepoint.c (all_tracepoint_actions): Rename from
1391 all_tracepoint_actions_and_cleanup. Change return type.
1392 (actions_command, encode_actions_1, encode_actions)
1393 (trace_dump_actions, tdump_command): Update.
1394 * remote.c (remote_download_command_source): Update.
1395 * python/python.c (gdbpy_eval_from_control_command)
1396 (python_command, python_interactive_command): Update.
1397 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
1398 * guile/guile.c (guile_command)
1399 (gdbscm_eval_from_control_command, guile_command): Update.
1400 * compile/compile.c (compile_code_command)
1401 (compile_print_command, compile_to_object): Update.
1402 * cli/cli-script.h (struct command_lines_deleter): New.
1403 (counted_command_line): New typedef.
1404 (struct command_line): Add constructor, destructor.
1405 <body_list>: Remove.
1406 <body_list_0, body_list_1>: New members.
1407 (command_line_up): Remove typedef.
1408 (read_command_lines, read_command_lines_1, get_command_line):
1409 Update.
1410 (copy_command_lines): Don't declare.
1411 * cli/cli-script.c (build_command_line): Use "new".
1412 (get_command_line): Return counted_command_line.
1413 (print_command_lines, execute_user_command)
1414 (execute_control_command_1, while_command, if_command): Update.
1415 (realloc_body_list): Remove.
1416 (process_next_line, recurse_read_control_structure): Update.
1417 (read_command_lines, read_command_lines_1): Return counted_command_line.
1418 (free_command_lines): Use "delete".
1419 (copy_command_lines): Remove.
1420 (define_command, document_command, show_user_1): Update.
1421 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
1422 a counted_command_line.
1423 * breakpoint.h (counted_command_line): Remove typedef.
1424 (breakpoint_set_commands): Update.
1425 * breakpoint.c (check_no_tracepoint_commands)
1426 (validate_commands_for_breakpoint): Update.
1427 (breakpoint_set_commands): Change commands to be a
1428 counted_command_line.
1429 (commands_command_1, update_dprintf_command_list)
1430 (create_tracepoint_from_upload): Update.
1431
e2fc72e2
TT
14322018-05-04 Tom Tromey <tom@tromey.com>
1433
1434 * cli/cli-decode.h (cmd_list_element): New constructor.
1435 (~cmd_list_element): New destructor.
1436 (struct cmd_list_element): Add initializers.
1437 * cli/cli-decode.c (do_add_cmd): Use "new".
1438 (delete_cmd): Use "delete".
1439
a3b60e45
JK
14402018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1441 Pedro Alves <palves@redhat.com>
1442
1443 PR breakpoints/19806 and support for PR external/20207.
1444 * NEWS: Mention Aarch64 watchpoint improvements.
1445 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
1446 watchpoints and PR external/20207 watchpoints.
1447 * nat/aarch64-linux-hw-point.c
1448 (kernel_supports_any_contiguous_range): New.
1449 (aarch64_watchpoint_offset): New.
1450 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
1451 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
1452 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
1453 (aarch64_align_watchpoint): New parameters aligned_offset_p and
1454 next_addr_orig_p. Support PR external/20207 watchpoints.
1455 (aarch64_downgrade_regs): New.
1456 (aarch64_dr_state_insert_one_point): New parameters offset and
1457 addr_orig.
1458 (aarch64_dr_state_remove_one_point): Likewise.
1459 (aarch64_handle_breakpoint): Update caller.
1460 (aarch64_handle_aligned_watchpoint): Likewise.
1461 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
1462 aligned_offset.
1463 (aarch64_linux_set_debug_regs): Remove const from state. Call
1464 aarch64_downgrade_regs.
1465 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
1466 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
1467 (DR_CONTROL_MASK): ... this.
1468 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
1469 (unsigned int aarch64_watchpoint_offset): New prototype.
1470 (aarch64_linux_set_debug_regs): Remove const from state.
1471 * utils.c (align_up, align_down): Move to ...
1472 * common/common-utils.c (align_up, align_down): ... here.
1473 * utils.h (align_up, align_down): Move to ...
1474 * common/common-utils.h (align_up, align_down): ... here.
1475
05bc7456
JB
14762018-05-04 Joel Brobecker <brobecker@adacore.com>
1477
1478 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
1479 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
1480 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
1481 Re-implement to match the ABI as summarized in GCC's
1482 gcc/config/sparc/sparc.c. All callers updated.
1483 (sparc32_store_arguments): Remove assertion.
1484
2f433492
TT
14852018-05-04 Tom Tromey <tom@tromey.com>
1486
1487 * printcmd.c: Don't include tui.h.
1488 (decode_format): Use skip_spaces.
1489
9be2ae8f
TT
14902018-05-04 Tom Tromey <tom@tromey.com>
1491
1492 PR gdb/22619:
1493 * printcmd.c (last_count): New global.
1494 (x_command): Use saved count when repeating.
1495
f0b3976b
TT
14962018-05-04 Tom Tromey <tom@tromey.com>
1497
1498 * nto-procfs.c (do_closedir_cleanup): Remove.
1499 (procfs_pidlist): Use gdb_dir_up.
1500 * procfs.c (do_closedir_cleanup): Remove.
1501 (proc_update_threads): Use gdb_dir_up.
1502 * common/filestuff.h (struct gdb_dir_deleter): New.
1503 (gdb_dir_up): New typedef.
1504
862d101a
TT
15052018-05-04 Tom Tromey <tom@tromey.com>
1506
1507 * ada-lang.c (print_mention_exception): Use std::string.
1508
cb7de75e
TT
15092018-05-04 Tom Tromey <tom@tromey.com>
1510
1511 * ada-lang.c (create_excep_cond_exprs): Update.
1512 (ada_exception_catchpoint_cond_string): Use std::string.
1513
49d83361
TT
15142018-05-04 Tom Tromey <tom@tromey.com>
1515
1516 * ada-lang.c (xget_renaming_scope): Return std::string.
1517 (old_renaming_is_invisible): Update.
1518
ade72a34
TT
15192018-05-04 Tom Tromey <tom@tromey.com>
1520
1521 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
1522 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
1523
2be4d7f0
UW
15242018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
1525
1526 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
1527
69b6ecb0
TT
15282018-05-04 Tom Tromey <tom@tromey.com>
1529
1530 * remote.c (remote_query_supported_append): Change type.
1531 (remote_check_symbols): Update.
1532
bf27f0e2
PP
15332018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
1534
1535 PR gdb/11420
1536 * configure.ac: Prepend libpython.
1537 * python/python-config.py: Likewise.
1538 * configure: Regenerate.
1539
4ea17de8
SM
15402018-05-03 Simon Marchi <simon.marchi@ericsson.com>
1541
1542 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
1543
bd732259
PA
15442018-05-03 Pedro Alves <palves@redhat.com>
1545
1546 * s390-linux-nat.c
1547 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
1548 override. Write 'true' instead of '1'.
1549 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
1550 declaration.
1551
d9f719f1
PA
15522018-05-02 Pedro Alves <palves@redhat.com>
1553
1554 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
1555 add_inf_child_target.
1556 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
1557 add_inf_child_target.
1558 * aix-thread.c (aix_thread_target_info): New.
1559 (aix_thread_target) <shortname, longname, doc>: Delete.
1560 <info>: New.
1561 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
1562 add_inf_child_target.
1563 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
1564 add_inf_child_target.
1565 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
1566 add_inf_child_target.
1567 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
1568 add_inf_child_target.
1569 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
1570 add_inf_child_target.
1571 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
1572 add_inf_child_target.
1573 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
1574 add_inf_child_target.
1575 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
1576 add_inf_child_target.
1577 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
1578 add_inf_child_target.
1579 * bfd-target.c (target_bfd_target_info): New.
1580 (target_bfd) <shortname, longname, doc>: Delete.
1581 <info>: New.
1582 * bsd-kvm.c (bsd_kvm_target_info): New.
1583 (bsd_kvm_target) <shortname, longname, doc>: Delete.
1584 <info>: New.
1585 (bsd_kvm_target::open): Rename to ...
1586 (bsd_kvm_target_open): ... this. Adjust.
1587 * bsd-uthread.c (bsd_uthread_target_info): New.
1588 (bsd_uthread_target) <shortname, longname, doc>: Delete.
1589 <info>: New.
1590 * corefile.c (core_file_command): Adjust.
1591 * corelow.c (core_target_info): New.
1592 (core_target) <shortname, longname, doc>: Delete.
1593 <info>: New.
1594 (core_target::open): Rename to ...
1595 (core_target_open): ... this. Adjust.
1596 * ctf.c (ctf_target_info): New.
1597 (ctf_target) <shortname, longname, doc>: Delete.
1598 <info>: New.
1599 (ctf_target::open): Rename to ...
1600 (ctf_target_open): ... this.
1601 (_initialize_ctf): Adjust.
1602 * exec.c (exec_target_info): New.
1603 (exec_target) <shortname, longname, doc>: Delete.
1604 <info>: New.
1605 (exec_target::open): Rename to ...
1606 (exec_target_open): ... this.
1607 * gdbcore.h (core_target_open): Declare.
1608 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
1609 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
1610 add_inf_child_target.
1611 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
1612 add_inf_child_target.
1613 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
1614 add_inf_child_target.
1615 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
1616 add_inf_child_target.
1617 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
1618 add_inf_child_target.
1619 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
1620 add_inf_child_target.
1621 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
1622 add_inf_child_target.
1623 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
1624 add_inf_child_target.
1625 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
1626 add_inf_child_target.
1627 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
1628 add_inf_child_target.
1629 * inf-child.c (inf_child_target_info): New.
1630 (inf_child_target::info): New.
1631 (inf_child_open_target): Remove 'target' parameter. Use
1632 get_native_target instead.
1633 (inf_child_target::open): Delete.
1634 (add_inf_child_target): New.
1635 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
1636 Delete.
1637 <info>: New.
1638 (add_inf_child_target): Declare.
1639 (inf_child_open_target): Declare.
1640 * linux-thread-db.c (thread_db_target_info): New.
1641 (thread_db_target) <shortname, longname, doc>: Delete.
1642 <info>: New.
1643 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
1644 add_inf_child_target.
1645 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
1646 add_inf_child_target.
1647 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
1648 add_inf_child_target.
1649 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
1650 add_inf_child_target.
1651 * make-target-delegates (print_class): Adjust.
1652 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
1653 add_inf_child_target.
1654 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
1655 add_inf_child_target.
1656 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
1657 add_inf_child_target.
1658 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
1659 add_inf_child_target.
1660 * nto-procfs.c (nto_native_target_info): New.
1661 (nto_procfs_target_native) <shortname, longname, doc>:
1662 Delete.
1663 <info>: New.
1664 (nto_procfs_target_info): New.
1665 (nto_procfs_target_procfs) <shortname, longname, doc>:
1666 Delete.
1667 <info>: New.
1668 (init_procfs_targets): Adjust.
1669 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
1670 add_inf_child_target.
1671 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
1672 add_inf_child_target.
1673 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
1674 add_inf_child_target.
1675 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
1676 add_inf_child_target.
1677 * ravenscar-thread.c (ravenscar_target_info): New.
1678 (ravenscar_thread_target) <shortname, longname, doc>:
1679 Delete.
1680 <info>: New.
1681 * record-btrace.c (record_btrace_target_info):
1682 (record_btrace_target) <shortname, longname, doc>: Delete.
1683 <info>: New.
1684 (record_btrace_target::open): Rename to ...
1685 (record_btrace_target_open): ... this. Adjust.
1686 * record-full.c (record_longname, record_doc): New.
1687 (record_full_base_target) <shortname, longname, doc>: Delete.
1688 <info>: New.
1689 (record_full_target_info): New.
1690 (record_full_target): <shortname>: Delete.
1691 <info>: New.
1692 (record_full_core_open_1, record_full_open_1): Update comments.
1693 (record_full_base_target::open): Rename to ...
1694 (record_full_open): ... this.
1695 (cmd_record_full_restore): Update.
1696 (_initialize_record_full): Update.
1697 * remote-sim.c (remote_sim_target_info): New.
1698 (gdbsim_target) <shortname, longname, doc>: Delete.
1699 <info>: New.
1700 (gdbsim_target::open): Rename to ...
1701 (gdbsim_target_open): ... this.
1702 (_initialize_remote_sim): Adjust.
1703 * remote.c (remote_doc): New.
1704 (remote_target_info): New.
1705 (remote_target) <shortname, longname, doc>: Delete.
1706 <info>: New.
1707 (extended_remote_target_info): New.
1708 (extended_remote_target) <shortname, longname, doc>: Delete.
1709 <info>: New.
1710 (remote_target::open_1): Make static. Adjust.
1711 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
1712 * s390-linux-nat.c (_initialize_s390_nat): Use
1713 add_inf_child_target.
1714 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
1715 add_inf_child_target.
1716 * sol-thread.c (thread_db_target_info): New.
1717 (sol_thread_target) <shortname, longname, doc>: Delete.
1718 <info>: New.
1719 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
1720 add_inf_child_target.
1721 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
1722 add_inf_child_target.
1723 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
1724 add_inf_child_target.
1725 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
1726 add_inf_child_target.
1727 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
1728 add_inf_child_target.
1729 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
1730 add_inf_child_target.
1731 * spu-linux-nat.c (_initialize_spu_nat): Use
1732 add_inf_child_target.
1733 * spu-multiarch.c (spu_multiarch_target_info): New.
1734 (spu_multiarch_target) <shortname, longname, doc>: Delete.
1735 <info>: New.
1736 * target-delegates.c: Regenerate.
1737 * target.c: Include <unordered_map>.
1738 (target_ops_p): Delete.
1739 (DEF_VEC_P(target_ops_p)): Delete.
1740 (target_factories): New.
1741 (test_target_info): New.
1742 (test_target_ops::info): New.
1743 (open_target): Adjust to use target_factories.
1744 (add_target_with_completer): Rename to ...
1745 (add_target): ... this. Change prototype. Register target_info
1746 and open callback in target_factories. Register target_info in
1747 command context instead of target_ops.
1748 (add_target): Delete old implementation.
1749 (add_deprecated_target_alias): Change prototype. Adjust.
1750 (the_native_target): New.
1751 (set_native_target, get_native_target): New.
1752 (find_default_run_target): Use the_native_target.
1753 (find_attach_target, find_run_target): Simplify.
1754 (target_ops::open): Delete.
1755 (dummy_target_info): New.
1756 (dummy_target::shortname, dummy_target::longname)
1757 (dummy_target::doc): Delete.
1758 (dummy_target::info): New.
1759 (debug_target::shortname, debug_target::longname)
1760 (debug_target::doc): Delete.
1761 (debug_target::info): New.
1762 * target.h (struct target_info): New.
1763 (target_ops::~target_ops): Add comment.
1764 (target_ops::info): New.
1765 (target_ops::shortname, target_ops::longname, target_ops::doc): No
1766 longer virtual. Implement in terms of target_info.
1767 (set_native_target, get_native_target): Declare.
1768 (target_open_ftype): New.
1769 (add_target, add_target_with_completer)
1770 (add_deprecated_target_alias): Change prototype.
1771 (test_target) <shortname, longname, doc>: Delete.
1772 <info>: New.
1773 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
1774 add_inf_child_target.
1775 * tracefile-tfile.c (tfile_target_info): New.
1776 (tfile_target) <shortname, longname, doc>: Delete.
1777 <info>: New.
1778 (tfile_target::open): Rename to ...
1779 (tfile_target_open): ... this.
1780 (_initialize_tracefile_tfile): Adjust.
1781 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
1782 add_inf_child_target.
1783 * windows-nat.c (_initialize_windows_nat): Use
1784 add_inf_child_target.
1785 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
1786 add_inf_child_target.
1787
135340af
PA
17882018-05-02 Pedro Alves <palves@redhat.com>
1789
1790 * linux-nat.h (linux_nat_target) <low_new_thread,
1791 low_delete_thread, low_new_fork, low_forget_process,
1792 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
1793 New virtual methods.
1794 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
1795 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
1796 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
1797 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
1798 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
1799 Delete.
1800 * linux-fork.c (delete_fork): Adjust to call low method.
1801 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
1802 (linux_nat_new_fork, linux_nat_forget_process_hook)
1803 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
1804 (linux_nat_status_is_event):
1805 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
1806 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
1807 to call low method.
1808 (sigtrap_is_event): Rename to ...
1809 (linux_nat_target::low_status_is_event): ... this.
1810 (linux_nat_set_status_is_event): Delete.
1811 (save_stop_reason, linux_nat_wait_1)
1812 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
1813 low methods.
1814 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
1815 (linux_nat_set_new_fork, linux_nat_set_forget_process)
1816 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
1817 (linux_nat_set_prepare_to_resume): Delete.
1818 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
1819 low virtual methods.
1820 * amd64-linux-nat.c: Likewise.
1821 * arm-linux-nat.c: Likewise.
1822 * i386-linux-nat.c: Likewise.
1823 * ia64-linux-nat.c: Likewise.
1824 * mips-linux-nat.c: Likewise.
1825 * ppc-linux-nat.c: Likewise.
1826 * s390-linux-nat.c: Likewise.
1827 * sparc64-linux-nat.c: Likewise.
1828 * x86-linux-nat.c: Likewise.
1829 * x86-linux-nat.h: Include "nat/x86-linux.h".
1830 (x86_linux_nat_target) <low_new_fork, low_forget_process,
1831 low_prepare_to_resume, low_new_thread, low_delete_thread>:
1832 Override methods.
1833
57810aa7
PA
18342018-05-02 Pedro Alves <palves@redhat.com>
1835
1836 * target.h (target_ops)
1837 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
1838 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
1839 stopped_by_watchpoint, have_continuable_watchpoint,
1840 stopped_data_address, watchpoint_addr_within_range,
1841 can_accel_watchpoint_condition, can_run, thread_alive,
1842 has_all_memory, has_memory, has_stack, has_registers,
1843 has_execution, can_async_p, is_async_p, supports_non_stop,
1844 always_non_stop_p, can_execute_reverse, supports_multi_process,
1845 supports_enable_disable_tracepoint,
1846 supports_disable_randomization, supports_string_tracing,
1847 supports_evaluation_of_breakpoint_conditions,
1848 can_run_breakpoint_commands, filesystem_is_local,
1849 can_download_tracepoint, get_trace_state_variable_value,
1850 set_trace_notes, get_tib_address, use_agent, can_use_agent,
1851 record_is_replaying, record_will_replay,
1852 augmented_libraries_svr4_read>: Adjust to return bool.
1853 * aarch64-linux-nat.c: All implementations adjusted.
1854 * aix-thread.c: All implementations adjusted.
1855 * arm-linux-nat.c: All implementations adjusted.
1856 * breakpoint.c: All implementations adjusted.
1857 * bsd-kvm.c: All implementations adjusted.
1858 * bsd-uthread.c: All implementations adjusted.
1859 * corelow.c: All implementations adjusted.
1860 * ctf.c: All implementations adjusted.
1861 * darwin-nat.c: All implementations adjusted.
1862 * darwin-nat.h: All implementations adjusted.
1863 * exec.c: All implementations adjusted.
1864 * fbsd-nat.c: All implementations adjusted.
1865 * fbsd-nat.h: All implementations adjusted.
1866 * gnu-nat.c: All implementations adjusted.
1867 * gnu-nat.h: All implementations adjusted.
1868 * go32-nat.c: All implementations adjusted.
1869 * ia64-linux-nat.c: All implementations adjusted.
1870 * inf-child.c: All implementations adjusted.
1871 * inf-child.h: All implementations adjusted.
1872 * inf-ptrace.c: All implementations adjusted.
1873 * inf-ptrace.h: All implementations adjusted.
1874 * linux-nat.c: All implementations adjusted.
1875 * linux-nat.h: All implementations adjusted.
1876 * mips-linux-nat.c: All implementations adjusted.
1877 * nto-procfs.c: All implementations adjusted.
1878 * ppc-linux-nat.c: All implementations adjusted.
1879 * procfs.c: All implementations adjusted.
1880 * ravenscar-thread.c: All implementations adjusted.
1881 * record-btrace.c: All implementations adjusted.
1882 * record-full.c: All implementations adjusted.
1883 * remote-sim.c: All implementations adjusted.
1884 * remote.c: All implementations adjusted.
1885 * s390-linux-nat.c: All implementations adjusted.
1886 * sol-thread.c: All implementations adjusted.
1887 * spu-multiarch.c: All implementations adjusted.
1888 * target-delegates.c: All implementations adjusted.
1889 * target.c: All implementations adjusted.
1890 * target.h: All implementations adjusted.
1891 * tracefile-tfile.c: All implementations adjusted.
1892 * tracefile.c: All implementations adjusted.
1893 * tracefile.h: All implementations adjusted.
1894 * windows-nat.c: All implementations adjusted.
1895 * x86-linux-nat.h: All implementations adjusted.
1896 * x86-nat.h: All implementations adjusted.
1897
ad6a4e2d
PA
18982018-05-02 Pedro Alves <palves@redhat.com>
1899
1900 * make-target-delegates (scan_target_h): Don't trim lines here.
1901 Replace sequences of tabs and/or whitespace with a single
1902 whitespace.
1903 (top level, parsing methods): Trim each line before processing it
1904 here.
1905
f6ac5f3d
PA
19062018-05-02 Pedro Alves <palves@redhat.com>
1907 John Baldwin <jhb@freebsd.org>
1908
1909 * target.h (enum strata) <debug_stratum>: New.
1910 (struct target_ops) <all delegation methods>: Replace by C++
1911 virtual methods, and drop "to_" prefix. All references updated
1912 throughout.
1913 <to_shortname, to_longname, to_doc, to_data,
1914 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
1915 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
1916 virtual methods. All references updated throughout.
1917 <can_attach, supports_terminal_ours, can_create_inferior,
1918 get_thread_control_capabilities, attach_no_wait>: New
1919 virtual methods.
1920 <insert_breakpoint, remove_breakpoint>: Now
1921 TARGET_DEFAULT_NORETURN methods.
1922 <info_proc>: Now returns bool.
1923 <to_magic>: Delete.
1924 (OPS_MAGIC): Delete.
1925 (current_target): Delete. All references replaced by references
1926 to ...
1927 (target_stack): ... this. New.
1928 (target_shortname, target_longname): Adjust.
1929 (target_can_run): Now a function declaration.
1930 (default_child_has_all_memory, default_child_has_memory)
1931 (default_child_has_stack, default_child_has_registers)
1932 (default_child_has_execution): Remove target_ops parameter.
1933 (complete_target_initialization): Delete.
1934 (memory_breakpoint_target): New template class.
1935 (test_target_ops): Refactor as a C++ class with virtual methods.
1936 * make-target-delegates (NAME_PART): Tighten.
1937 (POINTER_PART, CP_SYMBOL): New.
1938 (SIMPLE_RETURN_PART): Reimplement.
1939 (VEC_RETURN_PART): Expect less.
1940 (RETURN_PART, VIRTUAL_PART): New.
1941 (METHOD): Adjust to C++ virtual methods.
1942 (scan_target_h): Remove reference to C99.
1943 (dname): Output "target_ops::" prefix.
1944 (write_function_header): Adjust to output a C++ class method.
1945 (write_declaration): New.
1946 (write_delegator): Adjust to output a C++ class method.
1947 (tdname): Output "dummy_target::" prefix.
1948 (write_tdefault, write_debugmethod): Adjust to output a C++ class
1949 method.
1950 (tdefault_names, debug_names): Delete.
1951 (return_types, tdefaults, styles, argtypes_array): New.
1952 (top level): All methods are delegators.
1953 (print_class): New.
1954 (top level): Print dummy_target and debug_target classes.
1955 * target-delegates.c: Regenerate.
1956 * target-debug.h (target_debug_print_enum_info_proc_what)
1957 (target_debug_print_thread_control_capabilities)
1958 (target_debug_print_thread_info_p): New.
1959 * target.c (dummy_target): Delete.
1960 (the_dummy_target, the_debug_target): New.
1961 (target_stack): Now extern.
1962 (set_targetdebug): Push/unpush debug target.
1963 (default_child_has_all_memory, default_child_has_memory)
1964 (default_child_has_stack, default_child_has_registers)
1965 (default_child_has_execution): Remove target_ops parameter.
1966 (complete_target_initialization): Delete.
1967 (add_target_with_completer): No longer call
1968 complete_target_initialization.
1969 (target_supports_terminal_ours): Use regular delegation.
1970 (update_current_target): Delete.
1971 (push_target): No longer check magic number. Don't call
1972 update_current_target.
1973 (unpush_target): Don't call update_current_target.
1974 (target_is_pushed): No longer check magic number.
1975 (target_require_runnable): Skip for all stratums over
1976 process_stratum.
1977 (target_ops::info_proc): New.
1978 (target_info_proc): Use find_target_at and
1979 find_default_run_target.
1980 (target_supports_disable_randomization): Use regular delegation.
1981 (target_get_osdata): Use find_target_at.
1982 (target_ops::open, target_ops::close, target_ops::can_attach)
1983 (target_ops::attach, target_ops::can_create_inferior)
1984 (target_ops::create_inferior, target_ops::can_run)
1985 (target_can_run): New.
1986 (default_fileio_target): Use regular delegation.
1987 (target_ops::fileio_open, target_ops::fileio_pwrite)
1988 (target_ops::fileio_pread, target_ops::fileio_fstat)
1989 (target_ops::fileio_close, target_ops::fileio_unlink)
1990 (target_ops::fileio_readlink): New.
1991 (target_fileio_open_1, target_fileio_unlink)
1992 (target_fileio_readlink): Always call the target method. Handle
1993 FILEIO_ENOSYS.
1994 (return_zero, return_zero_has_execution): Delete.
1995 (init_dummy_target): Delete.
1996 (dummy_target::dummy_target, dummy_target::shortname)
1997 (dummy_target::longname, dummy_target::doc)
1998 (debug_target::debug_target, debug_target::shortname)
1999 (debug_target::longname, debug_target::doc): New.
2000 (target_supports_delete_record): Use regular delegation.
2001 (setup_target_debug): Delete.
2002 (maintenance_print_target_stack): Skip debug_stratum.
2003 (initialize_targets): Instantiate the_dummy_target and
2004 the_debug_target.
2005 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
2006 use target_stack.
2007 (target_auxv_search, fprint_target_auxv): Adjust.
2008 (info_auxv_command): Adjust to use target_stack.
2009 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
2010 * exceptions.c (print_flush): Handle a NULL target_stack.
2011 * regcache.c (target_ops_no_register): Refactor as class with
2012 virtual methods.
2013
2014 * exec.c (exec_target): New class.
2015 (exec_ops): Now an exec_target.
2016 (exec_open, exec_close_1, exec_get_section_table)
2017 (exec_xfer_partial, exec_files_info, exec_has_memory)
2018 (exec_make_note_section): Refactor as exec_target methods.
2019 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
2020 Delete.
2021 (exec_target::find_memory_regions): New.
2022 (_initialize_exec): Don't call init_exec_ops.
2023 * gdbcore.h (exec_file_clear): Delete.
2024
2025 * corefile.c (core_target): Delete.
2026 (core_file_command): Adjust.
2027 * corelow.c (core_target): New class.
2028 (the_core_target): New.
2029 (core_close): Remove target_ops parameter.
2030 (core_close_cleanup): Adjust.
2031 (core_target::close): New.
2032 (core_open, core_detach, get_core_registers, core_files_info)
2033 (core_xfer_partial, core_thread_alive, core_read_description)
2034 (core_pid_to_str, core_thread_name, core_has_memory)
2035 (core_has_stack, core_has_registers, core_info_proc): Rework as
2036 core_target methods.
2037 (ignore, core_remove_breakpoint, init_core_ops): Delete.
2038 (_initialize_corelow): Initialize the_core_target.
2039 * gdbcore.h (core_target): Delete.
2040 (the_core_target): New.
2041
2042 * ctf.c: (ctf_target): New class.
2043 (ctf_ops): Now a ctf_target.
2044 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
2045 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
2046 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
2047 methods.
2048 (init_ctf_ops): Delete.
2049 (_initialize_ctf): Don't call it.
2050 * tracefile-tfile.c (tfile_target): New class.
2051 (tfile_ops): Now a tfile_target.
2052 (tfile_open, tfile_close, tfile_files_info)
2053 (tfile_get_tracepoint_status, tfile_trace_find)
2054 (tfile_fetch_registers, tfile_xfer_partial)
2055 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
2056 Refactor as tfile_target methods.
2057 (tfile_xfer_partial_features): Remove target_ops parameter.
2058 (init_tfile_ops): Delete.
2059 (_initialize_tracefile_tfile): Don't call it.
2060 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
2061 (tracefile_has_stack, tracefile_has_registers)
2062 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
2063 tracefile_target methods.
2064 (init_tracefile_ops): Delete.
2065 (tracefile_target::tracefile_target): New.
2066 * tracefile.h: Include "target.h".
2067 (tracefile_target): New class.
2068 (init_tracefile_ops): Delete.
2069
2070 * spu-multiarch.c (spu_multiarch_target): New class.
2071 (spu_ops): Now a spu_multiarch_target.
2072 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
2073 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
2074 (spu_search_memory, spu_mourn_inferior): Refactor as
2075 spu_multiarch_target methods.
2076 (init_spu_ops): Delete.
2077 (_initialize_spu_multiarch): Remove references to init_spu_ops,
2078 complete_target_initialization.
2079
2080 * ravenscar-thread.c (ravenscar_thread_target): New class.
2081 (ravenscar_ops): Now a ravenscar_thread_target.
2082 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
2083 (ravenscar_thread_alive, ravenscar_pid_to_str)
2084 (ravenscar_fetch_registers, ravenscar_store_registers)
2085 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
2086 (ravenscar_stopped_by_hw_breakpoint)
2087 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
2088 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
2089 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
2090 methods.
2091 (init_ravenscar_thread_ops): Delete.
2092 (_initialize_ravenscar): Remove references to
2093 init_ravenscar_thread_ops and complete_target_initialization.
2094
2095 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
2096 (bsd_uthread_target): New class.
2097 (bsd_uthread_ops): Now a bsd_uthread_target.
2098 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
2099 (bsd_uthread_close, bsd_uthread_mourn_inferior)
2100 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
2101 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
2102 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
2103 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
2104 (bsd_uthread_target): Delete function.
2105 (_initialize_bsd_uthread): Remove reference to
2106 complete_target_initialization.
2107
2108 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
2109 (target_bfd): ... this new class.
2110 (target_bfd_xfer_partial, target_bfd_get_section_table)
2111 (target_bfd_close): Refactor as target_bfd methods.
2112 (target_bfd::~target_bfd): New.
2113 (target_bfd_reopen): Adjust.
2114 (target_bfd::close): New.
2115
2116 * record-btrace.c (record_btrace_target): New class.
2117 (record_btrace_ops): Now a record_btrace_target.
2118 (record_btrace_open, record_btrace_stop_recording)
2119 (record_btrace_disconnect, record_btrace_close)
2120 (record_btrace_async, record_btrace_info)
2121 (record_btrace_insn_history, record_btrace_insn_history_range)
2122 (record_btrace_insn_history_from, record_btrace_call_history)
2123 (record_btrace_call_history_range)
2124 (record_btrace_call_history_from, record_btrace_record_method)
2125 (record_btrace_is_replaying, record_btrace_will_replay)
2126 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
2127 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
2128 (record_btrace_store_registers, record_btrace_prepare_to_store)
2129 (record_btrace_to_get_unwinder)
2130 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
2131 (record_btrace_commit_resume, record_btrace_wait)
2132 (record_btrace_stop, record_btrace_can_execute_reverse)
2133 (record_btrace_stopped_by_sw_breakpoint)
2134 (record_btrace_supports_stopped_by_sw_breakpoint)
2135 (record_btrace_stopped_by_hw_breakpoint)
2136 (record_btrace_supports_stopped_by_hw_breakpoint)
2137 (record_btrace_update_thread_list, record_btrace_thread_alive)
2138 (record_btrace_goto_begin, record_btrace_goto_end)
2139 (record_btrace_goto, record_btrace_stop_replaying_all)
2140 (record_btrace_execution_direction)
2141 (record_btrace_prepare_to_generate_core)
2142 (record_btrace_done_generating_core): Refactor as
2143 record_btrace_target methods.
2144 (init_record_btrace_ops): Delete.
2145 (_initialize_record_btrace): Remove reference to
2146 init_record_btrace_ops.
2147 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
2148 the execution_direction global.
2149 (record_full_base_target, record_full_target)
2150 (record_full_core_target): New classes.
2151 (record_full_ops): Now a record_full_target.
2152 (record_full_core_ops): Now a record_full_core_target.
2153 (record_full_target::detach, record_full_target::disconnect)
2154 (record_full_core_target::disconnect)
2155 (record_full_target::mourn_inferior, record_full_target::kill):
2156 New.
2157 (record_full_open, record_full_close, record_full_async): Refactor
2158 as methods of the record_full_base_target class.
2159 (record_full_resume, record_full_commit_resume): Refactor
2160 as methods of the record_full_target class.
2161 (record_full_wait, record_full_stopped_by_watchpoint)
2162 (record_full_stopped_data_address)
2163 (record_full_stopped_by_sw_breakpoint)
2164 (record_full_supports_stopped_by_sw_breakpoint)
2165 (record_full_stopped_by_hw_breakpoint)
2166 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
2167 methods of the record_full_base_target class.
2168 (record_full_store_registers, record_full_xfer_partial)
2169 (record_full_insert_breakpoint, record_full_remove_breakpoint):
2170 Refactor as methods of the record_full_target class.
2171 (record_full_can_execute_reverse, record_full_get_bookmark)
2172 (record_full_goto_bookmark, record_full_execution_direction)
2173 (record_full_record_method, record_full_info, record_full_delete)
2174 (record_full_is_replaying, record_full_will_replay)
2175 (record_full_goto_begin, record_full_goto_end, record_full_goto)
2176 (record_full_stop_replaying): Refactor as methods of the
2177 record_full_base_target class.
2178 (record_full_core_resume, record_full_core_kill)
2179 (record_full_core_fetch_registers)
2180 (record_full_core_prepare_to_store)
2181 (record_full_core_store_registers, record_full_core_xfer_partial)
2182 (record_full_core_insert_breakpoint)
2183 (record_full_core_remove_breakpoint)
2184 (record_full_core_has_execution): Refactor
2185 as methods of the record_full_core_target class.
2186 (record_full_base_target::supports_delete_record): New.
2187 (init_record_full_ops): Delete.
2188 (init_record_full_core_ops): Delete.
2189 (record_full_save): Refactor as method of the
2190 record_full_base_target class.
2191 (_initialize_record_full): Remove references to
2192 init_record_full_ops and init_record_full_core_ops.
2193
2194 * remote.c (remote_target, extended_remote_target): New classes.
2195 (remote_ops): Now a remote_target.
2196 (extended_remote_ops): Now an extended_remote_target.
2197 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
2198 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
2199 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
2200 (remote_pass_signals, remote_set_syscall_catchpoint)
2201 (remote_program_signals, )
2202 (remote_thread_always_alive): Remove target_ops parameter.
2203 (remote_thread_alive, remote_thread_name)
2204 (remote_update_thread_list, remote_threads_extra_info)
2205 (remote_static_tracepoint_marker_at)
2206 (remote_static_tracepoint_markers_by_strid)
2207 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
2208 (remote_open): Refactor as methods of remote_target.
2209 (extended_remote_open, extended_remote_detach)
2210 (extended_remote_attach, extended_remote_post_attach):
2211 (extended_remote_supports_disable_randomization)
2212 (extended_remote_create_inferior): : Refactor as method of
2213 extended_remote_target.
2214 (remote_set_permissions, remote_open_1, remote_detach)
2215 (remote_follow_fork, remote_follow_exec, remote_disconnect)
2216 (remote_resume, remote_commit_resume, remote_stop)
2217 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
2218 (remote_terminal_ours, remote_wait, remote_fetch_registers)
2219 (remote_prepare_to_store, remote_store_registers)
2220 (remote_flash_erase, remote_flash_done, remote_files_info)
2221 (remote_kill, remote_mourn, remote_insert_breakpoint)
2222 (remote_remove_breakpoint, remote_insert_watchpoint)
2223 (remote_watchpoint_addr_within_range)
2224 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
2225 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
2226 (remote_supports_stopped_by_sw_breakpoint)
2227 (remote_stopped_by_hw_breakpoint)
2228 (remote_supports_stopped_by_hw_breakpoint)
2229 (remote_stopped_by_watchpoint, remote_stopped_data_address)
2230 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
2231 (remote_verify_memory): Refactor as methods of remote_target.
2232 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
2233 parameter.
2234 (remote_xfer_partial, remote_get_memory_xfer_limit)
2235 (remote_search_memory, remote_rcmd, remote_memory_map)
2236 (remote_pid_to_str, remote_get_thread_local_address)
2237 (remote_get_tib_address, remote_read_description): Refactor as
2238 methods of remote_target.
2239 (remote_target::fileio_open, remote_target::fileio_pwrite)
2240 (remote_target::fileio_pread, remote_target::fileio_close): New.
2241 (remote_hostio_readlink, remote_hostio_fstat)
2242 (remote_filesystem_is_local, remote_can_execute_reverse)
2243 (remote_supports_non_stop, remote_supports_disable_randomization)
2244 (remote_supports_multi_process, remote_supports_cond_breakpoints)
2245 (remote_supports_enable_disable_tracepoint)
2246 (remote_supports_string_tracing)
2247 (remote_can_run_breakpoint_commands, remote_trace_init)
2248 (remote_download_tracepoint, remote_can_download_tracepoint)
2249 (remote_download_trace_state_variable, remote_enable_tracepoint)
2250 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
2251 (remote_trace_start, remote_get_trace_status)
2252 (remote_get_tracepoint_status, remote_trace_stop)
2253 (remote_trace_find, remote_get_trace_state_variable_value)
2254 (remote_save_trace_data, remote_get_raw_trace_data)
2255 (remote_set_disconnected_tracing, remote_core_of_thread)
2256 (remote_set_circular_trace_buffer, remote_traceframe_info)
2257 (remote_get_min_fast_tracepoint_insn_len)
2258 (remote_set_trace_buffer_size, remote_set_trace_notes)
2259 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
2260 (remote_disable_btrace, remote_teardown_btrace)
2261 (remote_read_btrace, remote_btrace_conf)
2262 (remote_augmented_libraries_svr4_read, remote_load)
2263 (remote_pid_to_exec_file, remote_can_do_single_step)
2264 (remote_execution_direction, remote_thread_handle_to_thread_info):
2265 Refactor as methods of remote_target.
2266 (init_remote_ops, init_extended_remote_ops): Delete.
2267 (remote_can_async_p, remote_is_async_p, remote_async)
2268 (remote_thread_events, remote_upload_tracepoints)
2269 (remote_upload_trace_state_variables): Refactor as methods of
2270 remote_target.
2271 (_initialize_remote): Remove references to init_remote_ops and
2272 init_extended_remote_ops.
2273
2274 * remote-sim.c (gdbsim_target): New class.
2275 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
2276 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
2277 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
2278 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
2279 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
2280 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
2281 Refactor as methods of gdbsim_target.
2282 (gdbsim_ops): Now a gdbsim_target.
2283 (init_gdbsim_ops): Delete.
2284 (gdbsim_cntrl_c): Adjust.
2285 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
2286
2287 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
2288 (the_amd64_linux_nat_target): New.
2289 (amd64_linux_fetch_inferior_registers)
2290 (amd64_linux_store_inferior_registers): Refactor as methods of
2291 amd64_linux_nat_target.
2292 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
2293 * i386-linux-nat.c: Don't include "linux-nat.h".
2294 (i386_linux_nat_target): New class.
2295 (the_i386_linux_nat_target): New.
2296 (i386_linux_fetch_inferior_registers)
2297 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
2298 as methods of i386_linux_nat_target.
2299 (_initialize_i386_linux_nat): Adjust. Set linux_target.
2300 * inf-child.c (inf_child_ops): Delete.
2301 (inf_child_fetch_inferior_registers)
2302 (inf_child_store_inferior_registers): Delete.
2303 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
2304 methods of inf_child_target.
2305 (inf_child_target::supports_terminal_ours)
2306 (inf_child_target::terminal_init)
2307 (inf_child_target::terminal_inferior)
2308 (inf_child_target::terminal_ours_for_output)
2309 (inf_child_target::terminal_ours, inf_child_target::interrupt)
2310 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
2311 New.
2312 (inf_child_open, inf_child_disconnect, inf_child_close)
2313 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
2314 (inf_child_post_startup_inferior, inf_child_can_run)
2315 (inf_child_pid_to_exec_file): Refactor as methods of
2316 inf_child_target.
2317 (inf_child_follow_fork): Delete.
2318 (inf_child_target::can_create_inferior)
2319 (inf_child_target::can_attach): New.
2320 (inf_child_target::has_all_memory, inf_child_target::has_memory)
2321 (inf_child_target::has_stack, inf_child_target::has_registers)
2322 (inf_child_target::has_execution): New.
2323 (inf_child_fileio_open, inf_child_fileio_pwrite)
2324 (inf_child_fileio_pread, inf_child_fileio_fstat)
2325 (inf_child_fileio_close, inf_child_fileio_unlink)
2326 (inf_child_fileio_readlink, inf_child_use_agent)
2327 (inf_child_can_use_agent): Refactor as methods of
2328 inf_child_target.
2329 (return_zero, inf_child_target): Delete.
2330 (inf_child_target::inf_child_target): New.
2331 * inf-child.h: Include "target.h".
2332 (inf_child_target): Delete function prototype.
2333 (inf_child_target): New class.
2334 (inf_child_open_target, inf_child_mourn_inferior)
2335 (inf_child_maybe_unpush_target): Delete.
2336 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
2337 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
2338 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
2339 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
2340 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
2341 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
2342 (inf_ptrace_wait, inf_ptrace_xfer_partial)
2343 (inf_ptrace_thread_alive, inf_ptrace_files_info)
2344 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
2345 methods of inf_ptrace_target.
2346 (inf_ptrace_target): Delete function.
2347 * inf-ptrace.h: Include "inf-child.h".
2348 (inf_ptrace_target): Delete function declaration.
2349 (inf_ptrace_target): New class.
2350 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
2351 * linux-nat.c (linux_target): New.
2352 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
2353 (linux_nat_target::~linux_nat_target): New.
2354 (linux_child_post_attach, linux_child_post_startup_inferior)
2355 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
2356 (linux_child_remove_fork_catchpoint)
2357 (linux_child_insert_vfork_catchpoint)
2358 (linux_child_remove_vfork_catchpoint)
2359 (linux_child_insert_exec_catchpoint)
2360 (linux_child_remove_exec_catchpoint)
2361 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
2362 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
2363 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
2364 (linux_nat_stopped_data_address)
2365 (linux_nat_stopped_by_sw_breakpoint)
2366 (linux_nat_supports_stopped_by_sw_breakpoint)
2367 (linux_nat_stopped_by_hw_breakpoint)
2368 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
2369 (linux_nat_kill, linux_nat_mourn_inferior)
2370 (linux_nat_xfer_partial, linux_nat_thread_alive)
2371 (linux_nat_update_thread_list, linux_nat_pid_to_str)
2372 (linux_nat_thread_name, linux_child_pid_to_exec_file)
2373 (linux_child_static_tracepoint_markers_by_strid)
2374 (linux_nat_is_async_p, linux_nat_can_async_p)
2375 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
2376 (linux_nat_supports_multi_process)
2377 (linux_nat_supports_disable_randomization, linux_nat_async)
2378 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
2379 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
2380 (linux_nat_fileio_open, linux_nat_fileio_readlink)
2381 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
2382 methods of linux_nat_target.
2383 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
2384 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
2385 parameter.
2386 (check_stopped_by_watchpoint): Adjust.
2387 (linux_xfer_partial): Delete.
2388 (linux_target_install_ops, linux_target, linux_nat_add_target):
2389 Delete.
2390 (linux_nat_target::linux_nat_target): New.
2391 * linux-nat.h: Include "inf-ptrace.h".
2392 (linux_nat_target): New.
2393 (linux_target, linux_target_install_ops, linux_nat_add_target):
2394 Delete function declarations.
2395 (linux_target): Declare global.
2396 * linux-thread-db.c (thread_db_target): New.
2397 (thread_db_target::thread_db_target): New.
2398 (thread_db_ops): Delete.
2399 (the_thread_db_target): New.
2400 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
2401 (thread_db_update_thread_list, thread_db_pid_to_str)
2402 (thread_db_extra_thread_info)
2403 (thread_db_thread_handle_to_thread_info)
2404 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
2405 (thread_db_resume): Refactor as methods of thread_db_target.
2406 (init_thread_db_ops): Delete.
2407 (_initialize_thread_db): Remove reference to init_thread_db_ops.
2408 * x86-linux-nat.c: Don't include "linux-nat.h".
2409 (super_post_startup_inferior): Delete.
2410 (x86_linux_nat_target::~x86_linux_nat_target): New.
2411 (x86_linux_child_post_startup_inferior)
2412 (x86_linux_read_description, x86_linux_enable_btrace)
2413 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
2414 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
2415 methods of x86_linux_nat_target.
2416 (x86_linux_create_target): Delete. Bits folded ...
2417 (x86_linux_add_target): ... here. Now takes a linux_nat_target
2418 pointer.
2419 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
2420 (x86_linux_nat_target): New class.
2421 (x86_linux_create_target): Delete.
2422 (x86_linux_add_target): Now takes a linux_nat_target pointer.
2423 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
2424 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
2425 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
2426 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
2427 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
2428 make extern.
2429 (x86_use_watchpoints): Delete.
2430 * x86-nat.h: Include "breakpoint.h" and "target.h".
2431 (x86_use_watchpoints): Delete.
2432 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
2433 (x86_stopped_by_watchpoint, x86_stopped_data_address)
2434 (x86_insert_watchpoint, x86_remove_watchpoint)
2435 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
2436 (x86_stopped_by_hw_breakpoint): New declarations.
2437 (x86_nat_target): New template class.
2438
2439 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
2440 (the_ppc_linux_nat_target): New.
2441 (ppc_linux_fetch_inferior_registers)
2442 (ppc_linux_can_use_hw_breakpoint)
2443 (ppc_linux_region_ok_for_hw_watchpoint)
2444 (ppc_linux_ranged_break_num_registers)
2445 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
2446 (ppc_linux_insert_mask_watchpoint)
2447 (ppc_linux_remove_mask_watchpoint)
2448 (ppc_linux_can_accel_watchpoint_condition)
2449 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
2450 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
2451 (ppc_linux_watchpoint_addr_within_range)
2452 (ppc_linux_masked_watch_num_registers)
2453 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
2454 (ppc_linux_read_description): Refactor as methods of
2455 ppc_linux_nat_target.
2456 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
2457
2458 * procfs.c (procfs_xfer_partial): Delete forward declaration.
2459 (procfs_target): New class.
2460 (the_procfs_target): New.
2461 (procfs_target): Delete function.
2462 (procfs_auxv_parse, procfs_attach, procfs_detach)
2463 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
2464 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
2465 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
2466 (procfs_create_inferior, procfs_update_thread_list)
2467 (procfs_thread_alive, procfs_pid_to_str)
2468 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
2469 (procfs_stopped_data_address, procfs_insert_watchpoint)
2470 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
2471 (proc_find_memory_regions, procfs_info_proc)
2472 (procfs_make_note_section): Refactor as methods of procfs_target.
2473 (_initialize_procfs): Adjust.
2474 * sol-thread.c (sol_thread_target): New class.
2475 (sol_thread_ops): Now a sol_thread_target.
2476 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
2477 (sol_thread_fetch_registers, sol_thread_store_registers)
2478 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
2479 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
2480 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
2481 (init_sol_thread_ops): Delete.
2482 (_initialize_sol_thread): Adjust. Remove references to
2483 init_sol_thread_ops and complete_target_initialization.
2484
2485 * windows-nat.c (windows_nat_target): New class.
2486 (windows_fetch_inferior_registers)
2487 (windows_store_inferior_registers, windows_resume, windows_wait)
2488 (windows_attach, windows_detach, windows_pid_to_exec_file)
2489 (windows_files_info, windows_create_inferior)
2490 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
2491 (windows_close, windows_pid_to_str, windows_xfer_partial)
2492 (windows_get_tib_address, windows_get_ada_task_ptid)
2493 (windows_thread_name, windows_thread_alive): Refactor as
2494 windows_nat_target methods.
2495 (do_initial_windows_stuff): Adjust.
2496 (windows_target): Delete function.
2497 (_initialize_windows_nat): Adjust.
2498
2499 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
2500 (darwin_mourn_inferior, darwin_kill_inferior)
2501 (darwin_create_inferior, darwin_attach, darwin_detach)
2502 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
2503 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
2504 (darwin_supports_multi_process): Refactor as darwin_nat_target
2505 methods.
2506 (darwin_resume_to, darwin_files_info): Delete.
2507 (_initialize_darwin_inferior): Rename to ...
2508 (_initialize_darwin_nat): ... this. Adjust to C++ification.
2509 * darwin-nat.h: Include "inf-child.h".
2510 (darwin_nat_target): New class.
2511 (darwin_complete_target): Delete.
2512 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
2513 (darwin_target): New.
2514 (i386_darwin_fetch_inferior_registers)
2515 (i386_darwin_store_inferior_registers): Refactor as methods of
2516 darwin_nat_target.
2517 (darwin_complete_target): Delete, with ...
2518 (_initialize_i386_darwin_nat): ... bits factored out here.
2519
2520 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
2521 (the_alpha_linux_nat_target): New.
2522 (alpha_linux_register_u_offset): Refactor as
2523 alpha_linux_nat_target method.
2524 (_initialize_alpha_linux_nat): Adjust.
2525 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
2526 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
2527 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
2528 methods of linux_nat_trad_target.
2529 (linux_trad_target): Delete.
2530 * linux-nat-trad.h (linux_trad_target): Delete function.
2531 (linux_nat_trad_target): New class.
2532 * mips-linux-nat.c (mips_linux_nat_target): New class.
2533 (super_fetch_registers, super_store_registers, super_close):
2534 Delete.
2535 (the_mips_linux_nat_target): New.
2536 (mips64_linux_regsets_fetch_registers)
2537 (mips64_linux_regsets_store_registers)
2538 (mips64_linux_fetch_registers, mips64_linux_store_registers)
2539 (mips_linux_register_u_offset, mips_linux_read_description)
2540 (mips_linux_can_use_hw_breakpoint)
2541 (mips_linux_stopped_by_watchpoint)
2542 (mips_linux_stopped_data_address)
2543 (mips_linux_region_ok_for_hw_watchpoint)
2544 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
2545 (mips_linux_close): Refactor as methods of mips_linux_nat.
2546 (_initialize_mips_linux_nat): Adjust to C++ification.
2547
2548 * aix-thread.c (aix_thread_target): New class.
2549 (aix_thread_ops): Now an aix_thread_target.
2550 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
2551 (aix_thread_fetch_registers, aix_thread_store_registers)
2552 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
2553 (aix_thread_thread_alive, aix_thread_pid_to_str)
2554 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
2555 Refactor as methods of aix_thread_target.
2556 (init_aix_thread_ops): Delete.
2557 (_initialize_aix_thread): Remove references to init_aix_thread_ops
2558 and complete_target_initialization.
2559 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
2560 (rs6000_nat_target): New class.
2561 (the_rs6000_nat_target): New.
2562 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
2563 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
2564 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
2565 (super_create_inferior): Delete.
2566 (_initialize_rs6000_nat): Adjust to C++ification.
2567
2568 * arm-linux-nat.c (arm_linux_nat_target): New class.
2569 (the_arm_linux_nat_target): New.
2570 (arm_linux_fetch_inferior_registers)
2571 (arm_linux_store_inferior_registers, arm_linux_read_description)
2572 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
2573 (arm_linux_remove_hw_breakpoint)
2574 (arm_linux_region_ok_for_hw_watchpoint)
2575 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
2576 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
2577 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
2578 arm_linux_nat_target.
2579 (_initialize_arm_linux_nat): Adjust to C++ification.
2580
2581 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
2582 (the_aarch64_linux_nat_target): New.
2583 (aarch64_linux_fetch_inferior_registers)
2584 (aarch64_linux_store_inferior_registers)
2585 (aarch64_linux_child_post_startup_inferior)
2586 (aarch64_linux_read_description)
2587 (aarch64_linux_can_use_hw_breakpoint)
2588 (aarch64_linux_insert_hw_breakpoint)
2589 (aarch64_linux_remove_hw_breakpoint)
2590 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
2591 (aarch64_linux_region_ok_for_hw_watchpoint)
2592 (aarch64_linux_stopped_data_address)
2593 (aarch64_linux_stopped_by_watchpoint)
2594 (aarch64_linux_watchpoint_addr_within_range)
2595 (aarch64_linux_can_do_single_step): Refactor as methods of
2596 aarch64_linux_nat_target.
2597 (super_post_startup_inferior): Delete.
2598 (_initialize_aarch64_linux_nat): Adjust to C++ification.
2599
2600 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
2601 (the_hppa_linux_nat_target): New.
2602 (hppa_linux_fetch_inferior_registers)
2603 (hppa_linux_store_inferior_registers): Refactor as methods of
2604 hppa_linux_nat_target.
2605 (_initialize_hppa_linux_nat): Adjust to C++ification.
2606
2607 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
2608 (the_ia64_linux_nat_target): New.
2609 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
2610 (ia64_linux_stopped_data_address)
2611 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
2612 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
2613 ia64_linux_nat_target methods.
2614 (super_xfer_partial): Delete.
2615 (_initialize_ia64_linux_nat): Adjust to C++ification.
2616
2617 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
2618 (the_m32r_linux_nat_target): New.
2619 (m32r_linux_fetch_inferior_registers)
2620 (m32r_linux_store_inferior_registers): Refactor as
2621 m32r_linux_nat_target methods.
2622 (_initialize_m32r_linux_nat): Adjust to C++ification.
2623
2624 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
2625 (the_m68k_linux_nat_target): New.
2626 (m68k_linux_fetch_inferior_registers)
2627 (m68k_linux_store_inferior_registers): Refactor as
2628 m68k_linux_nat_target methods.
2629 (_initialize_m68k_linux_nat): Adjust to C++ification.
2630
2631 * s390-linux-nat.c (s390_linux_nat_target): New class.
2632 (the_s390_linux_nat_target): New.
2633 (s390_linux_fetch_inferior_registers)
2634 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
2635 (s390_insert_watchpoint, s390_remove_watchpoint)
2636 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
2637 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
2638 (s390_auxv_parse, s390_read_description): Refactor as methods of
2639 s390_linux_nat_target.
2640 (_initialize_s390_nat): Adjust to C++ification.
2641
2642 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
2643 (the_sparc_linux_nat_target): New.
2644 (_initialize_sparc_linux_nat): Adjust to C++ification.
2645 * sparc-nat.c (sparc_fetch_inferior_registers)
2646 (sparc_store_inferior_registers): Remove target_ops parameter.
2647 * sparc-nat.h (sparc_fetch_inferior_registers)
2648 (sparc_store_inferior_registers): Remove target_ops parameter.
2649 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
2650 (the_sparc64_linux_nat_target): New.
2651 (_initialize_sparc64_linux_nat): Adjust to C++ification.
2652
2653 * spu-linux-nat.c (spu_linux_nat_target): New class.
2654 (the_spu_linux_nat_target): New.
2655 (spu_child_post_startup_inferior, spu_child_post_attach)
2656 (spu_child_wait, spu_fetch_inferior_registers)
2657 (spu_store_inferior_registers, spu_xfer_partial)
2658 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
2659 methods.
2660 (_initialize_spu_nat): Adjust to C++ification.
2661
2662 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
2663 (the_tilegx_linux_nat_target): New.
2664 (fetch_inferior_registers, store_inferior_registers):
2665 Refactor as methods.
2666 (_initialize_tile_linux_nat): Adjust to C++ification.
2667
2668 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
2669 (the_xtensa_linux_nat_target): New.
2670 (xtensa_linux_fetch_inferior_registers)
2671 (xtensa_linux_store_inferior_registers): Refactor as
2672 xtensa_linux_nat_target methods.
2673 (_initialize_xtensa_linux_nat): Adjust to C++ification.
2674
2675 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
2676 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
2677 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
2678 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
2679 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
2680 (fbsd_stopped_by_sw_breakpoint)
2681 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
2682 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
2683 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
2684 (fbsd_post_startup_inferior, fbsd_post_attach)
2685 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
2686 (fbsd_set_syscall_catchpoint)
2687 (super_xfer_partial, super_resume, super_wait)
2688 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
2689 (fbsd_handle_debug_trap): Remove target_ops parameter.
2690 (fbsd_nat_add_target): Delete.
2691 * fbsd-nat.h: Include "inf-ptrace.h".
2692 (fbsd_nat_add_target): Delete.
2693 (USE_SIGTRAP_SIGINFO): Define.
2694 (fbsd_nat_target): New class.
2695
2696 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
2697 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
2698 (amd64bsd_target): Delete.
2699 * amd64-bsd-nat.h: New file.
2700 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
2701 "x86-bsd-nat.h".
2702 (amd64_fbsd_nat_target): New class.
2703 (the_amd64_fbsd_nat_target): New.
2704 (amd64fbsd_read_description): Refactor as method of
2705 amd64_fbsd_nat_target.
2706 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
2707 (_initialize_amd64fbsd_nat): Adjust to C++ification.
2708 * amd64-nat.h (amd64bsd_target): Delete function declaration.
2709 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
2710 (i386bsd_store_inferior_registers): Remove target_ops parameter.
2711 (i386bsd_target): Delete.
2712 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
2713 (i386bsd_fetch_inferior_registers)
2714 (i386bsd_store_inferior_registers): Declare.
2715 (i386_bsd_nat_target): New class.
2716 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
2717 (the_i386_fbsd_nat_target): New.
2718 (i386fbsd_resume, i386fbsd_read_description): Refactor as
2719 i386_fbsd_nat_target methods.
2720 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
2721 (_initialize_i386fbsd_nat): Adjust to C++ification.
2722 * x86-bsd-nat.c (super_mourn_inferior): Delete.
2723 (x86bsd_mourn_inferior, x86bsd_target): Delete.
2724 (_initialize_x86_bsd_nat): Adjust to C++ification.
2725 * x86-bsd-nat.h: Include "x86-nat.h".
2726 (x86bsd_target): Delete declaration.
2727 (x86bsd_nat_target): New class.
2728
2729 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
2730 (the_aarch64_fbsd_nat_target): New.
2731 (aarch64_fbsd_fetch_inferior_registers)
2732 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
2733 aarch64_fbsd_nat_target.
2734 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
2735 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
2736 (the_alpha_bsd_nat_target): New.
2737 (alphabsd_fetch_inferior_registers)
2738 (alphabsd_store_inferior_registers): Refactor as
2739 alpha_bsd_nat_target methods.
2740 (_initialize_alphabsd_nat): Refactor as methods of
2741 alpha_bsd_nat_target.
2742 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
2743 (the_amd64_nbsd_nat_target): New.
2744 (_initialize_amd64nbsd_nat): Adjust to C++ification.
2745 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
2746 (the_amd64_obsd_nat_target): New.
2747 (_initialize_amd64obsd_nat): Adjust to C++ification.
2748 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
2749 (the_arm_fbsd_nat_target): New.
2750 (arm_fbsd_fetch_inferior_registers)
2751 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
2752 (_initialize_arm_fbsd_nat): Refactor as methods of
2753 arm_fbsd_nat_target.
2754 (_initialize_arm_fbsd_nat): Adjust to C++ification.
2755 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
2756 (the_arm_netbsd_nat_target): New.
2757 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
2758 arm_netbsd_nat_target.
2759 (_initialize_arm_netbsd_nat): Adjust to C++ification.
2760 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
2761 (the_hppa_nbsd_nat_target): New.
2762 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
2763 hppa_nbsd_nat_target methods.
2764 (_initialize_hppanbsd_nat): Adjust to C++ification.
2765 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
2766 (the_hppa_obsd_nat_target): New.
2767 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
2768 methods of hppa_obsd_nat_target.
2769 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
2770 add_target.
2771 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
2772 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
2773 add_target.
2774 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
2775 (_initialize_i386obsd_nat): Use add_target.
2776 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
2777 (the_m68k_bsd_nat_target): New.
2778 (m68kbsd_fetch_inferior_registers)
2779 (m68kbsd_store_inferior_registers): Refactor as methods of
2780 m68k_bsd_nat_target.
2781 (_initialize_m68kbsd_nat): Adjust to C++ification.
2782 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
2783 (the_mips_fbsd_nat_target): New.
2784 (mips_fbsd_fetch_inferior_registers)
2785 (mips_fbsd_store_inferior_registers): Refactor as methods of
2786 mips_fbsd_nat_target.
2787 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
2788 add_target.
2789 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
2790 (the_mips_nbsd_nat_target): New.
2791 (mipsnbsd_fetch_inferior_registers)
2792 (mipsnbsd_store_inferior_registers): Refactor as methods of
2793 mips_nbsd_nat_target.
2794 (_initialize_mipsnbsd_nat): Adjust to C++ification.
2795 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
2796 (the_mips64_obsd_nat_target): New.
2797 (mips64obsd_fetch_inferior_registers)
2798 (mips64obsd_store_inferior_registers): Refactor as methods of
2799 mips64_obsd_nat_target.
2800 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
2801 add_target.
2802 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
2803 nbsd_nat_target.
2804 * nbsd-nat.h: Include "inf-ptrace.h".
2805 (nbsd_nat_target): New class.
2806 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
2807 (obsd_wait): Refactor as methods of obsd_nat_target.
2808 (obsd_add_target): Delete.
2809 * obsd-nat.h: Include "inf-ptrace.h".
2810 (obsd_nat_target): New class.
2811 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
2812 (the_ppc_fbsd_nat_target): New.
2813 (ppcfbsd_fetch_inferior_registers)
2814 (ppcfbsd_store_inferior_registers): Refactor as methods of
2815 ppc_fbsd_nat_target.
2816 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
2817 add_target.
2818 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
2819 (the_ppc_nbsd_nat_target): New.
2820 (ppcnbsd_fetch_inferior_registers)
2821 (ppcnbsd_store_inferior_registers): Refactor as methods of
2822 ppc_nbsd_nat_target.
2823 (_initialize_ppcnbsd_nat): Adjust to C++ification.
2824 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
2825 (the_ppc_obsd_nat_target): New.
2826 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
2827 methods of ppc_obsd_nat_target.
2828 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
2829 add_target.
2830 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
2831 (the_sh_nbsd_nat_target): New.
2832 (shnbsd_fetch_inferior_registers)
2833 (shnbsd_store_inferior_registers): Refactor as methods of
2834 sh_nbsd_nat_target.
2835 (_initialize_shnbsd_nat): Adjust to C++ification.
2836 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
2837 (inf_ptrace_xfer_partial): Delete.
2838 (sparc_xfer_partial, sparc_target): Delete.
2839 * sparc-nat.h (sparc_fetch_inferior_registers)
2840 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
2841 (sparc_target): Delete function declaration.
2842 (sparc_target): New template class.
2843 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
2844 (_initialize_sparcnbsd_nat): Adjust to C++ification.
2845 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
2846 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
2847 add_target.
2848 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
2849 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
2850 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
2851 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
2852 add_target.
2853 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
2854 (the_vax_bsd_nat_target): New.
2855 (vaxbsd_fetch_inferior_registers)
2856 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
2857 methods.
2858 (_initialize_vaxbsd_nat): Adjust to C++ification.
2859
2860 * bsd-kvm.c (bsd_kvm_target): New class.
2861 (bsd_kvm_ops): Now a bsd_kvm_target.
2862 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
2863 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
2864 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
2865 bsd_kvm_target.
2866 (bsd_kvm_return_one): Delete.
2867 (bsd_kvm_add_target): Adjust to C++ification.
2868
2869 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
2870 (nto_procfs_target_procfs): New classes.
2871 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
2872 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
2873 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
2874 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
2875 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
2876 (procfs_remove_hw_breakpoint, procfs_resume)
2877 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
2878 (procfs_kill_inferior, procfs_store_registers)
2879 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
2880 as methods of nto_procfs_target.
2881 (nto_procfs_ops): Now an nto_procfs_target_procfs.
2882 (nto_native_ops): Delete.
2883 (procfs_open, procfs_native_open): Delete.
2884 (nto_native_ops): Now an nto_procfs_target_native.
2885 (init_procfs_targets): Adjust to C++ification.
2886 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
2887 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
2888 Refactor as methods of nto_procfs_target.
2889
2890 * go32-nat.c (go32_nat_target): New class.
2891 (the_go32_nat_target): New.
2892 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
2893 (go32_store_registers, go32_xfer_partial, go32_files_info)
2894 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
2895 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
2896 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
2897 (go32_pid_to_str): Refactor as methods of go32_nat_target.
2898 (go32_target): Delete.
2899 (_initialize_go32_nat): Adjust to C++ification.
2900
2901 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
2902 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
2903 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
2904 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
2905 gnu_nat_target.
2906 (gnu_target): Delete.
2907 * gnu-nat.h (gnu_target): Delete.
2908 (gnu_nat_target): New class.
2909 * i386-gnu-nat.c (gnu_base_target): New.
2910 (i386_gnu_nat_target): New class.
2911 (the_i386_gnu_nat_target): New.
2912 (_initialize_i386gnu_nat): Adjust to C++ification.
2913
3fffc070
PA
29142018-05-02 Pedro Alves <palves@redhat.com>
2915
2916 * bfd-target.c (target_bfd_xclose): Rename to ...
2917 (target_bfd_close): ... this.
2918 (target_bfd_reopen): Adjust.
2919 * target.c (target_close): Remove references to to_xclose.
2920 * target.h (target_ops::to_xclose): Delete.
2921 (target_ops::to_close): Update comments.
2922
6798487f
PA
29232018-05-02 Pedro Alves <palves@redhat.com>
2924
2925 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
2926 "linux-nat.h".
2927 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
2928 * inf-ptrace.c (inf_ptrace_register_u_offset)
2929 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
2930 (inf_ptrace_store_register, inf_ptrace_store_registers)
2931 (inf_ptrace_trad_target): Move to ...
2932 * linux-nat-trad.c: ... this new file.
2933 * linux-nat-trad.h: New file.
2934 * linux-nat.c (linux_target_install_ops): Make extern.
2935 (linux_trad_target): Delete.
2936 * linux-nat.h (linux_trad_target): Delete declaration.
2937 (linux_target_install_ops): Declare.
2938 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
2939 "linux-nat.h".
2940
c1955e17
PA
29412018-05-02 Pedro Alves <palves@redhat.com>
2942
2943 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
2944 procfs_target/add_target here.
2945 * procfs.c (procfs_target): Make static.
2946 (_initialize_procfs): Call add_target here.
2947 * procfs.h (struct target_ops): Remove forward declaration.
2948 (procfs_target): Remove declaration.
2949 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
2950
b5c8fcb1
PA
29512018-05-02 Pedro Alves <palves@redhat.com>
2952
2953 * procfs.c (procfs_stopped_by_watchpoint)
2954 (procfs_insert_watchpoint, procfs_remove_watchpoint)
2955 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
2956 Forward declare.
2957 (procfs_use_watchpoints): Delete, move contents...
2958 (procfs_target): ... here.
2959 * procfs.h (procfs_use_watchpoints): Delete declaration.
2960 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
2961 procfs_use_watchpoints.
2962 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
2963 procfs_use_watchpoints.
2964
0489430a
TT
29652018-05-02 Tom Tromey <tom@tromey.com>
2966
2967 PR python/20084:
2968 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
2969 and var_zuinteger_unlimited.
2970 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
2971 and PARAM_ZUINTEGER_UNLIMITED.
2972 (set_parameter_value): Handle var_zuinteger and
2973 var_zuinteger_unlimited.
2974 (add_setshow_generic): Likewise.
2975 (parmpy_init): Likewise.
2976
1632f8ba
DR
29772018-04-28 Dan Robertson <danlrobertson89@gmail.com>
2978
2979 PR rust/23124
2980 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
2981 pointer is not null before dereferencing it.
2982
76761936
TT
29832018-04-30 Tom Tromey <tom@tromey.com>
2984
2985 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
2986 is_mi_like_p.
2987
2d33446d
TT
29882018-04-30 Tom Tromey <tom@tromey.com>
2989
2990 * breakpoint.c (mention): Remove use of is_mi_like_p.
2991 (print_mention_ranged_breakpoint): Likewise.
2992 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
2993 of is_mi_like_p.
2994
f3c6abab
TT
29952018-04-30 Tom Tromey <tom@tromey.com>
2996
2997 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
2998
40c03530
TT
29992018-04-30 Tom Tromey <tom@tromey.com>
3000
3001 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
3002 (info_spu_event_command): Remove some uses of is_mi_like_p.
3003
2038b7fd
TT
30042018-04-30 Tom Tromey <tom@tromey.com>
3005
3006 * python/py-framefilter.c (py_print_single_arg)
3007 (enumerate_locals, py_print_args, py_print_frame): Remove some
3008 uses of is_mi_like_p.
3009
4904c3c6
TT
30102018-04-30 Tom Tromey <tom@tromey.com>
3011
3012 * ui-out.c: Update.
3013 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
3014 * ui-out.h (ui_out::is_mi_like_p): Now const.
3015 (ui_out::do_is_mi_like_p): Now const.
3016 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
3017
7c66fffc
TT
30182018-04-30 Tom Tromey <tom@tromey.com>
3019
3020 * varobj.c (varobj_set_visualizer): Use new_reference.
3021 * python/python.c (gdbpy_decode_line): Use new_reference.
3022 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
3023 new_reference.
3024
bbfa6f00
TT
30252018-04-30 Tom Tromey <tom@tromey.com>
3026
3027 * varobj.c (install_new_value): Use new_reference.
3028 * value.h (value_incref): Return void. Swap intro comment with
3029 value_decref.
3030 * value.c (set_value_parent): Use new_reference.
3031 (value_incref): Return void. Update intro comment.
3032 (release_value): Use new_reference.
3033 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
3034
1831a9f9
TT
30352018-04-30 Tom Tromey <tom@tromey.com>
3036
3037 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
3038 * gdb_bfd.h (new_bfd_ref): Remove.
3039 (gdb_bfd_open): Update comment.
3040 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
3041 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
3042 (gdb_bfd_fdopenr): Use new_reference.
3043 * exec.c (exec_file_attach): Use new_reference.
3044
7c1b5f3d
TT
30452018-04-30 Tom Tromey <tom@tromey.com>
3046
3047 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
3048 method.
3049
e11fb955
TT
30502018-04-30 Tom Tromey <tom@tromey.com>
3051
3052 * jit.c (jit_read_code_entry): Use type_align.
3053 * i386-tdep.c (i386_gdbarch_init): Don't call
3054 set_gdbarch_long_long_align_bit.
3055 * gdbarch.sh: Remove long_long_align_bit.
3056 * gdbarch.c, gdbarch.h: Rebuild.
3057 * arc-tdep.c (arc_type_align): New function.
3058 (arc_gdbarch_init): Use arc_type_align. Don't call
3059 set_gdbarch_long_long_align_bit.
3060
2fff16dd
TT
30612018-04-30 Tom Tromey <tom@tromey.com>
3062
3063 * rust-lang.c (rust_type_alignment): Remove.
3064 (rust_composite_type): Use type_align.
3065
6d7bb824
TT
30662018-04-30 Tom Tromey <tom@tromey.com>
3067
3068 * NEWS: Mention Type.align.
3069 * python/py-type.c (typy_get_alignof): New function.
3070 (type_object_getset): Add "alignof".
3071
007e1530
TT
30722018-04-30 Tom Tromey <tom@tromey.com>
3073
3074 PR exp/17095:
3075 * NEWS: Update.
3076 * std-operator.def (UNOP_ALIGNOF): New operator.
3077 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
3078 New.
3079 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
3080 * c-lang.c (c_op_print_tab): Add alignof.
3081 * c-exp.y (ALIGNOF): New token.
3082 (exp): Add "ALIGNOF" production.
3083 (ident_tokens): Add _Alignof and alignof.
3084
2b4424c3
TT
30852018-04-30 Tom Tromey <tom@tromey.com>
3086
3087 * i386-tdep.c (i386_type_align): New function.
3088 (i386_gdbarch_init): Update.
3089 * gdbarch.sh (type_align): New method.
3090 * gdbarch.c, gdbarch.h: Rebuild.
3091 * arch-utils.h (default_type_align): Declare.
3092 * arch-utils.c (default_type_align): New function.
3093 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
3094 (struct type) <align_log2>: New field.
3095 <instance_flags>: Now a bitfield.
3096 (TYPE_RAW_ALIGN): New macro.
3097 (type_align, type_raw_align, set_type_align): Declare.
3098 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
3099 functions.
3100 * dwarf2read.c (quirk_rust_enum): Set type alignment.
3101 (get_alignment, maybe_set_alignment): New functions.
3102 (read_structure_type, read_enumeration_type, read_array_type)
3103 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
3104 (read_subrange_type, read_base_type): Set type alignment.
3105
d33bc52e
SM
31062018-04-30 Simon Marchi <simon.marchi@ericsson.com>
3107
3108 * dwarf2read.c (read_index_from_section): Use bool.
3109
e28b63a9
FG
31102018-04-29 Fabian Groffen <grobian@gentoo.org>
3111
3112 PR gdb/22950
3113 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
3114 with #ifdef.
3115
cd8c76e4
JR
31162018-04-29 John Reiser <jreiser@BitWagon.com>
3117
3118 PR build/22873
3119 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
3120 last step, and do it atomically.
3121
476d250e
AO
31222018-04-27 Alexandre Oliva <aoliva@redhat.com>
3123
3124 * compile/compile-c-types.c (convert_int, convert_float):
3125 Update for C FE v1.
3126
6873858b
TT
31272018-04-27 Tom Tromey <tom@tromey.com>
3128
3129 PR rust/22545:
3130 * rust-lang.c (rust_inclusive_range_type_p): New function.
3131 (rust_range): Handle inclusive ranges.
3132 (rust_compute_range): Likewise.
3133 * rust-exp.y (struct rust_op) <inclusive>: New field.
3134 (DOTDOTEQ): New constant.
3135 (range_expr): Add "..=" productions.
3136 (operator_tokens): Add "..=" token.
3137 (ast_range): Add "inclusive" parameter.
3138 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
3139 ranges.
3140 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
3141 bounds values.
3142 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
3143 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
3144 Update comments.
3145 * expprint.c (print_subexp_standard): Handle new bounds values.
3146 (dump_subexp_body_standard): Likewise.
3147
632e107b
TT
31482018-04-27 Tom Tromey <tom@tromey.com>
3149
3150 * configure: Rebuild.
3151 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
3152 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
3153 "OVERRIDE".
3154 (class symbol_needs_eval_context): Likewise.
3155 * dwarf2read.c (mock_mapped_index::symbol_name_count)
3156 (mock_mapped_index::symbol_name_at): Use "override". Remove
3157 "virtual".
3158 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
3159 "override".
3160 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
3161 * aarch64-tdep.c (instruction_reader::read): Use "override".
3162 (instruction_reader_test::read): Likewise.
3163 * arm-tdep.c (instruction_reader::read): Use "override".
3164 (instruction_reader_thumb::read): Likewise.
3165
b75abf5b
AK
31662018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
3167
3168 PR remote/9665
3169 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
3170 instead of remote_send.
3171 (remote_send): Remove.
3172
79188d8d
PA
31732018-04-26 Pedro Alves <palves@redhat.com>
3174
3175 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
3176 find_function_start_sal instead of find_pc_line.
3177
f50776aa
PA
31782018-04-26 Pedro Alves <palves@redhat.com>
3179
3180 * breakpoint.c (set_breakpoint_location_function): Handle
3181 mst_data_gnu_ifunc.
3182 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
3183 * elfread.c (elf_symtab_read): Give data symbols with
3184 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
3185 (elf_rel_plt_read): Update comment.
3186 * linespec.c (convert_linespec_to_sals): Handle
3187 mst_data_gnu_ifunc.
3188 (minsym_found): Handle mst_data_gnu_ifunc.
3189 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
3190 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
3191 * parse.c (find_minsym_type_and_address): Handle
3192 mst_data_gnu_ifunc.
3193 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
3194 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
3195 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
3196 comment.
3197 <mst_data_gnu_ifunc>: New enumerator.
3198
20944a6e
PA
31992018-04-26 Pedro Alves <palves@redhat.com>
3200
3201 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
3202 (lookup_minimal_symbol_by_pc_section): ... this. Replace
3203 'want_trampoline' parameter by a lookup_msym_prefer parameter.
3204 Handle it.
3205 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
3206 (lookup_minimal_symbol_by_pc): Adjust.
3207 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
3208 (lookup_solib_trampoline_symbol_by_pc): Adjust.
3209 * minsyms.h (lookup_msym_prefer): New enum.
3210 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
3211 parameter by a lookup_msym_prefer parameter.
3212
1adeb822
PA
32132018-04-26 Pedro Alves <palves@redhat.com>
3214
3215 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
3216 ends in "@plt" instead of looking at the symbol's section.
3217
a0aca7b0
PA
32182018-04-26 Pedro Alves <palves@redhat.com>
3219
3220 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
3221 all references.
3222 (find_pc_partial_function_gnu_ifunc): Rename to ...
3223 (find_pc_partial_function): ... this, and remove references to
3224 'is_gnu_ifunc_p'.
3225 (find_pc_partial_function): Delete old implementation.
3226 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
3227
76af0f26
PA
32282018-04-26 Pedro Alves <palves@redhat.com>
3229
3230 * linespec.c (struct bound_minimal_symbol_search_key): New.
3231 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
3232 skip first line if we found a GNU ifunc minimal symbol by name.
3233 (compare_msymbols): Change parameters to work with a destructured
3234 lhs minsym.
3235 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
3236 functions.
3237
3467ec66
PA
32382018-04-26 Pedro Alves <palves@redhat.com>
3239
3240 * breakpoint.c (set_breakpoint_location_function): Don't resolve
3241 ifunc targets here. Instead, if we have an ifunc minsym, use its
3242 address/name.
3243 (add_location_to_breakpoint): Store the minsym and the objfile in
3244 the breakpoint location.
3245 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
3246 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
3247 Record the minsym in the sal.
3248 * symtab.h (symtab_and_line) <msymbol>: New field.
3249
28f4fa4d
PA
32502018-04-26 Pedro Alves <palves@redhat.com>
3251
3252 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
3253 unless we actually resolved the ifunc.
3254
ca31ab1d
PA
32552018-04-26 Pedro Alves <palves@redhat.com>
3256
3257 * c-exp.y (variable production): Prefer ifunc minsyms over
3258 regular function symbols.
3259 * symtab.c (find_gnu_ifunc): New function.
3260 * minsyms.h (lookup_msym_prefer): New enum.
3261 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
3262 parameter by a lookup_msym_prefer parameter.
3263 * symtab.h (find_gnu_ifunc): New declaration.
3264
8388016d
PA
32652018-04-26 Pedro Alves <palves@redhat.com>
3266
3267 * blockframe.c (find_gnu_ifunc_target_type): New function.
3268 (find_function_type): New.
3269 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
3270 return a value with a memory address.
3271 (eval_call): For calls to GNU ifunc functions, try to find the
3272 type of the target function from the type that the resolver
3273 returns.
3274 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
3275 symbols.
3276 * infcall.c (find_function_return_type): Delete.
3277 (find_function_addr): Add 'function_type' parameter. For calls to
3278 GNU ifunc functions, try to find the type of the target function
3279 from the type that the resolver returns, and return it via
3280 FUNCTION_TYPE.
3281 (call_function_by_hand_dummy): Adjust to use the function type
3282 returned by find_function_addr.
3283 (find_function_addr): Add 'function_type' parameter and move
3284 description here.
3285 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
3286 declarations.
3287
a376e11d
PA
32882018-04-26 Pedro Alves <palves@redhat.com>
3289
3290 * c-exp.y (variable production): Skip finding an alias for ifunc
3291 symbols.
3292
02e169e2
PA
32932018-04-26 Pedro Alves <palves@redhat.com>
3294
3295 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
3296
249b5733
PA
32972018-04-25 Pedro Alves <palves@redhat.com>
3298
3299 * infcmd.c (kill_command): Print the pid as string, not the whole
3300 thread's ptid. Add comment. s/has been killed/killed/ in output
3301 message.
3302 * remote.c (remote_detach_1): Print the pid as string, not the
3303 whole thread's ptid.
3304
f67c0c91
SDJ
33052018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3306 Sergio Durigan Junior <sergiodj@redhat.com>
3307 Pedro Alves <palves@redhat.com>
3308
3309 * infcmd.c (kill_command): Print message when inferior has
3310 been killed.
3311 * inferior.c (print_inferior_events): Remove 'static'. Set as
3312 '1'.
3313 (add_inferior): Improve message printed when
3314 'print_inferior_events' is on.
3315 (exit_inferior): Remove message printed when
3316 'print_inferior_events' is on.
3317 (detach_inferior): Improve message printed when
3318 'print_inferior_events' is on.
3319 (initialize_inferiors): Use 'add_inferior_silent' to set
3320 'current_inferior_'.
3321 * inferior.h (print_inferior_events): Declare here as
3322 'extern'.
3323 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
3324 '[Detaching...]' messages when 'print_inferior_events' is on.
3325 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
3326 as prefix/suffix for messages. Remove periods. Fix erroneous
3327 'Detaching after fork from child...', replace it by '... from
3328 parent...'.
3329 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
3330 prefix/suffix when printing 'Detaching...' messages. Print
3331 them when 'print_inferior_events' is on.
3332 * remote.c (remote_detach_1): Print message when detaching
3333 from inferior and '!is_fork_parent'.
3334
e427af18
TT
33352018-04-24 Tom Tromey <tom@tromey.com>
3336
3337 * cli-out.h: Reindent.
3338
05b1d8d6
TT
33392018-04-24 Tom Tromey <tom@tromey.com>
3340
3341 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
3342 (cli_ui_out::do_field_string): Use fputs_filtered.
3343 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
3344
a95c7dab
TT
33452018-04-23 Tom Tromey <tom@tromey.com>
3346
3347 * guile/scm-frame.c (gdbscm_frame_read_var): Use
3348 gdb::unique_xmalloc_ptr.
3349
458412c3
TT
33502018-04-23 Tom Tromey <tom@tromey.com>
3351
3352 * configure: Rebuild.
3353
db86b02b
RS
33542018-04-22 Rajendra SY <rajendra.sy@gmail.com>
3355
3356 PR gdb/23095
3357 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
3358 prepare_for_testing. Set normal_bp to r_debug_state if target
3359 is bsd.
3360
00aecdcf
PA
33612018-04-21 Pedro Alves <palves@redhat.com>
3362 Rajendra SY <rajendra.sy@gmail.com>
3363
3364 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
3365 * remote.c (extended_remote_attach): In all-stop mode, mark the
3366 thread as executing.
3367
224608c3
PW
33682018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3369
3370 * thread.c (thread_apply_all_command): Fix comment.
3371 (thread_command): Fix comment.
3372
3b74854b
AH
33732018-04-10 Alan Hayward <alan.hayward@arm.com>
3374
3375 * common/tdesc.h (tdesc_create_feature): Remove xml filename
3376 parameter.
3377 * features/aarch64-core.c (create_feature_aarch64_core):
3378 Regenerate.
3379 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
3380 Likewise.
3381 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
3382 Likewise.
3383 * features/i386/32bit-avx512.c
3384 (create_feature_i386_32bit_avx512): Likewise.
3385 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
3386 Likewise.
3387 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
3388 Likewise.
3389 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
3390 Likewise.
3391 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
3392 Likewise.
3393 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
3394 Likewise.
3395 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
3396 Likewise.
3397 * features/i386/64bit-avx512.c
3398 (create_feature_i386_64bit_avx512): Likewise.
3399 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
3400 Likewise.
3401 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
3402 Likewise.
3403 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
3404 Likewise.
3405 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
3406 Likewise.
3407 * features/i386/64bit-segments.c
3408 (create_feature_i386_64bit_segments): Likewise.
3409 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
3410 Likewise.
3411 * features/i386/x32-core.c
3412 (create_feature_i386_x32_core): Likewise.
3413 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
3414 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
3415 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
3416 * target-descriptions.c: In generated code, don't pass xml
3417 filename.
3418
e98577a9
AH
34192018-04-18 Alan Hayward <alan.hayward@arm.com>
3420
3421 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
3422 (print_xml_feature::visit_post): Likewise.
3423 (print_xml_feature::visit): Likewise.
3424 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
3425 (print_xml_feature): Add new class.
3426 * regformats/regdat.sh: Null xmltarget on feature targets.
3427 * target-descriptions.c (struct target_desc): Add xmltarget.
3428 (maintenance_check_tdesc_xml_convert): Add unittest function.
3429 (tdesc_get_features_xml): Add function to get xml.
3430 (maintenance_check_xml_descriptions): Test xml generation.
3431 * xml-tdesc.c (string_read_description_xml): Add function.
3432 * xml-tdesc.h (string_read_description_xml): Add declaration.
3433
ad7fc756
AH
34342018-04-18 Alan Hayward <alan.hayward@arm.com>
3435
3436 * features/Makefile: Add feature marker to targets with new style
3437 target descriptions.
3438 * regformats/aarch64.dat: Regenerate.
3439 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
3440 * regformats/i386/amd64-avx-linux.dat: Likewise.
3441 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
3442 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
3443 * regformats/i386/amd64-linux.dat: Likewise.
3444 * regformats/i386/amd64-mpx-linux.dat: Likewise.
3445 * regformats/i386/amd64.dat: Likewise.
3446 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
3447 * regformats/i386/i386-avx-linux.dat: Likewise.
3448 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
3449 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
3450 * regformats/i386/i386-linux.dat: Likewise.
3451 * regformats/i386/i386-mmx-linux.dat: Likewise.
3452 * regformats/i386/i386-mpx-linux.dat: Likewise.
3453 * regformats/i386/i386.dat: Likewise.
3454 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
3455 * regformats/i386/x32-avx-linux.dat: Likewise.
3456 * regformats/i386/x32-linux.dat: Likewise.
3457 * regformats/tic6x-c62x-linux.dat: Likewise.
3458 * regformats/tic6x-c64x-linux.dat: Likewise.
3459 * regformats/tic6x-c64xp-linux.dat: Likewise.
3460 * regformats/regdat.sh: Parse feature marker.
3461
d278f585
AH
34622018-04-18 Alan Hayward <alan.hayward@arm.com>
3463
3464 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
3465 (tdesc_osabi_name): Likewise.
3466 * target-descriptions.c (tdesc_architecture_name): Add new
3467 function.
3468 (tdesc_osabi_name): Likewise.
3469
eee8a18d
AH
34702018-04-18 Alan Hayward <alan.hayward@arm.com>
3471
3472 * common/tdesc.c (tdesc_predefined_type): Move to here.
3473 (tdesc_named_type): Likewise.
3474 (tdesc_create_vector): Likewise.
3475 (tdesc_create_struct): Likewise.
3476 (tdesc_set_struct_size): Likewise.
3477 (tdesc_create_union): Likewise.
3478 (tdesc_create_flags): Likewise.
3479 (tdesc_create_enum): Likewise.
3480 (tdesc_add_field): Likewise.
3481 (tdesc_add_typed_bitfield): Likewise.
3482 (tdesc_add_bitfield): Likewise.
3483 (tdesc_add_flag): Likewise.
3484 (tdesc_add_enum_value): Likewise.
3485 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
3486 (struct tdesc_type_vector): Likewise.
3487 (struct tdesc_type_field): Likewise.
3488 (struct tdesc_type_with_fields): Likewise.
3489 (tdesc_create_enum): Add declaration.
3490 (tdesc_add_typed_bitfield): Likewise.
3491 (tdesc_add_enum_value): Likewise.
3492 * target-descriptions.c (tdesc_type_field): Move from here.
3493 (tdesc_type_builtin): Likewise.
3494 (tdesc_type_vector): Likewise.
3495 (tdesc_type_with_fields): Likewise.
3496 (tdesc_predefined_types): Likewise.
3497 (tdesc_named_type): Likewise.
3498 (tdesc_create_vector): Likewise.
3499 (tdesc_create_struct): Likewise.
3500 (tdesc_set_struct_size): Likewise.
3501 (tdesc_create_union): Likewise.
3502 (tdesc_create_flags): Likewise.
3503 (tdesc_create_enum): Likewise.
3504 (tdesc_add_field): Likewise.
3505 (tdesc_add_typed_bitfield): Likewise.
3506 (tdesc_add_bitfield): Likewise.
3507 (tdesc_add_flag): Likewise.
3508 (tdesc_add_enum_value): Likewise.
3509 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
3510 (tdesc_add_typed_bitfield): Likewise.
3511 (tdesc_add_enum_value): Likewise.
3512
82ec9bc7
AH
35132018-04-18 Alan Hayward <alan.hayward@arm.com>
3514
3515 * common/tdesc.c (tdesc_feature::accept): Move to here.
3516 (tdesc_feature::operator==): Likewise.
3517 (tdesc_create_reg): Likewise.
3518 * common/tdesc.h (tdesc_type_kind): Likewise.
3519 (struct tdesc_type): Likewise.
3520 (struct tdesc_feature): Likewise.
3521 * regformats/regdat.sh: Create a feature.
3522 * target-descriptions.c (tdesc_type_kind): Move from here.
3523 (tdesc_type): Likewise.
3524 (tdesc_type_up): Likewise.
3525 (tdesc_feature): Likewise.
3526 (tdesc_create_reg): Likewise.
3527
ea3e7d71
AH
35282018-04-18 Alan Hayward <alan.hayward@arm.com>
3529
3530 * Makefile.in: Add arch/tdesc.c
3531 * common/tdesc.c: New file.
3532 * common/tdesc.h (tdesc_element_visitor): Move to here.
3533 (tdesc_element): Likewise.
3534 (tdesc_reg): Likewise.
3535 (tdesc_reg_up): Likewise.
3536 * regformats/regdef.h (reg): Add offset to constructors.
3537 * target-descriptions.c (tdesc_element_visitor): Move from here.
3538 (tdesc_element): Likewise.
3539 (tdesc_reg): Likewise.
3540 (tdesc_reg_up): Likewise.
3541
bedda9ac
TT
35422018-04-17 Tom Tromey <tom@tromey.com>
3543
3544 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
3545 discriminant field.
3546
a037790e
TT
35472018-04-17 Tom Tromey <tom@tromey.com>
3548
3549 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
3550
c7dcbf88
AA
35512018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
3552
3553 * symtab.c (print_symbol_info): Skip printing filename and line
3554 number when `last' is NULL.
3555 (symtab_symbol_info): Use empty string instead of NULL for first
3556 invocation of print_symbol_info.
3557 (rbreak_command): Pass NULL to `last' parameter of
3558 print_symbol_info.
3559
07d28c77
SM
35602018-04-16 Simon Marchi <simon.marchi@ericsson.com>
3561
3562 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
3563 instead of nullptr.
3564
8a3de5e1
PA
35652018-04-16 Pedro Alves <palves@redhat.com>
3566
3567 * MAINTAINERS (sh): Remove.
3568 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
3569 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
3570 (ALLDEPFILES): Remove sh64-tdep.c.
3571 * NEWS: Mentions that support for SH-5/SH64 is removed.
3572 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
3573 (sh*-*-openbsd*): Ditto.
3574 (sh64-*-elf*): Remove.
3575 (sh*): Remove.
3576 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
3577 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
3578 * sh-tdep.c: No longer include "sh64-tdep.h".
3579 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
3580 * sh64-tdep.c, sh64-tdep.h: Remove files.
3581
a2a79012
PA
35822018-04-16 Pedro Alves <palves@redhat.com>
3583
3584 * MAINTAINERS: Remove m88k.
3585 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
3586 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
3587 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
3588 * NEWS: Mention that support for m88k was removed.
3589 * configure.host (m88*-*-*): Remove support.
3590 * configure.nat (m88k-*-*): Remove support.
3591 * configure.tgt (m88*-*-openbsd*): Remove.
3592 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
3593
eda4efb1
SM
35942018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
3595
3596 * configure.tgt (x86_tobjs): New variable.
3597 (amd64_tobjs, i386_tobjs): Use it.
3598
b744723f
AA
35992018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3600
3601 * symtab.c (print_symbol_info): Precede the symbol definition by
3602 the line number when available.
3603 * NEWS: Advertise this enhancement.
3604
4a4495d6
MM
36052018-04-13 Markus Metzger <markus.t.metzger@intel.com>
3606
3607 * NEWS (New options): announce set/show record btrace cpu.
3608 * btrace.c: Include record-btrace.h.
3609 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
3610 the vendor is unknown.
3611 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
3612 Maybe overwrite the btrace configuration's cpu.
3613 (btrace_compute_ftrace): Add cpu parameter. Update callers.
3614 (btrace_fetch): Add cpu parameter. Update callers.
3615 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
3616 Maybe overwrite the btrace configuration's cpu. Skip enabling
3617 errata workarounds if the vendor is unknown.
3618 * python/py-record-btrace.c: Include record-btrace.h.
3619 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
3620 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
3621 * record-btrace.c (record_btrace_cpu_state_kind): New.
3622 (record_btrace_cpu): New.
3623 (set_record_btrace_cpu_cmdlist): New.
3624 (record_btrace_get_cpu): New.
3625 (require_btrace_thread, record_btrace_info)
3626 (record_btrace_resume_thread): Call record_btrace_get_cpu.
3627 (cmd_set_record_btrace_cpu_none): New.
3628 (cmd_set_record_btrace_cpu_auto): New.
3629 (cmd_set_record_btrace_cpu): New.
3630 (cmd_show_record_btrace_cpu): New.
3631 (_initialize_record_btrace): Initialize set/show record btrace cpu
3632 commands.
3633 * record-btrace.h (record_btrace_get_cpu): New.
3634
69f90c75
MM
36352018-04-13 Markus Metzger <markus.t.metzger@intel.com>
3636
3637 * record.c (set_record_command): Fix typo in message.
3638
b85310e1
MM
36392018-04-13 Markus Metzger <markus.t.metzger@intel.com>
3640
3641 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
3642
1d509aa6
MM
36432018-04-13 Markus Metzger <markus.t.metzger@intel.com>
3644
3645 * infrun.c (process_event_stop_test): Call
3646 gdbarch_in_indirect_branch_thunk.
3647 * gdbarch.sh (in_indirect_branch_thunk): New.
3648 * gdbarch.c: Regenerated.
3649 * gdbarch.h: Regenerated.
3650 * x86-tdep.h: New.
3651 * x86-tdep.c: New.
3652 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
3653 (HFILES_NO_SRCDIR): Add x86-tdep.h.
3654 (ALLDEPFILES): Add x86-tdep.c.
3655 * arch-utils.h (default_in_indirect_branch_thunk): New.
3656 * arch-utils.c (default_in_indirect_branch_thunk): New.
3657 * i386-tdep: Include x86-tdep.h.
3658 (i386_in_indirect_branch_thunk): New.
3659 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
3660 function.
3661 * amd64-tdep: Include x86-tdep.h.
3662 (amd64_in_indirect_branch_thunk): New.
3663 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
3664
b4be9bfd
JK
36652018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
3666
3667 PR gdb/23053
3668 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
3669 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
3670 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
3671 regression.
3672
53d7df28
TT
36732018-04-12 Tom Tromey <tom@tromey.com>
3674
3675 * rust-lang.c (rust_print_struct_def): Remove univariant code.
3676 (rust_evaluate_subexp): Likewise.
3677
70b33f19
PA
36782018-04-12 Pedro Alves <palves@redhat.com>
3679
3680 * procfs.c (procfs_detach): Make forward declaration's prototype
3681 match definition's protototype.
3682 (proc_get_LDT_entry): Remove stale do_cleanups call.
3683
436411b1
PA
36842018-04-12 Pedro Alves <palves@redhat.com>
3685
3686 * target.h (target_ops::to_has_exited): Delete.
3687 (target_has_exited): Delete.
3688 * target-delegates.c: Regenerate.
3689
20db9c52
PA
36902018-04-11 Pedro Alves <palves@redhat.com>
3691
3692 * target.c (fileio_fh_t::t): Add comment.
3693 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
3694 (target_fileio_close): Handle a NULL target.
3695 (invalidate_fileio_fh): New.
3696 (target_close): Call it.
3697 * remote.c (remote_hostio_send_command): No longer check whether
3698 remote_desc is open.
3699
5ff79300
PA
37002018-04-11 Pedro Alves <palves@redhat.com>
3701
3702 * target.c (fileio_fh_t): Make it a named struct instead of a
3703 typedef.
3704 (fileio_fh_t::is_closed): New method.
3705 (DEF_VEC_O (fileio_fh_t)): Remove.
3706 (fileio_fhandles): Now a std::vector.
3707 (is_closed_fileio_fh): Delete.
3708 (acquire_fileio_fd): Adjust. Rename parameters.
3709 (release_fileio_fd): Adjust.
3710 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
3711 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
3712 (target_fileio_close): Adjust.
3713
6e22e10d
SM
37142018-04-10 Simon Marchi <simon.marchi@ericsson.com>
3715
3716 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
3717 index.
3718
731f534f
PA
37192018-04-10 Pedro Alves <palves@redhat.com>
3720
3721 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
3722 (scoped_finish_thread_state): New class.
3723 * infcmd.c (run_command_1): Use it instead of finish_thread_state
3724 cleanup.
3725 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
3726 (fetch_inferior_event, normal_stop): Likewise.
3727 * thread.c (finish_thread_state_cleanup): Delete.
3728
d5f4488f
SM
37292018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3730 Pedro Alves <palves@redhat.com>
3731
3732 * value.c: Include "selftest.h" and "common/array-view.h".
3733 (struct range) <operator ==>: New.
3734 (test_ranges_contain): New.
3735 (check_ranges_vector): New.
3736 (test_insert_into_bit_range_vector): New.
3737 (_initialize_values): Register selftests.
3738 * common/array-view.h (operator==, operator!=): New.
3739
b24531ed
SM
37402018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3741
3742 * common/gdb_vecs.h (unordered_remove): Add overload that takes
3743 an iterator.
3744 * inline-frame.c: Include <algorithm>.
3745 (struct inline_state): Add constructor.
3746 (inline_state_s): Remove.
3747 (DEF_VEC_O(inline_state_s)): Remove.
3748 (inline_states): Change type to std::vector.
3749 (find_inline_frame_state): Adjust to std::vector.
3750 (allocate_inline_frame_state): Remove.
3751 (clear_inline_frame_state): Adjust to std::vector.
3752 (skip_inline_frames): Adjust to std::vector.
3753
c252925c
SM
37542018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3755
3756 * tracepoint.h (struct trace_state_variable): Add constructor.
3757 <name>: Change type to std::string.
3758 * tracepoint.c (tsv_s): Remove.
3759 (DEF_VEC_O(tsv_s)): Remove.
3760 (tvariables): Change to std::vector.
3761 (create_trace_state_variable): Adjust to std::vector.
3762 (find_trace_state_variable): Likewise.
3763 (find_trace_state_variable_by_number): Likewise.
3764 (delete_trace_state_variable): Likewise.
3765 (trace_variable_command): Adjust to std::string.
3766 (delete_trace_variable_command): Likewise.
3767 (tvariables_info_1): Adjust to std::vector.
3768 (save_trace_state_variables): Likewise.
3769 (start_tracing): Likewise.
3770 (merge_uploaded_trace_state_variables): Adjust to std::vector
3771 and std::string.
3772 * target.h (struct target_ops)
3773 <to_download_trace_state_variable>: Pass reference to
3774 trace_state_variable.
3775 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
3776 * target-delegates.c: Re-generate.
3777 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
3778 (mi_tsv_deleted): Likewise.
3779 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
3780 * remote.c (remote_download_trace_state_variable): Change
3781 pointer to reference and adjust.
3782 * make-target-delegates (parse_argtypes): Handle references.
3783 (write_function_header): Likewise.
3784 (munge_type): Likewise.
3785
c9638d26
SM
37862018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3787
3788 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3789 string_view-selftests.c.
3790 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
3791 testsuite.
3792 * unittests/basic_string_view/cons/char/1.cc: Likewise.
3793 * unittests/basic_string_view/cons/char/2.cc: Likewise.
3794 * unittests/basic_string_view/cons/char/3.cc: Likewise.
3795 * unittests/basic_string_view/element_access/char/1.cc:
3796 Likewise.
3797 * unittests/basic_string_view/element_access/char/empty.cc:
3798 Likewise.
3799 * unittests/basic_string_view/element_access/char/front_back.cc:
3800 Likewise.
3801 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
3802 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
3803 Likewise.
3804 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
3805 Likewise.
3806 * unittests/basic_string_view/modifiers/swap/char/1.cc:
3807 Likewise.
3808 * unittests/basic_string_view/operations/compare/char/1.cc:
3809 Likewise.
3810 * unittests/basic_string_view/operations/compare/char/13650.cc:
3811 Likewise.
3812 * unittests/basic_string_view/operations/copy/char/1.cc:
3813 Likewise.
3814 * unittests/basic_string_view/operations/data/char/1.cc:
3815 Likewise.
3816 * unittests/basic_string_view/operations/find/char/1.cc:
3817 Likewise.
3818 * unittests/basic_string_view/operations/find/char/2.cc:
3819 Likewise.
3820 * unittests/basic_string_view/operations/find/char/3.cc:
3821 Likewise.
3822 * unittests/basic_string_view/operations/find/char/4.cc:
3823 Likewise.
3824 * unittests/basic_string_view/operations/rfind/char/1.cc:
3825 Likewise.
3826 * unittests/basic_string_view/operations/rfind/char/2.cc:
3827 Likewise.
3828 * unittests/basic_string_view/operations/rfind/char/3.cc:
3829 Likewise.
3830 * unittests/basic_string_view/operations/substr/char/1.cc:
3831 Likewise.
3832 * unittests/basic_string_view/operators/char/2.cc: Likewise.
3833 * unittests/string_view-selftests.c: New file.
3834
fdc11678
SM
38352018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3836
3837 * unittests/basic_string_view/capacity/1.cc: New file.
3838 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
3839 * unittests/basic_string_view/cons/char/1.cc: New file.
3840 * unittests/basic_string_view/cons/char/2.cc: New file.
3841 * unittests/basic_string_view/cons/char/3.cc: New file.
3842 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
3843 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
3844 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
3845 * unittests/basic_string_view/element_access/char/1.cc: New file.
3846 * unittests/basic_string_view/element_access/char/2.cc: New file.
3847 * unittests/basic_string_view/element_access/char/empty.cc: New file.
3848 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
3849 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
3850 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
3851 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
3852 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
3853 * unittests/basic_string_view/include.cc: New file.
3854 * unittests/basic_string_view/inserters/char/1.cc: New file.
3855 * unittests/basic_string_view/inserters/char/2.cc: New file.
3856 * unittests/basic_string_view/inserters/char/3.cc: New file.
3857 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
3858 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
3859 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
3860 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
3861 * unittests/basic_string_view/literals/types.cc: New file.
3862 * unittests/basic_string_view/literals/values.cc: New file.
3863 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
3864 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
3865 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
3866 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
3867 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
3868 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
3869 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
3870 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
3871 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
3872 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
3873 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
3874 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
3875 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
3876 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
3877 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
3878 * unittests/basic_string_view/operations/data/char/1.cc: New file.
3879 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
3880 * unittests/basic_string_view/operations/find/char/1.cc: New file.
3881 * unittests/basic_string_view/operations/find/char/2.cc: New file.
3882 * unittests/basic_string_view/operations/find/char/3.cc: New file.
3883 * unittests/basic_string_view/operations/find/char/4.cc: New file.
3884 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
3885 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
3886 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
3887 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
3888 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
3889 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
3890 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
3891 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
3892 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
3893 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
3894 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
3895 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
3896 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
3897 * unittests/basic_string_view/operators/char/2.cc: New file.
3898 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
3899 * unittests/basic_string_view/range_access/char/1.cc: New file.
3900 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
3901 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
3902 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
3903 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
3904 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
3905 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
3906 * unittests/basic_string_view/requirements/typedefs.cc: New file.
3907 * unittests/basic_string_view/typedefs.cc: New file.
3908 * unittests/basic_string_view/types/1.cc: New file.
3909
8345c4a2
SM
39102018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3911
3912 * common/gdb_string_view.h: Remove libstdc++ implementation
3913 details, adjust to gdb reality.
3914 * common/gdb_string_view.tcc: Likewise.
3915 * cli/cli-script.c (struct string_view): Remove.
3916 (user_args) <m_args>: Change element type to gdb::string_view.
3917 (user_args::insert_args): Adjust.
3918
7adcdf08
SM
39192018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3920
3921 * common/gdb_string_view.h: New file.
3922 * common/gdb_string_view.tcc: New file.
3923
41260ac2
SM
39242018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3925
3926 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
3927 * configure: Re-generate.
3928
0bee6dd4
PA
39292018-04-09 Pedro Alves <palves@redhat.com>
3930
3931 * gdbarch.sh: Include "observable.h" instead of "observer.h".
3932 (set_target_gdbarch): Call
3933 gdb::observers::architecture_changed.notify instead of
3934 observer_notify_architecture_changed.
3935
6f14adc5
SM
39362018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3937
3938 * tracepoint.c (struct current_traceframe_cleanup): Remove.
3939 (do_restore_current_traceframe_cleanup): Remove.
3940 (restore_current_traceframe_cleanup_dtor): Remove.
3941 (make_cleanup_restore_current_traceframe): Remove.
3942 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
3943 New.
3944 * tracepoint.h (struct scoped_restore_current_traceframe): New.
3945 * infrun.c (fetch_inferior_event): Use
3946 scoped_restore_current_traceframe.
3947
b2bdb8cf
SM
39482018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3949
3950 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
3951 Remove.
3952 <n_allocated_type_units>: Remove.
3953 <all_type_units>: Change to std::vector.
3954 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
3955 to std::vector change.
3956 (dwarf2_per_objfile::get_cutu): Likewise.
3957 (dwarf2_per_objfile::get_tu): Likewise.
3958 (create_signatured_type_table_from_index): Likewise.
3959 (create_signatured_type_table_from_debug_names): Likewise.
3960 (dw2_symtab_iter_next): Likewise.
3961 (dw2_print_stats): Likewise.
3962 (dw2_expand_all_symtabs): Likewise.
3963 (dw2_expand_marked_cus): Likewise.
3964 (dw2_debug_names_iterator::next): Likewise.
3965 (dwarf2_initialize_objfile): Likewise.
3966 (add_signatured_type_cu_to_table): Likewise.
3967 (create_all_type_units): Likewise.
3968 (add_type_unit): Likewise.
3969 (struct tu_abbrev_offset): Add constructor.
3970 (build_type_psymtabs_1): Adjust to std::vector change.
3971 (print_tu_stats): Likewise.
3972 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
3973 (write_debug_names): Likewise.
3974
b76e467d
SM
39752018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3976
3977 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
3978 Make an std::vector.
3979 <n_comp_units>: Remove.
3980 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
3981 to std::vector change.
3982 (dwarf2_per_objfile::get_cutu): Likewise.
3983 (dwarf2_per_objfile::get_cu): Likewise.
3984 (create_cus_from_index): Likewise.
3985 (create_addrmap_from_index): Likewise.
3986 (create_addrmap_from_aranges): Likewise.
3987 (dwarf2_read_index): Likewise.
3988 (dw2_find_last_source_symtab): Likewise.
3989 (dw2_map_symtabs_matching_filename): Likewise.
3990 (dw2_symtab_iter_next): Likewise.
3991 (dw2_print_stats): Likewise.
3992 (dw2_expand_all_symtabs): Likewise.
3993 (dw2_expand_symtabs_with_fullname): Likewise.
3994 (dw2_expand_marked_cus): Likewise.
3995 (dw2_map_symbol_filenames): Likewise.
3996 (create_cus_from_debug_names): Likewise.
3997 (dwarf2_read_debug_names): Likewise.
3998 (dw2_debug_names_iterator::next): Likewise.
3999 (dwarf2_initialize_objfile): Likewise.
4000 (set_partial_user): Likewise.
4001 (dwarf2_build_psymtabs_hard): Likewise.
4002 (read_comp_units_from_section): Remove arguments, adjust to
4003 std::vector change.
4004 (create_all_comp_units): Adjust to std::vector and
4005 read_comp_units_from_section changes.
4006 (dwarf2_find_containing_comp_unit): Adjust to std::vector
4007 change.
4008 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
4009 (psyms_seen_size): Likewise.
4010 (write_gdbindex): Likewise.
4011 (write_debug_names): Likewise.
4012
12359b5e
SM
40132018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4014
4015 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
4016 with dwarf2_per_objfile.
4017 (create_cus_from_index): Likewise.
4018 (create_signatured_type_table_from_index): Likewise.
4019 (dwarf2_read_index): Likewise.
4020 (dwarf2_initialize_objfile): Likewise.
4021 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
4022 per_cu rather than get_dwarf2_per_objfile.
4023
ff4c9fec
SM
40242018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4025
4026 * dwarf2read.h (struct signatured_type): Forward declare.
4027 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
4028 New methods.
4029 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
4030 (dw2_get_cutu): ...this.
4031 (dwarf2_per_objfile::get_cu): Rename from...
4032 (dw2_get_cu): ...this.
4033 (dwarf2_per_objfile::get_tu): New.
4034 (create_addrmap_from_index): Adjust.
4035 (create_addrmap_from_aranges): Adjust.
4036 (dw2_find_last_source_symtab): Adjust.
4037 (dw2_map_symtabs_matching_filename): Adjust.
4038 (dw2_symtab_iter_next): Adjust.
4039 (dw2_print_stats): Adjust.
4040 (dw2_expand_all_symtabs): Adjust.
4041 (dw2_expand_symtabs_with_fullname): Adjust.
4042 (dw2_expand_marked_cus): Adjust.
4043 (dw_expand_symtabs_matching_file_matcher): Adjust.
4044 (dw2_map_symbol_filenames): Adjust.
4045 (dw2_debug_names_iterator::next): Adjust.
4046 (dwarf2_initialize_objfile): Adjust.
4047 (set_partial_user): Adjust.
4048 (dwarf2_build_psymtabs_hard): Adjust.
4049
5ca3fcb6
SM
40502018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4051
4052 * dwarf2read.c (create_signatured_type_table_from_debug_names):
4053 Remove unused variables.
4054 (dw2_map_symtabs_matching_filename): Likewise.
4055 (dwarf2_record_block_ranges): Likewise.
4056 (dwarf2_read_addr_index): Likewise.
4057 (follow_die_offset): Likewise.
4058
b2e586e8
SM
40592018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4060
4061 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
4062 to symbol_file_add_main.
4063
7c4e78cf
SM
40642018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4065
4066 PR mi/22299
4067 * mi/mi-console.c (do_fputc_async_safe): New.
4068 (mi_console_file::write_async_safe): New.
4069 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
4070 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
4071 New.
4072 * ui-file.c (ui_file::putstrn): Adjust call to
4073 fputstrn_unfiltered.
4074 * utils.c (printchar): Replace do_fputs and do_fprintf
4075 parameters by do_fputc.
4076 (fputstr_filtered): Adjust call to printchar.
4077 (fputstr_unfiltered): Likewise.
4078 (fputstrn_filtered): Likewise.
4079 (fputstrn_unfiltered): Add do_fputc parameter, pass to
4080 printchar.
4081 * utils.h (do_fputc_ftype): New typedef.
4082 (fputstrn_unfiltered): Add do_fputc parameter.
4083
5dc026d3
SM
40842018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4085
4086 * regformats/i386/i386-avx.dat: Remove.
4087
c912f608
SM
40882018-04-07 Simon Marchi <simon.marchi@ericsson.com>
4089
4090 PR gdb/22979
4091 * amd64-tdep.c (amd64_none_init_abi): New function.
4092 (amd64_x32_none_init_abi): New function.
4093 (_initialize_amd64_tdep): Register handlers for x86-64 and
4094 x64_32 with GDB_OSABI_NONE.
4095 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
4096 GDB_OSABI_NONE osabi.
4097
26540402
SM
40982018-04-07 Simon Marchi <simon.marchi@ericsson.com>
4099
4100 PR gdb/22980
4101 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
4102 GDB_OSABI_NONE.
4103 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
4104 * osabi.c (gdb_osabi_names): Add "unknown" entry.
4105
9018be22
SM
41062018-04-07 Simon Marchi <simon.marchi@ericsson.com>
4107
4108 * common/byte-vector.h (char_vector): New type.
4109 * target.h (target_read_alloc): Return
4110 gdb::optional<byte_vector>.
4111 (target_read_stralloc): Return gdb::optional<char_vector>.
4112 (target_get_osdata): Return gdb::optional<char_vector>.
4113 * target.c (target_read_alloc_1): Templatize. Replacement
4114 manual memory management with vector.
4115 (target_read_alloc): Change return type, adjust.
4116 (target_read_stralloc): Change return type, adjust.
4117 (target_get_osdata): Change return type, adjust.
4118 * auxv.c (struct auxv_info) <length>: Remove.
4119 <data>: Change type to gdb::optional<byte_vector>.
4120 (auxv_inferior_data_cleanup): Free auxv_info with delete.
4121 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
4122 (target_auxv_search): Adjust.
4123 (fprint_target_auxv): Adjust.
4124 * avr-tdep.c (avr_io_reg_read_command): Adjust.
4125 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
4126 (linux_make_corefile_notes): Adjust.
4127 * osdata.c (get_osdata): Adjust.
4128 * remote.c (remote_get_threads_with_qxfer): Adjust.
4129 (remote_memory_map): Adjust.
4130 (remote_traceframe_info): Adjust.
4131 (btrace_read_config): Adjust.
4132 (remote_read_btrace): Adjust.
4133 (remote_pid_to_exec_file): Adjust.
4134 * solib-aix.c (solib_aix_get_library_list): Adjust.
4135 * solib-dsbt.c (decode_loadmap): Don't free buf.
4136 (dsbt_get_initial_loadmaps): Adjust.
4137 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
4138 * solib-target.c (solib_target_current_sos): Adjust.
4139 * tracepoint.c (sdata_make_value): Adjust.
4140 * xml-support.c (xinclude_start_include): Adjust.
4141 (xml_fetch_content_from_file): Adjust.
4142 * xml-support.h (xml_fetch_another): Change return type.
4143 (xml_fetch_content_from_file): Change return type.
4144 * xml-syscall.c (xml_init_syscalls_info): Adjust.
4145 * xml-tdesc.c (file_read_description_xml): Adjust.
4146 (fetch_available_features_from_target): Change return type.
4147 (target_fetch_description_xml): Adjust.
4148 (target_read_description_xml): Adjust.
4149
14c88955
TT
41502018-04-06 Tom Tromey <tom@tromey.com>
4151
4152 * value.c (~value): Update.
4153 (struct value) <contents>: Now unique_xmalloc_ptr.
4154 (value_contents_bits_eq, allocate_value_contents)
4155 (value_contents_raw, value_contents_all_raw)
4156 (value_contents_for_printing, value_contents_for_printing_const)
4157 (set_value_enclosing_type): Update.
4158
0c7e6dd8
TT
41592018-04-06 Tom Tromey <tom@tromey.com>
4160
4161 * value.c (range_s): Remove typedef, VEC.
4162 (struct range): Add operator<.
4163 (range_lessthan): Remove.
4164 (ranges_contain): Change type.
4165 (~value): Update.
4166 (struct value) <unavailable, optimized_out>: Now std::vector.
4167 (value_entirely_available)
4168 (value_entirely_covered_by_range_vector)
4169 (value_entirely_unavailable, value_entirely_optimized_out):
4170 Update.
4171 (insert_into_bit_range_vector): Change argument type.
4172 (find_first_range_overlap): Likewise.
4173 (struct ranges_and_idx, value_contents_bits_eq)
4174 (require_not_optimized_out, require_available): Update.
4175 (ranges_copy_adjusted): Change argument types.
4176 (value_optimized_out, value_copy, value_fetch_lazy): Update.
4177
2c8331b9
TT
41782018-04-06 Tom Tromey <tom@tromey.com>
4179
4180 * value.c (~value): Update.
4181 (struct value) <parent>: Now a value_ref_ptr.
4182 (value_parent, set_value_parent, value_address, value_copy):
4183 Update.
4184
466ce3ae
TT
41852018-04-06 Tom Tromey <tom@tromey.com>
4186
4187 * value.c (struct value): Add constructor, destructor, and member
4188 initializers.
4189 (allocate_value_lazy, value_decref): Update.
4190
062d818d
TT
41912018-04-06 Tom Tromey <tom@tromey.com>
4192
4193 * value.c (struct value) <released, next>: Remove.
4194 (all_values): Now a std::vector.
4195 (allocate_value_lazy): Update.
4196 (value_next): Remove.
4197 (value_mark, value_free_to_mark, release_value)
4198 (value_release_to_mark): Update.
4199
a6535de1
TT
42002018-04-06 Tom Tromey <tom@tromey.com>
4201
4202 * value.h (fetch_subexp_value, value_release_to_mark): Update.
4203 (free_value_chain): Remove.
4204 * value.c (free_value_chain): Remove.
4205 (value_release_to_mark): Return a std::vector.
4206 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
4207 std::vector.
4208 (check_condition): Update.
4209 * eval.c (fetch_subexp_value): Change "val_chain" to a
4210 std::vector.
4211 * breakpoint.c (update_watchpoint): Update.
4212 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
4213
b5621201
TT
42142018-04-06 Tom Tromey <tom@tromey.com>
4215
4216 * value.h (free_all_values): Remove.
4217 * value.c (free_all_values): Remove.
4218
4d0266a0
TT
42192018-04-06 Tom Tromey <tom@tromey.com>
4220
4221 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
4222 (value_history_chain, value_history_count): Remove.
4223 (value_history): New global.
4224 (record_latest_value, access_value_history, show_values)
4225 (preserve_values): Update.
4226
b4d61099
TT
42272018-04-06 Tom Tromey <tom@tromey.com>
4228
4229 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
4230 * varobj.c (varobj_set_display_format, varobj_set_value)
4231 (install_default_visualizer, construct_visualizer)
4232 (install_new_value, ~varobj, varobj_get_value_type)
4233 (my_value_of_variable, varobj_editable_p): Update.
4234 * c-varobj.c (c_describe_child, c_value_of_variable)
4235 (cplus_number_of_children, cplus_describe_child): Update.
4236 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
4237 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
4238 (ada_value_of_variable, ada_value_is_changeable_p): Update.
4239
9b558729
TT
42402018-04-06 Tom Tromey <tom@tromey.com>
4241
4242 * printcmd.c (last_examine_address): Change type to
4243 value_ref_ptr.
4244 (do_examine, x_command): Update.
4245
850645cf
TT
42462018-04-06 Tom Tromey <tom@tromey.com>
4247
4248 * value.c (release_value): Update.
4249 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
4250 (struct bpstats) <val>: Now a value_ref_ptr.
4251 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
4252 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
4253 (~watchpoint, print_it_watchpoint, watch_command_1)
4254 (invalidate_bp_value_on_memory_change): Update.
4255
22bc8444
TT
42562018-04-06 Tom Tromey <tom@tromey.com>
4257
4258 * varobj.c (varobj_clear_saved_item)
4259 (update_dynamic_varobj_children, install_new_value, ~varobj):
4260 Update.
4261 * value.h (value_incref): Move declaration earlier.
4262 (value_decref): Rename from value_free.
4263 (struct value_ref_policy): New.
4264 (value_ref_ptr): New typedef.
4265 (struct value_deleter): Remove.
4266 (gdb_value_up): Remove typedef.
4267 (release_value): Change return type.
4268 (release_value_or_incref): Remove.
4269 * value.c (set_value_parent): Update.
4270 (value_incref): Change return type.
4271 (value_decref): Rename from value_free.
4272 (value_free_to_mark, free_all_values, free_value_chain): Update.
4273 (release_value): Return value_ref_ptr.
4274 (release_value_or_incref): Remove.
4275 (record_latest_value, set_internalvar, clear_internalvar):
4276 Update.
4277 * stack.c (info_frame_command): Don't call value_free.
4278 * python/py-value.c (valpy_dealloc, valpy_new)
4279 (value_to_value_object): Update.
4280 * printcmd.c (do_examine): Update.
4281 * opencl-lang.c (lval_func_free_closure): Update.
4282 * mi/mi-main.c (register_changed_p): Don't call value_free.
4283 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
4284 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
4285 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
4286 value_free.
4287 * guile/scm-value.c (vlscm_free_value_smob)
4288 (vlscm_scm_from_value): Update.
4289 * frame.c (frame_register_unwind, frame_unwind_register_signed)
4290 (frame_unwind_register_unsigned, get_frame_register_bytes)
4291 (put_frame_register_bytes): Don't call value_free.
4292 * findvar.c (address_from_register): Don't call value_free.
4293 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
4294 * dwarf2loc.c (entry_data_value_free_closure)
4295 (value_of_dwarf_reg_entry, free_pieced_value_closure)
4296 (dwarf2_evaluate_loc_desc_full): Update.
4297 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
4298 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
4299 (~watchpoint, watch_command_1)
4300 (invalidate_bp_value_on_memory_change): Update.
4301 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
4302
7f8a5d38
SM
43032018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
4304
4305 PR gdb/23022
4306 * warning.m4: Add -Wno-error=deprecated-register.
4307 * configure: Re-generate.
4308
8a76bd3b
TT
43092018-04-05 Tom Tromey <tom@tromey.com>
4310
4311 * linespec.h: Remove include of "vec.h".
4312
8e8d776e
TT
43132018-04-05 Tom Tromey <tom@tromey.com>
4314
4315 * linespec.c (typep): Remove typedef.
4316 (find_methods, find_superclass_methods): Take a std::vector.
4317 (find_method): Use std::vector.
4318
9b2f8581
TT
43192018-04-05 Tom Tromey <tom@tromey.com>
4320
4321 * utils.c (compare_strings): Remove.
4322 * utils.h (compare_strings): Remove.
4323 * objc-lang.h (find_imps): Update.
4324 * objc-lang.c (find_methods): Take a std::vector.
4325 (uniquify_strings, find_imps): Likewise.
4326 * linespec.c (find_methods): Take a std::vector.
4327 (decode_objc): Use std::vector.
4328 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
4329 a std::vector.
4330 (find_method, find_function_symbols): Use std::vector.
4331
459a2e4c
TT
43322018-04-05 Tom Tromey <tom@tromey.com>
4333
4334 * completer.c (completion_tracker::completion_tracker): Remove
4335 cast.
4336 (completion_tracker::discard_completions): Likewise.
4337 * breakpoint.c (ambiguous_names_p): Remove cast.
4338 * ada-lang.c (_initialize_ada_language): Remove cast.
4339 * utils.h (streq): Update.
4340 (streq_hash): Add new declaration.
4341 * utils.c (streq): Return bool.
4342 (streq_hash): New function.
4343
9be2c17a
TT
43442018-04-05 Tom Tromey <tom@tromey.com>
4345
4346 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
4347 Remove a string copy.
4348
f73c6ece
TT
43492018-04-05 Tom Tromey <tom@tromey.com>
4350
4351 * linespec.c (filter_results): Use std::vector.
4352 (decode_line_2, decode_line_full): Update.
4353
53a0f8a2
TT
43542018-04-05 Tom Tromey <tom@tromey.com>
4355
4356 * linespec.c (canonical_to_fullform): Return std::string.
4357 (filter_results): Update.
4358 (struct decode_line_2_item): Add constructor.
4359 <fullform, displayform>: Now std::string.
4360 (decode_line_2_compare_items): Now a std::sort comparator.
4361 (decode_line_2): Update.
4362
a5b5adf5
TT
43632018-04-05 Tom Tromey <tom@tromey.com>
4364
4365 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
4366 (unexpected_linespec_error): Update.
4367 (linespec_parse_basic, parse_linespec): Update.
4368
6a307fc5
TT
43692018-04-05 Tom Tromey <tom@tromey.com>
4370
4371 * linespec.c (linespec_parse_basic): Reindent.
4372
41c1efc6
TT
43732018-04-05 Tom Tromey <tom@tromey.com>
4374
4375 * minsyms.h (iterate_over_minimal_symbols): Update.
4376 * minsyms.c (iterate_over_minimal_symbols): Take a
4377 gdb::function_view.
4378 * linespec.c (struct collect_minsyms): Remove.
4379 (compare_msyms): Now a std::sort comparator.
4380 (add_minsym): Add parameters.
4381 (search_minsyms_for_name): Update. Use std::vector.
4382
c5edbf3d
TT
43832018-04-03 Tom Tromey <tom@tromey.com>
4384
4385 * mipsread.c (read_alphacoff_dynamic_symtab): Use
4386 gdb::byte_vector.
4387
b39efc48
WP
43882018-04-02 Weimin Pan <weimin.pan@oracle.com>
4389
4390 * MAINTAINERS (Write After Approval): Add Weimin Pan.
4391
121ad66c 43922018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
4393
4394 PR gdb/16959
4395 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
4396 printing static type.
4397
09473be8
TT
43982018-04-01 Tom Tromey <tom@tromey.com>
4399
4400 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
4401 (rs6000_xfer_shared_libraries): Update.
4402
ec1f2d91
SM
44032018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
4404
4405 * common/gdb_vecs.h (char_ptr): Remove.
4406 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
4407
d8611974
SM
44082018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
4409
4410 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
4411 with std::vector.
4412 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
4413
a18ba4e4
SM
44142018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
4415
4416 * tracepoint.h (struct uploaded_tp): Initialize fields.
4417 <actions, step_actions, cmd_strings>: Change type to
4418 std::vector<char *>.
4419 * tracepoint.c (get_uploaded_tp): Allocate with new.
4420 (free_uploaded_tps): Free with delete.
4421 (parse_tracepoint_definition): Adjust to std::vector change.
4422 * breakpoint.c (read_uploaded_action): Likewise.
4423 (create_tracepoint_from_upload): Likewise.
4424 * ctf.c (ctf_write_uploaded_tp): Likewise.
4425 (SET_ARRAY_FIELD): Likewise.
4426 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
4427
a7961323
TT
44282018-03-30 Tom Tromey <tom@tromey.com>
4429
4430 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
4431 std::unique_ptr.
4432 (svr4_keep_data_in_core): Update.
4433 (svr4_read_so_list): Update.
4434
e83e4e24
TT
44352018-03-30 Tom Tromey <tom@tromey.com>
4436
4437 * windows-nat.c (handle_output_debug_string, handle_exception):
4438 Update.
4439 * target.h (target_read_string): Update.
4440 * target.c (target_read_string): Change "string" to
4441 unique_xmalloc_ptr.
4442 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
4443 Update.
4444 * solib-frv.c (frv_current_sos): Update.
4445 * solib-dsbt.c (dsbt_current_sos): Update.
4446 * solib-darwin.c (darwin_current_sos): Update.
4447 * linux-thread-db.c (inferior_has_bug): Update.
4448 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
4449 Update. Remove alloca.
4450 * ada-lang.c (ada_main_name): Update.
4451
263db9a1
TT
44522018-03-30 Tom Tromey <tom@tromey.com>
4453
4454 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
4455 (struct dwo_file_deleter): New.
4456 (dwo_file_up): New typedef.
4457 (open_and_init_dwo_file): Use dwo_file_up.
4458 (free_dwo_file_cleanup): Remove.
4459
5dafb3d1
TT
44602018-03-30 Tom Tromey <tom@tromey.com>
4461
4462 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
4463 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
4464
11ed8cad
TT
44652018-03-30 Tom Tromey <tom@tromey.com>
4466
4467 * dwarf2read.c (class free_cached_comp_units): New class.
4468 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
4469 (free_cached_comp_units): Remove function.
4470
9ae79dac
TT
44712018-03-30 Tom Tromey <tom@tromey.com>
4472
4473 * utils.h (make_cleanup_unpush_target): Remove.
4474 * inf-ptrace.c (struct target_unpusher): New.
4475 (target_unpush_up) New typedef.
4476 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
4477 target_unpush_up.
4478 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
4479
5aa89276
TT
44802018-03-27 Tom Tromey <tom@tromey.com>
4481
4482 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
4483
1dbeed45
TT
44842018-03-27 Pedro Alves <palves@redhat.com>
4485 Tom Tromey <tom@tromey.com>
4486
4487 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
4488 destructor. Now a class.
4489 (gdb_readline_wrapper_cleanup): Remove function.
4490 (gdb_readline_wrapper): Remove cleanups.
4491
c819b2c0
TT
44922018-03-27 Tom Tromey <tom@tromey.com>
4493
4494 * typeprint.h (struct type_print_options) <local_typedefs,
4495 global_typedefs>: Remove "struct" keyword.
4496 (class typedef_hash_table): New class.
4497 (recursively_update_typedef_hash, add_template_parameters)
4498 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
4499 (find_typedef_in_hash): Don't declare.
4500 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
4501 (typedef_hash_table::recursively_update): Rename from
4502 recursively_update_typedef_hash. Now a member.
4503 (typedef_hash_table::add_template_parameters): Rename from
4504 add_template_parameters. Now a member.
4505 (typedef_hash_table::typedef_hash_table): Now a constructor;
4506 rename from create_typedef_hash.
4507 (typedef_hash_table::~typedef_hash_table): Now a destructor;
4508 rename from free_typedef_hash.
4509 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
4510 (do_free_global_table): Remove.
4511 (typedef_hash_table::typedef_hash_table): New constructor; renamed
4512 from copy_type_recursive.
4513 (create_global_typedef_table): Remove.
4514 (typedef_hash_table::find_global_typedef): Now a member of
4515 typedef_hash_table.
4516 (typedef_hash_table::find_typedef): Rename from
4517 find_typedef_in_hash; now a member.
4518 (whatis_exp): Update.
4519 * extension.h (struct ext_lang_type_printers): Add constructor and
4520 destructor.
4521 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
4522 declare.
4523 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
4524 Now a constructor; rename from start_ext_lang_type_printers.
4525 (ext_lang_type_printers): Now a destructor; rename from
4526 free_ext_lang_type_printers.
4527 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
4528 Update.
4529 (c_type_print_base_struct_union): Update. Remove cleanups.
4530
608219fb
TT
45312018-03-27 Tom Tromey <tom@tromey.com>
4532
4533 * dwarf-index-write.c: Include <cmath>.
4534
3fcded8f
JB
45352018-03-27 Joel Brobecker <brobecker@adacore.com>
4536
4537 * NEWS: Add entry describing new "set|show varsize-limit" command.
4538 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
4539 command.
4540 * printcmd.c (_initialize_printcmd): Add "set var" alias of
4541 "set variable".
4542
cd4fb1b2
SM
45432018-03-27 Simon Marchi <simon.marchi@ericsson.com>
4544
4545 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
4546 dwarf-index-write.c
4547 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
4548 * dwarf-index-common.c: New file.
4549 * dwarf-index-common.h: New file.
4550 * dwarf-index-write.c: New file.
4551 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
4552 (struct dwarf2_section_info): Move from here.
4553 (dwarf2_section_info_def): Likewise.
4554 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
4555 (offset_type): Likewise.
4556 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
4557 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
4558 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
4559 (byte_swap): Likewise.
4560 (MAYBE_SWAP): Likewise.
4561 (dwarf2_per_cu_ptr): Likewise.
4562 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
4563 (struct tu_stats): Likewise.
4564 (struct dwarf2_per_objfile): Likewise.
4565 (struct dwarf2_per_cu_data): Likewise.
4566 (struct signatured_type): Likewise.
4567 (sig_type_ptr): Likewise.
4568 (DEF_VEC_P (sig_type_ptr)): Likewise.
4569 (INDEX4_SUFFIX): Likewise.
4570 (INDEX5_SUFFIX): Likewise.
4571 (DEBUG_STR_SUFFIX): Likewise.
4572 (dwarf2_read_section): Make non-static.
4573 (mapped_index_string_hash): Move from here.
4574 (dwarf5_djb_hash): Likewise.
4575 (file_write): Likewise.
4576 (class data_buf): Likewise.
4577 (struct symtab_index_entry): Likewise.
4578 (struct mapped_symtab): Likewise.
4579 (find_slot): Likewise.
4580 (hash_expand): Likewise.
4581 (add_index_entry): Likewise.
4582 (uniquify_cu_indices): Likewise.
4583 (class c_str_view): Likewise.
4584 (class c_str_view_hasher): Likewise.
4585 (class vector_hasher): Likewise.
4586 (write_hash_table): Likewise.
4587 (psym_index_map): Likewise.
4588 (struct addrmap_index_data): Likewise.
4589 (add_address_entry): Likewise.
4590 (add_address_entry_worker): Likewise.
4591 (write_address_map): Likewise.
4592 (symbol_kind): Likewise.
4593 (write_psymbols): Likewise.
4594 (struct signatured_type_index_data): Likewise.
4595 (write_one_signatured_type): Likewise.
4596 (recursively_count_psymbols): Likewise.
4597 (recursively_write_psymbols): Likewise.
4598 (class debug_names): Likewise.
4599 (check_dwarf64_offsets): Likewise.
4600 (psyms_seen_size): Likewise.
4601 (write_gdbindex): Likewise.
4602 (write_debug_names): Likewise.
4603 (assert_file_size): Likewise.
4604 (write_psymtabs_to_index): Likewise.
4605 (save_gdb_index_command): Likewise.
4606 (_initialize_dwarf2_read): Don't register the "save gdb-index"
4607 command.
4608 * dwarf2read.h: New file.
4609
59cc4834
JB
46102018-03-27 Joel Brobecker <brobecker@adacore.com>
4611
4612 PR gdb/22670
4613 * dwarf2read.c (dwarf2_physname): Do not return the demangled
4614 symbol name if the CU's language stores symbol names in linkage
4615 format.
4616 * language.h (struct language_defn)
4617 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
4618 all instances of this struct.
4619
67501539
TT
46202018-03-26 Tom Tromey <tom@tromey.com>
4621
4622 * stack.c (backtrace_command_1): Remove verbose code.
4623
76c939ac
TT
46242018-03-26 Tom Tromey <tom@tromey.com>
4625
4626 * python/py-framefilter.c (py_print_type): Don't catch
4627 exceptions. Return void.
4628 (py_print_value): Likewise.
4629 (py_print_single_arg): Likewise.
4630 (enumerate_args): Don't catch exceptions.
4631 (py_print_args): Likewise.
4632 (py_print_frame): Likewise.
4633 (gdbpy_apply_frame_filter): Catch exceptions here.
4634
9507b29c
TT
46352018-03-26 Tom Tromey <tom@tromey.com>
4636
4637 * stack.c (_initialize_stack): Remove trailing newlines from help
4638 text. Add "Usage" line to "backtrace" help.
4639
eb68e487
TT
46402018-03-26 Tom Tromey <tom@tromey.com>
4641
4642 PR python/16486:
4643 * python/py-framefilter.c (py_print_args): Call wrap_hint.
4644
1f111921
TT
46452018-03-26 Tom Tromey <tom@tromey.com>
4646
4647 * python/py-framefilter.c (py_print_single_arg): Return
4648 EXT_LANG_BT_ERROR from catch.
4649
fb7eb8b5
TT
46502018-03-26 Tom Tromey <tom@tromey.com>
4651
4652 PR backtrace/15584:
4653 * stack.c (backtrace_command_1): Move some code into no-filters
4654 "if".
4655
4ca59a9f
TT
46562018-03-26 Tom Tromey <tom@tromey.com>
4657
4658 * python/py-framefilter.c (throw_quit_or_print_exception): New
4659 function.
4660 (gdbpy_apply_frame_filter): Use it.
4661
92256134
TT
46622018-03-26 Tom Tromey <tom@tromey.com>
4663
4664 PR cli/17716:
4665 * python/py-framefilter.c (py_print_type, py_print_value)
4666 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
4667 RETURN_MASK_ERROR.
4668
7a630bc2
TT
46692018-03-26 Tom Tromey <tom@tromey.com>
4670
4671 * python/py-framefilter.c (enumerate_args): Use
4672 gdb::unique_xmalloc_ptr.
4673
63283d4a
TT
46742018-03-26 Tom Tromey <tom@tromey.com>
4675
4676 * python/py-framefilter.c (py_print_frame): Return
4677 EXT_LANG_BT_OK.
4678 (gdbpy_apply_frame_filter): Update comment.
4679 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
4680 Remove.
4681 <EXT_LANG_BT_NO_FILTERS>: Change value.
4682
978d6c75
TT
46832018-03-26 Tom Tromey <tom@tromey.com>
4684
4685 PR backtrace/15582:
4686 * stack.c (backtrace_command): Parse "hide" argument.
4687 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
4688 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
4689 constant.
4690
1cf7e640
TT
46912018-03-26 Tom Tromey <tom@tromey.com>
4692
4693 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
4694 add "flags".
4695 (backtrace_command): Remove "fulltrace", add "flags".
4696
ea3b0687
TT
46972018-03-26 Tom Tromey <tom@tromey.com>
4698
4699 * stack.c (backtrace_command): Rewrite command line parsing.
4700
9f034d75
SM
47012018-03-26 Simon Marchi <simon.marchi@ericsson.com>
4702
4703 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
4704
ce1459e5
SM
47052018-03-26 Simon Marchi <simon.marchi@ericsson.com>
4706
4707 * filename-seen-cache.h: Add include guard.
4708
4f7ae6f5
KS
47092018-03-26 Keith Seitz <keiths@redhat.com>
4710
4711 * symfile.c (place_section): Remove "struct" from section_addr_info
4712 in comment.
4713 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
4714 "struct" keyword from section_addr_info.
4715
5cd3e386
AH
47162018-03-26 Alan Hayward <alan.hayward@arm.com>
4717
4718 * regformats/regdef.h (reg): Add constructors.
4719
3e5ef9a4
PA
47202018-03-25 Pedro Alves <palves@redhat.com>
4721
4722 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
4723 if then/else bodies in var_func_name extraction.
4724
c88d2fcc 47252018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
4726
4727 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
4728 lookup_minimal_symbol() to find symbol entry.
4729 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
4730
b7fee5a3
KS
47312018-03-23 Keith Seitz <keiths@redhat.com>
4732
4733 PR c++/22968
4734 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
4735 nested type definitions for C++, too.
4736
2cc9b304
TT
47372018-03-23 Tom Tromey <tom@tromey.com>
4738
4739 * machoread.c (struct oso_el): Add a constructor. Don't define as
4740 a typedef.
4741 (macho_register_oso): Remove.
4742 (macho_symtab_read): Take a std::vector.
4743 (oso_el_compare_name): Now a std::sort comparator.
4744 (macho_symfile_read_all_oso): Take a std::vector.
4745 (macho_symfile_read): Use std::vector. Remove cleanups.
4746
a2b2bc12
TT
47472018-03-22 Tom Tromey <tom@tromey.com>
4748
4749 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
4750 (record_full_goto_bookmark): Use std::string.
4751
7a8f494c
PFC
47522018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4753
4754 PR tdep/18295
4755 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
4756 a single mask.
4757
dd6d677f
PFC
47582018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4759
4760 * rs6000-tdep.c (store_insn_p): New function.
4761 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
4762 and cr_reg to their unshifted values. Use store_insn_p to
4763 match LR saves using either R1 or fdata->alloca_reg. Use
4764 store_insn_p to match CR saves. Set alloca_reg_offset
4765 when alloca_reg and framep are set. Remove lr_reg shift
4766 when assigning to fdata->lr_register.
4767
26d6cec4
AA
47682018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
4769
4770 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
4771 command line args instead of emitting a warning.
4772
5d9310c4
SM
47732018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
4774
4775 * tracepoint.h (struct static_tracepoint_marker): Initialize
4776 fields, define default constructor, move constructor and move
4777 assignment, disable the rest.
4778 <str_id, extra>: Make std::string.
4779 (release_static_tracepoint_marker): Remove.
4780 (free_current_marker): Remove.
4781 * tracepoint.c (free_current_marker): Remove.
4782 (parse_static_tracepoint_marker_definition): Adjust to
4783 std::string, use new hex2str overload.
4784 (release_static_tracepoint_marker): Remove.
4785 (print_one_static_tracepoint_marker): Get marker by reference
4786 and adjust to std::string.
4787 (info_static_tracepoint_markers_command): Adjust to std::vector
4788 changes
4789 * target.h (static_tracepoint_marker_p): Remove typedef.
4790 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
4791 (struct target_ops) <to_static_tracepoint_marker_at>: Return
4792 bool.
4793 <to_static_tracepoint_markers_by_strid>: Return std::vector.
4794 * target-debug.h
4795 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
4796 (target_debug_print_std_vector_static_tracepoint_marker): New.
4797 (target_debug_print_struct_static_tracepoint_marker_p): Rename
4798 to...
4799 (target_debug_print_static_tracepoint_marker_p): ... this.
4800 * target-delegates.c: Re-generate.
4801 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
4802 Make std::string.
4803 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
4804 (decode_static_tracepoint_spec): Adjust to std::vector.
4805 (tracepoint_print_one_detail): Adjust to std::string.
4806 (strace_marker_decode_location): Adjust to std::string.
4807 (update_static_tracepoint): Adjust to std::string, remove call
4808 to release_static_tracepoint_marker.
4809 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
4810 Adjust to std::vector.
4811 * remote.c (remote_static_tracepoint_marker_at): Return bool.
4812 (remote_static_tracepoint_markers_by_strid): Adjust to
4813 std::vector.
4814 * common/rsp-low.h (hex2str): New overload with explicit count
4815 of bytes.
4816 * common/rsp-low.c (hex2str): New overload with explicit count
4817 of bytes.
4818 * unittests/rsp-low-selftests.c (test_hex2str): New function.
4819 (_initialize_rsp_low_selftests): Add test_hex2str test.
4820 * unittests/tracepoint-selftests.c
4821 (test_parse_static_tracepoint_marker_definition): Adjust to
4822 std::string.
4823
62c222b6
SM
48242018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
4825
4826 * tracepoint.c (parse_static_tracepoint_marker_definition):
4827 Consider case where the definition is followed by more
4828 definitions.
4829 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4830 tracepoint-selftests.c.
4831 * unittests/tracepoint-selftests.c: New.
4832
7eb2418f
PFC
48332018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4834
4835 * MAINTAINERS (Write After Approval): Add Pedro Franco de
4836 Carvalho.
4837
7cbe16e9
SR
48382018-03-20 Stephen Roberts <stephen.roberts@arm.com>
4839
3d6b3b82 4840 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 4841
4ee89e90
SR
48422018-03-20 Stephen Roberts <stephen.roberts@arm.com>
4843
3d6b3b82 4844 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 4845
92630041
TT
48462018-03-19 Tom Tromey <tom@tromey.com>
4847
4848 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
4849 "IDENT" production.
4850
76727919
TT
48512018-03-19 Pedro Alves <palves@redhat.com>
4852 Tom Tromey <tom@tromey.com>
4853
4854 * unittests/observable-selftests.c: New file.
4855 * common/observable.h: New file.
4856 * observable.h: New file.
4857 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
4858 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
4859 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
4860 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
4861 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
4862 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
4863 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
4864 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
4865 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
4866 python/py-breakpoint.c, python/py-finishbreakpoint.c,
4867 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
4868 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
4869 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
4870 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
4871 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
4872 tui/tui-interp.c, valops.c: Update all users.
4873 * tui/tui-hooks.c (tui_bp_created_observer)
4874 (tui_bp_deleted_observer, tui_bp_modified_observer)
4875 (tui_inferior_exit_observer, tui_before_prompt_observer)
4876 (tui_normal_stop_observer, tui_register_changed_observer):
4877 Remove.
4878 (tui_observers_token): New global.
4879 (attach_or_detach, tui_attach_detach_observers): New functions.
4880 (tui_install_hooks, tui_remove_hooks): Use
4881 tui_attach_detach_observers.
4882 * record-btrace.c (record_btrace_thread_observer): Remove.
4883 (record_btrace_thread_observer_token): New global.
4884 * observer.sh: Remove.
4885 * observer.c: Rename to observable.c.
4886 * observable.c (namespace gdb_observers): Define new objects.
4887 (observer_debug): Move into gdb_observers namespace.
4888 (struct observer, struct observer_list, xalloc_observer_list_node)
4889 (xfree_observer_list_node, generic_observer_attach)
4890 (generic_observer_detach, generic_observer_notify): Remove.
4891 (_initialize_observer): Update.
4892 Don't include observer.inc.
4893 * Makefile.in (generated_files): Remove observer.h, observer.inc.
4894 (clean mostlyclean): Likewise.
4895 (observer.h, observer.inc): Remove targets.
4896 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
4897 (COMMON_SFILES): Use observable.c, not observer.c.
4898 * .gitignore: Remove observer.h.
4899
1cb1f3da
TT
49002018-03-18 Tom Tromey <tom@tromey.com>
4901
4902 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
4903 gdb::def_vector.
4904 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
4905
a06ab151
TT
49062018-03-17 Tom Tromey <tom@tromey.com>
4907
4908 * auto-load.c (auto_load_objfile_script_1): Use std::string.
4909
770623f7
TT
49102018-03-17 Tom Tromey <tom@tromey.com>
4911
4912 * target.c (class scoped_target_fd): New.
4913 (target_fileio_close_cleanup): Remove.
4914 (target_fileio_read_alloc_1): Use scoped_target_fd.
4915
39be3c7e
SM
49162018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
4917
4918 * silent-rules.mk: New.
4919 * Makefile.in: Include silent-rules.mk
4920 (srcdir, VPATH, top_srcdir): Move up.
4921 (COMPILE): Add ECHO_CXX.
4922 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
4923 (init.c): Add ECHO_INIT_C.
4924 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
4925 (version.c): Add ECHO_GEN.
4926 (printcmd.o): Add ECHO_CXX.
4927 (target-float.o): Add ECHO_CXX.
4928 (ada-exp.o): Add ECHO_CXX.
4929 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
4930 (insight$(EXEEXT)): Add ECHO_CXXLD.
4931 * gnulib/configure.ac: Add AM_SILENT_RULES.
4932 * gnulib/aclocal.m4: Re-generate.
4933 * gnulib/configure: Re-generate.
4934 * gnulib/import/Makefile.in: Re-generate.
4935
37e136b1
TT
49362018-03-16 Tom Tromey <tom@tromey.com>
4937
4938 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
4939 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
4940 * utils.c (do_free_section_addr_info)
4941 (make_cleanup_free_section_addr_info): Remove.
4942 * symfile.h (struct other_sections): Add constructor.
4943 (struct section_addr_info): Remove.
4944 (section_addr_info): New typedef.
4945 (struct sym_fns) <sym_offsets>: Change type of parameter.
4946 (build_section_addr_info_from_objfile)
4947 (relative_addr_info_to_section_offsets, addr_info_make_relative)
4948 (default_symfile_offsets, symbol_file_add)
4949 (symbol_file_add_from_bfd)
4950 (build_section_addr_info_from_section_table): Update.
4951 (alloc_section_addr_info, free_section_addr_info): Don't declare.
4952 * symfile.c (alloc_section_addr_info): Remove.
4953 (build_section_addr_info_from_section_table): Change return type.
4954 Update.
4955 (build_section_addr_info_from_bfd)
4956 (build_section_addr_info_from_objfile): Likewise.
4957 (free_section_addr_info): Remove.
4958 (relative_addr_info_to_section_offsets): Change type of "addrs".
4959 (addrs_section_compar): Now a std::sort comparator.
4960 (addrs_section_sort): Change return type.
4961 (addr_info_make_relative): Change type of "addrs". Update.
4962 (default_symfile_offsets, syms_from_objfile_1)
4963 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
4964 (symbol_file_add_separate): Update.
4965 (symbol_file_add): Change type of "addrs". Update.
4966 (add_symbol_file_command): Update. Remove cleanups.
4967 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
4968 cleanups.
4969 * symfile-debug.c (debug_sym_offsets): Change type of "info".
4970 * solib.c (solib_read_symbols): Update.
4971 * objfiles.c (objfile_relocate): Update. Remove cleanups.
4972 * machoread.c (macho_symfile_offsets): Update.
4973 * jit.c (jit_bfd_try_read_symtab): Update.
4974
03afa6ef
SM
49752018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
4976
4977 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4978 unittests/utils-selftests.c.
4979 * unittests/utils-selftests.c: New file.
4980
3ae9ce5d
TT
49812018-03-14 Tom Tromey <tom@tromey.com>
4982
4983 PR cli/14977:
4984 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
4985 for NULL.
4986
b8c2339b
TT
49872018-03-14 Tom Tromey <tom@tromey.com>
4988
4989 PR cli/19918:
4990 * printcmd.c (printf_pointer): Allow "-" in format.
4991
80ae639d
TT
49922018-03-14 Tom Tromey <tom@tromey.com>
4993
4994 * printcmd.c (_initialize_printcmd): Add usage to printf.
4995
0d671d99
YQ
49962018-03-14 Yao Qi <qiyao@sourceware.org>
4997
4998 * MAINTAINERS: Update my email address.
4999
b577b6af
TT
50002018-03-13 Tom Tromey <tom@tromey.com>
5001
5002 * machoread.c (macho_check_dsym): Change filenamep to a
5003 std::string*.
5004 (macho_symfile_read): Update.
5005 * symfile.c (load_command): Use std::string.
5006
89a3b63e
AB
50072018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
5008
5009 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
5010 to error message string.
5011 (riscv_register_name): Use xsnprintf instead of sprintf.
5012 (riscv_insn::fetch_instruction): Use gdb_assert instead of
5013 internal_error.
5014 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
5015 error.
5016 (riscv_push_dummy_call): Likewise.
5017
984c7238
TT
50182018-03-12 Tom Tromey <tom@tromey.com>
5019
5020 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
5021 Use gdb::byte_vector.
5022 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
5023
933522d1
YQ
50242018-03-12 Yao Qi <yao.qi@linaro.org>
5025
5026 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
5027 parameter type to readable_regcache.
5028 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
5029 the declaration.
5030
be2daae6
TT
50312018-03-11 Tom Tromey <tom@tromey.com>
5032
5033 * dwarf2read.c (struct nextfield): Add initializers.
5034 (struct nextfnfield): Remove.
5035 (struct fnfieldlist): Add initializers. Remove "length" and
5036 "head", use std::vector.
5037 (struct decl_field_list): Remove.
5038 (struct field_info): Add initializers.
5039 <fields, baseclasses>: Now std::vector.
5040 <nbaseclasses, nfnfields, typedef_field_list_count,
5041 nested_types_list_count>: Remove.
5042 (dwarf2_add_field, dwarf2_add_type_defn)
5043 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
5044 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
5045 (process_structure_scope): Update.
5046
484cf504
TT
50472018-03-11 Tom Tromey <tom@tromey.com>
5048
5049 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
5050 for use by std::sort.
5051 (build_type_psymtabs_1): Use std::vector.
5052
9bd8e0b0
EZ
50532018-03-09 Eli Zaretskii <eliz@gnu.org>
5054
5055 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
5056 and LIBMPFR in the printed configuration.
5057
5dc1a704
TT
50582018-03-08 Tom Tromey <tom@tromey.com>
5059
5060 * source.c (get_filename_and_charpos): Use scoped_fd.
5061 * nto-procfs.c (procfs_open_1): Use scoped_fd.
5062 (procfs_pidlist): Likewise.
5063 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
5064 (iterate_over_mappings): Likewise.
5065
fdf07f3a
TT
50662018-03-08 Tom Tromey <tom@tromey.com>
5067
5068 * infcall.c (struct call_return_meta_info)
5069 <stack_temporaries_enabled>: Remove.
5070 (get_call_return_value, call_function_by_hand_dummy): Update.
5071 * thread.c (disable_thread_stack_temporaries): Remove.
5072 (enable_thread_stack_temporaries): Remove.
5073 (thread_stack_temporaries_enabled_p): Return bool.
5074 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
5075 (get_last_thread_stack_temporary): Update.
5076 * eval.c (evaluate_subexp): Update.
5077 * gdbthread.h (class enable_thread_stack_temporaries): Now a
5078 class, not a function.
5079 (value_ptr, value_vec): Remove typedefs.
5080 (class thread_info) <stack_temporaries_enabled>: Now bool.
5081 <stack_temporaries>: Now a std::vector.
5082 (thread_stack_temporaries_enabled_p)
5083 (value_in_thread_stack_temporaries): Return bool.
5084
567a3e54
SM
50852018-03-08 Simon Marchi <simon.marchi@ericsson.com>
5086
5087 * remote.c (putpkt_binary): Fix omitted bytes reporting.
5088 (getpkt_or_notif_sane_1): Likewise.
5089
00b40057
SM
50902018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5091
5092 * build-id.c (build_id_to_debug_bfd): Use std::string.
5093
a8dbfd58
SM
50942018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5095
5096 * build-id.c (find_separate_debug_file_by_buildid): Return
5097 std::string.
5098 * build-id.h (find_separate_debug_file_by_buildid): Return
5099 std::string.
5100 * coffread.c (coff_symfile_read): Adjust to std::string.
5101 * elfread.c (elf_symfile_read): Adjust to std::string.
5102 * symfile.c (separate_debug_file_exists): Change parameter to
5103 std::string.
5104 (find_separate_debug_file): Return std::string.
5105 (find_separate_debug_file_by_debuglink): Return std::string.
5106 * symfile.h (find_separate_debug_file_by_debuglink): Return
5107 std::string.
5108
e6a58aa8
SM
51092018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5110
5111 * common/xml-utils.c (xml_escape_text): Move code to...
5112 (xml_escape_text_append): ... this new function.
5113 * common/xml-utils.h (xml_escape_text_append): New declaration.
5114 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
5115 New function.
5116 (_initialize_xml_utils): register test_xml_escape_text_append as
5117 a selftest.
5118
4ef0bef6
AH
51192018-03-07 Alan Hayward <alan.hayward@arm.com>
5120
5121 * defs.h: Remove MAX_REGISTER_SIZE.
5122 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
5123 asserts.
5124 * python/py-unwind.c (pyuw_sniffer): Likewise.
5125
e0d3522b
TT
51262018-03-07 Tom Tromey <tom@tromey.com>
5127
5128 * linux-tdep.c (linux_info_proc): Update.
5129 * target.h (struct target_ops) <to_fileio_readlink>: Return
5130 optional<string>.
5131 (target_fileio_readlink): Return optional<string>.
5132 * remote.c (remote_hostio_readlink): Return optional<string>.
5133 * inf-child.c (inf_child_fileio_readlink): Return
5134 optional<string>.
5135 * target.c (target_fileio_readlink): Return optional<string>.
5136
ea005f31
AB
51372018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
5138
5139 * regcache.c (cooked_read_test): Add riscv to the list of
5140 architectures that have a save_reggroup.
5141
e95a97d4
AA
51422018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
5143
5144 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
5145 value is not a dynamic class object.
5146
d8344f3d
TT
51472018-03-06 Tom Tromey <tom@tromey.com>
5148
5149 * rust-exp.y: Formatting fixes.
5150
9add17f2
AB
51512018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5152
5153 * riscv-tdep.c (riscv_register_name): Remove target description
5154 support.
5155 (riscv_gdbarch_init): Remove target description check.
5156
c9486dfe
AB
51572018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5158
5159 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
5160 comment.
5161 * riscv-tdep.h: Likewise.
5162
d74aff3d
AB
51632018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5164
5165 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
5166 (riscv_pseudo_register_write): Delete.
5167 (riscv_gdbarch_init): Remove all use of pseudo registers.
5168
7ea78b59
SM
51692018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
5170
5171 * record-btrace.c (btrace_print_lines): Replace cleanup
5172 parameter with RAII equivalents.
5173 (btrace_insn_history): Replace cleanup with RAII equivalents.
5174 * ui-out.h (make_cleanup_ui_out_list_begin_end,
5175 make_cleanup_ui_out_tuple_begin_end): Remove.
5176 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
5177 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
5178 make_cleanup_ui_out_list_begin_end): Remove.
5179
53127008
SM
51802018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
5181
5182 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
5183 parameter types to std::vector. Use bool.
5184 (record_btrace_wait): Replace VEC(tp_t) with
5185 std::vector<thread_info *>.
5186 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
5187
228f1508
SM
51882018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
5189
5190 * record-btrace.c (record_btrace_disable_callback): Remove.
5191 (struct scoped_btrace_disable): New.
5192 (record_btrace_open): Use scoped_btrace_disable.
5193
b2970c23
AB
51942018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5195
5196 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
5197 reading values from registers.
5198
fb294655
AB
51992018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5200
5201 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
5202 where appropriate.
5203
cab5bb9d
AB
52042018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5205
5206 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
5207 change parameter type. Use GDB's print functions, and use
5208 core_addr_to_string where appropriate.
5209 (riscv_push_dummy_call): Use core_addr_to_string where
5210 appropriate, update call to riscv_print_arg_location, and reindent
5211 a few lines.
5212 (riscv_return_value): Update call to riscv_print_arg_location.
5213
dbbb1059
AB
52142018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5215 Tim Newsome <tim@sifive.com>
5216 Albert Ou <a0u@eecs.berkeley.edu>
5217 Darius Rad <darius@bluespec.com>
5218
5219 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
5220 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
5221 (ALLDEPFILES): Add riscv-tdep.c
5222 * configure.tgt: Add riscv support.
5223 * riscv-tdep.c: New file.
5224 * riscv-tdep.h: New file.
5225 * NEWS: Mention new target.
5226 * MAINTAINERS: Add entry for riscv.
5227
5dc43913
AB
52282018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5229
5230 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
5231 fields within aggregates.
5232
3dea1ef7
SM
52332018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
5234
5235 * record-btrace.c (btrace_print_lines): Change type of flags to
5236 gdb_disassembly_flags.
5237
7efba073
JB
52382018-03-04 John Baldwin <jhb@FreeBSD.org>
5239
5240 * fbsd-nat.c: Include "inf-ptrace.h".
5241 (USE_SIGTRAP_SIGINFO): Conditionally define.
5242 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
5243 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
5244 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
5245 function.
5246 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
5247 Likewise.
5248 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
5249 Likewise.
5250 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
5251 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
5252 "supports_stopped_by_hw_breakpoint" target methods.
5253
386a8676
JB
52542018-03-04 John Baldwin <jhb@FreeBSD.org>
5255
5256 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
5257 * fbsd-nat.c (debug_fbsd_nat): New variable.
5258 (show_fbsd_nat_debug): New function.
5259 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
5260 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
5261
12279366
JB
52622018-03-04 John Baldwin <jhb@FreeBSD.org>
5263
5264 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
5265 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
5266 prototype.
5267 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
5268 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
5269 method.
5270
54693cf5
SM
52712018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5272
5273 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
5274 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
5275
ccb2231c
SM
52762018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5277
5278 * charset.c (struct charset_vector): New.
5279 (charsets): Change type to charset_vector.
5280 (find_charset_names): Adjust.
5281 (add_one): Adjust.
5282 (_initialize_charset): Adjust.
5283
6fb16ce6
SM
52842018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5285
5286 * progspace.h (struct program_space) <deleted_solibs>: Change
5287 type to std::vector<std::string>.
5288 * progspace.c (clear_program_space_solib_cache): Adjust.
5289 * breakpoint.c (print_solib_event): Adjust.
5290 (check_status_catch_solib): Adjust.
5291 * solib.c (update_solib_list): Adjust.
5292 * ui-out.h (class ui_out) <field_string>: New overload.
5293 * ui-out.c (ui_out::field_string): New overload.
5294
564b1e3f
SM
52952018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5296
5297 * progspace.h (struct program_space): Add constructor and
5298 destructor, initialize fields.
5299 (add_program_space): Remove.
5300 * progspace.c (add_program_space): Rename to...
5301 (program_space::program_space): ... this.
5302 (release_program_space): Rename to...
5303 (program_space::~program_space): ... this.
5304 (delete_program_space): Use delete to delete program_space.
5305 (initialize_progspace): Use new to allocate program_space.
5306 * inferior.c (add_inferior_with_spaces): Likewise.
5307 (clone_inferior_command): Likewise.
5308 * infrun.c (follow_fork_inferior): Likewise.
5309 (handle_vfork_child_exec_or_exit): Likewise.
5310
e80aaf61
SM
53112018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5312
5313 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
5314 (delim_string_to_char_ptr_vec): Return std::vector of
5315 gdb::unique_xmalloc_ptr.
5316 (dirnames_to_char_ptr_vec_append): Take std::vector of
5317 gdb::unique_xmalloc_ptr.
5318 (dirnames_to_char_ptr_vec): Return std::vector of
5319 gdb::unique_xmalloc_ptr.
5320 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
5321 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
5322 (delim_string_to_char_ptr_vec): Return an std::vector of
5323 gdb::unique_xmalloc_ptr, adjust the code.
5324 (dirnames_to_char_ptr_vec_append): Take an std::vector of
5325 gdb::unique_xmalloc_ptr, adjust the code.
5326 (dirnames_to_char_ptr_vec): Return an std::vector of
5327 gdb::unique_xmalloc_ptr, adjust the code.
5328 * auto-load.c (auto_load_safe_path_vec): Change type to
5329 std::vector of gdb::unique_xmalloc_ptr.
5330 (auto_load_expand_dir_vars): Return an std::vector of
5331 gdb::unique_xmalloc_ptr, adjust the code.
5332 (auto_load_safe_path_vec_update): Adjust.
5333 (filename_is_in_auto_load_safe_path_vec): Adjust.
5334 (auto_load_objfile_script_1): Adjust.
5335 * build-id.c (build_id_to_debug_bfd): Adjust.
5336 * linux-thread-db.c (thread_db_load_search): Adjust.
5337 * source.c (add_path): Adjust.
5338 (openp): Adjust.
5339 * symfile.c (find_separate_debug_file): Adjust.
5340 * utils.c (do_free_char_ptr_vec): Remove.
5341 (make_cleanup_free_char_ptr_vec): Remove.
5342
ab818ade
SDJ
53432018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
5344
5345 PR gdb/22907
5346 * common/pathstuff.c: Conditionally include "<windows.h>".
5347
e1e6f073
GS
53482018-03-01 Georg Sauthoff <mail@georg.so>
5349
5350 PR gdb/22888
5351 * gcore.in: Quote variables and switch interpreter to bash.
5352
c7b15a66
TT
53532018-03-01 Tom Tromey <tom@tromey.com>
5354
5355 * dwarf2read.c (alloc_discriminant_info): Fix default_index
5356 assertion. Add assertion for discriminant_index.
5357 (quirk_rust_enum): Use correct base type name in univariant case.
5358
0cb7c7b0
SM
53592018-03-01 Simon Marchi <simon.marchi@ericsson.com>
5360
5361 * record.c (get_call_history_modifiers): Return a
5362 record_print_flags.
5363 (cmd_record_call_history): Adjust.
5364 * record-btrace.c (record_btrace_call_history): Adjust.
5365 (record_btrace_call_history_range): Adjust.
5366 (record_btrace_call_history_from): Adjust.
5367 * target-debug.h (target_debug_print_record_print_flags): New.
5368 * target-delegates.c: Re-generate.
5369 * target.c (target_call_history): Change flags type.
5370 (target_call_history_from): Likewise.
5371 (target_call_history_range): Likewise.
5372 * target.h (struct target_ops) <target_call_history>: Likewise.
5373 (target_call_history_from): Likewise.
5374 (target_call_history_range): Likewise.
5375
25e3c82c
SDJ
53762018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5377 Simon Marchi <simon.marchi@polymtl.ca>
5378
5379 * common/common-utils.c: Include "sys/stat.h".
5380 (is_regular_file): Move here from "source.c"; change return
5381 type to "bool".
5382 * common/common-utils.h (is_regular_file): New prototype.
5383 * common/pathstuff.c (contains_dir_separator): New function.
5384 * common/pathstuff.h (contains_dir_separator): New prototype.
5385 * source.c: Don't include "sys/stat.h".
5386 (is_regular_file): Move to "common/common-utils.c".
5387
b4987c95
SDJ
53882018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5389
5390 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
5391 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
5392 * auto-load.c: Include "common/pathstuff.h".
5393 * common/common-def.h (current_directory): Move here.
5394 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
5395 function.
5396 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
5397 prototype.
5398 * common/pathstuff.c: New file.
5399 * common/pathstuff.h: New file.
5400 * compile/compile.c: Include "common/pathstuff.h".
5401 * defs.h (current_directory): Move to "common/common-defs.h".
5402 * dwarf2read.c: Include "common/pathstuff.h".
5403 * exec.c: Likewise.
5404 * guile/scm-safe-call.c: Likewise.
5405 * linux-thread-db.c: Likewise.
5406 * main.c: Likewise.
5407 * nto-tdep.c: Likewise.
5408 * objfiles.c: Likewise.
5409 * source.c: Likewise.
5410 * symtab.c: Likewise.
5411 * utils.c: Include "common/pathstuff.h".
5412 (gdb_realpath): Move to "common/pathstuff.c".
5413 (gdb_realpath_keepfile): Likewise.
5414 (gdb_abspath): Likewise.
5415 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
5416 (gdb_realpath_keepfile): Likewise.
5417 (gdb_abspath): Likewise.
5418
f169cfdc
JB
54192018-02-28 John Baldwin <jhb@FreeBSD.org>
5420
5421 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
5422 wildcard process pid for super_resume for kernels with a
5423 specific bug.
5424
e05cac70
PM
54252018-02-27 Phil Muldoon <pmuldoon@redhat.com>
5426
5427 * compile/compile.c (get_args): Add additional comments
5428 explaining function.
5429
55089490
TT
54302018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
5431 Tom Tromey <tom@tromey.com>
5432
5433 * target.h (memory_write_request_s): Remove typedef. Don't define
5434 VEC.
5435 (target_write_memory_blocks): Change argument to std::vector.
5436 (struct memory_write_request): Add constructor.
5437 * target-memory.c (compare_block_starting_address): Return bool.
5438 Change argument types.
5439 (claim_memory): Change arguments to use std::vector.
5440 (split_regular_and_flash_blocks, blocks_to_erase)
5441 (compute_garbled_blocks): Likewise.
5442 (cleanup_request_data, cleanup_write_requests_vector): Remove.
5443 (target_write_memory_blocks): Change argument to std::vector.
5444 * symfile.c (struct load_section_data): Add constructor and
5445 destructor. Use std::vector for "requests".
5446 (struct load_progress_data): Add initializers.
5447 (load_section_callback): Update. Use "new".
5448 (clear_memory_write_data): Remove.
5449 (generic_load): Update.
5450
0c305b61
AH
54512018-02-27 Alan Hayward <alan.hayward@arm.com>
5452
5453 * arch/aarch64.h: Use common/tdesc.h.
5454
c5196c92
MR
54552018-02-26 Maciej W. Rozycki <macro@mips.com>
5456
5457 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
5458 architecture with a 64-bit ABI.
5459
37c33887
MR
54602018-02-26 Maciej W. Rozycki <macro@mips.com>
5461
5462 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
5463 ahead of target description loading.
5464
d4dd3282
TT
54652018-02-26 Tom Tromey <tom@tromey.com>
5466
5467 * stack.c (backtrace_command_1): Update.
5468 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
5469 of "flags".
5470 * python/py-framefilter.c (py_print_frame)
5471 (gdbpy_apply_frame_filter): Change type of "flags".
5472 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
5473 of "flags".
5474 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
5475 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
5476 * extension.h (enum frame_filter_flag): Rename from
5477 frame_filter_flags.
5478 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
5479 (apply_ext_lang_frame_filter): Change type of "flags".
5480 * extension.c (apply_ext_lang_frame_filter): Change type of
5481 "flags".
5482 * extension-priv.h (struct extension_language_ops)
5483 <apply_frame_filter>: Change type of "flags".
5484
6893c19a
TT
54852018-02-26 Tom Tromey <tom@tromey.com>
5486
5487 PR python/16497:
5488 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
5489 off-by-one in py_end computation.
5490 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
5491 PRINT_MORE_FRAMES.
5492 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
5493 constant.
5494
2ddeaf8a
TT
54952018-02-26 Tom Tromey <tom@tromey.com>
5496
5497 * dwarf2read.c (struct variant_field): New.
5498 (struct nextfield) <variant>: New field.
5499 (dwarf2_add_field): Handle DW_TAG_variant_part.
5500 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
5501 discriminated union.
5502 (read_structure_type): Handle DW_TAG_variant_part.
5503 (handle_struct_member_die): New function, extracted from
5504 process_structure_scope. Handle DW_TAG_variant.
5505 (process_structure_scope): Handle discriminated unions. Call
5506 handle_struct_member_die.
5507
c9317f21
TT
55082018-02-26 Tom Tromey <tom@tromey.com>
5509
5510 * rust-lang.h (rust_last_path_segment): Declare.
5511 * rust-lang.c (rust_last_path_segment): Now public. Change
5512 contract.
5513 (struct disr_info): Remove.
5514 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
5515 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
5516 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
5517 (rust_enum_p, rust_enum_variant): New function.
5518 (rust_underscore_fields): Remove "offset" parameter.
5519 (rust_print_enum): New function.
5520 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
5521 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
5522 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
5523 enums.
5524 (rust_internal_print_type): New function, from rust_print_type.
5525 Remove enum code.
5526 (rust_print_type): Call rust_internal_print_type.
5527 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
5528 Update enum handling.
5529 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
5530 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
5531 (rust_union_quirks): New functions.
5532 (process_full_comp_unit, process_full_type_unit): Call
5533 rust_union_quirks.
5534 (process_structure_scope): Update rust_unions if necessary.
5535
7c22600a
TT
55362018-02-26 Tom Tromey <tom@tromey.com>
5537
5538 * value.h (value_union_variant): Declare.
5539 * valops.c (value_union_variant): New function.
5540 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
5541 (struct discriminant_info): New.
5542 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
5543 enumerator.
5544 (struct main_type) <flag_discriminated_union>: New field.
5545
15ce8941
TT
55462018-02-26 Tom Tromey <tom@tromey.com>
5547
5548 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5549 unittests/unpack-selftests.c.
5550 * unittests/unpack-selftests.c: New file.
5551 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
5552
48fbe735
YQ
55532018-02-26 Yao Qi <yao.qi@linaro.org>
5554
5555 * dwarf2read.c (struct partial_die_info) <read>: New method.
5556 (read_partial_die): Remove the declaration.
5557 (load_partial_dies): Update.
5558 (partial_die_info::partial_die_info):
5559 (read_partial_die): Change it to partial_die_info::read.
5560
52356b79
YQ
55612018-02-26 Yao Qi <yao.qi@linaro.org>
5562
5563 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
5564 (fixup_partial_die): Remove declaration.
5565 (scan_partial_symbols): Update.
5566 (partial_die_parent_scope): Likewise.
5567 (partial_die_full_name): Likewise.
5568 (fixup_partial_die): Change it to partial_die_info::fixup.
5569
35cc7ed7
YQ
55702018-02-26 Yao Qi <yao.qi@linaro.org>
5571
5572 * dwarf2read.c (read_partial_die): Update the declaration.
5573 (load_partial_dies): Caller update.
5574 (read_partial_die): Remove one argument abbrev_len.
5575
6f06d47b
YQ
55762018-02-26 Yao Qi <yao.qi@linaro.org>
5577
5578 * dwarf2read.c (struct partial_die_info): Add ctor, delete
5579 assignment operator.
5580 (load_partial_dies): Use ctor and copy ctor.
5581 (read_partial_die): Update.
5582 (dwarf2_cu::find_partial_die): Use ctor.
5583
d590ff25
YQ
55842018-02-26 Yao Qi <yao.qi@linaro.org>
5585
5586 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
5587 (find_partial_die_in_comp_unit): Change it to
5588 dwarf2_cu::find_partial_die.
5589 (find_partial_die): Update.
5590
fd0a254f
YQ
55912018-02-26 Yao Qi <yao.qi@linaro.org>
5592
5593 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
5594 is NULL.
5595
cd9983dd
YQ
55962018-02-26 Yao Qi <yao.qi@linaro.org>
5597
5598 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
5599
f46cd62a
AH
56002018-02-26 Alan Hayward <alan.hayward@arm.com>
5601
5602 * arch/amd64.h: Use common/tdesc.h.
5603 * arch/i386.c: Likewise.
5604 * arch/i386.h: Likewise.
5605 * arch/tic6x.c: Likewise.
5606 * arch/tdesc.h: Move file from here...
5607 * common/tdesc.h: ...to here.
5608 * features/aarch64-core.c: Regenerate.
5609 * features/aarch64-fpu.c: Regenerate.
5610 * features/i386/32bit-avx.c: Regenerate.
5611 * features/i386/32bit-avx512.c: Regenerate.
5612 * features/i386/32bit-core.c: Regenerate.
5613 * features/i386/32bit-linux.c: Regenerate.
5614 * features/i386/32bit-mpx.c: Regenerate.
5615 * features/i386/32bit-pkeys.c: Regenerate.
5616 * features/i386/32bit-sse.c: Regenerate.
5617 * features/i386/64bit-avx.c: Regenerate.
5618 * features/i386/64bit-avx512.c: Regenerate.
5619 * features/i386/64bit-core.c: Regenerate.
5620 * features/i386/64bit-linux.c: Regenerate.
5621 * features/i386/64bit-mpx.c: Regenerate.
5622 * features/i386/64bit-pkeys.c: Regenerate.
5623 * features/i386/64bit-segments.c: Regenerate.
5624 * features/i386/64bit-sse.c: Regenerate.
5625 * features/i386/x32-core.c: Regenerate.
5626 * features/tic6x-c6xp.c: Regenerate.
5627 * features/tic6x-core.c: Regenerate.
5628 * features/tic6x-gp.c: Regenerate.
5629 * target-descriptions.c: Use common/tdesc.h.
5630 * target-descriptions.h: Likewise.
5631
9b292f68
TT
56322018-02-24 Tom Tromey <tom@tromey.com>
5633
5634 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
5635 (try_thread_db_load_from_dir, thread_db_load_search): Use
5636 std::string.
5637 (info_auto_load_libthread_db_compare): Return bool. Change
5638 argument types.
5639 (info_auto_load_libthread_db): Use std::vector, std::string.
5640 Remove cleanups.
5641
281d762b
TT
56422018-02-24 Tom Tromey <tom@tromey.com>
5643
5644 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
5645 std::string.
5646 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
5647 std::string*.
5648 * gdbarch.c: Rebuild.
5649 * gdbarch.h: Rebuild.
5650 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
5651 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
5652 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
5653 std::string*.
5654
9d8780f0
SM
56552018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
5656
5657 * gdbtypes.h (sect_offset): Change type to uint64_t.
5658 (sect_offset_str): New function.
5659 * dwarf2read.c (create_addrmap_from_aranges): Use
5660 sect_offset_str.
5661 (error_check_comp_unit_head): Likewise.
5662 (create_debug_type_hash_table): Likewise.
5663 (read_cutu_die_from_dwo): Likewise.
5664 (init_cutu_and_read_dies): Likewise.
5665 (init_cutu_and_read_dies_no_follow): Likewise.
5666 (process_psymtab_comp_unit_reader): Likewise.
5667 (partial_die_parent_scope): Likewise.
5668 (peek_die_abbrev): Likewise.
5669 (process_queue): Likewise.
5670 (dwarf2_physname): Likewise.
5671 (read_namespace_alias): Likewise.
5672 (read_import_statement): Likewise.
5673 (create_dwo_cu_reader): Likewise.
5674 (create_cus_hash_table): Likewise.
5675 (lookup_dwo_cutu): Likewise.
5676 (inherit_abstract_dies): Likewise.
5677 (read_func_scope): Likewise.
5678 (read_call_site_scope): Likewise.
5679 (dwarf2_add_member_fn): Likewise.
5680 (read_common_block): Likewise.
5681 (read_module_type): Likewise.
5682 (read_typedef): Likewise.
5683 (read_subrange_type): Likewise.
5684 (load_partial_dies): Likewise.
5685 (read_partial_die): Likewise.
5686 (find_partial_die): Likewise.
5687 (read_str_index): Likewise.
5688 (dwarf2_string_attr): Likewise.
5689 (build_error_marker_type): Likewise.
5690 (lookup_die_type): Likewise.
5691 (dump_die_shallow): Likewise.
5692 (follow_die_ref): Likewise.
5693 (dwarf2_fetch_die_loc_sect_off): Likewise.
5694 (dwarf2_fetch_constant_bytes): Likewise.
5695 (follow_die_sig): Likewise.
5696 (get_signatured_type): Likewise.
5697 (get_DW_AT_signature_type): Likewise.
5698 (dwarf2_find_containing_comp_unit): Likewise.
5699 (set_die_type): Likewise.
5700
8ec57239
JB
57012018-02-21 John Baldwin <jhb@FreeBSD.org>
5702
5703 * arch/aarch64.c: Include "common-defs.h".
5704 * arch/amd64.c: Likewise.
5705 * arch/i386.c: Likewise.
5706
3eac2b65
TT
57072018-02-21 Tom Tromey <tom@tromey.com>
5708
5709 * value.h: (extract_field_op): Update.
5710 * eval.c (extract_field_op): Return a const char *.
5711 * expression.h (parse_expression_for_completion): Update.
5712 * completer.c (complete_expression): Update.
5713 (add_struct_fields): Make fieldname const.
5714 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
5715 (mark_completion_tag, parse_exp_in_context_1): Update.
5716 (parse_expression_for_completion): Change "name" to
5717 unique_xmalloc_ptr*.
5718
6ccb583f
TT
57192018-02-21 Tom Tromey <tom@tromey.com>
5720
5721 * infcall.c (call_function_by_hand_dummy): Use std::vector.
5722
c113ed0c
YQ
57232018-02-21 Yao Qi <yao.qi@linaro.org>
5724
5725 * avr-tdep.c (avr_read_pc): Change parameter type to
5726 readable_regcache.
5727 * gdbarch.sh (read_pc): Likewise.
5728 * gdbarch.c: Re-generated.
5729 * gdbarch.h: Re-generated.
5730 * hppa-tdep.c (hppa_read_pc): Change parameter type to
5731 readable_regcache.
5732 * ia64-tdep.c (ia64_read_pc): Likewise.
5733 * mips-tdep.c (mips_read_pc): Likewise.
5734 * spu-tdep.c (spu_read_pc): Likewise.
5735
4c74fe6b
YQ
57362018-02-21 Yao Qi <yao.qi@linaro.org>
5737
5738 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
5739 * regcache-dump.c: New file.
5740 * regcache.c: Move register_dump to regcache-dump.c.
5741 (maintenance_print_registers): Likewise.
5742 (maintenance_print_raw_registers): Likewise.
5743 (maintenance_print_cooked_registers): Likewise.
5744 (maintenance_print_register_groups): Likewise.
5745 (maintenance_print_remote_registers): Likewise.
5746 (_initialize_regcache): Likewise.
5747 * regcache.h (register_dump): Moved from regcache.c.
5748
796bb026
YQ
57492018-02-21 Yao Qi <yao.qi@linaro.org>
5750
5751 * regcache.c (regcache::regcache): Update.
5752 (regcache::invalidate): Move it to detached_regcache::invalidate.
5753 (get_thread_arch_aspace_regcache): Update.
5754 (regcache::raw_update): Update.
5755 (regcache::cooked_read): Remove some code.
5756 (regcache::cooked_read_value): Likewise.
5757 (regcache::raw_write): Remove assert on m_readonly_p.
5758 (regcache::raw_supply_integer): Move it to
5759 detached_regcache::raw_supply_integer.
5760 (regcache::raw_supply_zeroed): Likewise.
5761 * regcache.h (detached_regcache) <raw_supply_integer>: New
5762 declaration.
5763 <raw_supply_zeroed, invalidate>: Likewise.
5764 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
5765 <invalidate>: Likewise.
5766 <m_readonly_p>: Removed.
5767
215c69dc
YQ
57682018-02-21 Yao Qi <yao.qi@linaro.org>
5769
5770 * infcmd.c (get_return_value): Let stop_regs point to
5771 get_current_regcache.
5772 * regcache.c (regcache::regcache): Remove.
5773 (register_dump_reg_buffer): New class.
5774 (regcache_print): Adjust.
5775 * regcache.h (regcache): Remove constructors.
5776
f3384e66
YQ
57772018-02-21 Yao Qi <yao.qi@linaro.org>
5778
5779 * regcache.c (class register_dump): New class.
5780 (register_dump_regcache, register_dump_none): New class.
5781 (register_dump_remote, register_dump_groups): New class.
5782 (regcache_print): Update.
5783 * regcache.h (regcache_dump_what): Move it to regcache.c.
5784 (regcache) <dump>: Remove.
5785
c8ec2f33
YQ
57862018-02-21 Yao Qi <yao.qi@linaro.org>
5787
5788 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
5789 reg_buffer_rw *.
5790 (jit_unwind_reg_set_impl): Call raw_supply.
5791 (jit_frame_sniffer): Use reg_buffer_rw.
5792 * record-full.c (record_full_core_regbuf): Change its type.
5793 (record_full_core_open_1): Use reg_buffer_rw.
5794 (record_full_close): Likewise.
5795 (record_full_core_fetch_registers): Use regcache->raw_supply.
5796 (record_full_core_store_registers): Likewise.
5797 * regcache.c (regcache::get_register_status): Move it to
5798 reg_buffer.
5799 (regcache_raw_set_cached_value): Remove.
5800 (regcache::raw_set_cached_value): Remove.
5801 (regcache::raw_write): Call raw_supply.
5802 (regcache::raw_supply): Move it to reg_buffer_rw.
5803 * regcache.h (regcache_raw_set_cached_value): Remove.
5804 (reg_buffer_rw): New class.
5805
daf6667d
YQ
58062018-02-21 Yao Qi <yao.qi@linaro.org>
5807
5808 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
5809 readonly_detached_regcache.
5810 (dummy_frame_prev_register): Use regcache->cooked_read.
5811 * frame.c (frame_save_as_regcache): Change return type.
5812 (frame_pop): Update.
5813 * frame.h (frame_save_as_regcache): Update declaration.
5814 * inferior.h (get_infcall_suspend_state_regcache): Update
5815 declaration.
5816 * infrun.c (infcall_suspend_state) <registers>: use
5817 readonly_detached_regcache.
5818 (save_infcall_suspend_state): Don't use regcache_dup.
5819 (get_infcall_suspend_state_regcache): Change return type.
5820 * linux-fork.c (struct fork_info) <savedregs>: Change to
5821 readonly_detached_regcache.
5822 <pc>: New field.
5823 (fork_save_infrun_state): Don't use regcache_dup.
5824 (info_checkpoints_command): Adjust.
5825 * mi/mi-main.c (register_changed_p): Update declaration.
5826 (mi_cmd_data_list_changed_registers): Use
5827 readonly_detached_regcache.
5828 (register_changed_p): Change parameter type to
5829 readonly_detached_regcache.
5830 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
5831 readonly_detached_regcache.
5832 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
5833 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
5834 New.
5835 (regcache::save): Move it to reg_buffer.
5836 (regcache::restore): Change parameter type.
5837 (regcache_dup): Remove.
5838 * regcache.h (reg_buffer) <save>: New method.
5839 (readonly_detached_regcache): New class.
5840 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
5841 readonly_detached_regcache.
5842 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
5843
fc5b8736
YQ
58442018-02-21 Yao Qi <yao.qi@linaro.org>
5845
5846 * frame.c (frame_save_as_regcache): Use regcache method save.
5847 (frame_pop): Use regcache method restore.
5848 * infrun.c (restore_infcall_suspend_state): Likewise.
5849 * linux-fork.c (fork_load_infrun_state): Likewise.
5850 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
5851 save.
5852 * regcache.c (regcache_save): Remove.
5853 (regcache::restore): More asserts.
5854 (regcache_cpy): Remove.
5855 * regcache.h (regcache_save): Remove the declaration.
5856 (regcache::restore): Move from private to public.
5857 Remove the friend declaration of regcache_cpy.
5858 (regcache_cpy): Remove declaration.
5859
849d0ba8
YQ
58602018-02-21 Yao Qi <yao.qi@linaro.org>
5861
5862 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
5863 parameter type to 'readable_regcache *'.
5864 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
5865 * arm-tdep.c (arm_neon_quad_read): Likewise.
5866 (arm_pseudo_read): Likewise.
5867 * avr-tdep.c (avr_pseudo_register_read): Likewise.
5868 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
5869 * frv-tdep.c (frv_pseudo_register_read): Likewise.
5870 * gdbarch.c: Re-generated.
5871 * gdbarch.h: Re-generated.
5872 * gdbarch.sh (pseudo_register_read): Change parameter type to
5873 'readable_regcache *'.
5874 (pseudo_register_read_value): Likewise.
5875 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
5876 (h8300_pseudo_register_read): Likewise.
5877 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
5878 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
5879 (i386_pseudo_register_read_into_value): Likewise.
5880 (i386_pseudo_register_read_value): Likewise.
5881 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
5882 declaration.
5883 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
5884 * m32c-tdep.c (m32c_raw_read): Likewise.
5885 (m32c_read_flg): Likewise.
5886 (m32c_banked_register): Likewise.
5887 (m32c_banked_read): Likewise.
5888 (m32c_sb_read): Likewise.
5889 (m32c_part_read): Likewise.
5890 (m32c_cat_read): Likewise.
5891 (m32c_r3r2r1r0_read): Likewise.
5892 (m32c_pseudo_register_read): Likewise.
5893 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
5894 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
5895 (mep_pseudo_cr64_read): Likewise.
5896 (mep_pseudo_register_read): Likewise.
5897 * mips-tdep.c (mips_pseudo_register_read): Likewise.
5898 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
5899 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
5900 * regcache.c (regcache::raw_read): Move it to readable_regcache.
5901 (regcache::cooked_read): Likewise.
5902 (regcache::cooked_read_value): Likewise.
5903 (regcache_cooked_read_signed):
5904 (regcache::cooked_read): Likewise.
5905 * regcache.h (readable_regcache): New class.
5906 (regcache): Inherit readable_regcache. Move some methods to
5907 readable_regcache.
5908 * rl78-tdep.c (rl78_pseudo_register_read): Change
5909 parameter type to 'readable_regcache *'.
5910 * rs6000-tdep.c (do_regcache_raw_read): Remove.
5911 (e500_pseudo_register_read): Change parameter type to
5912 'readable_regcache *'.
5913 (dfp_pseudo_register_read): Likewise.
5914 (vsx_pseudo_register_read): Likewise.
5915 (efpr_pseudo_register_read): Likewise.
5916 * s390-tdep.c (s390_pseudo_register_read): Likewise.
5917 * sh-tdep.c (sh_pseudo_register_read): Likewise.
5918 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
5919 (sh64_pseudo_register_read): Likewise.
5920 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
5921 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
5922 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
5923 (spu_pseudo_register_read): Likewise.
5924 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
5925 (xtensa_pseudo_register_read): Likewise.
5926
31716595
YQ
59272018-02-21 Yao Qi <yao.qi@linaro.org>
5928
5929 * regcache.c (regcache::regcache): Call reg_buffer ctor.
5930 (regcache::arch): Move it to reg_buffer::arch.
5931 (regcache::register_buffer): Likewise.
5932 (regcache::assert_regnum): Likewise.
5933 (regcache::num_raw_registers): Likewise.
5934 * regcache.h (reg_buffer): New class.
5935 (regcache): Inherit reg_buffer.
5936
7104e59b
SM
59372018-02-20 Simon Marchi <simon.marchi@ericsson.com>
5938
5939 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
5940 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
5941
2d8adcbd
MM
59422018-02-20 Markus Metzger <markus.t.metzger@intel.com>
5943
5944 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
5945
b5884fa7
AH
59462018-02-19 Alan Hayward <alan.hayward@arm.com>
5947
5948 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
5949 (SFILES): Remove common/*.c files.
5950 (COMMON_OBS): Remove some *.o files built from common/*.c files.
5951 * common/common.host: Add common reference.
5952 * configure.ac: Likewise.
5953 * configure: Regenerate.
5954
fd90ace4
YQ
59552018-02-16 Yao Qi <yao.qi@linaro.org>
5956
5957 * block.c (block_namespace_info): Inherit allocate_on_obstack.
5958 (block_initialize_namespace): Use new.
5959 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
5960 (dwarf2_free_objfile): Use delete.
5961 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
5962 (copy_type_recursive): Use new.
5963 * gdb_obstack.h (allocate_on_obstack): New.
5964
85046ae2
YQ
59652018-02-15 Yao Qi <yao.qi@linaro.org>
5966
5967 PR gdb/22849
5968 * inferior.c (exit_inferior_1): Reset inf->control.
5969
355c559b
JB
59702018-02-15 Joel Brobecker <brobecker@adacore.com>
5971
5972 * ada-lang.c (ada_to_fixed_value_create): Delete advance
5973 declaration.
5974
980548fd
PA
59752018-02-14 Pedro Alves <palves@redhat.com>
5976
5977 * frame-unwind.c (frame_unwind_try_unwinder): Always call
5978 frame_cleanup_after_sniffer on exception.
5979
692d6f97
TT
59802018-02-14 Tom Tromey <tom@tromey.com>
5981
5982 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
5983 const.
5984 (solib_bfd_open): Make pathname const.
5985 * solib.c (solib_bfd_open): Make pathname const.
5986 * solib-spu.c (spu_bfd_fopen): Make name const.
5987 (spu_bfd_open): Make pathname const.
5988 * solib-darwin.c (darwin_bfd_open): Make pathname const.
5989 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
5990
e0cc99a6
TT
59912018-02-14 Tom Tromey <tom@tromey.com>
5992
5993 * symfile.c (symfile_bfd_open): Update.
5994 * source.h (openp, source_full_path_of, find_and_open_source):
5995 Change argument type to unique_xmalloc_ptr.
5996 * source.c (openp): Take a unique_xmalloc_ptr.
5997 (source_full_path_of, find_and_open_source): Likewise.
5998 (open_source_file, symtab_to_fullname): Update.
5999 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
6000 unique_xmalloc_ptr.
6001 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
6002 (exec_file_find): Update.
6003 * psymtab.c (psymtab_to_fullname): Update.
6004 * nto-tdep.h (nto_find_and_open_solib): Update.
6005 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
6006 unique_xmalloc_ptr.
6007 * exec.c (exec_file_attach): Update.
6008 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
6009 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
6010
b46a8d7c
TT
60112018-02-14 Tom Tromey <tom@tromey.com>
6012
6013 * solib.c: Include source.h.
6014 * nto-tdep.c: Include source.h.
6015 * mi/mi-cmd-env.c: Include source.h.
6016 * infcmd.c: Include source.h.
6017 * exec.c: Include source.h.
6018 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
6019 (add_path, directory_switch, source_path, init_source_path): Move
6020 declarations...
6021 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
6022 (add_path, directory_switch, source_path, init_source_path):
6023 ...here.
6024
797bc1cb
TT
60252018-02-14 Tom Tromey <tom@tromey.com>
6026
6027 * solist.h (exec_file_find, solib_find): Return
6028 unique_xmalloc_ptr.
6029 (solib_bfd_fopen): Take a const char *.
6030 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
6031 (exec_file_find, solib_find): Likewise.
6032 (solib_bfd_fopen): Do not take ownership of "pathname".
6033 (solib_bfd_open): Use unique_xmalloc_ptr.
6034 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
6035 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
6036 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
6037 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
6038
f98b2e33
JB
60392018-02-14 Joel Brobecker <brobecker@adacore.com>
6040
6041 * ada-lang.c (name_match_type_from_name): Remove reference to
6042 ada_name_for_lookup in function's documentation.
6043 * ada-lang.h (ada_name_for_lookup): Delete declaration.
6044
24b9144d
SM
60452018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
6046
6047 * defs.h (enum openp_flags): New enum.
6048 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
6049 Move to enum openp_flags.
6050 (openp_flags): New enum flags.
6051 (openp): Change parameter type to openp_flags.
6052 * source.c (openp): Change parameter type to openp_flags.
6053 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
6054 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
6055
387cd15b
SM
60562018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
6057
6058 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
6059 per-command.
6060
b303c6f6
AB
60612018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
6062
6063 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
6064 into...
6065 (class dwarf2_queue_guard): ...the destructor of this new class.
6066 (dw2_do_instantiate_symtab): Create instance of the new class
6067 dwarf2_queue_guard, remove cleanup.
6068
9c3630e9
TT
60692018-02-09 Tom Tromey <tom@tromey.com>
6070
6071 * source.c (find_source_lines): Don't reference past the end of
6072 the vector.
6073
c4e12631
MM
60742018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6075
6076 * remote.c (remote_btrace_maybe_reopen): Change error message.
6077 * btrace.c (btrace_enable): Likewise.
6078 (parse_xml_btrace): Likewise.
6079 (parse_xml_btrace_conf): Likewise.
6080
88711fbf
MM
60812018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6082
6083 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
6084 (linux_enable_pt, linux_enable_bts): Call
6085 diagnose_perf_event_open_fail.
6086
17ad2a4f
MM
60872018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6088
6089 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
6090 Remove parameter and change return type. Update callers. Move it.
6091 (linux_enable_bts, linux_enable_pt): Improve error message.
6092 (linux_enable_pt): Remove zero buffer size check.
6093 (linux_enable_btrace): Improve error messages. Remove NULL return
6094 check.
6095
de6242d3
MM
60962018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6097
6098 * btrace.c (btrace_enable): Remove target_supports_btrace call.
6099 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
6100 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
6101 (linux_supports_pt, linux_supports_btrace): Remove.
6102 (linux_enable_bts): Call cpu_supports_bts.
6103 * nat/linux-btrace.h (linux_supports_btrace): Remove.
6104 * remote.c (remote_supports_btrace): Remove.
6105 (init_remote_ops): Remove remote_supports_btrace.
6106 * target-delegates.c: Regenerated.
6107 * target.c (target_supports_btrace): Remove.
6108 * target.h (target_ops) <to_supports_btrace>: Remove
6109 (target_supports_btrace): Remove.
6110 * x86-linux-nat.c (x86_linux_create_target): Remove
6111 linux_supports_btrace.
6112
9ee23a85
MM
61132018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6114
6115 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
6116 btrace failed.
6117 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
6118 exception and use message in own exception.
6119
5c3284c1
MM
61202018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6121
6122 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
6123 (perf_event_pt_event_type): Use gdb_file_up.
6124 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
6125 scoped_fd, and scoped_mmap.
6126
84696f37
MM
61272018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6128
6129 * common/scoped_mmap.h: New.
6130 * unittests/scoped_mmap-selftest.c: New.
6131 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6132 unittests/scoped_mmap-selftest.c.
6133
ea4a0888
MM
61342018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6135
6136 * common/scoped_fd.h: New.
6137 * unittests/scoped_fd-selftest.c: New.
6138 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6139 unittests/scoped_fd-selftest.c.
6140
869e8290
TT
61412018-02-09 Tom Tromey <tom@tromey.com>
6142
6143 * auto-load.c (auto_load_section_scripts): Use
6144 gdb::unique_xmalloc_ptr.
6145
a37a2ae7
TT
61462018-02-09 Tom Tromey <tom@tromey.com>
6147
6148 * auto-load.c (execute_script_contents): Use std::string.
6149
4e725347
JB
61502018-02-09 Joel Brobecker <brobecker@adacore.com>
6151
6152 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
6153 Python function, rather than a new command.
6154
9a897d43
TT
61552018-02-08 Tom Tromey <tom@tromey.com>
6156
6157 * solib.c (solib_find_1): Use std::string.
6158 (solib_bfd_fopen): Use unique_xmalloc_ptr.
6159
58ef3771
TT
61602018-02-08 Tom Tromey <tom@tromey.com>
6161
6162 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
6163
a9abc434
TT
61642018-02-08 Tom Tromey <tom@tromey.com>
6165
6166 * source.c (find_source_lines): Use gdb::def_vector.
6167
84f27c6f
TT
61682018-02-08 Tom Tromey <tom@tromey.com>
6169
6170 * macrocmd.c (struct temporary_macro_definition): New.
6171 (macro_define_command): Use temporary_macro_definition. Remove
6172 cleanups.
6173 (free_macro_definition_ptr): Remove.
6174
0354904b
TT
61752018-02-08 Tom Tromey <tom@tromey.com>
6176
6177 * macroexp.c (maybe_expand): Use std::string.
6178
1739cf24
TT
61792018-02-08 Tom Tromey <tom@tromey.com>
6180
6181 * macroexp.c (struct macro_buffer): Add initializers for some
6182 members.
6183 (init_buffer, init_shared_buffer, free_buffer)
6184 (free_buffer_return_text): Remove.
6185 (macro_buffer): New constructors.
6186 (~macro_buffer): New destructor.
6187 (macro_buffer::set_shared): New method.
6188 (macro_buffer::resize_buffer, macro_buffer::appendc)
6189 (macro_buffer::appendmem): Now methods, not free functions.
6190 (set_token, append_tokens_without_splicing, stringify)
6191 (macro_stringify): Update.
6192 (gather_arguments): Change return type. Remove argc_p argument,
6193 add args_ptr argument. Use std::vector.
6194 (substitute_args): Remove argc argument. Accept std::vector.
6195 (expand): Update. Use std::vector.
6196 (scan, macro_expand, macro_expand_next): Update.
6197
f6c2623e
TT
61982018-02-08 Tom Tromey <tom@tromey.com>
6199
6200 * symtab.c (default_collect_symbol_completion_matches_break_on):
6201 Use unique_xmalloc_ptr.
6202 * macroscope.h: (sal_macro_scope, user_macro_scope)
6203 (default_macro_scope): Return unique_xmalloc_ptr.
6204 * macroscope.c (sal_macro_scope, user_macro_scope)
6205 (default_macro_scope): Return unique_xmalloc_ptr.
6206 * macroexp.h (macro_expand, macro_expand_once): Return
6207 unique_xmalloc_ptr.
6208 * macroexp.c (macro_expand, macro_expand_once): Return
6209 unique_xmalloc_ptr.
6210 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6211 (info_macro_command, info_macros_command): Use
6212 unique_xmalloc_ptr.
6213 * compile/compile-c-support.c (write_macro_definitions): Use
6214 unique_xmalloc_ptr.
6215 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
6216
c2e0e465
SM
62172018-02-07 Simon Marchi <simon.marchi@ericsson.com>
6218
6219 * value.c (value_static_field): Assign field type instead of
6220 containing type when returning an optimized out value.
6221
3f8c94b4
YQ
62222018-02-06 Yao Qi <yao.qi@linaro.org>
6223
6224 * ft32-tdep.c (ft32_read_pc): Remove.
6225 (ft32_write_pc): Remove.
6226 (ft32_gdbarch_init): Update.
6227 * m32r-tdep.c (m32r_read_pc): Remove.
6228 (m32r_gdbarch_init): Update.
6229 * mep-tdep.c (mep_read_pc): Remove.
6230 (mep_gdbarch_init): Update.
6231 * microblaze-tdep.c (microblaze_write_pc): Remove.
6232 (microblaze_gdbarch_init): Update.
6233 * mn10300-tdep.c (mn10300_read_pc): Remove.
6234 (mn10300_write_pc): Remove.
6235 (mn10300_gdbarch_init): Update.
6236 * moxie-tdep.c (moxie_read_pc): Remove.
6237 (moxie_write_pc): Remove.
6238 (moxie_gdbarch_init): Update.
6239
bca65a23
YQ
62402018-02-06 Yao Qi <yao.qi@linaro.org>
6241
6242 * expprint.c (print_subexp_standard): Handle
6243 OP_F77_UNDETERMINED_ARGLIST.
6244 (dump_subexp_body_standard): Likewise.
6245
583e3f90 62462018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 6247
583e3f90
YQ
6248 * target-descriptions.c (tdesc_element_visitor) Add empty
6249 implementations.
b8df6ca7
AH
6250 (tdesc_type): Move make_gdb_type from here.
6251 (tdesc_type_builtin): Likewise.
6252 (tdesc_type_vector): Likewise.
6253 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
6254 (make_gdb_type_struct): Move from tdesc_type_with_fields.
6255 (make_gdb_type_union): Likewise.
6256 (make_gdb_type_flags): Likewise.
6257 (make_gdb_type_enum): Likewise.
6258 (make_gdb_type): New function.
6259 (tdesc_register_type): Use static make_gdb_type.
6260
e813d34a
RK
62612018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
6262
6263 * infcmd.c (default_print_one_register_info): Align natural-format
6264 column values consistently one under another.
6265 (pad_to_column): New function.
6266
0eb876f5
JB
62672018-02-05 Joel Brobecker <brobecker@adacore.com>
6268
6269 * dwarf2read.c (dwarf2_physname): Move commment.
6270
0625771b
LS
62712018-02-01 Leszek Swirski <leszeks@google.com>
6272
6273 * varobj.c (varobj_formatted_print_options): Allow recursive
6274 pretty printing if pretty printing is enabled.
6275
59498c30
LS
62762018-02-01 Leszek Swirski <leszeks@google.com>
6277
6278 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
6279 names after a structop as a filename.
6280
2d9e6acb
YQ
62812018-02-01 Yao Qi <yao.qi@linaro.org>
6282
6283 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
6284 (arm_record_coproc_data_proc): Likewise.
6285
df95a9cf
YQ
62862018-02-01 Yao Qi <yao.qi@linaro.org>
6287
6288 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
6289
07e5f5cf
NP
62902018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
6291
6292 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
6293 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
6294
3045b475
PA
62952018-01-31 Pedro Alves <palves@redhat.com>
6296
6297 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
6298 * inflow.c (child_terminal_save_inferior): Wrap reference to
6299 tcgetpgrp in HAVE_TERMIOS_H.
6300 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
6301 _WIN32.
6302 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
6303 always iterate over all inferiors.
6304 (gdbsim_cntrl_c): Adjust.
6305 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
6306
929b5ad4
JB
63072018-01-31 Joel Brobecker <brobecker@adacore.com>
6308
6309 * gdbtypes.c (lookup_array_range_type): Make sure the array's
6310 index type is objfile-owned if the element type is as well.
6311
29236ca2
JB
63122018-01-31 Joel Brobecker <brobecker@adacore.com>
6313
6314 GDB 8.1 released.
6315
c81e8879
PR
63162018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
6317
6318 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
6319 "features/s390x-linux64.c".
6320 (_initialize_s390_linux_tdep): Remove initialization of tdescs
6321 s390_linux32 and s390x_linux64.
6322 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
6323 default tdesc.
6324 * s390-tdep.c: Include "features/s390-linux32.c" and
6325 "features/s390x-linux64.c".
6326 (s390_tdesc_valid): Add check for tdesc_has_registers.
6327 (s390_gdbarch_init): Make sure there is always a valid tdesc.
6328 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
6329 tdesc_s390x_linux64.
6330 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
6331 tdesc_s390x_linux64 to...
6332 * s390-tdep.h: ...here.
6333
e671cd59
PA
63342018-01-30 Pedro Alves <palves@redhat.com>
6335
6336 PR gdb/13211
6337 * config.in, configure: Regenerate.
6338 * configure.ac: Check for getpgid.
6339 * go32-nat.c (go32_pass_ctrlc): New.
6340 (go32_target): Install it.
6341 * inf-child.c (inf_child_target): Install
6342 child_terminal_save_inferior, child_pass_ctrlc and
6343 child_interrupt.
6344 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
6345 (inf_ptrace_target): No longer install it.
6346 * infcmd.c (interrupt_target_1): Adjust.
6347 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
6348 (child_interrupt): Declare.
6349 (inferior::terminal_state): New.
6350 * inflow.c (struct terminal_info): Update comments.
6351 (inferior_process_group): Delete.
6352 (terminal_is_ours): Delete.
6353 (gdb_tty_state): New.
6354 (child_terminal_init): Adjust.
6355 (is_gdb_terminal, sharing_input_terminal_1)
6356 (sharing_input_terminal): New functions.
6357 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
6358 Set the process's actual process group in the foreground if
6359 possible. Handle is_ours_for_output/is_ours distinction. Don't
6360 mark terminal as the inferior's if not sharing GDB's terminal.
6361 Don't check attach_flag.
6362 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
6363 pass down a target_terminal_state.
6364 (child_terminal_save_inferior): New, factored out from ...
6365 (child_terminal_ours_1): ... this. Handle
6366 target_terminal_state::is_ours_for_output.
6367 (child_interrupt, child_pass_ctrlc): New.
6368 (inflow_inferior_exit): Clear the inferior's terminal_state.
6369 (copy_terminal_info): Copy the inferior's terminal state.
6370 (_initialize_inflow): Remove reference to terminal_is_ours.
6371 * inflow.h (inferior_process_group): Delete.
6372 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
6373 * procfs.c (procfs_target): Don't install procfs_interrupt.
6374 (procfs_interrupt): Delete.
6375 * remote.c (remote_serial_quit_handler): Adjust.
6376 (remote_interrupt): Remove ptid parameter. Adjust.
6377 * target-delegates.c: Regenerate.
6378 * target.c: Include "terminal.h".
6379 (target_terminal::terminal_state): Rename to ...
6380 (target_terminal::m_terminal_state): ... this.
6381 (target_terminal::init): Adjust.
6382 (target_terminal::inferior): Adjust to per-inferior
6383 terminal_state.
6384 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
6385 (target_terminal::ours, target_terminal::ours_for_output): Use
6386 target_terminal_is_ours_kind.
6387 (target_interrupt): Remove ptid parameter. Adjust.
6388 (default_target_pass_ctrlc): Adjust.
6389 * target.h (target_ops::to_terminal_save_inferior): New field.
6390 (target_ops::to_interrupt): Remove ptid_t parameter.
6391 (target_interrupt): Remove ptid_t parameter. Update comment.
6392 (target_pass_ctrlc): Update comment.
6393 * target/target.h (target_terminal_state): New scoped enum,
6394 factored out of ...
6395 (target_terminal::terminal_state): ... here.
6396 (target_terminal::inferior): Update comments.
6397 (target_terminal::restore_inferior): New.
6398 (target_terminal::is_inferior, target_terminal::is_ours)
6399 (target_terminal::is_ours_for_output): Adjust.
6400 (target_terminal::scoped_restore_terminal_state): Adjust to
6401 rename, and call restore_inferior() instead of inferior().
6402 (target_terminal::scoped_restore_terminal_state::m_state): Change
6403 type.
6404 (target_terminal::terminal_state): Rename to ...
6405 (target_terminal::m_terminal_state): ... this and change type.
6406
9c3a5d93
PA
64072018-01-30 Pedro Alves <palves@redhat.com>
6408
6409 * linux-nat.c (wait_for_signal): New function.
6410 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
6411 directly.
6412 (async_terminal_is_ours)
6413 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
6414 (linux_nat_add_target): Don't override
6415 to_terminal_inferior/to_terminal_ours.
6416
69ab5edb
SDJ
64172018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
6418
6419 * remote.c (remote_follow_fork): Don't call "detach_inferior".
6420
fc8e7e75
SM
64212018-01-28 Simon Marchi <simon.marchi@ericsson.com>
6422
6423 * dwarf2read.c (free_dwo_files): Add forward-declaration.
6424 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
6425 dwarf2_per_objfile_free here.
6426 (dwarf2_per_objfile_free): Remove.
6427 (_initialize_dwarf2_read): Don't register
6428 dwarf2_per_objfile_free as a registry cleanup.
6429
b2a426e2
EZ
64302018-01-27 Eli Zaretskii <eliz@gnu.org>
6431
6432 Avoid compilation errors in MinGW native builds
6433
6434 The error is triggered by including python-internal.h, and the
6435 error message is:
6436
6437 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
6438 from build-gnulib/import/math.h:27,
6439 from d:/usr/Python26/include/pyport.h:235,
6440 from d:/usr/Python26/include/Python.h:58,
6441 from python/python-internal.h:94,
6442 from python/py-arch.c:24:
6443 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
6444 using ::hypot;
6445 ^~~~~
6446
6447 This happens because Python headers define 'hypot' to expand t
6448 '_hypot' in the Windows builds.
6449 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
6450 'hypoth'. This avoids a compilation error.
6451
0bdd8eac
AH
64522018-01-26 Alan Hayward <alan.hayward@arm.com>
6453
6454 * MAINTAINERS (Write After Approval): Fix ordering.
6455
56ae9dc3
AH
64562018-01-26 Alan Hayward <alan.hayward@arm.com>
6457
6458 * MAINTAINERS (Write After Approval): Add Alan Hayward.
6459
7433498b
AM
64602018-01-26 Alan Modra <amodra@gmail.com>
6461
6462 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
6463 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
6464 Remove nop. Make const. Comment.
6465 (powerpc32_plt_stub_so_2): New.
6466 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
6467 Correct count. Update uses.
6468 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
6469 Move common code reading PLT entry word. Correct
6470 powerpc32_plt_stub PLT address calculation.
6471 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
6472 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
6473 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
6474 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
6475 (ppc64_standard_linkage8): Likewise.
6476 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
6477 Correct insns description.
6478 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
6479
0f59d5fc
PA
64802018-01-24 Pedro Alves <palves@redhat.com>
6481
6482 GCC PR libstdc++/83906
6483 * gdbtypes.c (operator==(const dynamic_prop &,
6484 const dynamic_prop &)): New.
6485 (operator==(const range_bounds &, const range_bounds &)): New.
6486 (check_types_equal): Use them instead of memcmp.
6487 * gdbtypes.h (operator==(const dynamic_prop &,
6488 const dynamic_prop &)): Declare.
6489 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
6490 (operator==(const range_bounds &, const range_bounds &)): Declare.
6491 (operator!=(const range_bounds &, const range_bounds &)): Declare.
6492
ef8914a4
PR
64932018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6494
6495 * s390-linux-tdep.c (s390_record_address_mask)
6496 (s390_record_calc_disp_common, s390_record_calc_disp)
6497 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
6498 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
6499 (s390_process_record): Move to s390-tdep.c.
6500 (s390_linux_init_abi_any): Adjust.
6501 * s390-tdep.c (s390_record_address_mask)
6502 (s390_record_calc_disp_common, s390_record_calc_disp)
6503 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
6504 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
6505 (s390_process_record): Moved from s390-linux-tdep.c
6506 (s390_gdbarch_init): Adjust.
6507
d6e58945
PR
65082018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6509
6510 * s390-linux-nat.c (s390-tdep.h): New include.
6511 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
6512 (HFILES_NO_SRCDIR): Add s390-tdep.h.
6513 (ALLDEPFILES): Add s390-tdep.c.
6514 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
6515 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
6516 * s390-tdep.h: ...this. New file.
6517 * s390-linux-tdep.c (s390-tdep.h): New include.
6518 (_initialize_s390_tdep): Rename to...
6519 (_initialize_s390_linux_tdep): ...this and adjust.
6520 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
6521 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
6522 s390-tdep.h.
6523 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
6524 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
6525 (s390_is_partial_instruction, s390_software_single_step)
6526 (is_non_branch_ril, s390_displaced_step_copy_insn)
6527 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
6528 (s390_prologue_data, s390_addr, s390_store, s390_load)
6529 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
6530 (s390_register_call_saved, s390_guess_tracepoint_registers)
6531 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
6532 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
6533 (s390_pseudo_register_name, s390_pseudo_register_type)
6534 (s390_pseudo_register_read, s390_pseudo_register_write)
6535 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
6536 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
6537 (s390_addr_bits_remove, s390_address_class_type_flags)
6538 (s390_address_class_type_flags_to_name)
6539 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
6540 (s390_function_arg_float, s390_function_arg_vector)
6541 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
6542 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
6543 (s390_frame_align, s390_register_return_value, s390_return_value)
6544 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
6545 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
6546 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
6547 (s390_trad_frame_prev_register, s390_unwind_cache)
6548 (s390_prologue_frame_unwind_cache)
6549 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
6550 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
6551 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
6552 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
6553 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
6554 (s390_frame_base_address, s390_local_base_address)
6555 (s390_frame_base, s390_gcc_target_options)
6556 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
6557 (s390_validate_reg_range, s390_tdesc_valid)
6558 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
6559 * s390-tdep.c: ...this. New file.
6560
9c0b896e
PR
65612018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6562
6563 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
6564 (s390_process_record, s390_gdbarch_tdep_alloc)
6565 (s390_linux_init_abi_any): Use/set new hook.
6566
7042632b
PR
65672018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6568
6569 * s390-linux-tdep.c (osabi.h): New include.
6570 (s390_linux_init_abi_31, s390_linux_init_abi_64)
6571 (s390_linux_init_abi_any): New functions.
6572 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
6573
650f5e13
PR
65742018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6575
6576 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
6577 tdesc_has_registers check
6578
47c9317e
PR
65792018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6580
6581 * s390-linux-tdep.c (s390_tdesc_valid): New function.
6582 (s390_validate_reg_range): New macro.
6583 (s390_gdbarch_init): Adjust.
6584
095085d8
PR
65852018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6586
6587 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
6588 (s390_gdbarch_tdep_alloc): Adjust.
6589 (s390_gdbarch_init): Adjust.
6590
ab9bcc67
PR
65912018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6592
6593 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
6594 <have_tdb>: Change type to bool.
6595 (s390_gdbarch_tdep_alloc): Adjust.
6596 (s390_gdbarch_init): Adjust.
6597
21f6f5ff
PR
65982018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6599
6600 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
6601 (gdbarch_tdep) <have_upper, have_vx>: New fields.
6602 (s390_gdbarch_tdep_alloc): New function.
6603 (s390_gdbarch_init): Allocate tdep at start and use its fields
6604 instead of separate variables.
6605
0eb97953
PR
66062018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
6607
6608 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
6609 when looking for cached gdbarch and add comment for remaining.
6610
5c319bb2
PA
66112018-01-22 Pedro Alves <palves@redhat.com>
6612 Sergio Durigan Junior <sergiodj@redhat.com>
6613
6614 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
6615 case.
6616
d65ce302
MR
66172018-01-22 Maciej W. Rozycki <macro@mips.com>
6618
6619 * MAINTAINERS: Update my company e-mail address.
6620
ec7a5fcb
YQ
66212018-01-22 Yao Qi <yao.qi@linaro.org>
6622
6623 * regcache.c (cooked_write_test): New function.
6624 (_initialize_regcache): Register the test.
6625
11f57cb6
YQ
66262018-01-22 Yao Qi <yao.qi@linaro.org>
6627
6628 * ia64-tdep.c (ia64_pseudo_register_read): Call
6629 regcache->cooked_read instead of regcache_cooked_read_unsigned.
6630 * m32c-tdep.c (m32c_cat_read): Likewise.
6631 (m32c_r3r2r1r0_read): Likewise.
6632 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
6633 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
6634
03f50fc8
YQ
66352018-01-22 Yao Qi <yao.qi@linaro.org>
6636
6637 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
6638 method raw_read instead of regcache_raw_read.
6639 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
6640 * arm-tdep.c (arm_neon_quad_read): Likewise.
6641 * avr-tdep.c (avr_pseudo_register_read): Likewise.
6642 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
6643 * frv-tdep.c (frv_pseudo_register_read): Likewise.
6644 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
6645 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
6646 (i386_pseudo_register_read_into_value): Likewise.
6647 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
6648 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
6649 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
6650 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
6651 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
6652 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
6653 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
6654 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
6655 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
6656
dc711524
YQ
66572018-01-22 Yao Qi <yao.qi@linaro.org>
6658
6659 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
6660 * configure.tgt: Remove target mt.
6661 * mt-tdep.c: Remove.
6662 * regcache.c (cooked_read_test): Remove the check for mt.
6663
3f5a868b
YQ
66642018-01-22 Yao Qi <yao.qi@linaro.org>
6665
6666 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
6667 instead of gdbarch_pseudo_register_read_value.
6668
de4cb04a
JB
66692018-01-22 Joel Brobecker <brobecker@adacore.com>
6670
6671 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
6672 language is Ada.
6673
a9e40818
JB
66742018-01-22 Joel Brobecker <brobecker@adacore.com>
6675
6676 * linespec.c (create_sals_line_offset): Remove code that preserved
6677 the symtab_and_line's line number.
6678
e707fc44
AB
66792018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
6680
6681 * varobj.c (varobj_create): Don't set valid_block when creating a
6682 floating varobj.
6683
03d0bf7b
AB
66842018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
6685
6686 * varobj.c (varobj_create): Remove out of date comment.
6687
ae451627
AB
66882018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
6689
6690 PR mi/20395
6691 * ada-exp.y (write_var_from_sym): Pass extra parameter when
6692 updating innermost block.
6693 * parse.c (innermost_block_tracker::update): Take extra type
6694 parameter, and check types match before updating innermost block.
6695 (write_dollar_variable): Update innermost block for registers.
6696 * parser-defs.h (enum innermost_block_tracker_type): New enum.
6697 (innermost_block_tracker::innermost_block_tracker): Initialise
6698 m_types member.
6699 (innermost_block_tracker::reset): Take type parameter.
6700 (innermost_block_tracker::update): Take type parameter, and pass
6701 type through as needed.
6702 (innermost_block_tracker::m_types): New member.
6703 * varobj.c (varobj_create): Pass type when reseting innermost
6704 block.
6705
aee1fcdf
AB
67062018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
6707
6708 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
6709 * ada-lang.c (resolve_subexp): Likewise.
6710 * breakpoint.c (set_breakpoint_condition) Likewise.
6711 (watch_command_1) Likewise.
6712 * c-exp.y (variable): Likewise.
6713 * d-exp.y (PrimaryExpression): Likewise.
6714 * f-exp.y (variable): Likewise.
6715 * go-exp.y (variable): Likewise.
6716 * m2-exp.y (variable): Likewise.
6717 * objfiles.c (objfile::~objfile): Likewise.
6718 * p-exp.y (variable): Likewise.
6719 * parse.c (innermost_block): Change type.
6720 * parser-defs.h (class innermost_block_tracker): New.
6721 (innermost_block): Change to innermost_block_tracker.
6722 * printcmd.c (display_command): Switch to innermost_block API.
6723 (do_one_display): Likewise.
6724 * rust-exp.y (do_one_display): Likewise.
6725 * symfile.c (clear_symtab_users): Likewise.
6726 * varobj.c (varobj_create): Switch to innermost_block API, replace
6727 use of innermost_block with block stored on varobj object.
6728
396af9a1
AB
67292018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
6730
6731 * expression.h (innermost_block): Remove declaration.
6732 * varobj.c: Add 'parser-defs.h' include.
6733
fcfcc376
TT
67342018-01-19 Tom Tromey <tom@tromey.com>
6735
6736 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
6737 symbols in the static and global blocks.
6738
5a6c3296
JC
67392018-01-19 James Clarke <jrtc27@jrtc27.com>
6740
6741 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
6742 gdb_ptrace.h, and move including gdb_wait.h ...
6743 * nat/linux-ptrace.h: ... to here.
6744
bc09b0c1
SM
67452018-01-19 Simon Marchi <simon.marchi@ericsson.com>
6746
6747 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
6748 inf_ptrace_detach_success.
6749 (inf_ptrace_detach_success): Add inferior parameter, use it
6750 instead of inferior_ptid, pass it to detach_inferior.
6751 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
6752 parameter.
6753 * inferior.c (detach_inferior): Add overload that takes an
6754 inferior object.
6755 * inferior.h (detach_inferior): Likewise.
6756 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
6757 use inferior_ptid, adjust call to inf_ptrace_detach_success.
6758 * linux-thread-db.c (thread_db_detach): Use inf parameter.
6759
6e1e1966
SM
67602018-01-19 Simon Marchi <simon.marchi@ericsson.com>
6761
6762 * target.h (struct target_ops) <to_detach>: Add inferior
6763 parameter.
6764 (target_detach): Likewise.
6765 * target.c (dispose_inferior): Pass inferior down.
6766 (target_detach): Pass inferior down. Assert that it is equal to
6767 the current inferior.
6768 * aix-thread.c (aix_thread_detach): Pass inferior down.
6769 * corefile.c (core_file_command): Pass current_inferior() down.
6770 * corelow.c (core_detach): Add inferior parameter.
6771 * darwin-nat.c (darwin_detach): Likewise.
6772 * gnu-nat.c (gnu_detach): Likewise.
6773 * inf-ptrace.c (inf_ptrace_detach): Likewise.
6774 * infcmd.c (detach_command): Pass current_inferior() down to
6775 target_detach.
6776 * infrun.c (follow_fork_inferior): Pass parent_inf to
6777 target_detach.
6778 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
6779 target_detach.
6780 * linux-nat.c (linux_nat_detach): Add inferior parameter.
6781 * linux-thread-db.c (thread_db_detach): Likewise.
6782 * nto-procfs.c (procfs_detach): Likewise.
6783 * procfs.c (procfs_detach): Likewise.
6784 * record.c (record_detach): Likewise.
6785 * record.h (struct inferior): Forward-declare.
6786 (record_detach): Add inferior parameter.
6787 * remote-sim.c (gdbsim_detach): Likewise.
6788 * remote.c (remote_detach_1): Likewise.
6789 (remote_detach): Likewise.
6790 (extended_remote_detach): Likewise.
6791 * sol-thread.c (sol_thread_detach): Likewise.
6792 * target-debug.h (target_debug_print_inferior_p): New macro.
6793 * target-delegates.c: Re-generate.
6794 * top.c (kill_or_detach): Pass inferior down to target_detach.
6795 * windows-nat.c (windows_detach): Add inferior parameter.
6796
6bd6f3b6
SM
67972018-01-19 Simon Marchi <simon.marchi@ericsson.com>
6798
6799 * target.h (struct target_ops) <to_detach>: Remove args
6800 parameter.
6801 (target_detach): Likewise.
6802 * target.c (dispose_inferior): Adjust.
6803 (target_detach): Remove args parameter, adjust.
6804 * aix-thread.c (aix_thread_detach): Adjust.
6805 * corefile.c (core_file_command): Adjust.
6806 * corelow.c (core_detach): Adjust.
6807 * darwin-nat.c (darwin_detach): Adjust.
6808 * gnu-nat.c (gnu_detach): Adjust.
6809 * inf-ptrace.c (inf_ptrace_detach): Adjust.
6810 * infcmd.c (detach_command): Adjust
6811 * infrun.c (follow_fork_inferior): Adjust.
6812 (handle_vfork_child_exec_or_exit): Adjust.
6813 * linux-fork.c (linux_fork_detach): Remove args parameter.
6814 * linux-fork.h (linux_fork_detach): Likewise.
6815 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
6816 * linux-thread-db.c (thread_db_detach): Likewise.
6817 * nto-procfs.c (procfs_detach): Likewise.
6818 * procfs.c (procfs_detach): Likewise.
6819 (do_detach): Remove signo parameter.
6820 * record.c (record_detach): Remove args parameter.
6821 * record.h (record_detach): Likewise.
6822 * remote-sim.c (gdbsim_detach): Likewise.
6823 * remote.c (remote_detach_1): Likewise.
6824 (remote_detach): Likewise.
6825 (extended_remote_detach): Likewise.
6826 * sol-thread.c (sol_thread_detach): Likewise.
6827 * target-delegates.c: Re-generate.
6828 * top.c (struct qt_args) <args>: Remove field.
6829 (kill_or_detach): Don't pass args.
6830 (quit_force): Don't set args.
6831 * windows-nat.c (windows_detach): Remove args parameter.
6832
88af8ea8
YQ
68332018-01-19 Yao Qi <yao.qi@linaro.org>
6834
6835 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
6836 (arm_linux_init_abi): Install it.
6837
dea445b9
YQ
68382018-01-19 Yao Qi <yao.qi@linaro.org>
6839
6840 * osabi.c (gdb_osabi_names): Extend the regexp for
6841 arm-linux-gnueabihf.
6842
4a17f768
YQ
68432018-01-18 Yao Qi <yao.qi@linaro.org>
6844
6845 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
6846 m_abbrevs.
6847 (abbrev_table::add_abbrev): Update.
6848 (abbrev_table::lookup_abbrev): Update.
6849
d679c21a
YQ
68502018-01-18 Yao Qi <yao.qi@linaro.org>
6851
6852 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
6853
7d937cad
SDJ
68542018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
6855
6856 * compile/compile.c (compile_to_object): Convert "triplet_rx"
6857 to "std::string".
6858
9e14690d
TT
68592018-01-17 Tom Tromey <tom@tromey.com>
6860
6861 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
6862
50a82047
TT
68632018-01-17 Tom Tromey <tom@tromey.com>
6864
6865 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
6866 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
6867 (create_array_type_with_stride): Update.
6868 * dwarf2read.c (set_die_type): Update.
6869
c89b44cd
TT
68702018-01-17 Tom Tromey <tom@tromey.com>
6871
6872 * dwarf2read.c (delayed_method_info): Remove typedef.
6873 (dwarf2_cu::method_info): Now a std::vector.
6874 (add_to_method_list): Update.
6875 (free_delayed_list): Remove.
6876 (compute_delayed_physnames): Update.
6877 (process_full_comp_unit, process_full_type_unit): Clear the method
6878 list. Remove cleanups.
6879 (psymtab_include_file_name): Add name_holder parameter. Use
6880 unique_xmalloc_ptr.
6881 (dwarf_decode_lines): Update.
6882
fcd3b13d
SM
68832018-01-17 Tom Tromey <tom@tromey.com>
6884 Simon Marchi <simon.marchi@ericsson.com>
6885
6886 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
6887 (dwarf2_per_objfile::free_cached_comp_units)
6888 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
6889 (init_cutu_and_read_dies_no_follow): Update.
6890 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
6891 (dwarf2_cu::~dwarf2_cu): New.
6892 (free_heap_comp_unit, free_stack_comp_unit): Remove.
6893 (age_cached_comp_units, free_one_cached_comp_unit): Update.
6894
685af9cd
TT
68952018-01-17 Tom Tromey <tom@tromey.com>
6896 Simon Marchi <simon.marchi@ericsson.com>
6897
6898 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
6899 (struct die_reader_specs) <abbrev_table>: New member.
6900 (struct abbrev_table): Add constructor.
6901 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
6902 <abbrev_obstack>: Now an auto_obstack.
6903 (abbrev_table_up): New typedef.
6904 (init_cu_die_reader): Add abbrev_table parameter.
6905 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
6906 Add result_dwo_abbrev_table.
6907 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
6908 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
6909 Update.
6910 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
6911 parameter.
6912 (skip_children): Update.
6913 (abbrev_table::alloc_abbrev): Rename from
6914 abbrev_table_alloc_abbrev.
6915 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
6916 (abbrev_table::lookup_abbrev): Rename from
6917 abbrev_table_lookup_abbrev.
6918 (abbrev_table_read_table): Return abbrev_table_up.
6919 (abbrev_table_free, abbrev_table_free_cleanup)
6920 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
6921 (load_partial_dies): Update.
6922
5e2db402
TT
69232018-01-17 Tom Tromey <tom@tromey.com>
6924
6925 * dwarf2read.c (dwarf2_compute_name): Update comment.
6926 (read_func_scope, read_variable): Update.
6927 (new_symbol): Remove.
6928 (new_symbol_full): Rename to new_symbol.
6929
ee7f689e 69302018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
6931
6932 PR gdb/16577
6933 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
6934 a warning instead of throwing an error, set section size to 0 and return
6935 NULL.
6936 * gdb_bfd.h (gdb_bfd_map_section): Update description.
6937
4d9b86e1
SM
69382018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6939
6940 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
6941 std::string.
6942 (linux_ptrace_attach_fail_reason_string): Likewise.
6943 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
6944 Likewise.
6945 (linux_ptrace_attach_fail_reason_string): Likewise.
6946 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
6947
a7b2d0fb
SM
69482018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6949
6950 * linux-nat.c (linux_nat_attach): Remove xstrdup.
6951
f517c180
EA
69522018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
6953
6954 PR gdb/21559
6955 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6956 checking for fs_base/gs_base fields in struct user_regs_struct.
6957 * configure: Regenerate.
6958
7045b1ca
YQ
69592018-01-17 Yao Qi <yao.qi@linaro.org>
6960
6961 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
6962 function.
6963 (aarch64_linux_init_abi): Install it to gdbarch hook
6964 gcc_target_options.
6965
db422fb2
PA
69662018-01-15 Pedro Alves <palves@redhat.com>
6967
6968 * common/signals-state-save-restore.c
6969 (save_original_signals_state): Fix typos.
6970
ba643918
SDJ
69712017-01-12 Tom Tromey <tom@tromey.com>
6972 Sergio Durigan Junior <sergiodj@redhat.com>
6973
6974 * Makefile.in (install-only): Install gdb-add-index.
6975
906b4aac
JB
69762018-01-12 John Baldwin <jhb@FreeBSD.org>
6977
6978 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
6979
bdf2a94a
AA
69802018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6981
6982 * infrun.c (keep_going_pass_signal): Clear step-over info when
6983 insert_breakpoints fails.
6984
71d378ae
PA
69852018-01-11 Pedro Alves <palves@redhat.com>
6986
6987 PR gdb/22583
6988 * infrun.c (resume): Rename to ...
6989 (resume_1): ... this.
6990 (resume): Reimplement as wrapper around resume_1.
6991
3cada740
PA
69922018-01-11 Pedro Alves <palves@redhat.com>
6993
6994 PR remote/22597
6995 * remote.c (remote_parse_stop_reply): Default to the last-set
6996 general thread instead of to 'magic_null_ptid'.
6997
618daa93
PA
69982018-01-10 Pedro Alves <palves@redhat.com>
6999
7000 * language.h (language_get_symbol_name_matcher): Rename ...
7001 (get_symbol_name_matcher): ... this.
7002 * language.c (language_get_symbol_name_matcher): Ditto.
7003 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
7004 callers adjusted.
7005
c63d3e8d
PA
70062018-01-10 Pedro Alves <palves@redhat.com>
7007
7008 PR gdb/22670
7009 * dwarf2read.c
7010 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
7011 Adjust to use language_get_symbol_name_matcher instead of
7012 language_defn::la_get_symbol_name_matcher.
7013 * language.c (language_get_symbol_name_matcher): If in Ada mode
7014 and the lookup name is a verbatim match, return Ada's matcher.
7015 * language.h (language_get_symbol_name_matcher): Adjust comment.
7016 (ada_lookup_name_info::verbatim_p):: New method.
7017
d4c2a405
PA
70182018-01-10 Pedro Alves <palves@redhat.com>
7019
7020 PR gdb/22670
7021 * ada-lang.c (ada_collect_symbol_completion_matches): If the
7022 minsym's language is language_auto or language_cplus, pass down
7023 language_ada instead.
7024 * symtab.c (compare_symbol_name): Don't frob symbol language here.
7025
8825213e
PA
70262018-01-10 Pedro Alves <palves@redhat.com>
7027
7028 PR gdb/22670
7029 * minsyms.c (linkage_name_str): New function.
7030 (iterate_over_minimal_symbols): Use it.
7031
2d97a5d9
JB
70322018-01-09 John Baldwin <jhb@FreeBSD.org>
7033
7034 * NEWS: Document that 'info proc' now works on FreeBSD.
7035
92fce24d
JB
70362018-01-09 John Baldwin <jhb@FreeBSD.org>
7037
7038 * configure.ac: Check for kinfo_getfile in libutil.
7039 * configure: Regenerate.
7040 * config.in: Regenerate.
7041 * fbsd-nat.c: Include "fbsd-tdep.h".
7042 (fbsd_fetch_cmdline): New.
7043 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
7044 rather than calling error.
7045 (fbsd_info_proc): New.
7046 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
7047 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
7048 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
7049
262f62f5
JB
70502018-01-09 John Baldwin <jhb@FreeBSD.org>
7051
7052 * fbsd-nat.c (struct free_deleter): Remove.
7053 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
7054
b999e203
JB
70552018-01-09 John Baldwin <jhb@FreeBSD.org>
7056
7057 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
7058 NULL for an empty pathname.
7059
d2176225
JB
70602018-01-09 John Baldwin <jhb@FreeBSD.org>
7061
7062 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
7063 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
7064 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
7065 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
7066 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
7067 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
7068 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
7069 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
7070 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
7071 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
7072 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
7073 (fbsd_core_fetch_timeval, fbsd_print_sigset)
7074 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
7075 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
7076 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
7077
9c4ac400
ST
70782018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
7079
7080 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
7081 (gnu_xfer_auxv): New function.
7082 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
7083 TARGET_OBJECT_AUXV.
7084
1e5ded6c
YQ
70852018-01-08 Yao Qi <yao.qi@linaro.org>
7086 Simon Marchi <simon.marchi@ericsson.com>
7087
7088 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
7089 common/selftest.c.
7090 (COMMON_OBS): Remove selftest.o.
7091 * configure.ac: Append selftest-arch.c and common/selftest.c to
7092 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
7093 * configure: Re-generated.
7094 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
7095 GDB_SELF_TEST.
7096 (maintenance_info_selftests): Likewise.
7097
04bafb1e
XR
70982018-01-08 Xavier Roirand <roirand@adacore.com>
7099
7100 * ada-valprint.c (val_print_packed_array_elements): Use
7101 proper number of elements when printing an array indexed
7102 by an enumeration type.
7103
518817b3
SM
71042018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
7105
7106 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
7107 (dw2_get_file_names_reader): Adjust.
7108 (lookup_dwo_signatured_type): Adjust.
7109 (lookup_dwp_signatured_type): Adjust.
7110 (lookup_signatured_type): Adjust.
7111 (create_type_unit_group): Adjust.
7112 (get_type_unit_group): Adjust.
7113 (process_psymtab_comp_unit_reader): Adjust.
7114 (build_type_psymtabs_reader): Adjust.
7115 (scan_partial_symbols): Adjust.
7116 (add_partial_symbol): Adjust.
7117 (add_partial_subprogram): Adjust.
7118 (peek_die_abbrev): Adjust.
7119 (fixup_go_packaging): Adjust.
7120 (process_imported_unit_die): Adjust.
7121 (dwarf2_compute_name): Adjust.
7122 (dwarf2_physname): Adjust.
7123 (read_import_statement): Adjust.
7124 (handle_DW_AT_stmt_list): Adjust.
7125 (read_file_scope): Adjust.
7126 (read_func_scope): Adjust.
7127 (read_lexical_block_scope): Adjust.
7128 (read_call_site_scope): Adjust.
7129 (read_variable): Adjust.
7130 (dwarf2_rnglists_process): Adjust.
7131 (dwarf2_ranges_process): Adjust.
7132 (dwarf2_ranges_read): Adjust.
7133 (dwarf2_get_pc_bounds): Adjust.
7134 (dwarf2_record_block_ranges): Adjust.
7135 (dwarf2_add_field): Adjust.
7136 (dwarf2_add_member_fn): Adjust.
7137 (read_structure_type): Adjust.
7138 (process_structure_scope): Adjust.
7139 (read_enumeration_type): Adjust.
7140 (read_array_type): Adjust.
7141 (mark_common_block_symbol_computed): Adjust.
7142 (read_common_block): Adjust.
7143 (read_namespace_type): Adjust.
7144 (read_namespace): Adjust.
7145 (read_module_type): Adjust.
7146 (read_tag_pointer_type): Adjust.
7147 (read_tag_ptr_to_member_type): Adjust.
7148 (read_tag_string_type): Adjust.
7149 (read_subroutine_type): Adjust.
7150 (read_typedef): Adjust.
7151 (read_base_type): Adjust.
7152 (attr_to_dynamic_prop): Adjust.
7153 (read_subrange_type): Adjust.
7154 (read_unspecified_type): Adjust.
7155 (dwarf2_read_abbrevs): Adjust.
7156 (load_partial_dies): Adjust.
7157 (read_partial_die): Adjust.
7158 (find_partial_die): Adjust.
7159 (guess_partial_die_structure_name): Adjust.
7160 (fixup_partial_die): Adjust.
7161 (read_attribute_value): Adjust.
7162 (read_addr_index): Adjust.
7163 (read_addr_index_from_leb128): Adjust.
7164 (read_str_index): Adjust.
7165 (dwarf2_string_attr): Adjust.
7166 (get_debug_line_section): Adjust.
7167 (dwarf_decode_line_header): Adjust.
7168 (lnp_state_machine::check_line_address): Adjust.
7169 (dwarf_decode_lines_1): Adjust.
7170 (dwarf_decode_lines): Adjust.
7171 (dwarf2_start_symtab): Adjust.
7172 (var_decode_location): Adjust.
7173 (new_symbol_full): Adjust.
7174 (dwarf2_const_value_data): Adjust.
7175 (dwarf2_const_value_attr): Adjust.
7176 (dwarf2_const_value): Adjust.
7177 (die_type): Adjust.
7178 (die_containing_type): Adjust.
7179 (build_error_marker_type): Adjust.
7180 (lookup_die_type): Adjust.
7181 (guess_full_die_structure_name): Adjust.
7182 (anonymous_struct_prefix): Adjust.
7183 (determine_prefix): Adjust.
7184 (dwarf2_name): Adjust.
7185 (follow_die_ref_or_sig): Adjust.
7186 (follow_die_offset): Adjust.
7187 (follow_die_ref): Adjust.
7188 (follow_die_sig_1): Adjust.
7189 (follow_die_sig): Adjust.
7190 (get_signatured_type): Adjust.
7191 (get_DW_AT_signature_type): Adjust.
7192 (decode_locdesc): Adjust.
7193 (dwarf_decode_macros): Adjust.
7194 (cu_debug_loc_section): Adjust.
7195 (fill_in_loclist_baton): Adjust.
7196 (dwarf2_symbol_mark_computed): Adjust.
7197 (init_one_comp_unit): Don't assign
7198 dwarf2_cu::dwarf2_per_objfile.
7199 (set_die_type): Adjust.
7200
ed2dc618
SM
72012018-01-07 Simon Marchi <simon.marchi@ericsson.com>
7202
7203 * dwarf2read.c (struct mapped_debug_names): Add constructor.
7204 <dwarf2_per_objfile>: New field.
7205 (dwarf2_per_objfile): Remove global.
7206 (get_dwarf2_per_objfile): New function.
7207 (set_dwarf2_per_objfile): New function.
7208 (dwarf2_build_psymtabs_hard): Change objfile parameter to
7209 dwarf2_per_objfile.
7210 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
7211 (read_abbrev_offset): Likewise.
7212 (read_indirect_string): Likewise.
7213 (read_indirect_line_string): Likewise.
7214 (read_indirect_string_at_offset): Likewise.
7215 (read_indirect_string_from_dwz): Likewise.
7216 (dwarf2_find_containing_comp_unit): Change objfile parameter to
7217 dwarf2_per_objfile.
7218 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
7219 (create_all_comp_units): Change objfile parameter to
7220 dwarf2_per_objfile.
7221 (create_all_type_units): Likewise.
7222 (process_queue): Add dwarf2_per_objfile parameter.
7223 (read_and_check_comp_unit_head): Likewise.
7224 (lookup_dwo_unit_in_dwp): Likewise.
7225 (get_dwp_file): Likewise.
7226 (process_cu_includes): Likewise.
7227 (struct free_dwo_file_cleanup_data): New struct.
7228 (dwarf2_has_info): Use get_dwarf2_per_objfile and
7229 set_dwarf2_per_objfile.
7230 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
7231 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
7232 context, adjust calls.
7233 (dw2_instantiate_symtab): Likewise.
7234 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
7235 (dw2_get_cu): Likewise.
7236 (create_cu_from_index_list): Change objfile parameter to
7237 dwarf2_per_objfile.
7238 (create_cus_from_index_list): Get dwarf2_per_objfile from
7239 context, adjust calls.
7240 (create_cus_from_index): Likewise.
7241 (create_signatured_type_table_from_index): Change objfile
7242 parameter to dwarf2_per_objfile.
7243 (create_signatured_type_table_from_debug_names): Change objfile
7244 parameter to dwarf2_per_objfile.
7245 (create_addrmap_from_index): Likewise.
7246 (create_addrmap_from_aranges): Likewise.
7247 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
7248 (dw2_setup): Remove.
7249 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
7250 context.
7251 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
7252 get_dwarf2_per_objfile.
7253 (dw2_forget_cached_source_info): Likewise.
7254 (dw2_map_symtabs_matching_filename): Likewise.
7255 (struct dw2_symtab_iterator) <index>: Remove.
7256 <dwarf2_per_objfile>: New field.
7257 (dw2_symtab_iter_init): Replace index parameter with
7258 dwarf2_per_objfile.
7259 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
7260 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
7261 (dw2_print_stats): Likewise.
7262 (dw2_dump): Likewise.
7263 (dw2_expand_symtabs_for_function): Likewise.
7264 (dw2_expand_all_symtabs): Likewise.
7265 (dw2_expand_symtabs_with_fullname): Likewise.
7266 (dw2_expand_marked_cus): Replace index and objfile parameters
7267 with dwarf2_per_objfile.
7268 (dw_expand_symtabs_matching_file_matcher): Add
7269 dwarf2_per_objfile parameter and adjust calls.
7270 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
7271 adjust calls.
7272 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
7273 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
7274 adjust calls.
7275 (create_cus_from_debug_names_list): Replace objfile parameter
7276 with dwarf2_per_objfile and adjust calls.
7277 (create_cus_from_debug_names): Likewise.
7278 (dwarf2_read_debug_names): Likewise.
7279 (mapped_debug_names::namei_to_name): Adjust call.
7280 (dw2_debug_names_iterator::next): Likewise.
7281 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
7282 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
7283 (dw2_debug_names_dump): Likewise.
7284 (dw2_debug_names_expand_symtabs_for_function): Likewise.
7285 (dw2_debug_names_expand_symtabs_matching): Likewise.
7286 (dwarf2_initialize_objfile): Likewise.
7287 (dwarf2_build_psymtabs): Likewise.
7288 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
7289 this_cu.
7290 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
7291 (read_and_check_comp_unit_head): Likewise.
7292 (read_abbrev_offset): Likewise.
7293 (create_debug_type_hash_table): Likewise.
7294 (create_debug_types_hash_table): Likewise.
7295 (create_all_type_units): Replace objfile parameter with
7296 dwarf2_per_objfile.
7297 (add_type_unit): Add dwarf2_per_objfile parameter.
7298 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
7299 with dwarf2_per_objfile.
7300 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
7301 (lookup_dwp_signatured_type): Likewise.
7302 (lookup_signatured_type): Likewise.
7303 (read_cutu_die_from_dwo): Likewise.
7304 (init_tu_and_read_dwo_dies): Likewise.
7305 (init_cutu_and_read_dies): Likewise.
7306 (init_cutu_and_read_dies_no_follow): Likewise.
7307 (allocate_type_unit_groups_table): Add objfile parameter.
7308 (create_type_unit_group): Use dwarf2_per_objfile from cu.
7309 (get_type_unit_group): Likewise.
7310 (process_psymtab_comp_unit): Update call.
7311 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
7312 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
7313 (print_tu_stats): Likewise.
7314 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
7315 in void* parameter.
7316 (build_type_psymtabs): Change objfile parameter to
7317 dwarf2_per_objfile.
7318 (process_skeletonless_type_unit): Use dwarf2_per_objfile
7319 passed in void* parameter.
7320 (process_skeletonless_type_units): Change objfile parameter to
7321 dwarf2_per_objfile.
7322 (set_partial_user): Likewise.
7323 (dwarf2_build_psymtabs_hard): Likewise.
7324 (read_comp_units_from_section): Likewise.
7325 (create_all_comp_units): Likewise.
7326 (scan_partial_symbols): Update calls.
7327 (add_partial_symbol): Likewise.
7328 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
7329 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
7330 (process_queue): Add dwarf2_per_objfile parameter.
7331 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
7332 (compute_compunit_symtab_includes): Likewise.
7333 (process_cu_includes): Add dwarf2_per_objfile parameter.
7334 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
7335 (process_full_type_unit): Likewise.
7336 (process_imported_unit_die): Update call.
7337 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
7338 (read_file_scope): Likewise.
7339 (allocate_dwo_file_hash_table): Add objfile parameter.
7340 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
7341 (create_cus_hash_table): Likewise.
7342 (create_dwp_hash_table): Likewise.
7343 (create_dwo_unit_in_dwp_v1): Likewise.
7344 (create_dwp_v2_section): Likewise.
7345 (create_dwo_unit_in_dwp_v2): Likewise.
7346 (lookup_dwo_unit_in_dwp): Likewise.
7347 (try_open_dwop_file): Likewise.
7348 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
7349 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
7350 cleanup to include a reference to dwarf2_per_objfile.
7351 (open_dwp_file): Add dwarf2_per_objfile parameter.
7352 (open_and_init_dwp_file): Likewise.
7353 (get_dwp_file): Likewise.
7354 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
7355 (queue_and_load_all_dwo_tus): Update call.
7356 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
7357 data.
7358 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
7359 (dwarf2_ranges_process): Likewise.
7360 (dwarf2_get_pc_bounds): Likewise.
7361 (mark_common_block_symbol_computed): Likewise.
7362 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
7363 (dwarf2_read_abbrevs): Update call.
7364 (read_partial_die): Use dwarf2_per_objfile from cu.
7365 (find_partial_die): Likewise.
7366 (fixup_partial_die): Likewise.
7367 (read_attribute_value): Likewise.
7368 (read_indirect_string_at_offset_from): Add objfile parameter.
7369 (read_indirect_string_at_offset): Add dwarf2_per_objfile
7370 parameter.
7371 (read_indirect_string_from_dwz): Add objfile parameter.
7372 (read_indirect_string): Add objfile parameter.
7373 (read_addr_index_1): Add dwarf2_per_objfile parameter.
7374 (read_addr_index): Use dwarf2_per_objfile from cu.
7375 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
7376 call dw2_setup.
7377 (read_str_index): Use dwarf2_per_objfile from cu.
7378 (get_debug_line_section): Likewise.
7379 (read_formatted_entries): Add dwarf2_per_objfile parameter.
7380 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
7381 (new_symbol_full): Use dwarf2_per_objfile from cu.
7382 (build_error_marker_type): Likewise.
7383 (lookup_die_type): Likewise.
7384 (determine_prefix): Likewise.
7385 (follow_die_offset): Likewise.
7386 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
7387 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
7388 (dwarf2_fetch_die_type_sect_off): Likewise.
7389 (dwarf2_get_die_type): Likewise.
7390 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
7391 (get_signatured_type): Likewise.
7392 (get_DW_AT_signature_type): Likewise.
7393 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
7394 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
7395 (cu_debug_loc_section): Likewise.
7396 (fill_in_loclist_baton): Likewise.
7397 (dwarf2_symbol_mark_computed): Likewise.
7398 (dwarf2_find_containing_comp_unit): Change objfile parameter to
7399 dwarf2_per_objfile.
7400 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
7401 parameter.
7402 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
7403 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
7404 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
7405 (set_die_type): Use dwarf2_free_objfile from cu.
7406 (get_die_type_at_offset): Likewise.
7407 (dwarf2_per_objfile_free): Don't assign global variable.
7408 (debug_names) <constructor>: Add dwarf2_per_objfile
7409 parameter, update m_debugstrlookup construction.
7410 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
7411 parameter.
7412 <m_dwarf2_per_objfile>: New field.
7413 <lookup>: Use m_dwarf2_per_objfile.
7414 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
7415 (psyms_seen_size): Likewise.
7416 (write_gdbindex): Replace objfile parameter with
7417 dwarf2_per_objfile.
7418 (write_debug_names): Likewise.
7419 (write_psymtabs_to_index): Likewise.
7420 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
7421 calls.
7422
e3b94546
SM
74232018-01-07 Simon Marchi <simon.marchi@ericsson.com>
7424
7425 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
7426 <dwarf2_per_objfile>: New field.
7427 (struct dwarf2_per_cu_data) <objfile>: Remove.
7428 <dwarf2_per_objfile>: New field.
7429 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
7430 of objfile.
7431 (create_signatured_type_table_from_index): Likewise.
7432 (create_debug_type_hash_table): Likewise.
7433 (fill_in_sig_entry_from_dwo_entry): Likewise.
7434 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
7435 (create_type_unit_group): Assign dwarf2_per_objfile instead of
7436 objfile.
7437 (create_partial_symtab): Access objfile through
7438 dwarf2_per_objfile.
7439 (process_psymtab_comp_unit_reader): Likewise.
7440 (read_comp_units_from_section): Likewise.
7441 (scan_partial_symbols): Likewise.
7442 (add_partial_symbol): Likewise.
7443 (add_partial_subprogram): Likewise.
7444 (peek_die_abbrev): Likewise.
7445 (fixup_go_packaging): Likewise.
7446 (process_full_comp_unit): Likewise.
7447 (process_full_type_unit): Likewise.
7448 (process_imported_unit_die): Likewise.
7449 (dwarf2_compute_name): Likewise.
7450 (dwarf2_physname): Likewise.
7451 (read_import_statement): Likewise.
7452 (create_cus_hash_table): Assign dwarf2_physname instead of
7453 objfile.
7454 (read_func_scope): Access objfile through dwarf2_per_objfile.
7455 (read_lexical_block_scope): Likewise.
7456 (read_call_site_scope): Likewise.
7457 (read_variable): Likewise.
7458 (dwarf2_rnglists_process): Likewise.
7459 (dwarf2_ranges_process): Likewise.
7460 (dwarf2_ranges_read): Likewise.
7461 (dwarf2_record_block_ranges): Likewise.
7462 (dwarf2_add_field): Likewise.
7463 (dwarf2_add_member_fn): Likewise.
7464 (read_structure_type): Likewise.
7465 (process_structure_scope): Likewise.
7466 (read_enumeration_type): Likewise.
7467 (read_array_type): Likewise.
7468 (read_common_block): Likewise.
7469 (read_namespace_type): Likewise.
7470 (read_namespace): Likewise.
7471 (read_module_type): Likewise.
7472 (read_tag_pointer_type): Likewise.
7473 (read_tag_ptr_to_member_type): Likewise.
7474 (read_tag_string_type): Likewise.
7475 (read_subroutine_type): Likewise.
7476 (read_typedef): Likewise.
7477 (read_base_type): Likewise.
7478 (attr_to_dynamic_prop): Likewise.
7479 (read_subrange_type): Likewise.
7480 (read_unspecified_type): Likewise.
7481 (load_partial_dies): Likewise.
7482 (read_partial_die): Likewise.
7483 (find_partial_die): Likewise.
7484 (guess_partial_die_structure_name): Likewise.
7485 (fixup_partial_die): Likewise.
7486 (read_attribute_value): Likewise.
7487 (read_addr_index_from_leb128): Likewise.
7488 (dwarf2_read_addr_index): Likewise.
7489 (dwarf2_string_attr): Likewise.
7490 (lnp_state_machine::check_line_address): Likewise.
7491 (dwarf_decode_lines_1): Likewise.
7492 (dwarf_decode_lines): Likewise.
7493 (dwarf2_start_symtab): Likewise.
7494 (var_decode_location): Likewise.
7495 (new_symbol_full): Likewise.
7496 (dwarf2_const_value_data): Likewise.
7497 (dwarf2_const_value_attr): Likewise.
7498 (dwarf2_const_value): Likewise.
7499 (die_type): Likewise.
7500 (die_containing_type): Likewise.
7501 (lookup_die_type): Likewise.
7502 (guess_full_die_structure_name): Likewise.
7503 (anonymous_struct_prefix): Likewise.
7504 (dwarf2_name): Likewise.
7505 (follow_die_ref_or_sig): Likewise.
7506 (follow_die_offset): Likewise.
7507 (follow_die_ref): Likewise.
7508 (dwarf2_fetch_die_loc_sect_off): Likewise.
7509 (dwarf2_fetch_constant_bytes): Likewise.
7510 (dwarf2_fetch_die_type_sect_off): Likewise.
7511 (dwarf2_get_die_type): Likewise.
7512 (follow_die_sig): Likewise.
7513 (decode_locdesc): Likewise.
7514 (dwarf2_per_cu_objfile): Likewise.
7515 (dwarf2_per_cu_text_offset): Likewise.
7516 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
7517 objfile.
7518 (set_die_type): Access objfile through
7519 dwarf2_per_objfile.
7520
b01ba14d
SM
75212018-01-07 Simon Marchi <simon.marchi@ericsson.com>
7522
7523 * valprint.c (converted_character_d): Remove typedef.
7524 (DEF_VEC_O (converted_character_d)): Remove.
7525 (count_next_character): Use std::vector.
7526 (print_converted_chars_to_obstack): Likewise.
7527 (generic_printstr): Likewise.
7528
4d0fdd9b
SM
75292018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
7530
7531 * xml-support.h (struct gdb_xml_value): Add constructor.
7532 <value>: Change type to unique_xmalloc_ptr.
7533 (gdb_xml_value_s): Remove typedef.
7534 (DEF_VEC_O (gdb_xml_value_s)): Remove.
7535 (gdb_xml_element_start_handler): Change parameter type to
7536 std::vector.
7537 (xml_find_attribute): Likewise.
7538 * xml-support.c (xml_find_attribute): Change parameter type to
7539 std::vector and adjust.
7540 (gdb_xml_values_cleanup): Remove.
7541 (gdb_xml_parser::start_element): Adjust to std::vector.
7542 (xinclude_start_include): Change paraeter type to std::vector
7543 and adjust.
7544 * btrace.c (check_xml_btrace_version): Likewise.
7545 (parse_xml_btrace_block): Likewise.
7546 (parse_xml_btrace_pt_config_cpu): Likewise.
7547 (parse_xml_btrace_pt): Likewise.
7548 (parse_xml_btrace_conf_bts): Likewise.
7549 (parse_xml_btrace_conf_pt): Likewise.
7550 * memory-map.c (memory_map_start_memory): Likewise.
7551 (memory_map_start_property): Likewise.
7552 * osdata.c (osdata_start_osdata): Likewise.
7553 (osdata_start_item): Likewise.
7554 (osdata_start_column): Likewise.
7555 * remote.c (start_thread): Likewise.
7556 * solib-aix.c (library_list_start_library): Likewise.
7557 (library_list_start_list): Likewise.
7558 * solib-svr4.c (library_list_start_library): Likewise.
7559 (svr4_library_list_start_list): Likewise.
7560 * solib-target.c (library_list_start_segment): Likewise.
7561 (library_list_start_section): Likewise.
7562 (library_list_start_library): Likewise.
7563 (library_list_start_list): Likewise.
7564 * tracepoint.c (traceframe_info_start_memory): Likewise.
7565 (traceframe_info_start_tvar): Likewise.
7566 * xml-syscall.c (syscall_start_syscall): Likewise.
7567 * xml-tdesc.c (tdesc_start_target): Likewise.
7568 (tdesc_start_feature): Likewise.
7569 (tdesc_start_reg): Likewise.
7570 (tdesc_start_union): Likewise.
7571 (tdesc_start_struct): Likewise.
7572 (tdesc_start_flags): Likewise.
7573 (tdesc_start_enum): Likewise.
7574 (tdesc_start_field): Likewise.
7575 (tdesc_start_enum_value): Likewise.
7576 (tdesc_start_vector): Likewise.
7577
f979c73f
SM
75782018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
7579
7580 * extension.h (struct xmethod_worker) <clone>: Remove.
7581 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
7582 Remove.
7583 (python_xmethod_worker::clone): Remove.
7584 * valops.c (find_overload_match): Use std::move instead of
7585 clone.
7586
ba18742c
SM
75872018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
7588
7589 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
7590 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
7591 <free_xmethod_worker_data>: Remove.
7592 <get_matching_xmethod_workers>: Chance VEC to std::vector.
7593 <get_xmethod_arg_types>: Remove.
7594 <get_xmethod_result_type>: Remove.
7595 <invoke_xmethod>: Remove.
7596 * extension.c (new_xmethod_worker): Remove.
7597 (clone_xmethod_worker): Remove.
7598 (get_matching_xmethod_workers): Return void, pass std::vector by
7599 pointer.
7600 (get_xmethod_arg_types): Rename to...
7601 (xmethod_worker::get_arg_types): ... this, and adjust.
7602 (get_xmethod_result_type): Rename to...
7603 (xmethod_worker::get_result_type): ... this, and adjust.
7604 (invoke_xmethod): Remove.
7605 (free_xmethod_worker): Remove.
7606 (free_xmethod_worker_vec): Remove.
7607 * extension.h (enum ext_lang_rc): Move here from
7608 extension-priv.h.
7609 (struct xmethod_worker): Add constructor and destructor.
7610 <data>: Remove.
7611 <value>: Remove.
7612 <invoke, clone, do_get_result_type, do_get_arg_types>: New
7613 virtual pure methods.
7614 <get_arg_types, get_result_type>: New methods.
7615 (xmethod_worker_ptr): Remove typedef.
7616 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
7617 (xmethod_worker_vec): Remove typedef.
7618 (xmethod_worker_up): New typedef.
7619 (invoke_xmethod): Remove.
7620 (clone_xmethod_worker): Remove.
7621 (free_xmethod_worker): Remove.
7622 (free_xmethod_worker_vec): Remove.
7623 (get_xmethod_arg_types): Remove.
7624 (get_xmethod_result_type): Remove.
7625 * valops.c (find_method_list): Use std::vector, don't use
7626 intermediate vector.
7627 (value_find_oload_method_list): Use std::vector.
7628 (find_overload_match): Use std::vector.
7629 (find_oload_champ): Use std::vector.
7630 * value.c (value_free): Use operator delete.
7631 (value_of_xmethod): Rename to...
7632 (value_from_xmethod): ... this. Don't assign
7633 xmethod_worker::value, take rvalue-reference.
7634 (result_type_of_xmethod): Adjust.
7635 (call_xmethod): Adjust.
7636 * value.h: Include extension.h.
7637 (struct xmethod_worker): Don't forward-declare.
7638 (value_of_xmethod): Rename to...
7639 (value_from_xmethod): ... this, take rvalue-reference.
7640 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
7641 (struct python_xmethod_worker): ... this, add constructor and
7642 destructor.
7643 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
7644 (gdbpy_free_xmethod_worker_data): Rename to...
7645 (python_xmethod_worker::~python_xmethod_worker): ... this and
7646 adjust.
7647 (gdbpy_clone_xmethod_worker_data): Rename to...
7648 (python_xmethod_worker::clone): ... this and adjust.
7649 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
7650 temporary vector.
7651 (gdbpy_get_xmethod_arg_types): Rename to...
7652 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
7653 (gdbpy_get_xmethod_result_type): Rename to...
7654 (python_xmethod_worker::do_get_result_type): ... this and
7655 adjust.
7656 (gdbpy_invoke_xmethod): Rename to...
7657 (python_xmethod_worker::invoke): ... this and adjust.
7658 (new_python_xmethod_worker): Rename to...
7659 (python_xmethod_worker::python_xmethod_worker): ... this and
7660 adjust.
7661 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
7662 Remove.
7663 (gdbpy_free_xmethod_worker_data): Remove.
7664 (gdbpy_get_matching_xmethod_workers): Use std::vector.
7665 (gdbpy_get_xmethod_arg_types): Remove.
7666 (gdbpy_get_xmethod_result_type): Remove.
7667 (gdbpy_invoke_xmethod): Remove.
7668 * python/python.c (python_extension_ops): Remove obsolete
7669 callbacks.
7670
e379cee6
PA
76712018-01-05 Pedro Alves <palves@redhat.com>
7672
7673 PR gdb/18653
7674 * common/signals-state-save-restore.c
7675 (save_original_signals_state): New parameter 'quiet'. Warn if we
7676 find a custom handler preinstalled, instead of internal erroring.
7677 But only warn if !quiet.
7678 * common/signals-state-save-restore.h
7679 (save_original_signals_state): New parameter 'quiet'.
7680 * main.c (captured_main_1): Move save_original_signals_state call
7681 after option handling, and pass QUIET.
7682
a655456c
PA
76832018-01-05 Pedro Alves <palves@redhat.com>
7684
7685 * spu-tdep.c (spu_catch_start): Pass
7686 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
7687
de63c46b
PA
76882018-01-05 Pedro Alves <palves@redhat.com>
7689
7690 PR gdb/22670
7691 * ada-lang.c (literal_symbol_name_matcher): New function.
7692 (ada_get_symbol_name_matcher): Use it for
7693 symbol_name_match_type::SEARCH_NAME.
7694 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
7695 it down instead of assuming symbol_name_match_type::FULL.
7696 * block.h (block_lookup_symbol): New parameter 'match_type'.
7697 * c-valprint.c (print_unpacked_pointer): Use
7698 lookup_symbol_search_name instead of lookup_symbol.
7699 * compile/compile-object-load.c (get_out_value_type): Pass down
7700 symbol_name_match_type::SEARCH_NAME.
7701 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
7702 symbol_name_match_type::FULL.
7703 * cp-support.c (cp_get_symbol_name_matcher): Handle
7704 symbol_name_match_type::SEARCH_NAME.
7705 * infrun.c (insert_exception_resume_breakpoint): Use
7706 lookup_symbol_search_name.
7707 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
7708 * psymtab.c (maintenance_check_psymtabs): Use
7709 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
7710 * stack.c (print_frame_args): Use lookup_symbol_search_name and
7711 SYMBOL_SEARCH_NAME.
7712 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
7713 if symbol_name_match_type::SEARCH_NAME.
7714 (lookup_symbol_in_language): Pass down
7715 symbol_name_match_type::FULL.
7716 (lookup_symbol_search_name): New.
7717 (lookup_language_this): Pass down
7718 symbol_name_match_type::SEARCH_NAME.
7719 (lookup_symbol_aux, lookup_local_symbol): New parameter
7720 'match_type'. Pass it down.
7721 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
7722 (lookup_symbol_search_name): New declaration.
7723 (lookup_symbol_in_block): New 'match_type' parameter.
7724
f98fc17b
PA
77252018-01-05 Pedro Alves <palves@redhat.com>
7726
7727 PR gdb/22670
7728 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
7729 ada_lookup_symbol.
7730 (ada_lookup_symbol): Reimplement in terms of
7731 ada_lookup_symbol_list, bits factored out from
7732 ada_lookup_encoded_symbol.
7733
342f8240
JB
77342018-01-05 Joel Brobecker <brobecker@adacore.com>
7735
7736 * ada-exp.y (write_object_renaming): When subscripting an array
7737 using a symbol as the index, pass the block in call to
7738 ada_lookup_encoded_symbol when looking that symbol up.
7739
7150d33c
JG
77402018-01-05 Jerome Guitton <guitton@adacore.com>
7741
7742 * ada-lang.c (ada_array_length): Use ada_index_type instead of
7743 TYPE_INDEX_TYPE.
7744
cc0e770c
JB
77452018-01-05 Joel Brobecker <brobecker@adacore.com>
7746
7747 * ada-lang.c (ada_to_fixed_value_create): Add handling of
7748 the case where VALUE_LVAL (val0) is not lval_memory.
7749
f79da888 77502018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
7751
7752 * ada-valprint.c (print_optional_low_bound): Handle
7753 character-indexed array printing like boolean-indexed array
7754 printing.
7755
cd385f94
JB
77562018-01-05 Joel Brobecker <brobecker@adacore.com>
7757
7758 * NEWS: Create a new section for the next release branch.
7759 Rename the section of the current branch, now that it has
7760 been cut.
7761
09aca949
JB
77622018-01-05 Joel Brobecker <brobecker@adacore.com>
7763
7764 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
7765 * version.in: Bump version to 8.1.50.DATE-git.
7766
9f757bf7
XR
77672018-01-03 Xavier Roirand <roirand@adacore.com>
7768
7769 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
7770 Add field.
7771 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
7772 Add field.
7773 (default_exception_support_info) <catch_handlers_sym>: Add field.
7774 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
7775 (ada_exception_name_addr_1): Add "catch handlers" handling.
7776 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
7777 Update all callers.
7778 (create_excep_cond_exprs) <ex>: Add parameter.
7779 (re_set_exception): Update create_excep_cond_exprs call.
7780 (print_it_exception, print_one_exception, print_mention_exception)
7781 (print_recreate_exception): Add "catch handler" handling.
7782 (allocate_location_catch_handlers, re_set_catch_handlers)
7783 (check_status_catch_handlers, print_it_catch_handlers)
7784 (print_one_catch_handlers, print_mention_catch_handlers)
7785 (print_recreate_catch_handlers): New function.
7786 (catch_handlers_breakpoint_ops): New variable.
7787 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
7788 Add parameter. Add "catch handler" handling.
7789 (ada_exception_sym_name, ada_exception_breakpoint_ops):
7790 Add "catch handler" handling.
7791 (ada_exception_catchpoint_cond_string): Add "catch handler"
7792 handling.
7793 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
7794 call.
7795 (catch_ada_handlers_command): New function.
7796 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
7797 operations structure.
7798 (_initialize_ada_language): Add "catch handlers" command entry.
7799 * NEWS: Document "catch handlers" feature.
7800
9fe561ab
JB
78012018-01-02 Joel Brobecker <brobecker@adacore.com>
7802
7803 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
7804 account when creating the array type of the slice.
7805 (ada_value_slice): Likewise.
7806
a405673c
JB
78072018-01-02 Joel Brobecker <brobecker@adacore.com>
7808
7809 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
7810 New enum value.
7811 (create_array_type_with_stride): Add byte_stride_prop parameter.
7812 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
7813 New parameter. Update all callers in this file.
7814 (array_type_has_dynamic_stride): New function.
7815 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
7816 of arrays with dynamic byte strides.
7817 * dwarf2read.c (read_array_type): Add support for dynamic
7818 DW_AT_byte_stride attributes.
7819
74a2f8ff
JB
78202018-01-02 Joel Brobecker <brobecker@adacore.com>
7821
7822 * dwarf2read.c (read_unspecified_type): Treat
7823 DW_TAG_enumeration_type DIEs from Ada units as stubs.
7824
e2882c85
JB
78252018-01-01 Joel Brobecker <brobecker@adacore.com>
7826
7827 Update copyright year range in all GDB files.
7828
1690bb24
JB
78292018-01-01 Joel Brobecker <brobecker@adacore.com>
7830
7831 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
7832 and gdb/testsuite/gdb.base/step-line.c.
7833
0f0c98a8
JB
78342018-01-01 Joel Brobecker <brobecker@adacore.com>
7835
7836 * copyright.py (main): Dump the contents of
7837 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
7838 even if BY_HAND is empty.
7839
82e1e79a
JB
78402018-01-01 Joel Brobecker <brobecker@adacore.com>
7841
7842 * top.c (print_gdb_version): Update Copyright year in version
7843 message.
7844
053f54e5 78452018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 7846
053f54e5 7847 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 7848
053f54e5 7849For older changes see ChangeLog-2017.
c906108c
SS
7850\f
7851Local Variables:
7852mode: change-log
7853left-margin: 8
7854fill-column: 74
7855version-control: never
57da7796 7856coding: utf-8
c906108c 7857End: