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