1 2017-12-07 Phil Muldoon <pmuldoon@redhat.com>
3 * python/py-breakpoint.c (bppy_init): Use string_to_event_location
4 over basic location code. Implement explicit location keywords.
5 (bppy_init_validate_args): New function.
6 * NEWS: Document Python explicit breakpoint locations.
8 2017-12-07 Joel Brobecker <brobecker@adacore.com>
10 * MAINTAINERS: Restore target entries for m68hc11-elf,
11 score-elf and xstormy16-elf, incorrectly removed in a previous
12 patch meant to only update the list of active maintainers.
14 2017-12-06 Pedro Alves <palves@redhat.com>
16 * break-catch-syscall.c (insert_catch_syscall)
17 (remove_catch_syscall): Adjust to pass reference to
18 inf_data->syscalls_counts directly via gdb::array_view.
19 * fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
21 * linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
22 * remote.c (remote_set_syscall_catchpoint): Likewise.
23 * target-debug.h (target_debug_print_bool): New.
24 (define target_debug_print_gdb_array_view_const_int): New.
25 * target-delegates.c: Regenerate.
26 * target.h (target_ops) <to_set_syscall_catchpoint>: Use
27 gdb::array_view and bool.
28 (target_set_syscall_catchpoint): Likewise.
30 2017-12-06 Simon Marchi <simon.marchi@ericsson.com>
32 * break-catch-syscall.c (catch_syscall_completer): Get pointers
33 to syscall group strings after building the string vector.
35 2017-12-06 Pedro Alves <palves@redhat.com>
37 * remote.c (remote_query_supported): Don't send "xmlRegisters=" if
38 "qXfer:features:read"" is disabled.
39 (remote_write_qxfer, remote_read_qxfer, remote_search_memory):
40 Check packet_config_support instead of packet->support directly.
42 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
44 * target-descriptions.c (struct tdesc_feature) <registers>: Use
46 (struct target_desc) <features>: Use tdesc_feature_up typedef.
48 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
50 * target-descriptions.c (struct tdesc_type): Use default
54 (struct tdesc_type_builtin): New.
55 (struct tdesc_type_vector): New.
56 (struct tdesc_type_with_fields): New.
57 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
58 (tdesc_gdb_type): Remove.
59 (tdesc_register_type): Adjust.
60 (tdesc_create_vector): Create tdesc_type_vector.
61 (tdesc_create_struct): Create tdesc_type_with_fields.
62 (tdesc_set_struct_size): Change parameter type.
63 (tdesc_create_union): Create tdesc_type_with_fields.
64 (tdesc_create_flags): Likewise.
65 (tdesc_create_enum): Likewise.
66 (tdesc_add_field): Change parameter type.
67 (tdesc_add_typed_bitfield): Likewise.
68 (tdesc_add_bitfield): Likewise.
69 (tdesc_add_flag): Likewise.
70 (tdesc_add_enum_value): Likewise.
71 (print_c_tdesc) <visit>: Remove overload with tdesc_type
72 parameter, add overloads for tdesc_type_builtin,
73 tdesc_type_with_fields and tdesc_type_vector.
74 <m_printed_type>: Remove.
75 <m_printed_element_type, m_printed_type_with_fields>: Add.
76 * target-descriptions.h (tdesc_create_enum): Change return type.
77 (tdesc_add_typed_bitfield): Change parameter type.
78 (tdesc_add_enum_value): Change parameter type.
79 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
80 type to tdesc_type_with_fields.
81 (tdesc_start_struct): Adjust.
82 (tdesc_start_flags): Adjust.
83 (tdesc_start_enum): Adjust.
84 (tdesc_start_field): Adjust.
85 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
86 (struct tdesc_type_vector): Forward-declare.
87 (struct tdesc_type_with_fields): Forward-declare.
88 (tdesc_create_struct): Change return type.
89 (tdesc_create_union): Likewise.
90 (tdesc_create_flags): Likewise.
91 (tdesc_add_field): Change parameter type.
92 (tdesc_set_struct_size): Likewise.
93 (tdesc_add_bitfield): Likewise.
94 (tdesc_add_flag): Likewise.
95 * features: Re-generate C files.
97 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
99 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
100 (struct tdesc_arch_reg): Add constructor.
101 (DEF_VEC_O (tdesc_arch_reg)): Remove.
102 (struct tdesc_arch_data): Initialize fields.
103 <arch_regs>: Change type to std::vector.
104 (target_find_description): Adjust.
105 (tdesc_find_type): Adjust.
106 (tdesc_data_init): Call tdesc_arch_data constructor.
107 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
108 (tdesc_data_cleanup): Free data with delete.
109 (tdesc_numbered_register): Adjust.
110 (tdesc_find_arch_register): Adjust.
111 (tdesc_use_registers): Adjust.
113 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
115 * target-descriptions.c (tdesc_type_field): Remove typedef.
116 (DEF_VEC_O (tdesc_type_field)): Remove.
117 (struct tdesc_type_field): Add constructor.
118 <name>: Change type to std::string.
119 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
121 <~tdesc_type>: Destroy vector if the type kind uses it.
122 <u::u::fields>: Change type to std::vector.
123 (tdesc_gdb_type): Adjust.
124 (tdesc_add_field): Adjust.
125 (tdesc_add_typed_bitfield): Adjust.
126 (tdesc_add_field): Adjust.
127 (tdesc_add_enum_value): Adjust.
128 (class print_c_tdesc) <visit>: Adjust.
130 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
132 * target-descriptions.c (struct tdesc_type) <name>: Change type
134 <~tdesc_type>: Don't manually free name.
135 <operator==>: Adjust.
136 (tdesc_named_type): Adjust.
137 (tdesc_find_type): Adjust.
138 (tdesc_gdb_type): Adjust.
139 (class print_c_tdesc) <visit>: Adjust.
141 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
143 * target-descriptions.c (tdesc_type_p): Remove typedef.
144 (DEF_VEC_P (tdesc_type_p)): Remove.
145 (struct tdesc_feature) <types>: Change type to std::vector.
146 <~tdesc_feature>: Replace with default implementation.
148 (tdesc_named_type): Adjust.
149 (tdesc_create_vector): Adjust.
150 (tdesc_create_struct): Adjust.
151 (tdesc_create_union): Adjust.
152 (tdesc_create_flags): Adjust.
153 (tdesc_create_enum): Adjust.
155 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
157 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
158 type of name_ parameter, adjust to std::string change.
159 <name, group, type>: Change type to std::string.
160 <~tdesc_reg>: Replace with default implementation.
161 <operator==>: Adjust.
162 (tdesc_find_register_early): Adjust.
163 (tdesc_register_name): Adjust.
164 (tdesc_register_type): Adjust.
165 (tdesc_register_in_reggroup_p): Adjust.
166 (class print_c_tdesc) <visit>: Adjust.
167 (class print_c_feature) <visit>: Adjust.
168 * features/arc-arcompact.c: Re-generate.
169 * features/arc-v2.c: Re-generate.
171 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
173 * target-descriptions.c (tdesc_reg_p): Remove typedef.
174 (DEF_VEC_P (tdesc_reg_p)): Remove.
175 (struct tdesc_feature) <registers>: Change type to std::vector.
176 <~tdesc_feature>: Don't manually free registers.
178 <operator==>: Adjust.
179 (tdesc_has_registers): Adjust.
180 (tdesc_find_register_early): Adjust.
181 (tdesc_use_registers): Adjust.
182 (tdesc_create_reg): Adjust.
184 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
186 * target-descriptions.c (tdesc_feature) <name>: Change type to
188 <~tdesc_feature>: Don't manually free name.
189 <operator==>: Adjust.
190 (tdesc_find_feature): Adjust.
191 (tdesc_feature_name): Adjust.
192 (class print_c_tdesc) <visit_pre>: Adjust.
193 (class print_c_feature) <visit_pre>: Adjust.
195 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
197 * target-descriptions.c (tdesc_feature_p): Remove typedef.
198 (DEF_VEC_P (tdesc_feature_p)): Remove.
199 (struct target_desc) <features>: Change type to std::vector.
200 <~target_desc>: Replace with default implementation.
202 <operator==>: Adjust.
203 (tdesc_has_registers): Adjust.
204 (tdesc_find_feature): Adjust.
205 (tdesc_use_registers): Adjust.
206 (tdesc_create_feature): Adjust.
208 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
210 * target-descriptions.c (arch_p): Remove typedef.
211 (DEF_VEC_P (arch_p)): Remove.
212 (struct target_desc) <compatible>: Change type to std::vector.
213 <~target_desc>: Don't manually free compatible.
214 (tdesc_compatible_p): Adjust.
215 (tdesc_add_compatible): Adjust.
216 (class print_c_tdesc) <visit_pre>: Adjust.
218 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
220 * target-descriptions.c (property_s): Remove typedef.
221 (DEF_VEC_O (property_s)): Remove.
222 (struct target_desc) <properties>: Make an std::vector.
223 <~target_desc>: Don't manually free properties.
224 (tdesc_property): Adjust.
225 (set_tdesc_property): Adjust.
226 (class print_c_tdesc) <visit_pre>: Adjust.
228 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
230 * common/gdb_assert.h (gdb_static_assert): Redefine using
233 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
235 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
237 (ada_is_redundant_range_encoding): Likewise.
238 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
240 * alpha-tdep.c (alpha_software_single_step): Likewise.
241 * arm-tdep.c (_initialize_arm_tdep): Likewise.
242 * auto-load.c (info_auto_load_cmd): Likewise.
243 * break-catch-syscall.c (insert_catch_syscall): Likewise.
244 (remove_catch_syscall): Likewise.
245 * breakpoint.c (condition_completer): Likewise.
246 (clear_command): Likewise.
247 (update_breakpoint_locations): Likewise.
248 * btrace.c (btrace_disable): Likewise.
249 (btrace_teardown): Likewise.
250 (btrace_maint_update_pt_packets): Likewise.
251 (maint_btrace_clear_cmd): Likewise.
252 * cli/cli-decode.c (lookup_cmd_1): Likewise.
253 (lookup_cmd_composition): Likewise.
254 * cli/cli-dump.c (scan_filename): Likewise.
255 (restore_command): Likewise.
256 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
257 * compile/compile-object-load.c (compile_object_load): Likewise.
258 * compile/compile-object-run.c (compile_object_run): Likewise.
259 * compile/compile.c (compile_to_object): Likewise.
260 * completer.c (filename_completer): Likewise.
261 (complete_files_symbols): Likewise.
262 (complete_expression): Likewise.
263 * corelow.c (core_open): Likewise.
264 * ctf.c (ctf_start): Likewise.
265 (ctf_write_status): Likewise.
266 (ctf_write_uploaded_tsv): Likewise.
267 (ctf_write_definition_end): Likewise.
268 (ctf_open_dir): Likewise.
269 (ctf_xfer_partial): Likewise.
270 (ctf_trace_find): Likewise.
271 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
273 * dwarf2loc.c (allocate_piece_closure): Likewise.
274 (indirect_pieced_value): Likewise.
275 (dwarf2_evaluate_loc_desc_full): Likewise.
276 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
277 (dw2_expand_symtabs_matching): Likewise.
278 (dw2_map_symbol_filenames): Likewise.
279 (read_and_check_comp_unit_head): Likewise.
280 (read_cutu_die_from_dwo): Likewise.
281 (lookup_dwo_unit): Likewise.
282 (read_comp_units_from_section): Likewise.
283 (dwarf2_compute_name): Likewise.
284 (handle_DW_AT_stmt_list): Likewise.
285 (create_cus_hash_table): Likewise.
286 (create_dwp_v2_section): Likewise.
287 (dwarf2_rnglists_process): Likewise.
288 (dwarf2_ranges_process): Likewise.
289 (dwarf2_record_block_ranges): Likewise.
290 (is_vtable_name): Likewise.
291 (read_formatted_entries): Likewise.
292 (skip_form_bytes): Likewise.
293 * elfread.c (elf_symtab_read): Likewise.
294 * exec.c (exec_file_command): Likewise.
295 * f-valprint.c (f_val_print): Likewise.
296 (info_common_command_for_block): Likewise.
297 * guile/guile.c (initialize_scheme_side): Likewise.
298 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
299 * guile/scm-cmd.c (cmdscm_completer): Likewise.
300 (gdbscm_register_command_x): Likewise.
301 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
302 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
303 * guile/scm-ports.c (file_port_magic): Likewise.
304 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
305 (ppscm_pretty_print_one_value): Likewise.
306 (ppscm_print_children): Likewise.
307 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
308 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
309 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
310 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
311 * i386-tdep.c (i386_register_reggroup_p): Likewise.
312 * infcmd.c (run_command_1): Likewise.
313 (until_next_fsm_clean_up): Likewise.
314 * linespec.c (linespec_complete): Likewise.
315 (find_label_symbols): Likewise.
316 * m2-valprint.c (m2_val_print): Likewise.
317 * memattr.c (require_user_regions): Likewise.
318 (lookup_mem_region): Likewise.
319 (disable_mem_command): Likewise.
320 (mem_delete): Likewise.
321 * mep-tdep.c (mep_register_name): Likewise.
322 (mep_analyze_prologue): Likewise.
323 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
324 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
325 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
326 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
327 * minidebug.c (lzma_open): Likewise.
328 * minsyms.c (lookup_minimal_symbol): Likewise.
329 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
330 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
331 (mips_o64_return_value): Likewise.
332 (mips_single_step_through_delay): Likewise.
333 (_initialize_mips_tdep): Likewise.
334 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
335 (nios2_software_single_step): Likewise.
336 * parse.c (find_minsym_type_and_address): Likewise.
337 * psymtab.c (psym_relocate): Likewise.
338 * python/py-breakpoint.c (bppy_get_commands): Likewise.
339 (gdbpy_breakpoint_modified): Likewise.
340 * python/py-infevents.c (create_inferior_call_event_object):
342 * python/py-record-btrace.c (btpy_list_item): Likewise.
343 * python/py-type.c (typy_str): Likewise.
344 * python/py-value.c (valpy_call): Likewise.
345 * python/python.c (do_start_initialization): Likewise.
346 * record-btrace.c (record_btrace_insn_history_range): Likewise.
347 (record_btrace_call_history_range): Likewise.
348 (record_btrace_record_method): Likewise.
349 (record_btrace_xfer_partial): Likewise.
350 (btrace_get_frame_function): Likewise.
351 * record-full.c (record_full_open): Likewise.
352 * record.c (get_context_size): Likewise.
353 * registry.h (DEFINE_REGISTRY): Likewise.
354 * remote-fileio.c (remote_fileio_request): Likewise.
355 * remote.c (remote_update_thread_list): Likewise.
356 (remote_check_symbols): Likewise.
357 (remote_commit_resume): Likewise.
358 (remote_interrupt): Likewise.
359 (remote_insert_breakpoint): Likewise.
360 (compare_sections_command): Likewise.
361 * rust-exp.y (super_name): Likewise.
362 (lex_string): Likewise.
363 (convert_ast_to_type): Likewise.
364 (convert_ast_to_expression): Likewise.
365 * rust-lang.c (rust_print_struct_def): Likewise.
366 (rust_print_type): Likewise.
367 (rust_evaluate_subexp): Likewise.
368 * rx-tdep.c (rx_register_type): Likewise.
369 * ser-event.c (serial_event_clear): Likewise.
370 * serial.c (serial_open): Likewise.
371 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
372 * symfile.c (section_is_overlay): Likewise.
373 (overlay_unmapped_address): Likewise.
374 (overlay_mapped_address): Likewise.
375 (simple_overlay_update_1): Likewise.
376 (simple_overlay_update): Likewise.
377 * symtab.c (symbol_find_demangled_name): Likewise.
378 (search_symbols): Likewise.
379 * target-descriptions.c (tdesc_predefined_type): Likewise.
380 * target.c (target_commit_resume): Likewise.
381 * thread.c (print_selected_thread_frame): Likewise.
382 * top.c (new_ui_command): Likewise.
383 (gdb_readline_no_editing): Likewise.
384 * tracefile-tfile.c (tfile_open): Likewise.
385 * tracepoint.c (create_tsv_from_upload): Likewise.
386 * utils.c (quit): Likewise.
387 (defaulted_query): Likewise.
388 * valarith.c (value_concat): Likewise.
389 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
390 * xml-tdesc.c (target_fetch_description_xml): Likewise.
391 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
392 (xtensa_pseudo_register_write): Likewise.
394 2017-12-04 Tom Tromey <tom@tromey.com>
396 * NEWS: Mention Rust trait object inspection.
398 2017-12-04 Pedro Alves <palves@redhat.com>
401 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
402 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
403 (vex2_prefix_p, vex3_prefix_p): New functions.
404 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
406 (fixup_riprel): Set VEX3.!B.
408 2017-12-03 Simon Marchi <simon.marchi@ericsson.com>
410 * target.h (mem_region_vector): Remove.
411 (struct target_ops) <to_memory_map>: Change return type to
412 std::vector<mem_region>.
413 * target-debug.h (target_debug_print_mem_region_vector): Rename
415 (target_debug_print_std_vector_mem_region): ... this.
416 * target-delegates.c: Re-generate.
418 2017-12-03 Pedro Alves <palves@redhat.com>
420 * make-target-delegates (munge_type): Also munge '<', '>', and
421 ':'. Avoid double underscores in identifiers, and trailing
424 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
426 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
427 * target-delegates.c: Regenerate.
429 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
431 * common/poison.h (XDELETE): Fix typo.
433 2017-12-01 Andrew Cagney <cagney@redhat.com>
434 Joel Brobecker <brobecker@adacore.com>
435 Sergio Durigan Junior <sergiodj@redhat.com>
437 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
439 * coffread.c (coff_symfile_read): Do not map over sections with
440 'coff_locate_sections' if readnever is on.
441 * dwarf2read.c (dwarf2_has_info): Return 0 if
443 * elfread.c (elf_symfile_read): Do not map over sections with
444 'elf_locate_sections' if readnever is on.
445 * main.c (validate_readnow_readnever): New function.
446 (captured_main_1): Add support for --readnever.
447 (print_gdb_help): Document --readnever.
448 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
450 * symfile.c (readnever_symbol_files): New global.
451 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
452 'READNEVER_SYMBOL_FILES' is set.
453 (validate_readnow_readnever): New function.
454 (symbol_file_command): Handle '-readnever' option.
455 Call 'validate_readnow_readnever'.
456 (add_symbol_file_command): Handle '-readnever' option.
457 Call 'validate_readnow_readnever'.
458 (_initialize_symfile): Document new '-readnever' option for
459 both 'symbol-file' and 'add-symbol-file' commands.
460 * top.h (readnever_symbol_files): New extern global.
461 * xcoffread.c (xcoff_initial_scan): Do not read debug
462 information if readnever is on.
464 2017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
466 * symfile.c (symbol_file_command): Call
467 'symbol_file_add_main_1' only after processing all command
469 (add_symbol_file_command): Modify logic to make arguments
470 position-independent.
472 2017-12-01 Joel Brobecker <brobecker@adacore.com>
474 * ada-lang.c (symbol_list_obstack): Delete.
475 (resolve_subexp): Make sure "candidates" gets xfree'ed.
476 (ada_lookup_symbol_list_worker): Remove the limitation that
477 the result is only good until the next call, now making it
478 the responsibility of the caller to free the result when no
479 longer needed. Adjust the function's intro comment accordingly.
480 (ada_lookup_symbol_list): Adjust the function's intro comment.
481 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
482 (ada_lookup_encoded_symbol, get_var_value): Likewise.
483 (_initialize_ada_language): Remove symbol_list_obstack
485 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
486 (write_var_or_type, write_name_assoc): Likewise.
488 2017-12-01 Tom Tromey <tom@tromey.com>
490 * Makefile.in (all_deps_files): New variable.
491 Include .Po files using all_deps_files.
493 2017-12-01 Joel Brobecker <brobecker@adacore.com>
495 * MAINTAINERS: Update list of maintainers, moving those who
496 stepped down or became inactive to the "Past Maintainers"
499 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
501 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
503 (NEW_PROC_API): Remove.
504 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
506 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
507 * configure: Regenerate.
508 * config.in: Regenerate.
509 * gdbserver/configure: Regenerate.
510 * gdbserver/config.in: Regenerate.
512 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
514 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
516 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
518 * proc-api.c: Remove !NEW_PROC_API support.
519 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
520 Remove tests for macros always defined on Solaris.
521 * proc-events.c: Remove !NEW_PROC_API support.
522 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
523 HAVE_SYS_USER_H tests.
524 (init_syscall_table): Remove non-Solaris syscalls.
525 Remove tests for syscalls present on all Solaris versions.
526 Add missing Solaris 10+ syscalls.
527 (signal_table): Remove non-Solaris signals.
528 Remove tests for signals present on all Solaris versions.
529 (fault_table): Remove non-Solaris faults.
530 Remove tests for faults present on all Solaris versions.
531 * proc-flags.c: Remove !NEW_PROC_API support.
532 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
533 Remove non-Solaris flags.
534 * proc-why.c: Remove !NEW_PROC_API support.
535 (pr_why_table): Remove meaningless comments.
536 Remove tests for reasons present on all Solaris versions.
538 (proc_prettyfprint_why): Likewise.
540 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
541 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
542 Remove WA_READ test, IRIX watchpoint support.
543 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
545 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
546 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
548 Remove CTL_PROC_NAME_FMT tests.
549 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
551 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
552 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
553 (proc_modify_flag): Replace GDBRESET by PCUNSET.
554 Remove PR_ASYNC, PR_KLC tests.
555 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
556 (proc_parent_pid): Remove PCWATCH etc. tests.
557 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
559 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
560 Remove SYS_lwpcreate || SYS_lwp_create test.
561 (proc_get_current_thread): Likewise.
562 [PIOCNTHR && PIOCTLIST]: Remove.
563 [PIOCLSTATUS]: Remove.
564 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
565 [PRFS_STOPEXEC]: Remove.
566 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
567 (syscall_is_exit): Likewise.
568 (syscall_is_exec): Likewise.
569 (syscall_is_lwp_create): Likewise.
570 Remove SYS_syssgi support.
571 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
572 [SYS_syssgi]: Remove.
573 Remove non-Solaris cases, conditionals.
574 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
576 (procfs_init_inferior) [SYS_syssgi]: Remove.
577 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
578 (procfs_inferior_created) [SYS_syssgi]: Remove.
579 (procfs_set_watchpoint): Remove !AIX5 test.
580 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
582 (mappingflags) [MA_PHYS]: Remove.
583 (info_mappings_callback): Remove PCAGENT test.
584 Remove PIOCOPENLWP || PCAGENT test.
586 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
588 * sol-thread.c (info_solthreads): Constify args.
591 2017-11-29 John Baldwin <jhb@FreeBSD.org>
593 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
595 2017-11-29 Joel Brobecker <brobecker@adacore.com>
597 * ada-lang.c (to_fixed_range_type): Make sure that the size
598 of the range type being returned is the same as the size
599 of the range type being fixed.
601 2017-11-29 Pedro Alves <palves@redhat.com>
604 * NEWS: Mention setting breakpoints on functions with C++ ABI
606 * completer.h (completion_match_for_lcd) <match,
607 mark_ignored_range>: New methods.
608 <finish>: Consider ignored ranges.
609 <clear>: Clear ignored ranges.
610 <m_ignored_ranges, m_finished_storage>: New fields.
611 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
612 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
613 completion_match_for_lcd pointer to strncmp_iw_with_mode.
614 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
615 * language.c (default_symbol_name_matcher): Pass the
616 completion_match_for_lcd pointer to strncmp_iw_with_mode.
617 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
618 * utils.c (skip_abi_tag): New function.
619 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
621 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
624 2017-11-29 Pedro Alves <palves@redhat.com>
627 * NEWS: Mention setting breakpoints on functions with C++ ABI
629 * completer.h (completion_match_for_lcd) <match,
630 mark_ignored_range>: New methods.
631 <finish>: Consider ignored ranges.
632 <clear>: Clear ignored ranges.
633 <m_ignored_ranges, m_finished_storage>: New fields.
634 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
635 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
636 completion_match_for_lcd pointer to strncmp_iw_with_mode.
637 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
638 * language.c (default_symbol_name_matcher): Pass the
639 completion_match_for_lcd pointer to strncmp_iw_with_mode.
640 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
641 * utils.c (skip_abi_tag): New function.
642 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
644 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
647 2017-11-29 Pedro Alves <palves@redhat.com>
649 * NEWS: Mention that breakpoints on C++ functions are now set on
650 on all namespaces/classes by default, and mention "break
652 * ax-gdb.c (agent_command_1): Adjust to pass a
653 symbol_name_match_type to new_linespec_location.
654 * breakpoint.c (parse_breakpoint_sals): Adjust to
655 get_linespec_location's return type change.
656 (strace_marker_create_sals_from_location): Adjust to pass a
657 symbol_name_match_type to new_linespec_location.
658 (strace_marker_decode_location): Adjust to get_linespec_location's
660 (strace_command): Adjust to pass a symbol_name_match_type to
661 new_linespec_location.
662 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
663 mention "-qualified".
664 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
665 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
667 (complete_address_and_linespec_locations): New parameter
668 'match_type'. Pass it down.
669 (explicit_options): Add "-qualified".
670 (collect_explicit_location_matches): Pass the requested match type
671 to the linespec completers. Handle MATCH_QUALIFIED.
672 (location_completer): Handle "-qualified" combined with linespecs.
673 * cp-support.c (cp_search_name_hash): New.
674 (cp_symbol_name_matches_1): Implement wild matching for C++.
675 (cp_fq_symbol_name_matches): Reimplement.
676 (cp_get_symbol_name_matcher): Return different matchers depending
677 on the lookup name's match type.
678 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
679 * cp-support.h (cp_search_name_hash): New declaration.
681 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
683 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
685 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
686 pass a symbol_name_match_type to new_linespec_location.
687 * linespec.c (linespec_parse_basic): Lookup function symbols using
688 the parser's symbol name match type.
689 (convert_explicit_location_to_linespec): New
690 symbol_name_match_type parameter. Pass it down to
691 find_linespec_symbols.
692 (convert_explicit_location_to_sals): Pass the location's name
693 match type to convert_explicit_location_to_linespec.
694 (parse_linespec): New match_type parameter. Save it in the
696 (linespec_parser_new): Default to symbol_name_match_type::WILD.
697 (linespec_complete_function): New symbol_name_match_type
699 (complete_linespec_component): Pass down the parser's recorded
701 (linespec_complete_label): New symbol_name_match_type parameter.
703 (linespec_complete): New symbol_name_match_type parameter. Save
704 it in the parser and pass it down. Adjust to
705 get_linespec_location's prototype change.
706 (find_function_symbols, find_linespec_symbols): New
707 symbol_name_match_type parameter. Pass it down instead of
708 assuming symbol_name_match_type::WILD.
709 * linespec.h (linespec_complete, linespec_complete_function)
710 (linespec_complete_label): New symbol_name_match_type parameter.
711 * location.c (event_location::linespec_location): Now a struct
713 (EL_LINESPEC): Adjust.
714 (initialize_explicit_location): Default to
715 symbol_name_match_type::WILD.
716 (new_linespec_location): New symbol_name_match_type parameter.
717 Record it in the location.
718 (get_linespec_location): Now returns a struct linespec_location.
719 (new_explicit_location): Also copy func_name_match_type.
720 (explicit_to_string_internal)
721 (string_to_explicit_location): Handle "-qualified".
722 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
723 Copy symbol_name_match_type fields.
724 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
726 (event_location_to_string): Adjust to LINESPEC_LOCATION type
727 change. Handle "-qualfied".
728 (string_to_explicit_location): Handle "-qualified".
729 (string_to_event_location_basic): New symbol_name_match_type
730 parameter. Pass it down.
731 (string_to_event_location): Handle "-qualified".
732 * location.h (struct linespec_location): New.
733 (explicit_location::func_name_match_type): New field.
734 (new_linespec_location): Now returns a const linespec_location *.
735 (string_to_event_location_basic): New symbol_name_match_type
737 (explicit_completion_info::saw_explicit_location_option): New
739 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
740 symbol_name_match_type to new_linespec_location.
741 * python/py-breakpoint.c (bppy_init): Likewise.
742 * python/python.c (gdbpy_decode_line): Likewise.
744 2017-11-29 Pedro Alves <palves@redhat.com>
746 * ada-lang.c (ada_lookup_name_info::matches): Change type of
747 parameter from completion_match to completion_match_result.
749 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
750 * completer.c (completion_tracker::maybe_add_completion): Add
751 match_for_lcd parameter and use it.
752 (completion_tracker::add_completion): Likewise.
753 * completer.h (class completion_match_for_lcd): New class.
754 (completion_match_result::match_for_lcd): New field.
755 (completion_match_result::set_match): New method.
756 (completion_tracker): Add comments.
757 (completion_tracker::add_completion): Add match_for_lcd parameter.
758 (completion_tracker::reset_completion_match_result): Reset
760 (completion_tracker::maybe_add_completion): Add match_for_lcd
762 (completion_tracker::m_lowest_common_denominator_unique): Extend
764 * cp-support.c (cp_symbol_name_matches_1)
765 (cp_fq_symbol_name_matches): Change type of parameter from
766 completion_match to completion_match_result. Adjust.
767 * language.c (default_symbol_name_matcher): Change type of
768 parameter from completion_match to completion_match_result.
770 * language.h (completion_match_for_lcd): Forward declare.
771 (default_symbol_name_matcher): Change type of parameter from
772 completion_match to completion_match_result.
773 * symtab.c (compare_symbol_name): Adjust.
774 (completion_list_add_name): Pass the match_for_lcd to the tracker.
775 * symtab.h (ada_lookup_name_info::matches): Change type of
776 parameter from completion_match to completion_match_result.
777 (symbol_name_matcher_ftype): Likewise, and update comments.
779 2017-11-29 Pedro Alves <palves@redhat.com>
781 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
782 * minsyms.c (msymbol_is_text): Delete.
783 (msymbol_is_function): New function.
784 * minsyms.h (msymbol_is_text): Delete.
785 (msymbol_is_function): New declaration.
786 * symtab.c (find_function_alias_target): Use msymbol_is_function.
788 2017-11-29 Tom Tromey <tom@tromey.com>
790 * Makefile.in (distclean): Handle the case where rmdir fails.
792 2017-11-29 Tom Tromey <tom@tromey.com>
794 * symfile.c (_initialize_symfile): Update usage text for
795 add-symbol-file, symbol-file, load.
797 2017-11-29 Tom Tromey <tom@tromey.com>
799 * symfile.c (add_symbol_file_command): Error if some arguments to
800 -s are missing. Change unrecognized-argument error message.
801 (_initialize_symfile): Fix usage text for add-symbol-file.
803 2017-11-27 Tom Tromey <tom@tromey.com>
805 * Makefile.in (REMOTE_OBS): Remove.
806 (SFILES): Remove remote sources.
807 (COMMON_SFILES): Add remote sources.
808 (ALLDEPFILES): Remove dcache.c.
810 2017-11-27 Tom Tromey <tom@tromey.com>
812 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
814 (SFILES): Use SUBDIR_TARGET_SRCS.
815 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
816 (CONFIG_SRC_SUBDIR): Add target.
817 (%.o): Remove target rule.
819 2017-11-27 Tom Tromey <tom@tromey.com>
821 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
822 registry.o, thread-fsm.o, debug.o.
823 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
824 thread-fsm.c, debug.c.
826 2017-11-27 Tom Tromey <tom@tromey.com>
828 * Makefile.in (COMMON_SFILES): New.
829 (SFILES): Move some entries to COMMON_SFILES.
830 (COMMON_OBS): Use COMMON_SFILES.
832 2017-11-27 Tom Tromey <tom@tromey.com>
834 * Makefile.in (YYFILES): Update comment.
837 2017-11-27 Tom Tromey <tom@tromey.com>
839 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
840 (CONFIG_SRC_SUBDIR): Add python.
841 (%.o): Remove python rule.
842 (python/%.o): New rule.
843 * configure: Rebuild.
844 * configure.ac (CONFIG_OBS): Refer to python/python.o
846 2017-11-27 Tom Tromey <tom@tromey.com>
848 * configure: Rebuild.
849 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
850 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
851 (CONFIG_SRC_SUBDIR): Add guile.
852 (%.o): Remove guile rule.
854 2017-11-27 Tom Tromey <tom@tromey.com>
856 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
857 (%.o): Remove unittests rule.
858 (CONFIG_SRC_SUBDIR): Add unittests.
860 2017-11-27 Tom Tromey <tom@tromey.com>
862 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
863 (CONFIG_SRC_SUBDIR): Add tui.
864 (%.o): Remove tui rule.
866 2017-11-27 Tom Tromey <tom@tromey.com>
868 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
869 (%.o): Remove compile rule.
870 (CONFIG_SRC_SUBDIR): Add compile.
872 2017-11-27 Tom Tromey <tom@tromey.com>
874 * Makefile.in (SUBDIR_MI_OBS): Redefine.
875 (%.o): Remove mi rule.
876 (CONFIG_SRC_SUBDIR): Add mi.
877 (COMMON_OBS): Use mi/mi-common.o
879 2017-11-27 Tom Tromey <tom@tromey.com>
881 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
882 (%.o): Remove cli rule.
883 (CONFIG_SRC_SUBDIR): Add cli.
885 2017-11-27 Tom Tromey <tom@tromey.com>
887 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
888 * configure: Rebuild.
889 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
890 (CONFIG_DEP_SUBDIR): New variable.
891 (%.o): Add order-only dependency.
892 ($(CONFIG_DEP_SUBDIR)): New target.
894 2017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
897 * findcmd.c (_initialize_mem_search): Update find command help
900 2017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
902 * python/python.c (do_start_initialization): Change progname
903 type to gdb::unique_xmalloc_ptr. Release the pointer when using
906 2017-11-26 Tom Tromey <tom@tromey.com>
908 * common/format.h: Add include guards.
910 2017-11-26 Tom Tromey <tom@tromey.com>
912 * nat/linux-personality.h (class
913 maybe_disable_address_space_randomization): New class.
914 (maybe_disable_address_space_randomization): Don't declare
916 * nat/linux-personality.c (restore_personality)
917 (make_disable_asr_cleanup): Remove.
918 (maybe_disable_address_space_randomization): Now a constructor.
919 (~maybe_disable_address_space_randomization): New destructor.
920 * linux-nat.c (linux_nat_create_inferior): Update.
922 2017-11-26 Tom Tromey <tom@tromey.com>
924 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
926 2017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
928 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
929 "cooked" register. Access only first four bytes of branch target
932 2017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
935 * stap-probe.c (relocate_address): New function.
936 (stap_probe::get_relocated_address): Use 'relocate_address'.
937 (stap_probe::set_semaphore): Use 'relocate_address' and pass
939 (stap_probe::clear_semaphore): Likewise.
941 2017-11-25 Pedro Alves <palves@redhat.com>
943 * dictionary.c: Include "safe-ctype.h".
944 * minsyms.c: Include "safe-ctype.h".
945 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
947 2017-11-25 Pedro Alves <palves@redhat.com>
949 * completer.c (complete_line_internal_1): Skip spaces until the
950 start of the command.
952 2017-11-24 Pedro Alves <palves@redhat.com>
954 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
955 cp_fq_symbol_name_matches. Pass language_cplus to
957 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
958 (selftests::test_cp_symbol_name_cmp): New.
959 (_initialize_cp_support): Register "cp_symbol_name_matches"
961 * language.c (default_symbol_name_matcher): Pass language_minimal
962 to strncmp_iw_with_mode.
963 * utils.c: Include "cp-support.h" and <algorithm>.
964 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
965 (cp_is_operator): New functions.
966 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
967 skip whitespace in the symbol name when the lookup name doesn't
968 have spaces, and vice versa.
969 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
970 * utils.h (strncmp_iw_with_mode): Add language parameter.
972 2017-11-24 Joel Brobecker <brobecker@adacore.com>
974 * ada-lang.c (ada_exception_message_1, ada_exception_message):
976 (print_it_exception): If available, display the exception
978 * NEWS: Document new feature.
980 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
982 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
984 2017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
986 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
987 (dtrace_probe::is_enabled, dtrace_probe::enable)
988 (dtrace_probe::disable): Remove keyword 'struct' at for-range
990 * probe.c (gen_ui_out_table_header_info)
991 (print_ui_out_not_applicables): Remove keyword 'struct' at
994 2017-11-24 Alan Hayward <alan.hayward@arm.com>
996 * configure.tgt: Add arch/aarch64.o
998 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1000 * common/common-utils.h: Include poison.h.
1001 (xfree): Remove declaration, add definition with static_assert.
1002 * common/common-utils.c (xfree): Remove.
1003 * common/poison.h (IsMallocatable): Define.
1004 (IsFreeable): Define.
1005 (free): Delete for non-freeable types.
1007 (XNEW): Undef and redefine.
1009 (XCNEW): Undef and redefine.
1011 (XDELETE): Undef and redefine.
1013 (XNEWVEC): Undef and redefine.
1015 (XCNEWVEC): Undef and redefine.
1017 (XRESIZEVEC): Undef and redefine.
1019 (XDELETEVEC): Undef and redefine.
1021 (XNEWVAR): Undef and redefine.
1023 (XCNEWVAR): Undef and redefine.
1025 (XRESIZEVAR): Undef and redefine.
1027 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1029 * gdbthread.h (private_thread_info): Define structure type, add
1030 virtual pure destructor.
1031 (thread_info) <priv>: Change type to unique_ptr.
1032 <private_dtor>: Remove.
1033 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
1034 (private_thread_info::~private_thread_info): Provide default
1036 (thread_info::~thread_info): Don't call private_dtor nor
1038 * aix-thread.c (private_thread_info): Rename to ...
1039 (aix_thread_info): ... this.
1040 (get_aix_thread_info): New.
1041 (sync_threadlists): Adjust.
1043 (aix_thread_resume): Adjust.
1044 (aix_thread_fetch_registers): Adjust.
1045 (aix_thread_store_registers): Adjust.
1046 (aix_thread_extra_thread_info): Adjust.
1047 * darwin-nat.h (private_thread_info): Rename to ...
1048 (darwin_thread_info): ... this.
1049 (get_darwin_thread_info): New.
1050 * darwin-nat.c (darwin_init_thread_list): Adjust.
1051 (darwin_check_new_threads): Adjust.
1052 (thread_info_from_private_thread_info): Adjust.
1053 * linux-thread-db.c (private_thread_info): Rename to ...
1054 (thread_db_thread_info): ... this, initialize fields.
1055 (get_thread_db_thread_info): New.
1056 <dying>: Change type to bool.
1057 (update_thread_state): Adjust to type rename.
1058 (record_thread): Adjust to type rename an use of unique_ptr.
1059 (thread_db_pid_to_str): Likewise.
1060 (thread_db_extra_thread_info): Likewise.
1061 (thread_db_thread_handle_to_thread_info): Likewise.
1062 (thread_db_get_thread_local_address): Likewise.
1063 * nto-tdep.h (private_thread_info): Rename to ...
1064 (nto_thread_info): ... this, initialize fields.
1065 (get_nto_thread_info): New.
1066 <name>: Change type to std::string.
1067 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1069 * nto-procfs.c (update_thread_private_data_name): Adjust to
1070 std::string change, allocate nto_private_thread_info with new.
1071 (update_thread_private_data): Adjust to unique_ptr.
1072 * remote.c (private_thread_info): Rename to ...
1073 (remote_thread_info): ... this, initialize data members with
1075 <extra, name>: Change type to std::string.
1076 <thread_handle>: Change type to non-pointer.
1077 (free_private_thread_info): Remove.
1078 (get_private_info_thread): Rename to...
1079 (get_remote_thread_info): ... this, change return type, adjust to
1080 use of unique_ptr, use remote_thread_info constructor.
1081 (remote_add_thread): Adjust.
1082 (get_private_info_ptid): Rename to...
1083 (get_remote_thread_info): ...this, change return type.
1084 (remote_thread_name): Use get_remote_thread_info, adjust to
1085 change to std::string.
1086 (struct thread_item) <~thread_item>: Remove.
1087 <thread_handle>: Make non pointer.
1088 (start_thread): Adjust to thread_item::thread_handle type
1090 (remote_update_thread_list): Adjust to type name change, move
1091 strings from temporary to long-lived object instead of
1093 (remote_threads_extra_info): Use get_remote_thread_info.
1094 (process_initial_stop_replies): Likewise.
1095 (resume_clear_thread_private_info): Likewise.
1096 (remote_resume): Adjust to type name change.
1097 (remote_commit_resume): Use get_remote_thread_info.
1098 (process_stop_reply): Adjust to type name change.
1099 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1100 (remote_stopped_by_hw_breakpoint): Likewise.
1101 (remote_stopped_by_watchpoint): Likewise.
1102 (remote_stopped_data_address): Likewise.
1103 (remote_core_of_thread): Likewise.
1104 (remote_thread_handle_to_thread_info): Use
1105 get_private_info_thread, adjust to thread_handle field type
1108 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1110 * remote.c (struct thread_item): Add constructor, disable copy
1111 construction and copy assignment, define default move
1112 construction and move assignment.
1113 <extra, name>: Change type to std::string.
1115 <thread_handle>: Make non-pointer.
1116 (thread_item_t): Remove typedef.
1117 (DEF_VEC_O(thread_item_t)): Remove.
1118 (threads_listing_context) <contains_thread>: New method.
1119 <remove_thread>: New method.
1120 <items>: Change type to std::vector.
1121 (clear_threads_listing_context): Remove.
1122 (threads_listing_context_remove): Remove.
1123 (remote_newthread_step): Use thread_item constructor, adjust to
1124 change to std::vector.
1125 (start_thread): Use thread_item constructor, adjust to change to
1127 (end_thread): Adjust to change to std::vector and std::string.
1128 (remote_get_threads_with_qthreadinfo): Use thread_item
1129 constructor, adjust to std::vector.
1130 (remote_update_thread_list): Adjust to change to std::vector and
1131 std::string, use threads_listing_context methods.
1132 (remove_child_of_pending_fork): Adjust.
1133 (remove_new_fork_children): Adjust.
1134 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1135 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1136 * unittests/rsp-low-selftests.c: New file.
1137 * common/rsp-low.h: Include common/byte-vector.h.
1138 (hex2bin): New overload.
1139 * common/rsp-low.c (hex2bin): New overload.
1141 2017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1143 * inferior.h (private_inferior): Define structure type, add
1144 virtual pure destructor.
1145 (inferior) <priv>: Change type to unique_ptr.
1146 * inferior.c (private_inferior::~private_inferior): Provide
1147 default implementation.
1148 (inferior::~inferior): Don't free priv field.
1149 (exit_inferior_1): Likewise.
1150 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1151 (darwin_exception_info): Remove typedef.
1152 (DEF_VEC_O (darwin_thread_t)); Remove.
1153 (private_inferior): Rename to ...
1154 (darwin_private_inferior): ... this, extend private_inferior.
1155 (get_darwin_inferior): New.
1156 <threads>: Change type to std::vector of darwin_thread_t pointers.
1157 * darwin-nat.c (darwin_check_new_threads): Adjust.
1158 (find_inferior_task_it): Adjust.
1159 (darwin_find_thread); Adjust.
1160 (darwin_suspend_inferior): Adjust.
1161 (darwin_resume_inferior): Adjust.
1162 (darwin_find_new_inferior): Adjust.
1163 (darwin_decode_notify_message): Adjust.
1164 (darwin_send_reply): Adjust.
1165 (darwin_resume_inferior_threads): Adjust.
1166 (darwin_suspend_inferior_threads): Adjust.
1167 (darwin_decode_message): Adjust.
1168 (darwin_wait): Adjust.
1169 (darwin_interrupt): Adjust.
1170 (darwin_deallocate_threads): Adjust.
1171 (darwin_mourn_inferior): Adjust, don't free private data.
1172 (darwin_reply_to_all_pending_messages): Adjust.
1173 (darwin_stop_inferior): Adjust.
1174 (darwin_setup_exceptions): Adjust.
1175 (darwin_kill_inferior): Adjust.
1176 (darwin_setup_request_notification): Adjust.
1177 (darwin_attach_pid): Adjust.
1178 (darwin_init_thread_list): Adjust.
1179 (darwin_setup_fake_stop_event): Adjust.
1180 (darwin_attach): Adjust.
1181 (darwin_detach): Adjust.
1182 (darwin_xfer_partial): Adjust.
1183 (set_enable_mach_exceptions): Adjust.
1184 (darwin_pid_to_exec_file): Adjust.
1185 (darwin_get_ada_task_ptid): Adjust.
1186 * darwin-nat-info.c (get_task_from_args): Adjust.
1187 (info_mach_ports_command): Adjust.
1188 (info_mach_region_command): Adjust.
1189 (info_mach_exceptions_command): Adjust.
1190 * remote.c (private_inferior): Rename to ...
1191 (remote_private_inferior): ... this, initialize fields.
1192 (get_remote_inferior); New.
1193 (remote_commit_resume): Use get_remote_inferior.
1194 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1196 2017-11-24 Pedro Alves <palves@redhat.com>
1198 * NEWS: Mention linespecs and explicit locations, and completion
1201 2017-11-24 Yao Qi <yao.qi@linaro.org>
1203 * regcache.c (regcache::dump): Remove footnote_register_size.
1205 2017-11-24 Yao Qi <yao.qi@linaro.org>
1207 * regcache.c (cooked_read_test): Add more test for readonly
1210 2017-11-24 Yao Qi <yao.qi@linaro.org>
1212 * gdbarch-selftests.c (test_target_has_registers): Move it to
1214 (test_target_has_stack): Likewise.
1215 (test_target_has_memory): Likewise.
1216 (test_target_prepare_to_store): Likewise.
1217 (test_target_store_registers): Likewise.
1218 (test_target_ops): Likewise.
1219 * regcache.c: Include selftest-arch.h and gdbthread.h.
1220 (target_ops_no_register): New class.
1221 (test_target_fetch_registers): New.
1222 (test_target_store_registers): New.
1223 (test_target_xfer_partial): New.
1224 (readwrite_regcache): New.
1225 (cooked_read_test): New.
1226 (_initialize_regcache): Register the test.
1227 * target.c: (test_target_has_registers): Moved from
1228 gdbarch-selftests.c.
1229 (test_target_has_stack): Likewise.
1230 (test_target_has_memory): Likewise.
1231 (test_target_prepare_to_store): Likewise.
1232 (test_target_store_registers): Likewise.
1233 * target.h (test_target_ops): New class.
1235 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1237 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1240 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1242 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1243 * arch/aarch64.c (aarch64_create_target_description): Create
1244 new target description.
1245 * features/Makefile: Add new files.
1246 * features/aarch64.c: Remove file.
1247 * features/aarch64-core.c: New autogenerated file.
1248 * features/aarch64-fpu.c: New autogenerated file.
1249 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
1251 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1253 * Makefile.in: Add new files.
1254 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1255 aarch64_read_description.
1256 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1257 Call aarch64_read_description.
1258 * aarch64-tdep.c (aarch64_read_description): New function.
1259 (aarch64_gdbarch_init): Call aarch64_read_description.
1260 * aarch64-tdep.h (aarch64_read_description): New function.
1261 * arch/aarch64.c: New file.
1262 * configure.tgt: Add new files.
1264 2017-11-24 Yao Qi <yao.qi@linaro.org>
1266 * mi/mi-main.c (register_changed_p): Update.
1267 * value.c (value_contents_bits_eq): Change return type.
1268 (value_contents_eq): Likewise.
1269 * value.h: Update comments.
1271 2017-11-24 Yao Qi <yao.qi@linaro.org>
1273 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1274 local 'changed'. Remove error.
1275 (register_changed_p): Change return type to bool.
1277 2017-11-24 Yao Qi <yao.qi@linaro.org>
1279 * arch/tic6x.c: New file.
1280 * arch/tic6x.h: New file.
1281 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1282 tic6x-core.xml and tic6x-gp.xml.
1283 * features/tic6x-c6xp.c: Generated.
1284 * features/tic6x-core.c: Generated.
1285 * features/tic6x-gp.c: Generated.
1286 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1289 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1291 * mi/mi-main.c (list_available_thread_groups): Change map value
1292 type to std::vector.
1294 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1296 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1298 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1300 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1302 <children_requested>: ... this.
1303 (varobj_get_num_children, varobj_update): Adjust.
1305 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1307 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1308 (ada_value_has_mutated): Likewise.
1309 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1310 (c_is_path_expr_parent): Likewise.
1311 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1312 (mi_cmd_var_set_frozen): Likewise.
1313 (mi_cmd_var_update_iter): Likewise.
1314 (mi_cmd_var_update): Likewise.
1315 * varobj.c (pretty_printing): Likewise.
1316 (varobj_enable_pretty_printing): Likewise.
1317 (struct varobj_root) <floating, is_valid>: Likewise.
1318 (struct varobj_dynamic) <children_requested>: Likewise.
1319 (delete_variable): Likewise.
1320 (delete_variable_1): Likewise.
1321 (install_variable): Likewise.
1322 (update_type_if_necessary): Likewise.
1323 (install_new_value): Likewise.
1324 (value_of_root): Likewise.
1325 (is_root_p): Likewise.
1326 (varobj_create): Likewise.
1327 (varobj_delete): Likewise.
1328 (varobj_has_more): Likewise.
1329 (varobj_set_frozen): Likewise.
1330 (varobj_get_frozen): Likewise.
1331 (install_dynamic_child): Likewise.
1332 (dynamic_varobj_has_child_method): Likewise.
1333 (update_dynamic_varobj_children): Likewise.
1334 (varobj_get_num_children): Likewise.
1335 (varobj_list_children): Likewise.
1336 (is_path_expr_parent): Likewise.
1337 (varobj_default_is_path_expr_parent): Likewise.
1338 (varobj_is_dynamic_p): Likewise.
1339 (varobj_set_value): Likewise.
1340 (varobj_value_has_mutated): Likewise.
1341 (varobj_update): Likewise.
1342 (check_scope): Likewise.
1343 (value_of_root_1): Likewise.
1344 (varobj_value_get_print_value): Likewise.
1345 (varobj_editable_p): Likewise.
1346 (varobj_value_is_changeable_p): Likewise.
1347 (varobj_floating_p): Likewise.
1348 (varobj_default_value_is_changeable_p): Likewise.
1349 (varobj_invalidate_iter): Likewise.
1350 * varobj.h (struct varobj_update_result) <type_changed,
1351 children_changed, changed, value_installed>: Likewise.
1352 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1353 (struct lang_varobj_ops) <value_is_changeable_p,
1354 value_has_mutated, is_path_expr_parent>: Likewise.
1355 (varobj_delete): Likewise.
1356 (varobj_set_frozen): Likewise.
1357 (varobj_get_frozen): Likewise.
1358 (varobj_set_value): Likewise.
1359 (varobj_update): Likewise.
1360 (varobj_editable_p): Likewise.
1361 (varobj_floating_p): Likewise.
1362 (varobj_has_more): Likewise.
1363 (varobj_is_dynamic_p): Likewise.
1364 (varobj_default_value_is_changeable_p): Likewise.
1365 (varobj_value_is_changeable_p): Likewise.
1366 (varobj_is_anonymous_child): Likewise.
1367 (varobj_default_is_path_expr_parent): Likewise.
1369 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1371 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1372 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1373 <type_str>: Convert to 'std::string'.
1374 <expr>: Convert to 'expression_up'.
1375 (dtrace_probe_arg_s): Delete type and VEC.
1376 (dtrace_probe_enabler_s): Likewise.
1377 (struct dtrace_probe): Replace by...
1378 (class dtrace_static_probe_ops): ...this and...
1379 (class dtrace_probe): ...this.
1380 (dtrace_probe_is_linespec): Rename to...
1381 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1383 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1384 Adjust code. Create new instance of 'dtrace_probe'.
1385 (dtrace_build_arg_exprs): Rename to...
1386 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1388 (dtrace_get_probes): Rename to...
1389 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1391 (dtrace_get_arg): Rename to...
1392 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1394 (dtrace_probe_is_enabled): Rename to...
1395 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
1397 (dtrace_get_probe_address): Rename to...
1398 (dtrace_probe::get_relocated_address): ...this. Adjust code
1400 (dtrace_get_probe_argument_count): Rename to...
1401 (dtrace_probe::get_argument_count): ...this. Adjust code to
1403 (dtrace_can_evaluate_probe_arguments): Rename to...
1404 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
1406 (dtrace_evaluate_probe_argument): Rename to...
1407 (dtrace_probe::evaluate_argument): ...this. Adjust code to
1409 (dtrace_compile_to_ax): Rename to...
1410 (dtrace_probe::compile_to_ax): ...this. Adjust code to
1412 (dtrace_probe_destroy): Delete.
1413 (dtrace_type_name): Rename to...
1414 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
1416 (dtrace_probe::get_static_ops): New method.
1417 (dtrace_gen_info_probes_table_header): Rename to...
1418 (dtrace_static_probe_ops::gen_info_probes_table_header):
1419 ...this. Adjust code to reflect change.
1420 (dtrace_gen_info_probes_table_values): Rename to...
1421 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
1422 code to reflect change.
1423 (dtrace_enable_probe): Rename to...
1424 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
1426 (dtrace_disable_probe): Rename to...
1427 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
1429 (struct probe_ops dtrace_probe_ops): Delete.
1430 (info_probes_dtrace_command): Call 'info_probes_for_spops'
1431 instead of 'info_probes_for_ops'.
1432 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
1435 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1436 Simon Marchi <simark@simark.ca>
1438 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
1440 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
1441 <aexpr>: Change type to 'expression_up'.
1442 (stap_probe_arg_s): Delete type and VEC.
1443 (struct stap_probe): Delete. Replace by...
1444 (class stap_static_probe_ops): ...this and...
1445 (class stap_probe): ...this. Rename variables to add 'm_'
1446 prefix. Do not use 'union' for arguments anymore.
1447 (stap_get_expected_argument_type): Receive probe name instead
1448 of 'struct stap_probe'. Adjust code.
1449 (stap_parse_probe_arguments): Rename to...
1450 (stap_probe::parse_arguments): ...this. Adjust code to
1452 (stap_get_probe_address): Rename to...
1453 (stap_probe::get_relocated_address): ...this. Adjust code
1455 (stap_get_probe_argument_count): Rename to...
1456 (stap_probe::get_argument_count): ...this. Adjust code
1458 (stap_get_arg): Rename to...
1459 (stap_probe::get_arg_by_number'): ...this. Adjust code to
1461 (can_evaluate_probe_arguments): Rename to...
1462 (stap_probe::can_evaluate_arguments): ...this. Adjust code
1464 (stap_evaluate_probe_argument): Rename to...
1465 (stap_probe::evaluate_argument): ...this. Adjust code
1467 (stap_compile_to_ax): Rename to...
1468 (stap_probe::compile_to_ax): ...this. Adjust code to
1470 (stap_probe_destroy): Delete.
1471 (stap_modify_semaphore): Adjust comment.
1472 (stap_set_semaphore): Rename to...
1473 (stap_probe::set_semaphore): ...this. Adjust code to reflect
1475 (stap_clear_semaphore): Rename to...
1476 (stap_probe::clear_semaphore): ...this. Adjust code to
1478 (stap_probe::get_static_ops): New method.
1479 (handle_stap_probe): Adjust code to create instance of
1481 (stap_get_probes): Rename to...
1482 (stap_static_probe_ops::get_probes): ...this. Adjust code to
1484 (stap_probe_is_linespec): Rename to...
1485 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
1487 (stap_type_name): Rename to...
1488 (stap_static_probe_ops::type_name): ...this. Adjust code to
1490 (stap_gen_info_probes_table_header): Rename to...
1491 (stap_static_probe_ops::gen_info_probes_table_header):
1492 ...this. Adjust code to reflect change.
1493 (stap_gen_info_probes_table_values): Rename to...
1494 (stap_probe::gen_info_probes_table_values): ...this. Adjust
1495 code to reflect change.
1496 (struct probe_ops stap_probe_ops): Delete.
1497 (info_probes_stap_command): Use 'info_probes_for_spops'
1498 instead of 'info_probes_for_ops'.
1499 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
1502 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1504 * break-catch-throw.c (fetch_probe_arguments): Use
1505 'probe.prob' instead of 'probe.probe'.
1506 * breakpoint.c (create_longjmp_master_breakpoint): Call
1507 'can_evaluate_arguments' and 'get_relocated_address' methods
1509 (create_exception_master_breakpoint): Likewise.
1510 (add_location_to_breakpoint): Use 'sal->prob' instead of
1512 (bkpt_probe_insert_location): Call 'set_semaphore' method from
1514 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
1515 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
1517 (probe_key_free): Call 'delete' on probe.
1518 (check_exception_resume): Use 'probe.prob' instead of
1520 * location.c (string_to_event_location_basic): Call
1521 'probe_linespec_to_static_ops'.
1522 * probe.c (class any_static_probe_ops): New class.
1523 (any_static_probe_ops any_static_probe_ops): New variable.
1524 (parse_probes_in_pspace): Receive 'static_probe_ops' as
1525 argument. Adjust code to reflect change.
1526 (parse_probes): Use 'static_probe_ops' instead of
1527 'probe_ops'. Adjust code to reflect change.
1528 (find_probes_in_objfile): Call methods to get name and
1529 provider from probe.
1530 (find_probe_by_pc): Use 'result.prob' instead of
1531 'result.probe'. Call 'get_relocated_address' method from
1533 (collect_probes): Adjust comment and argument list to receive
1534 'static_probe_ops' instead of 'probe_ops'. Adjust code to
1535 reflect change. Call necessary methods from probe.
1536 (compare_probes): Call methods to get name and provider from
1538 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
1539 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
1540 adjust code accordingly.
1541 (print_ui_out_not_applicables): Likewise.
1542 (info_probes_for_ops): Rename to...
1543 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
1544 as argument instead of 'probe_ops'. Adjust code. Call
1545 necessary methods from probe.
1546 (info_probes_command): Use 'info_probes_for_spops'.
1547 (enable_probes_command): Pass correct argument to
1548 'collect_probes'. Call methods from probe.
1549 (disable_probes_command): Likewise.
1550 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
1551 (get_probe_argument_count): Move to
1552 'any_static_probe_ops::get_argument_count'.
1553 (can_evaluate_probe_arguments): Move to
1554 'any_static_probe_ops::can_evaluate_arguments'.
1555 (evaluate_probe_argument): Move to
1556 'any_static_probe_ops::evaluate_argument'.
1557 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
1559 (probe_linespec_to_ops): Rename to...
1560 (probe_linespec_to_static_ops): ...this. Adjust code.
1561 (probe_any_is_linespec): Rename to...
1562 (any_static_probe_ops::is_linespec): ...this.
1563 (probe_any_get_probes): Rename to...
1564 (any_static_probe_ops::get_probes): ...this.
1565 (any_static_probe_ops::type_name): New method.
1566 (any_static_probe_ops::gen_info_probes_table_header): New
1568 (compute_probe_arg): Use 'pc_probe.prob' instead of
1569 'pc_probe.probe'. Call methods from probe.
1570 (compile_probe_arg): Likewise.
1571 (std::vector<const probe_ops *> all_probe_ops): Delete.
1572 (std::vector<const static_probe_ops *> all_static_probe_ops):
1574 (_initialize_probe): Use 'all_static_probe_ops' instead of
1576 * probe.h (struct info_probe_column) <field_name>: Delete
1578 (info_probe_column_s): Delete type and VEC.
1579 (struct probe_ops): Delete. Replace with...
1580 (class static_probe_ops): ...this and...
1581 (clas probe): ...this.
1582 (struct bound_probe) <bound_probe>: Delete extraneous
1583 newline. Adjust constructor to receive 'probe' instead of
1585 <probe>: Rename to...
1586 <prob>: ...this. Delete extraneous newline.
1587 <objfile>: Delete extraneous newline.
1588 (register_probe_ops): Delete unused prototype.
1589 (info_probes_for_ops): Rename to...
1590 (info_probes_for_spops): ...this. Adjust comment.
1591 (get_probe_address): Move to 'probe::get_address'.
1592 (get_probe_argument_count): Move to
1593 'probe::get_argument_count'.
1594 (can_evaluate_probe_arguments): Move to
1595 'probe::can_evaluate_arguments'.
1596 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
1597 * solib-svr4.c (struct svr4_info): Adjust comment.
1598 (struct probe_and_action) <probe>: Rename to...
1600 (register_solib_event_probe): Receive 'probe' instead of
1601 'struct probe' as argument. Use 'prob' instead of 'probe'
1603 (solib_event_probe_action): Call 'get_argument_count' method
1604 from probe. Adjust comment.
1605 (svr4_handle_solib_event): Adjust comment. Call
1606 'evaluate_argument' method from probe.
1607 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
1609 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
1610 'struct probe'. Call 'can_evaluate_arguments' from probe.
1611 * symfile.h: Forward declare 'class probe' instead of 'struct
1613 * symtab.h: Likewise.
1614 (struct symtab_and_line) <probe>: Rename to...
1616 * tracepoint.c (start_tracing): Use 'prob' when applicable.
1618 (stop_tracing): Likewise.
1620 2017-11-22 Joel Brobecker <brobecker@adacore.com>
1622 * ravenscar-thread.c (ravenscar_inferior_created): Remove
1623 trailing newline at end of string in call to warning.
1625 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1627 * osdata.h: Include vector isntead of vec.h.
1628 (osdata_column_s): Remove typedef.
1629 (struct osdata_column): Add constructor.
1630 <name, value>: Change type to std::string.
1631 (DEF_VEC_O (osdata_column_s)): Remove.
1632 (osdata_item_s): Remove typedef.
1633 (struct osdata_item) <columns>: Change type to std::vector.
1634 (DEF_VEC_O (osdata_item_s)): Remove.
1635 (struct osdata): Add constructor.
1636 <type>: Change type to std::string.
1637 <items>: Change type to std::vector.
1638 (osdata_p): Remove typedef.
1639 (DEF_VEC_P (osdata_p)): Remove.
1640 (osdata_parse): Return a unique_ptr.
1641 (osdata_free): Remove.
1642 (make_cleanup_osdata_free): Remove.
1643 (get_osdata): Return a unique_ptr.
1644 (get_osdata_column): Return pointer to std::string, take a
1645 reference to osdata_item as parameter.
1646 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
1648 <property_name>: Change type to std::string.
1649 (osdata_start_osdata): Allocate osdata with new and adjust.
1650 (osdata_start_item): Adjust.
1651 (osdata_start_column): Adjust.
1652 (osdata_end_column): Adjust.
1653 (clear_parsing_data): Remove.
1654 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
1655 (osdata_item_clear): Remove.
1656 (get_osdata): return a unique_ptr and adjust.
1657 (get_osdata_column): Return a pointer to std::string and adjust.
1658 (info_osdata): Adjust.
1659 * mi/mi-main.c: Include <map>.
1660 (free_vector_of_osdata_items): Remove.
1661 (list_available_thread_groups): Adjust, use std::map instead of
1664 2017-11-22 Simon Marchi <simon.marchi@ericsson.com>
1666 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
1669 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1671 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
1673 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1675 * varobj.h (struct varobj_update_result): Add constructor, add
1676 move constructor, disable copy and assign, initialize fields.
1677 <newobj>: Change type to std::vector.
1678 (varobj_update): Return std::vector.
1679 * varobj.c (install_dynamic_child): Change VEC parameters to
1680 std::vector and adjust.
1681 (update_dynamic_varobj_children): Likewise.
1682 (varobj_update): Return std::vector and adjust.
1683 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
1685 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1687 * varobj.h (struct varobj) <parent>: Remove const.
1688 <children>: Change type to std::vector.
1689 (varobj_list_children): Return std::vector const reference.
1690 (varobj_restrict_range): Change parameter type to std::vector
1692 * varobj.c (varobj_has_more): Adjust.
1693 (varobj_restrict_range): Change parameter type to std::vector
1694 const reference and adjust.
1695 (install_dynamic_child): Adjust.
1696 (update_dynamic_varobj_children): Adjust.
1697 (varobj_list_children): Return std::vector const reference and
1699 (varobj_add_child): Adjust.
1700 (update_type_if_necessary): Adjust.
1701 (varobj_update): Adjust.
1702 (delete_variable_1): Adjust.
1703 * ada-varobj.c (ada_value_has_mutated): Adjust.
1704 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
1706 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1708 * varobj.h (struct varobj): Add constructor and destructor,
1710 * varobj.c (struct varobj_root): Initialize fields.
1711 (struct varobj_dynamic): Initialize fields.
1712 (varobj_create): Use unique_ptr instead of cleanup. Create
1713 varobj with new instead of new_root_variable.
1714 (delete_variable_1): Free variable with delete instead of
1716 (create_child_with_value): Create variable with new instead of
1718 (varobj::varobj): New.
1719 (varobj::~varobj): New (body mostly coming from free_variable).
1720 (new_variable): Remove.
1721 (free_variable): Remove.
1722 (do_free_variable_cleanup): Remove.
1723 (make_cleanup_free_variable): Remove.
1725 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1727 * core-regset.c: Remove file.
1728 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
1730 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1732 * NEWS: Document use of GNU MPFR.
1735 * Makefile.in (LIBMPFR): Add define.
1736 (CLIBS): Add $(LIBMPFR).
1737 * configure.ac: Add --with-mpfr configure option.
1738 * configure: Regenerate.
1739 * config.in: Regenerate.
1741 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
1742 (class mpfr_float_ops): New type.
1743 (mpfr_float_ops::from_target): Two new overloaded functions.
1744 (mpfr_float_ops::to_target): Likewise.
1745 (mpfr_float_ops::to_string): New function.
1746 (mpfr_float_ops::from_string): Likewise.
1747 (mpfr_float_ops::to_longest): Likewise.
1748 (mpfr_float_ops::from_longest): Likewise.
1749 (mpfr_float_ops::from_ulongest): Likewise.
1750 (mpfr_float_ops::to_host_double): Likewise.
1751 (mpfr_float_ops::from_host_double): Likewise.
1752 (mpfr_float_ops::convert): Likewise.
1753 (mpfr_float_ops::binop): Likewise.
1754 (mpfr_float_ops::compare): Likewise.
1755 (get_target_float_ops): Use mpfr_float_ops if available.
1757 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1759 * target-float.c: Do not include <math.h>.
1760 Include <cmath> and <limits>.
1761 (DOUBLEST): Do not define.
1762 (class target_float_ops): New type.
1763 (class host_float_ops): New templated type.
1764 (class decimal_float_ops): New type.
1766 (floatformat_to_doublest): Rename to ...
1767 (host_float_ops<T>::from_target): ... this. Use template type T
1768 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1769 (host_float_ops<T>::from_target): New overload using a type argument.
1770 (floatformat_from_doublest): Rename to ...
1771 (host_float_ops<T>::to_target): ... this. Use template type T
1772 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1773 (host_float_ops<T>::to_target): New overload using a type argument.
1774 (floatformat_printf_format): New function.
1775 (struct printf_length_modifier): New templated type.
1776 (floatformat_to_string): Rename to ...
1777 (host_float_ops<T>::to_string): ... this. Use type instead of
1778 floatformat argument. Use floatformat_printf_format and
1779 printf_length_modifier. Remove special handling of invalid numbers,
1780 infinities and NaN (moved to target_float_to_string).
1781 (struct scanf_length_modifier): New templated type.
1782 (floatformat_from_string): Rename to ...
1783 (host_float_ops<T>::from_string): ... this. Use type instead of
1784 floatformat argument. Use scanf_length_modifier.
1785 (floatformat_to_longest): Rename to ...
1786 (host_float_ops<T>::to_longest): ... this. Use type instead of
1787 floatformat argument. Handle out-of-range values deterministically.
1788 (floatformat_from_longest): Rename to ...
1789 (host_float_ops<T>::from_longest): ... this. Use type instead of
1790 floatformat argument.
1791 (floatformat_from_ulongest): Rename to ...
1792 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
1793 floatformat argument.
1794 (floatformat_to_host_double): Rename to ...
1795 (host_float_ops<T>::to_host_double): ... this. Use type instead of
1796 floatformat argument.
1797 (floatformat_from_host_double): Rename to ...
1798 (host_float_ops<T>::from_host_double): ... this. Use type instead of
1799 floatformat argument.
1800 (floatformat_convert): Rename to ...
1801 (host_float_ops<T>::convert): ... this. Use type instead of
1802 floatformat arguments. Remove handling of no-op conversions.
1803 (floatformat_binop): Rename to ...
1804 (host_float_ops<T>::binop): ... this. Use type instead of
1805 floatformat arguments.
1806 (floatformat_compare): Rename to ...
1807 (host_float_ops<T>::compare): ... this. Use type instead of
1808 floatformat arguments.
1810 (match_endianness): Use type instead of length/byte_order arguments.
1811 (set_decnumber_context): Likewise.
1812 (decimal_from_number): Likewise. Update calls.
1813 (decimal_to_number): Likewise.
1814 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
1815 (decimal_float_ops::to_host_double): New dummy function.
1816 (decimal_float_ops::from_host_double): Likewise.
1817 (decimal_to_string): Rename to ...
1818 (decimal_float_ops::to_string): ... this. Use type instead of
1819 length/byte_order arguments. Update calls.
1820 (decimal_from_string): Rename to ...
1821 (decimal_float_ops::from_string): ... this. Use type instead of
1822 length/byte_order arguments. Update calls.
1823 (decimal_from_longest): Rename to ...
1824 (decimal_float_ops::from_longest): ... this. Use type instead of
1825 length/byte_order arguments. Update calls.
1826 (decimal_from_ulongest): Rename to ...
1827 (decimal_float_ops::from_ulongest): ... this. Use type instead of
1828 length/byte_order arguments. Update calls.
1829 (decimal_to_longest): Rename to ...
1830 (decimal_float_ops::to_longest): ... this. Use type instead of
1831 length/byte_order arguments. Update calls.
1832 (decimal_binop): Rename to ...
1833 (decimal_float_ops::binop): ... this. Use type instead of
1834 length/byte_order arguments. Update calls.
1835 (decimal_compare): Rename to ...
1836 (decimal_float_ops::compare): ... this. Use type instead of
1837 length/byte_order arguments. Update calls.
1838 (decimal_convert): Rename to ...
1839 (decimal_float_ops::convert): ... this. Use type instead of
1840 length/byte_order arguments. Update calls.
1842 (target_float_same_category_p): New function.
1843 (target_float_same_format_p): Likewise.
1844 (target_float_format_length): Likewise.
1845 (enum target_float_ops_kind): New type.
1846 (get_target_float_ops_kind): New function.
1847 (get_target_float_ops): Three new overloaded functions.
1849 (target_float_is_zero): Update call.
1850 (target_float_to_string): Add special handling of invalid numbers,
1851 infinities and NaN (moved from floatformat_to_string). Use
1852 target_float_ops callback.
1853 (target_float_from_string): Use target_float_ops callback.
1854 (target_float_to_longest): Likewise.
1855 (target_float_from_longest): Likewise.
1856 (target_float_from_ulongest): Likewise.
1857 (target_float_to_host_double): Likewise.
1858 (target_float_from_host_double): Likewise.
1859 (target_float_convert): Add special case for no-op conversions.
1860 Use target_float_ops callback.
1861 (target_float_binop): Use target_float_ops callback.
1862 (target_float_compare): Likewise.
1864 2017-11-22 Yao Qi <yao.qi@linaro.org>
1866 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
1868 2017-11-22 Yao Qi <yao.qi@linaro.org>
1870 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
1871 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
1873 2017-11-21 Jerome Guitton <guitton@adacore.com>
1875 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
1876 with event ptid from the lower layer before doing the
1877 ravenscar-specific update.
1879 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1881 * ravenscar-thread.c (is_ravenscar_task): Also verify that
1882 the ptid's TID is nonzero.
1884 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1886 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
1887 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
1888 Make non-static. Change return type to char *. Adjust code
1889 accordingly. Rewrite the function's documentation.
1890 (read_atcb): Adjust call to get_tcb_types_info accordingly.
1891 * ravenscar-thread.c (ravenscar_inferior_created): Check that
1892 we have enough debugging information in the runtime to support
1893 Ada task debugging before we enable the ravenscar-thread layer.
1895 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1897 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
1898 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
1899 * ravenscar-thread.c: Add into comment.
1900 (base_magic_null_ptid): Delete.
1901 (base_ptid): Change documentation.
1902 (ravenscar_active_task): Renames ravenscar_running_thread.
1903 All callers updated throughout.
1904 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
1905 (ravenscar_task_is_currently_active): Likewise.
1906 (get_base_thread_from_ravenscar_task): Ditto.
1907 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
1908 (ravenscar_runtime_initialized): Likewise.
1909 (get_running_thread_id): Add new parameter "cpu". Adjust
1910 implementation to handle this new parameter.
1911 (ravenscar_fetch_registers): Small adjustment to use
1912 is_ravenscar_task and ravenscar_task_is_currently_active in
1913 order to decide whether to use the target beneath or this
1915 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
1916 (ravenscar_stopped_by_sw_breakpoint): Use
1917 get_base_thread_from_ravenscar_task to get the underlying
1918 thread, rather than using base_ptid.
1919 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1920 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1922 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
1924 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1926 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
1927 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
1928 (get_tcb_types_info): Set fieldnos.base_cpu.
1929 (read_atcb): Set task_info->base_cpu.
1930 (info_task): Print "Base CPU" info if set by runtime.
1932 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1934 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
1935 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1936 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1938 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
1939 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
1940 to_stopped_data_address and to_core_of_thread fields of
1943 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
1945 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
1946 (struct gdbarch_tdep): New member long_double_abi.
1947 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
1948 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
1949 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
1950 format depending on long_double_abi tdep member.
1951 (ppc_floatformat_for_type): Handle __ibm128 type.
1953 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
1955 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
1957 2017-11-21 Pedro Alves <palves@redhat.com>
1959 * dwarf2read.c (mapped_index::find_name_components_bounds)
1960 <completion mode, upper bound>: Use std::lower_bound instead of
1962 (test_mapped_index_find_name_component_bounds): Remove incorrect
1963 "t1_fund" from expected symbols.
1965 2017-11-21 Pedro Alves <palves@redhat.com>
1967 * dwarf2read.c (mapped_index::name_components_casing): New field.
1968 (mapped_index) <build_name_components,
1969 find_name_components_bounds): Declare new methods.
1970 (mapped_index::find_name_components_bounds)
1971 (mapped_index::build_name_components): New methods, factored out
1972 from dw2_expand_symtabs_matching_symbol.
1973 (check_find_bounds_finds)
1974 (test_mapped_index_find_name_component_bounds): New.
1975 (run_test): Rename to ...
1976 (test_dw2_expand_symtabs_matching_symbol): ... this.
1977 (run_test): Reimplement.
1979 2017-11-21 Pedro Alves <palves@redhat.com>
1981 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
1982 (symbol_end): Use cp_ident_is_alnum.
1983 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
1984 * dwarf2read.c (make_sort_after_prefix_name): New function.
1985 (dw2_expand_symtabs_matching_symbol): Use it.
1986 (test_symbols): Add more symbols.
1987 (run_test): Add tests.
1989 2017-11-17 Tom Tromey <tom@tromey.com>
1991 * symtab.h (enum symbol_subclass_kind): New.
1992 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
1994 <subclass>: New member.
1995 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
1996 * rust-lang.c (rust_get_trait_object_pointer): Update.
1997 * dwarf2read.c (read_func_scope): Update.
1998 (read_variable): Update.
2000 2017-11-17 Tom Tromey <tom@tromey.com>
2002 * dwarf2read.c (read_func_scope): Update.
2003 * symtab.h (struct template_symbol): Derive from symbol.
2006 2017-11-17 Tom Tromey <tom@tromey.com>
2008 * symtab.h (struct symbol) <is_rust_vtable>: New member.
2009 (struct rust_vtable_symbol): New.
2010 (find_symbol_at_address): Declare.
2011 * symtab.c (find_symbol_at_address): New function.
2012 * symfile.h (struct quick_symbol_functions)
2013 <find_compunit_symtab_by_address>: New member.
2014 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
2016 (debug_sym_quick_functions): Link to
2017 debug_qf_find_compunit_symtab_by_address.
2018 * rust-lang.c (rust_get_trait_object_pointer): New function.
2019 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
2020 rust_get_trait_object_pointer.
2021 * psymtab.c (psym_relocate): Clear psymbol_map.
2022 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
2024 (psym_functions): Link to psym_find_compunit_symtab_by_address.
2025 * objfiles.h (struct objfile) <psymbol_map>: New member.
2026 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
2027 (process_die) <DW_TAG_variable>: New case. Call read_variable.
2028 (rust_containing_type, read_variable): New functions.
2030 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2032 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
2034 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2036 * common/filestuff.c: Include <algorithm>.
2037 (open_fds): Change type to std::vector<int>.
2038 (do_mark_open_fd): Adjust.
2039 (unmark_fd_no_cloexec): Adjust.
2042 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2044 * breakpoint.c (output_thread_groups): Take an std::vector.
2045 (print_one_breakpoint_location): Adjust.
2047 2017-11-17 Joel Brobecker <brobecker@adacore.com>
2049 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2050 (ada_evaluate_subexp_for_cast): New function.
2051 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2052 ada_evaluate_subexp_for_cast.
2053 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2055 * eval.c (evaluate_var_value): Make non-static.
2056 (evaluate_var_msym_value, eval_skip_value): Likewise.
2057 * value.h (evaluate_var_value, evaluate_var_msym_value)
2058 (eval_skip_value): Declare.
2060 2017-11-16 Joel Brobecker <brobecker@adacore.com>
2062 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2065 2017-11-16 Pedro Alves <palves@redhat.com>
2067 * python/py-unwind.c (pyuw_sniffer): Translate
2068 PyExc_KeyboardInterrupt to a GDB Quit exception.
2070 2017-11-16 Pedro Alves <palves@redhat.com>
2072 * infrun.c (resume_cleanups): Delete.
2073 (resume): No longer install a resume_cleanups cleanup nor call
2075 (proceed): Pass the terminal to the inferior.
2076 (keep_going_pass_signal): No longer install a resume_cleanups
2079 2017-11-16 Pedro Alves <palves@redhat.com>
2081 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2082 if the prompt is blocked.
2084 2017-11-16 Pedro Alves <palves@redhat.com>
2086 * breakpoint.c (insert_bp_location): Replace bp_err and
2087 bp_err_message locals by a gdb_exception local.
2089 2017-11-16 Pedro Alves <palves@redhat.com>
2091 * inflow.c (scoped_ignore_sigttou): New class.
2092 (child_terminal_ours_1, new_tty): Use it.
2094 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2096 * target-float.c (decimal_from_number): Add byte_order argument and
2097 call match_endianness. Error if unknown floating-point type.
2098 (decimal_to_number): Add byte_order argument and call match_endianness.
2099 (decimal_from_longest): Update call. Do not call match_endianness.
2100 (decimal_from_ulongest): Likewise.
2101 (decimal_binop): Likewise.
2102 (decimal_is_zero): Likewise.
2103 (decimal_compare): Likewise.
2104 (decimal_convert): Likewise.
2106 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2108 * python/python.c (gdbpy_rbreak): New function.
2109 * NEWS: Document Python rbreak feature.
2111 2017-11-16 Yao Qi <yao.qi@linaro.org>
2113 * features/tic6x-c62x.xml: Remove.
2114 * features/tic6x-c64x.xml: Remove.
2115 * features/tic6x-c64xp.xml: Remove.
2117 2017-11-15 John Baldwin <jhb@FreeBSD.org>
2119 * symtab.h: Include <array>.
2121 2017-11-15 John Baldwin <jhb@FreeBSD.org>
2123 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2124 (bsd_kvm_proc_cmd): Likewise.
2126 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2128 * tui/tui-win.c (window_name_completer): Replace VEC with
2131 2017-11-15 Andrew Cagney <cagney@gnu.org>
2133 * MAINTAINERS: Remove no-longer applicable entries.
2135 2017-11-15 Andrew Cagney <cagney@gnu.org>
2137 * MAINTAINERS: Move self to Past Maintainers.
2139 2017-11-15 Yao Qi <yao.qi@linaro.org>
2141 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2142 * features/nios2-linux.c: Remove.
2143 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2144 initialize_tdesc_nios2_linux.
2146 2017-11-15 Yao Qi <yao.qi@linaro.org>
2148 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2149 M68HC11_LAST_HARD_REG + 1.
2151 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2154 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2155 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2156 Return TARGET_XFER_EOF if size of returned data is 0.
2158 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2160 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2161 memory-map-selftests.c.
2162 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2163 * memory-map.c (memory_map_start_memory): Fix computation of hi
2165 * unittests/memory-map-selftests.c: New file.
2167 2017-11-09 Joel Brobecker <brobecker@adacore.com>
2169 * ada-lang.c: Fix some typos in the general command documenting
2170 how Ada expressions are being evaluated and how their result
2173 2017-11-09 Tom Tromey <tom@tromey.com>
2175 * psymtab.c (psymbol_hash): Do not hash string contents.
2176 (psymbol_compare): Add comment.
2178 2017-11-09 Tom Tromey <tom@tromey.com>
2180 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2182 2017-11-08 Joel Brobecker <brobecker@adacore.com>
2184 * ada-exp.y (write_var_from_sym): Remove parameter
2185 "orig_left_context". Update all callers.
2187 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2189 * tracepoint.h (class collection_list) <stringify>: Return
2190 std::vector<std::string>.
2191 (encode_actions_rsp): Change parameters to
2192 std::vector<std::string> *.
2193 * tracepoint.c (collection_list::stringify): Return
2194 std::vector<std::string> and adjust accordingly.
2195 (encode_actions_rsp): Changee parameters to
2196 std::vector<std::string> and adjust accordingly.
2197 * remote.c (free_actions_list),
2198 free_actions_list_cleanup_wrapper): Remove.
2199 (remote_download_tracepoint): Adjust to std::vector.
2201 2017-11-08 Tom Tromey <tom@tromey.com>
2203 * dwarf2read.c (symbolp): Remove typedef.
2204 (read_func_scope): Use std::vector.
2205 (process_structure_scope): Use std::vector.
2207 2017-11-08 Pedro Alves <palves@redhat.com>
2209 * ada-lang.c (ada_make_symbol_completion_list): Use
2210 completion_skip_symbol.
2211 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2212 (symbol_is_function_or_method(symbol*)): New.
2213 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2214 completion_skip_symbol.
2215 (default_collect_symbol_completion_matches_break_on): Use
2216 completion_skip_symbol. Pass down mode.
2217 (collect_file_symbol_completion_matches): Pass down mode.
2218 * symtab.h (symbol_is_function_or_method): New declarations.
2219 (completion_skip_symbol): New template function.
2221 2017-11-08 Pedro Alves <palves@redhat.com>
2223 * linespec.c (iterate_over_all_matching_symtabs): Add
2224 search_domain parameter. Pass it down to expand_symtabs_matching.
2225 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2226 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2228 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2230 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2232 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2235 2017-11-08 Pedro Alves <palves@redhat.com>
2237 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2238 text_len locals and don't pass them down.
2239 * symtab.c (completion_list_add_name): Remove
2240 sym_text/sym_text_len parameters and adjust.
2241 (completion_list_add_symbol, completion_list_add_msymbol)
2242 (completion_list_objc_symbol, completion_list_add_fields)
2243 (add_symtab_completions): Likewise.
2244 (default_collect_symbol_completion_matches_break_on)
2245 (collect_file_symbol_completion_matches): Remove sym_text_len
2246 local and don't pass it down.
2247 * symtab.h (completion_list_add_name): Remove
2248 sym_text/sym_text_len parameters.
2250 2017-11-08 Pedro Alves <palves@redhat.com>
2252 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2253 unittests/lookup_name_info-selftests.c.
2254 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2255 * cp-support.c: Include "selftest.h".
2256 (cp_remove_params_1): Rename from cp_remove_params. Add
2257 'require_param' parameter, and handle it.
2258 (cp_remove_params): Reimplement.
2259 (cp_remove_params_if_any): New.
2260 (selftests::quote): New.
2261 (selftests::check_remove_params): New.
2262 (selftests::test_cp_remove_params): New.
2263 (_initialize_cp_support): Install
2264 selftests::test_cp_remove_params.
2265 * cp-support.h (cp_remove_params_if_any): Declare.
2266 * dwarf2read.c :Include "selftest.h".
2267 (dw2_expand_symtabs_matching_symbol): Use
2268 lookup_name_info::make_ignore_params.
2269 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2270 (selftests::dw2_expand_symtabs_matching::string_or_null)
2271 (selftests::dw2_expand_symtabs_matching::check_match)
2272 (selftests::dw2_expand_symtabs_matching::test_symbols)
2273 (selftests::dw2_expand_symtabs_matching::run_test): New.
2274 (_initialize_dwarf2_read): Register
2275 selftests::dw2_expand_symtabs_matching::run_test.
2276 * psymtab.c (psym_expand_symtabs_matching): Use
2277 lookup_name_info::make_ignore_params.
2278 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2279 If the lookup name wants to ignore parameters, strip them.
2280 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2282 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2283 (default_collect_symbol_completion_matches_break_on): Don't try to
2285 * symtab.h (lookup_name_info::lookup_name_info): Add
2286 'ignore_parameters' parameter.
2287 (lookup_name_info::ignore_parameters)
2288 (lookup_name_info::make_ignore_params): New methods.
2289 (lookup_name_info::m_ignore_parameters): New field.
2290 * unittests/lookup_name_info-selftests.c: New file.
2292 2017-11-08 Pedro Alves <palves@redhat.com>
2294 * dwarf2read.c (dw2_expand_marked_cus)
2295 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2296 (dw2_expand_symtabs_matching): Move further below.
2297 (dw2_expand_marked_cus): Reindent.
2299 2017-11-08 Pedro Alves <palves@redhat.com>
2301 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2302 (struct name_component): New.
2303 (mapped_index::name_components): New field.
2304 (mapped_index::symbol_name_at): New method.
2305 (dwarf2_read_index): Call mapped_index ctor.
2306 (dw2_map_matching_symbols): Add comment about name_components
2308 (dw2_expand_symtabs_matching): Factor part to...
2309 (dw2_expand_symtabs_matching_symbol): ... this new function.
2310 Build name components table, and lookup symbols in it before
2311 calling the name matcher.
2312 (dw2_expand_marked_cus): New, factored out from
2313 dw2_expand_symtabs_matching.
2314 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2316 2017-11-08 Pedro Alves <palves@redhat.com>
2318 * ada-lang.c (ada_encode): Rename to ..
2319 (ada_encode_1): ... this. Add throw_errors parameter and handle
2321 (ada_encode): Reimplement.
2322 (match_name): Delete, folded into full_name.
2323 (resolve_subexp): No longer pass the encoded name to
2324 ada_lookup_symbol_list.
2325 (should_use_wild_match): Delete.
2326 (name_match_type_from_name): New.
2327 (ada_lookup_simple_minsym): Use lookup_name_info and the
2328 language's symbol_name_matcher_ftype.
2329 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2330 (ada_add_block_renamings): Adjust to use lookup_name_info.
2331 (ada_lookup_name): New.
2332 (add_nonlocal_symbols, ada_add_all_symbols)
2333 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2334 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2335 (ada_name_for_lookup): Delete.
2336 (ada_lookup_encoded_symbol): Construct a verbatim name.
2337 (wild_match): Reverse sense of return type. Use bool.
2338 (full_match): Reverse sense of return type. Inline bits of old
2340 (ada_add_block_symbols): Adjust to use lookup_name_info.
2341 (symbol_completion_match): Delete, folded into...
2342 (ada_lookup_name_info::matches): ... .this new method.
2343 (symbol_completion_add): Delete.
2344 (ada_collect_symbol_completion_matches): Add name_match_type
2345 parameter. Adjust to use lookup_name_info and
2346 completion_list_add_name.
2347 (get_var_value, ada_add_global_exceptions): Adjust to use
2349 (ada_get_symbol_name_cmp): Delete.
2350 (do_wild_match, do_full_match): New functions.
2351 (ada_lookup_name_info::ada_lookup_name_info): New method.
2352 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2354 (ada_language_defn): Install ada_get_symbol_name_matcher.
2355 * ada-lex.l (processId): If name starts with '<', copy it
2357 * block.c (block_iter_match_step, block_iter_match_first)
2358 (block_iter_match_next, block_lookup_symbol)
2359 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2361 * block.h (block_iter_match_first, block_iter_match_next)
2362 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2363 * c-lang.c (c_language_defn, cplus_language_defn)
2364 (asm_language_defn, minimal_language_defn): Adjust comments to
2365 refer to la_get_symbol_name_matcher.
2366 * completer.c (complete_files_symbols)
2367 (collect_explicit_location_matches, symbol_completer): Pass a
2368 symbol_name_match_type down.
2369 * completer.h (class completion_match, completion_match_result):
2371 (completion_tracker::reset_completion_match_result): New method.
2372 (completion_tracker::m_completion_match_result): New field.
2373 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2375 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2377 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2378 * d-lang.c: Adjust comments to refer to
2379 la_get_symbol_name_matcher.
2380 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2381 Adjust to use lookup_name_info.
2382 (dict_iter_match_first, dict_iter_match_next)
2383 (iter_match_first_hashed, iter_match_next_hashed)
2384 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2385 with a lookup_name_info.
2386 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2388 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2389 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2390 (gdb_index_symbol_name_matcher): New class.
2391 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2392 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2393 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2394 with a symbol_name_match_type.
2395 (f_language_defn): Adjust comments to refer to
2396 la_get_symbol_name_matcher.
2397 * go-lang.c (go_language_defn): Adjust comments to refer to
2398 la_get_symbol_name_matcher.
2399 * language.c (default_symbol_name_matcher)
2400 (language_get_symbol_name_matcher): New functions.
2401 (unknown_language_defn, auto_language_defn): Adjust comments to
2402 refer to la_get_symbol_name_matcher.
2403 * language.h (symbol_name_cmp_ftype): Delete.
2404 (language_defn) <la_collect_symbol_completion_matches>: Add match
2406 <la_get_symbol_name_cmp>: Delete field.
2407 <la_get_symbol_name_matcher>: New field.
2408 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
2409 (default_symbol_name_matcher, language_get_symbol_name_matcher):
2411 * linespec.c (iterate_over_all_matching_symtabs)
2412 (iterate_over_file_blocks): Adjust to use lookup_name_info.
2413 (find_methods): Add language parameter, and use lookup_name_info
2414 and the language's symbol_name_matcher_ftype.
2415 (linespec_complete_function): Adjust.
2416 (lookup_prefix_sym): Use lookup_name_info.
2417 (add_all_symbol_names_from_pspace): Adjust.
2418 (find_superclass_methods): Add language parameter and pass it
2420 (find_method): Pass symbol language down.
2421 (find_linespec_symbols): Don't demangle or Ada encode here.
2422 (search_minsyms_for_name): Add lookup_name_info parameter.
2423 (add_matching_symbols_to_info): Add name_match_type parameter.
2424 Use lookup_name_info.
2425 * m2-lang.c (m2_language_defn): Adjust comments to refer to
2426 la_get_symbol_name_matcher.
2427 * minsyms.c: Include <algorithm>.
2428 (add_minsym_to_demangled_hash_table): Remove table parameter and
2429 add objfile parameter. Use search_name_hash, and add language to
2430 demangled languages vector.
2431 (struct found_minimal_symbols): New struct.
2432 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
2434 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
2435 input names here. Use lookup_name_info instead. Lookup up
2436 demangled names once for each language in the demangled names
2438 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
2439 demangled names once for each language in the demangled names
2441 (build_minimal_symbol_hash_tables): Adjust.
2442 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
2444 * objc-lang.c (objc_language_defn): Adjust comment to refer to
2445 la_get_symbol_name_matcher.
2446 * objfiles.h: Include <vector>.
2447 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
2448 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
2449 la_get_symbol_name_matcher.
2450 * p-lang.c (pascal_language_defn): Adjust comment to refer to
2451 la_get_symbol_name_matcher.
2452 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
2453 (match_partial_symbol): Use symbol_name_match_type,
2454 lookup_name_info and psymbol_name_matches.
2455 (lookup_partial_symbol): Use lookup_name_info.
2456 (map_block): Use symbol_name_match_type and lookup_name_info.
2457 (psym_map_matching_symbols): Use symbol_name_match_type.
2458 (psymbol_name_matches): New.
2459 (recursively_search_psymtabs): Use lookup_name_info and
2460 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
2461 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
2462 'kind' parameter to 'domain'.
2463 * rust-lang.c (rust_language_defn): Adjust comment to refer to
2464 la_get_symbol_name_matcher.
2465 * symfile-debug.c (debug_qf_map_matching_symbols)
2466 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
2467 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
2468 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
2469 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
2470 Adjust to use symbol_name_match_type.
2471 <expand_symtabs_matching>: Adjust to use lookup_name_info.
2472 (expand_symtabs_matching): Adjust to use lookup_name_info.
2473 * symmisc.c (maintenance_expand_symtabs): Use
2474 lookup_name_info::match_any ().
2475 * symtab.c (symbol_matches_search_name): New.
2476 (eq_symbol_entry): Adjust to use lookup_name_info and the
2478 (demangle_for_lookup_info::demangle_for_lookup_info): New.
2479 (lookup_name_info::match_any): New.
2480 (iterate_over_symbols, search_symbols): Use lookup_name_info.
2481 (compare_symbol_name): Add language, lookup_name_info and
2482 completion_match_result parameters, and use them.
2483 (completion_list_add_name): Make extern. Add language and
2484 lookup_name_info parameters. Use them.
2485 (completion_list_add_symbol, completion_list_add_msymbol)
2486 (completion_list_objc_symbol): Add lookup_name_info parameters and
2487 adjust. Pass down language.
2488 (completion_list_add_fields): Add lookup_name_info parameters and
2489 adjust. Pass down language.
2490 (add_symtab_completions): Add lookup_name_info parameters and
2492 (default_collect_symbol_completion_matches_break_on): Add
2493 name_match_type parameter, and use it. Use lookup_name_info.
2494 (default_collect_symbol_completion_matches)
2495 (collect_symbol_completion_matches): Add name_match_type
2496 parameter, and pass it down.
2497 (collect_symbol_completion_matches_type): Adjust.
2498 (collect_file_symbol_completion_matches): Add name_match_type
2499 parameter, and use lookup_name_info.
2500 * symtab.h: Include <string> and "common/gdb_optional.h".
2501 (enum class symbol_name_match_type): New.
2502 (class ada_lookup_name_info): New.
2503 (struct demangle_for_lookup_info): New.
2504 (class lookup_name_info): New.
2505 (symbol_name_matcher_ftype): New.
2506 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
2507 (symbol_matches_search_name): Declare.
2508 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
2509 (default_collect_symbol_completion_matches)
2510 (collect_symbol_completion_matches)
2511 (collect_file_symbol_completion_matches): Add name_match_type
2513 (iterate_over_symbols): Use lookup_name_info.
2514 (completion_list_add_name): Declare.
2515 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
2516 (strncmp_iw_with_mode): Now extern.
2517 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
2518 (strncmp_iw_with_mode): Declare.
2520 2017-11-08 Keith Seitz <keiths@redhat.com>
2521 Pedro Alves <palves@redhat.com>
2523 * ada-lang.c (ada_language_defn): Install
2524 default_search_name_hash.
2525 * buildsym.c (struct buildsym_compunit): <language>: New field.
2526 (finish_block_internal): Pass language when creating dictionaries.
2527 (start_buildsym_compunit, start_symtab): New language parameters.
2529 (restart_symtab): Pass down compilation unit's language.
2530 * buildsym.h (enum language): Forward declare.
2531 (start_symtab): New 'language' parameter.
2532 * c-lang.c (c_language_defn, cplus_language_defn)
2533 (asm_language_defn, minimal_language_defn): Install
2534 default_search_name_hash.
2535 * coffread.c (coff_start_symtab): Adjust.
2536 * d-lang.c (d_language_defn): Install default_search_name_hash.
2537 * dbxread.c (struct symloc): Add 'pst_language' field.
2538 (PST_LANGUAGE): Define.
2539 (start_psymtab, read_ofile_symtab): Use it.
2540 (process_one_symbol): New 'language' parameter. Pass it down.
2541 * dictionary.c (struct dictionary) <language>: New field.
2542 (DICT_LANGUAGE): Define.
2543 (dict_create_hashed, dict_create_hashed_expandable)
2544 (dict_create_linear, dict_create_linear_expandable): New parameter
2545 'language'. Set the dictionary's language.
2546 (iter_match_first_hashed): Adjust to rename.
2547 (insert_symbol_hashed): Assert we don't see mismatching
2548 languages. Adjust to rename.
2549 (dict_hash): Rename to ...
2550 (default_search_name_hash): ... this and make extern.
2551 * dictionary.h (struct language_defn): Forward declare.
2552 (dict_create_hashed): New parameter 'language'.
2553 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
2554 * f-lang.c (f_language_defn): Install default_search_name_hash.
2555 * go-lang.c (go_language_defn): Install default_search_name_hash.
2556 * jit.c (finalize_symtab): Pass compunit's language to dictionary
2558 * language.c (unknown_language_defn, auto_language_defn):
2559 * language.h (language_defn::la_search_name_hash): New field.
2560 (default_search_name_hash): Declare.
2561 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
2562 * mdebugread.c (new_block): New parameter 'language'.
2563 * mdebugread.c (parse_symbol): Pass symbol language to block
2565 (psymtab_to_symtab_1): Pass down language.
2566 (new_symtab): Pass compunit's language to block allocation.
2567 * objc-lang.c (objc_language_defn): Install
2568 default_search_name_hash.
2569 * opencl-lang.c (opencl_language_defn):
2570 * p-lang.c (pascal_language_defn): Install
2571 default_search_name_hash.
2572 * rust-lang.c (rust_language_defn): Install
2573 default_search_name_hash.
2574 * stabsread.h (enum language): Forward declare.
2575 (process_one_symbol): Add 'language' parameter.
2576 * symtab.c (search_name_hash): New function.
2577 * symtab.h (search_name_hash): Declare.
2578 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
2580 2017-11-08 Pedro Alves <palves@redhat.com>
2582 * cp-name-parser.y (main): Don't initialize extra_chars.
2584 2017-11-07 Tom Tromey <tom@tromey.com>
2586 * event-top.h (command_handler): Constify.
2587 * record-full.c (cmd_record_full_start): Update.
2588 * thread.c (thread_apply_all_command): Update.
2589 * printcmd.c (eval_command): Update.
2590 * mi/mi-main.c (mi_execute_cli_command): Update.
2591 (mi_execute_async_cli_command): Update.
2592 * tui/tui-stack.c (tui_update_command): Update.
2593 * cli/cli-interp.c (safe_execute_command): Constify.
2594 * record.c (record_start): Update.
2595 (record_start, record_stop, cmd_record_start): Update.
2596 * record-btrace.c (cmd_record_btrace_bts_start): Update.
2597 (cmd_record_btrace_pt_start): Update.
2598 (cmd_record_btrace_start): Update.
2599 (cmd_record_btrace_start): Update.
2600 * reverse.c (exec_reverse_once): Update.
2601 * python/python.c (execute_gdb_command): Don't copy the command.
2602 * event-top.c (command_line_handler): Update.
2603 (command_handler): Constify.
2604 * defs.h (deprecated_call_command_hook): Constify.
2605 * cli/cli-script.h (execute_user_command): Constify.
2606 * cli/cli-script.c (execute_user_command): Constify.
2607 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
2608 (enum command_control_type): Update.
2609 * main.c (catch_command_errors): Remove non-const overload.
2610 (catch_command_errors_ftype): Remove.
2611 * python/py-cmd.c (cmdpy_function): Constify.
2612 * guile/scm-cmd.c (cmdscm_function): Constify.
2613 * cli/cli-dump.c (call_dump_func): Constify.
2614 * cli/cli-decode.c (do_const_cfunc): Constify.
2615 (do_sfunc): Constify.
2616 (cmd_func): Constify.
2617 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
2618 * top.h (execute_command): Constify.
2619 * top.c (execute_command): Constify.
2620 (execute_command_to_string): Constify.
2621 (deprecated_call_command_hook): Constify.
2622 * command.h (cmd_func): Constify.
2623 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
2625 2017-11-07 Tom Tromey <tom@tromey.com>
2627 * ada-lang.c (catch_ada_exception_command): Constify.
2628 (catch_assert_command): Constify.
2629 * break-catch-throw.c (catch_catch_command, catch_throw_command)
2630 (catch_rethrow_command): Constify.
2631 (catch_exception_command_1): Constify.
2632 * breakpoint.h (add_catch_command): Constify.
2633 * break-catch-syscall.c (catch_syscall_command_1): Constify.
2634 (catch_syscall_split_args): Constify.
2635 * break-catch-sig.c (catch_signal_command): Constify.
2636 (catch_signal_split_args): Constify.
2637 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
2638 cmd_const_sfunc_ftype.
2639 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
2640 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2641 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2642 (add_setshow_string_cmd, struct cmd_list_element)
2643 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2644 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2645 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
2647 (set_cmd_sfunc): Constify.
2648 (empty_sfunc): Constify.
2649 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2650 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2651 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
2652 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2653 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2654 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
2656 (set_cmd_sfunc): Constify.
2657 (cmd_sfunc_ftype): Remove.
2658 * compile/compile.c (set_compile_args): Constify.
2659 * infrun.c (set_disable_randomization): Constify.
2660 * infcmd.c (set_args_command, set_cwd_command): Constify.
2661 * breakpoint.c (set_condition_evaluation_mode): Constify.
2662 (add_catch_command): Constify.
2663 (catch_fork_command_1, catch_exec_command_1)
2664 (catch_load_command_1, catch_unload_command_1): Constify.
2665 (catch_load_or_unload): Constify.
2666 * guile/scm-param.c (pascm_set_func): Constify.
2667 (add_setshow_generic): Constify.
2668 * python/py-param.c (get_set_value): Constify.
2669 * top.h (set_verbose): Constify.
2670 * tui/tui-win.c (tui_set_var_cmd): Constify.
2671 * mi/mi-main.c (set_mi_async_command): Constify.
2672 * cli/cli-logging.c (set_logging_overwrite)
2673 (set_logging_redirect): Constify.
2674 * value.c (set_max_value_size): Constify.
2675 * valprint.c (set_input_radix, set_output_radix): Constify.
2676 * utils.c (set_width_command, set_height_command): Constify.
2677 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
2678 * tracepoint.c (set_disconnected_tracing)
2679 (set_circular_trace_buffer, set_trace_buffer_size)
2680 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
2681 * top.c (set_history_size_command, set_verbose, set_editing)
2682 (set_gdb_datadir, set_history_filename): Constify.
2683 * target.c (set_targetdebug, maint_set_target_async_command)
2684 (maint_set_target_non_stop_command, set_target_permissions)
2685 (set_write_memory_permission): Constify.
2686 (open_target): Constify.
2687 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
2688 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
2689 * symtab.c (set_symbol_cache_size_handler): Constify.
2690 * symfile.c (set_ext_lang_command): Constify.
2691 * symfile-debug.c (set_debug_symfile): Constify.
2692 * source.c (set_directories_command): Constify.
2693 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
2694 * serial.c (set_parity): Constify.
2695 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
2696 * remote.c (set_remote_exec_file, set_remotebreak)
2697 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
2698 * record.c (set_record_insn_history_size)
2699 (set_record_call_history_size): Constify.
2700 * record-full.c (set_record_full_insn_max_num): Constify.
2701 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
2702 * osabi.c (set_osabi): Constify.
2703 * mips-tdep.c (set_mips64_transfers_32bit_regs)
2704 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
2705 * maint.c (maintenance_set_profile_cmd): Constify.
2706 * linux-thread-db.c (set_libthread_db_search_path): Constify.
2707 * language.c (set_language_command, set_range_command)
2708 (set_case_command): Constify.
2709 * infrun.c (set_non_stop, set_observer_mode)
2710 (set_stop_on_solib_events, set_schedlock_func)
2711 (set_exec_direction_func): Constify.
2712 * infcmd.c (set_inferior_tty_command): Constify.
2713 * disasm.c (set_disassembler_options_sfunc): Constify.
2714 * demangle.c (set_demangling_command): Constify.
2715 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
2716 * cris-tdep.c (set_cris_version, set_cris_mode)
2717 (set_cris_dwarf2_cfi): Constify.
2718 * corefile.c (set_gnutarget_command): Constify.
2719 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
2720 (set_target_wide_charset_sfunc): Constify.
2721 * breakpoint.c (update_dprintf_commands): Constify.
2722 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
2723 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
2724 (set_disassembly_style_sfunc): Constify.
2725 * arch-utils.c (set_endian, set_architecture): Constify.
2726 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
2727 * agent.c (set_can_use_agent): Constify.
2729 2017-11-07 Tom Tromey <tom@tromey.com>
2731 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
2732 (go32_pde, go32_pte, go32_pte_for_address): Constify.
2733 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
2734 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
2735 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
2736 (parse_int_arg, show_thread_default_detach_sc_cmd)
2737 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
2738 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
2739 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
2740 (show_task_pause_cmd, set_task_detach_sc_cmd)
2741 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
2742 (set_noninvasive_cmd, set_thread_pause_cmd)
2743 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
2744 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
2745 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
2746 * windows-nat.c (display_selectors): Constify.
2747 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
2749 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
2750 (cmd_cfunc_eq): Likewise.
2751 (struct cmd_list_element): Likewise.
2753 (cli_user_command_p): Update.
2754 * command.h (add_cmd): Remove non-const overload.
2755 (cmd_cfunc_ftype): Remove typedef.
2756 (cmd_cfunc_eq): Remove non-const overload.
2757 * value.c (show_values): Constify.
2758 * thread.c (thread_apply_all_command): Constify.
2759 * symfile.c (load_command): Constify.
2760 * source.c (directory_command): Constify.
2761 * maint.c (maintenance_internal_error)
2762 (maintenance_demangler_warning, maintenance_space_display)
2763 (maintenance_print_architecture, maintenance_translate_address)
2764 (maintenance_info_selftests, maintenance_internal_warning):
2766 * breakpoint.c (disable_trace_command, enable_trace_command):
2768 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
2770 (add_auto_load_safe_path): Constify.
2771 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
2772 * top.h (show_commands): Constify.
2773 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
2774 * sparc64-tdep.c (adi_examine_command): Constify.
2775 (adi_assign_command): Constify.
2777 2017-11-07 Tom Tromey <tom@tromey.com>
2779 * frame.h (info_locals_command, info_args_command): Constify.
2780 * auto-load.h (auto_load_info_scripts): Constify.
2781 * inferior.h (registers_info): Constify.
2782 * copying.c: Rebuild.
2783 * copying.awk: Constify generated commands.
2784 * auto-load.c (auto_load_info_scripts)
2785 (info_auto_load_gdb_scripts): Constify.
2786 * cli/cli-decode.c (struct cmd_list_element): Take a
2787 cmd_const_cfunc_ftype.
2788 * command.h (add_info): Take a cmd_const_cfunc_ftype.
2789 * tui/tui-win.c (tui_all_windows_info): Constify.
2790 * python/py-auto-load.c (info_auto_load_python_scripts):
2792 * cli/cli-cmds.c (show_command): Remove non-const overload.
2793 * tracepoint.c (info_tvariables_command, info_scope_command):
2795 (info_static_tracepoint_markers_command): Constify.
2796 * thread.c (info_threads_command): Constify.
2797 (print_thread_info_1): Constify.
2798 * target.c (info_target_command): Constify.
2799 * symtab.c (info_sources_command, info_functions_command)
2800 (info_types_command): Constify.
2801 (info_variables_command): Remove non-const overload.
2802 * symfile.c (info_ext_lang_command): Constify.
2803 * stack.c (info_frame_command, info_locals_command)
2804 (info_args_command): Constify.
2805 (backtrace_command): Remove non-const overload.
2806 * source.c (info_source_command, info_line_command): Constify.
2807 * solib.c (info_sharedlibrary_command): Constify.
2808 * skip.c (info_skip_command): Constify.
2809 * ser-go32.c (info_serial_command): Constify.
2810 * reverse.c (info_bookmarks_command): Constify.
2811 * printcmd.c (info_symbol_command, info_address_command)
2812 (info_display_command): Constify.
2813 * osdata.c (info_osdata_command): Constify.
2814 * objc-lang.c (info_selectors_command, info_classes_command):
2816 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
2817 * memattr.c (info_mem_command): Constify.
2818 * macrocmd.c (info_macro_command, info_macros_command): Constify.
2819 * linux-fork.c (info_checkpoints_command): Constify.
2820 * infrun.c (info_signals_command): Constify.
2821 * inflow.c (info_terminal_command): Constify.
2822 * inferior.c (info_inferiors_command): Constify.
2823 (print_inferior): Constify.
2824 * infcmd.c (info_program_command, info_all_registers_command)
2825 (info_registers_command, info_vector_command)
2826 (info_float_command): Constify.
2827 (registers_info): Constify.
2828 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
2829 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
2831 * f-valprint.c (info_common_command): Constify.
2832 * dcache.c (info_dcache_command): Constify.
2833 (dcache_info_1): Constify.
2834 * darwin-nat-info.c (info_mach_tasks_command)
2835 (info_mach_task_command, info_mach_ports_command)
2836 (info_mach_port_command, info_mach_threads_command)
2837 (info_mach_thread_command, info_mach_regions_command)
2838 (info_mach_regions_recurse_command, info_mach_region_command)
2839 (info_mach_exceptions_command): Constify.
2840 (get_task_from_args): Constify.
2841 * cp-support.c (info_vtbl_command): Constify.
2842 * breakpoint.c (info_watchpoints_command)
2843 (info_tracepoints_command): Constify.
2844 (info_breakpoints_command): Remove non-const overload.
2845 * avr-tdep.c (avr_io_reg_read_command): Constify.
2846 * auxv.c (info_auxv_command): Constify.
2847 * ada-tasks.c (info_tasks_command): Constify.
2848 (info_task): Constify.
2849 * ada-lang.c (info_exceptions_command): Constify.
2851 2017-11-07 Tom Tromey <tom@tromey.com>
2853 * solib.h (no_shared_libraries): Constify.
2854 * frame.h (return_command): Constify.
2855 * cli/cli-cmds.h (quit_command): Constify.
2856 * top.h (quit_command, execute_command): Constify.
2857 * target.h (flash_erase_command): Constify.
2858 * inferior.h (set_inferior_args, attach_command): Constify.
2859 * tracepoint.h (start_tracing, stop_tracing): Constify.
2860 * breakpoint.h (break_command, tbreak_command)
2861 (hbreak_command_wrapper, thbreak_command_wrapper)
2862 (rbreak_command_wrapper, watch_command_wrapper)
2863 (awatch_command_wrapper, rwatch_command_wrapper)
2864 (get_tracepoint_by_number): Constify.
2865 * symtab.c (info_variables_command, rbreak_command)
2866 (symtab_symbol_info): Constify.
2867 (info_variables_command): Add non-const overload.
2868 * top.c (dont_repeat_command): Constify.
2869 * breakpoint.c (ignore_command, commands_command)
2870 (condition_command, tbreak_command, hbreak_command)
2871 (thbreak_command, clear_command, break_command)
2872 (info_breakpoints_command, watch_command, rwatch_command)
2873 (awatch_command, trace_command, ftrace_command, strace_command)
2874 (trace_pass_command, break_range_command, dprintf_command)
2875 (agent_printf_command, get_tracepoint_by_number)
2876 (watch_maybe_just_location, trace_pass_command): Constify.
2877 (info_breakpoints_command): Add non-const overload.
2878 * tracefile.c (tsave_command): Constify.
2879 * infcmd.c (attach_command, disconnect_command, signal_command)
2880 (queue_signal_command, stepi_command, nexti_command)
2881 (finish_command, next_command, step_command, until_command)
2882 (advance_command, jump_command, continue_command, run_command)
2883 (start_command, starti_command, interrupt_command)
2884 (run_command_1, set_inferior_args, step_1): Constify.
2885 * inferior.c (add_inferior_command, remove_inferior_command)
2886 (clone_inferior_command): Constify.
2887 * linux-fork.c (checkpoint_command, restart_command): Constify.
2888 * windows-nat.c (signal_event_command): Constify.
2889 * guile/guile.c (guile_repl_command, guile_command): Constify.
2890 * printcmd.c (x_command, display_command, printf_command)
2891 (output_command, set_command, call_command, print_command)
2892 (eval_command): Constify.
2893 (non_const_set_command): Remove.
2894 (_initialize_printcmd): Update.
2895 * source.c (forward_search_command, reverse_search_command):
2897 * jit.c (jit_reader_load_command, jit_reader_unload_command):
2899 * infrun.c (handle_command): Constify.
2900 * memattr.c (mem_command): Constify.
2901 * stack.c (return_command, up_command, up_silently_command)
2902 (down_command, down_silently_command, frame_command)
2903 (backtrace_command, func_command, backtrace_command_1): Constify.
2904 (backtrace_command): Add non-const overload.
2905 * remote-sim.c (simulator_command): Constify.
2906 * exec.c (set_section_command): Constify.
2907 * tracepoint.c (tdump_command, trace_variable_command)
2908 (tstatus_command, tstop_command, tstart_command)
2909 (end_actions_pseudocommand, while_stepping_pseudocommand)
2910 (collect_pseudocommand, teval_pseudocommand, actions_command)
2911 (start_tracing, stop_tracing): Constify.
2912 * value.c (init_if_undefined_command): Constify.
2913 * tui/tui-stack.c (tui_update_command): Constify.
2914 * tui/tui-win.c (tui_refresh_all_command)
2915 (tui_set_tab_width_command, tui_set_win_height_command)
2916 (tui_set_focus_command, tui_scroll_forward_command)
2917 (tui_scroll_backward_command, tui_scroll_left_command)
2918 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
2919 (tui_set_win_height): Constify.
2920 * tui/tui-layout.c (tui_layout_command): Constify.
2921 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
2922 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
2923 (proc_untrace_sysexit_cmd): Constify.
2924 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
2925 (threadset_test_cmd, threadlist_update_test_cmd)
2926 (threadalive_test): Constify.
2927 * objc-lang.c (print_object_command): Constify.
2928 * command.h (add_com): Constify.
2929 * cli/cli-dump.c (restore_command): Constify.
2930 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
2931 (help_command, complete_command, shell_command, edit_command)
2932 (list_command, disassemble_command, make_command)
2933 (apropos_command, alias_command): Constify.
2934 * cli/cli-script.c (document_command, define_command)
2935 (while_command, if_command, validate_comname): Constify.
2936 * cli/cli-decode.c (struct cmd_list_element): Change type of
2938 * target.c (do_monitor_command, flash_erase_command): Constify.
2939 * regcache.c (reg_flush_command): Constify.
2940 * reverse.c (reverse_step, reverse_next, reverse_stepi)
2941 (reverse_nexti, reverse_continue, reverse_finish)
2942 (save_bookmark_command, goto_bookmark_command)
2943 (exec_reverse_once): Constify.
2944 * python/python.c (python_interactive_command, python_command):
2946 * typeprint.c (ptype_command, whatis_command, whatis_exp):
2948 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
2949 * gcore.c (gcore_command): Constify.
2951 2017-11-07 Tom Tromey <tom@tromey.com>
2953 * printcmd.c (x_command): Call set_repeat_arguments.
2954 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
2955 * top.c (repeat_arguments): New global.
2956 (set_repeat_arguments): New function.
2957 (execute_command): Handle repeat_arguments.
2958 (show_commands): Calls set_repeat_arguments.
2959 * command.h (set_repeat_arguments): Declare.
2961 2017-11-07 Tom Tromey <tom@tromey.com>
2963 * stack.c (backtrace_command): Use std::string.
2964 (backtrace_command_1): Make "count_exp" const.
2966 2017-11-07 Tom Tromey <tom@tromey.com>
2968 * source.c (directory_switch, mod_path, add_path): Constify.
2969 * defs.h (add_path, mod_path, directory_switch): Constify.
2970 * mi/mi-cmd-env.c (env_mod_path): Constify.
2972 2017-11-07 Tom Tromey <tom@tromey.com>
2974 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
2975 (run_command_1, continue_command, step_1, jump_command)
2976 (signal_command, until_command, advance_command, finish_command)
2977 (attach_command): Update.
2979 2017-11-07 Tom Tromey <tom@tromey.com>
2981 * command.h (set_cmd_cfunc): Don't declare.
2982 * cli/cli-decode.c (set_cmd_cfunc): Now static.
2984 2017-11-07 Tom Tromey <tom@tromey.com>
2986 * stack.c (select_frame_command): Constify.
2987 * cli/cli-decode.c (add_com_suppress_notification): Constify.
2988 * command.h (add_com_suppress_notification): Constify.
2990 2017-11-07 Tom Tromey <tom@tromey.com>
2992 * breakpoint.c (stop_command): Constify.
2993 * cli/cli-decode.c (struct cmd_list_element): Constify.
2994 * command.h (add_abbrev_prefix_cmd): Constify.
2996 2017-11-07 Pedro Alves <palves@redhat.com>
2998 * breakpoint.c (extract_bp_kind): New enum.
2999 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
3000 factored out from ...
3001 (extract_bp_number_and_location): ... here.
3002 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
3004 2017-11-07 Pedro Alves <palves@redhat.com>
3006 * breakpoint.c (extract_bp_number_and_location): Change return
3007 type to void. Throw error instead of warning.
3008 (enable_disable_command): Adjust.
3010 2017-11-07 Xavier Roirand <roirand@adacore.com>
3011 Pedro Alves <palves@redhat.com>
3013 * breakpoint.c (map_breakpoint_number_range): New, factored out
3015 (map_breakpoint_numbers): ... here.
3016 (find_location_by_number): Change parameters from string to
3017 breakpoint number and location.
3018 (extract_bp_number_and_location): New function.
3019 (enable_disable_bp_num_loc)
3020 (enable_disable_breakpoint_location_range)
3021 (enable_disable_command): New functions, factored out ...
3022 (enable_command, disable_command): ... these functions, and
3023 adjusted to support ranges.
3024 * NEWS: Document enable/disable breakpoint location range feature.
3026 2017-11-06 Luis Machado <luis.machado@linaro.org>
3028 * MAINTAINERS (Write After Approval): Update my e-mail address.
3030 2017-11-06 Pedro Alves <palves@redhat.com>
3032 * gnu-nat.c (gnu_terminal_init): Delete.
3033 (gnu_target): Don't install gnu_terminal_init.
3034 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
3035 (child_terminal_init): ... this function.
3037 2017-11-06 Pedro Alves <palves@redhat.com>
3039 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
3041 * config.in, configure: Regenerate.
3043 2017-11-06 Pedro Alves <palves@redhat.com>
3045 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
3046 (async_init_signals): Adjust.
3047 (handle_stop_sig): Rename to ...
3048 (handle_sigtstp): ... this.
3049 (async_stop_sig): Rename to ...
3050 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3052 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3053 instead of STOP_SIGNAL thoughout.
3054 (handle_stop_sig): Rename to ...
3055 (handle_sigtstp): ... this.
3056 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3058 2017-11-06 Pedro Alves <palves@redhat.com>
3060 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3061 longer set flags twice in row.
3063 2017-11-06 Pedro Alves <palves@redhat.com>
3065 * Makefile.in (SER_HARDWIRE): Update comment.
3066 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3067 * common/gdb_termios.h: Delete file.
3068 * common/job-control.c: Include termios.h and unistd.h instead of
3070 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3072 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3074 * configure.ac: No longer check for termio.h and sgtty.h.
3075 * configure: Regenerate.
3076 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3077 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3078 Replace PROCESS_GROUP_TYPE references with pid_t references
3080 (gdb_getpgrp): Delete.
3081 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3082 (child_terminal_inferior): Remove comment. Remove sgtty code.
3083 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3084 gdb_getpgrp. Use serial_set_tty_state instead aof
3085 serial_noflush_set_tty_state. Remove sgtty code.
3086 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3087 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3088 (inferior_process_group): Now returns pid_t.
3089 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3090 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3091 * ser-event.c (serial_event_ops): Update.
3092 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3094 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3095 * ser-pipe.c (pipe_ops): Update.
3096 * ser-tcp.c (tcp_ops): Update.
3097 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3098 HAVE_TERMIOS checks.
3099 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3100 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3101 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3103 (hardwire_noflush_set_tty_state): Delete.
3104 (hardwire_print_tty_state, hardwire_drain_output)
3105 (hardwire_flush_output, hardwire_flush_input)
3106 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3107 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3108 code, and assume termios.
3109 (hardwire_ops): Update.
3110 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3111 * serial.c (serial_noflush_set_tty_state): Delete.
3112 * serial.h (serial_noflush_set_tty_state): Delete.
3113 (serial_ops::noflush_set_tty_state): Delete.
3115 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3117 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3118 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3119 (COMMON_OBS): Remove doublest.o and dfp.o.
3120 Do not build target-float.c (instead of doublest.c)
3121 with -Wformat-nonliteral.
3123 * doublest.c: Remove file.
3124 * doublest.h: Remove file.
3125 * dfp.c: Remove file.
3126 * dfp.h: Remove file.
3128 * target-float.c: Do not include "doublest.h" and "dfp.h".
3129 (DOUBLEST): Move here from doublest.h.
3130 (enum float_kind): Likewise.
3131 (FLOATFORMAT_CHAR_BIT): Likewise.
3132 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3133 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3134 (floatformat_precision): Likewise.
3135 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3136 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3138 (host_float_format, host_double_format, host_long_double_format):
3140 (floatformat_to_string, floatformat_from_string): Likewise.
3141 (floatformat_to_doublest): Likewise. Also, inline the original
3142 convert_floatformat_to_doublest.
3143 (floatformat_from_doublest): Likewise. Also, inline the original
3144 convert_floatformat_from_doublest.
3146 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3147 (MAX_DECIMAL_STRING): Move here from dfp.c.
3148 (match_endianness): Likewise.
3149 (set_decnumber_context, decimal_check_errors): Likewise.
3150 (decimal_from_number, decimal_to_number): Likewise.
3151 (decimal_to_string, decimal_from_string): Likewise. Make static.
3152 (decimal_from_longest, decimal_from_ulongest): Likewise.
3153 (decimal_to_longest): Likewise.
3154 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3155 (decimal_convert): Likewise.
3157 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3159 * doublest.c: Do not include "gdbtypes.h".
3160 (extract_typed_floating): Remove.
3161 (store_typed_floating): Remove.
3162 (convert_typed_floating): Remove.
3163 * doublest.h (struct type): Remove.
3164 (DOUBLEST_PRINT_FORMAT): Remove.
3165 (DOUBLEST_SCAN_FORMAT): Remove.
3166 (extract_typed_floating): Remove.
3167 (store_typed_floating): Remove.
3168 (convert_typed_floating): Remove.
3170 * dfp.c (decimal_from_doublest): Remove.
3171 (decimal_to_doublest): Remove.
3172 * dfp.h: Do not include "doublest.h".
3173 (decimal_from_doublest): Remove.
3174 (decimal_to_doublest): Remove.
3176 * value.c: Do not include "doublest.h" and "dfp.h".
3177 (value_as_double): Remove.
3178 (unpack_double): Remove.
3179 (value_from_double): Remove.
3180 (value_from_decfloat): Remove.
3181 * value.h: Do not include "doublest.h".
3182 (value_as_double): Remove.
3183 (unpack_double): Remove.
3184 (value_from_double): Remove.
3185 (value_from_decfloat): Remove.
3187 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3189 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3190 (i386_extract_return_value): Use target_float_convert.
3191 (i386_store_return_value): Likewise.
3192 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3193 (i387_value_to_register): Likewise.
3194 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3195 (ia64_register_to_value): Use target_float_convert.
3196 (ia64_value_to_register): Likewise.
3197 (ia64_extract_return_value): Likewise.
3198 (ia64_store_return_value): Likewise.
3199 (ia64_push_dummy_call): Likewise.
3200 * m68k-tdep.c: Include "target-float.h".
3201 (m68k_register_to_value): Use target_float_convert.
3202 (m68k_value_to_register): Likewise.
3203 (m68k_svr4_extract_return_value): Likewise.
3204 (m68k_svr4_store_return_value): Likewise.
3205 * ppc-sysv-tdep.c: Include "target-float.h".
3206 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3207 (do_ppc_sysv_return_value): Likewise.
3208 (ppc64_sysv_abi_push_freg): Likewise.
3209 (ppc64_sysv_abi_return_value_base): Likewise.
3210 * rs6000-aix-tdep.c: Include "target-float.h".
3211 (rs6000_push_dummy_call): Use target_float_convert.
3212 (rs6000_return_value): Likewise.
3213 * rs6000-lynx178-tdep.c: Include "target-float.h".
3214 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3215 (rs6000_lynx178_return_value): Likewise.
3216 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3217 (rs6000_register_to_value): Use target_float_convert.
3218 (rs6000_value_to_register): Likewise.
3219 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3220 (arm_extract_return_value): Use target_float_convert.
3221 (arm_store_return_value): Likewise.
3222 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3223 (sh_register_convert_to_virtual): Use target_float_convert.
3224 (sh_register_convert_to_raw): Likewise.
3225 * sh64-tdep.c: Include "target-float.h".
3226 (sh64_extract_return_value): Use target_float_convert.
3227 (sh64_register_convert_to_virtual): Likewise.
3228 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3230 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3232 * target-float.c (floatformat_to_host_double): New function.
3233 (floatformat_from_host_double): Likewise.
3234 (target_float_to_host_double): Likewise.
3235 (target_float_from_host_double): Likewise.
3236 * target-float.h (target_float_to_host_double): Add prototype.
3237 (target_float_from_host_double): Likewise.
3239 * guile/scm-value.c: Include "target-float.h".
3240 (gdbscm_value_to_real): Use target_float_to_host_double.
3241 Handle integer source values via value_as_long.
3242 * guile/scm-math.c: Include "target-float.h". Do not include
3243 "doublest.h", "dfp.h", and "expression.h".
3244 (vlscm_convert_typed_number): Use target_float_from_host_double.
3245 (vlscm_convert_number): Likewise.
3247 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3248 (convert_value_from_python): Use target_float_from_host_double.
3250 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3252 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3253 (cast_from_fixed): Likewise.
3254 (ada_scaling_type): New function.
3255 (ada_delta): Return value instead of DOUBLEST. Perform target
3256 arithmetic instead of host arithmetic.
3257 (scaling_factor): Rename to ...
3258 (ada_scaling_factor) ... this. Make non-static. Return value instead
3259 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3260 (ada_fixed_to_float): Remove.
3261 (ada_float_to_fixed): Remove.
3262 * ada-lang.h (ada_fixed_to_float): Remove.
3263 (ada_float_to_fixed): Remove.
3264 (ada_delta): Return value instead of DOUBLEST.
3265 (ada_scaling_factor): Add prototype.
3267 * ada-typeprint.c: Include "target-float.h".
3268 (print_fixed_point_type): Perform target arithmetic instead of
3270 * ada-valprint.c: Include "target-float.h".
3271 (ada_val_print_num): Perform target arithmetic instead of
3272 host arithmetic for fixed-point types.
3274 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3276 * target-float.c: Include <math.h>.
3277 (floatformat_binop): New function.
3278 (floatformat_compare): Likewise.
3279 (target_float_binop): Likewise.
3280 (target_float_compare): Likewise.
3281 * target-float.h: Include "expression.h".
3282 (target_float_binop): Add prototype.
3283 (target_float_compare): Likewise.
3285 * valarith.c: Do not include "doublest.h" and "dfp.h".
3286 Include "common/byte-vector.h".
3287 (value_args_as_decimal): Remove, replace by ...
3288 (value_args_as_target_float): ... this function. Handle both
3289 binary and decimal target floating-point formats.
3290 (scalar_binop): Handle both binary and decimal FP using
3291 value_args_as_target_float and target_float_binop.
3292 (value_equal): Handle both binary and decimal FP using
3293 value_args_as_target_float and target_float_compare.
3294 (value_less): Likewise.
3295 (value_pos): Handle all scalar types as simple copy.
3296 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3297 * dfp.c (decimal_binop): Throw error instead of internal_error
3298 when called with an unsupported operation code.
3300 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3302 * target-float.c (target_float_to_string): New function.
3303 (target_float_from_string): New function.
3304 * target-float.h (target_float_to_string): Add prototype.
3305 (target_float_from_string): Add prototype.
3307 * valprint.c: Include "target-float.h". Do not include
3308 "doublest.h" and "dfp.h".
3309 (print_floating): Use target_float_to_string.
3310 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3311 (printf_floating): Use target_float_to_string.
3312 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3313 (print_i387_value): Use target_float_to_string.
3314 * mips-tdep.c: Include "target-float.h".
3315 (mips_print_fp_register): Use target_float_to_string.
3316 * sh64-tdep.c: Include "target-float.h".
3317 (sh64_do_fp_register): Use target_float_to_string.
3319 * parse.c: Include "target-float.h". Do not include
3320 "doublest.h" and "dfp.h".
3321 (parse_float): Use target_float_from_string.
3322 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3323 (define_symbol): Use target_float_from_string.
3324 * gdbarch-selftests.c: Include "target-float.h".
3325 (register_to_value_test): Use target_float_from_string.
3327 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3329 * Makefile.c (SFILES): Add target-float.c.
3330 (HFILES_NO_SRCDIR): Add target-float.h.
3331 (COMMON_OBS): Add target-float.o.
3332 * target-float.h: New file.
3333 * target-float.c: New file.
3335 * doublest.c (floatformat_classify): Fix detection of float_zero.
3337 * gdbtypes.c (is_floating_type): New function.
3338 * gdbtypes.h (is_floating_type): Add prototype.
3340 * value.c: Do not include "floatformat.h".
3341 (unpack_double): Use target_float_is_valid.
3342 (is_floating_value): New function.
3343 * value.h (is_floating_value): Add prototype-
3345 * valarith.c: Include "target-float.h".
3346 (value_logical_not): Use target_float_is_zero.
3348 * python/py-value.c: Include "target-float.h".
3349 (valpy_nonzero): Use target_float_is_zero.
3351 2017-11-04 Tom Tromey <tom@tromey.com>
3353 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3355 2017-11-04 Tom Tromey <tom@tromey.com>
3357 * breakpoint.c (set_momentary_breakpoint): Return
3359 (until_break_command): Update.
3360 (new_until_break_fsm): Change argument types to
3362 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3363 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3365 * infcmd.c (finish_forward): Update.
3366 * breakpoint.h (set_momentary_breakpoint)
3367 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3368 (make_cleanup_delete_breakpoint): Remove.
3369 (struct breakpoint_deleter): New.
3370 (breakpoint_up): New typedef.
3371 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3372 (insert_exception_resume_breakpoint): Update.
3373 (insert_exception_resume_from_probe): Update.
3374 (insert_longjmp_resume_breakpoint): Update.
3375 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3376 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3377 * infcall.c (call_function_by_hand_dummy): Update
3379 2017-11-04 Tom Tromey <tom@tromey.com>
3381 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3383 2017-11-04 Tom Tromey <tom@tromey.com>
3385 * linux-tdep.c (linux_core_info_proc_mappings): Use
3387 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3389 (linux_corefile_thread): Update.
3390 (linux_make_corefile_notes): Remove unused variable.
3392 2017-11-04 Tom Tromey <tom@tromey.com>
3394 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
3397 2017-11-04 Tom Tromey <tom@tromey.com>
3399 * objfiles.c (do_free_objfile_cleanup): Remove.
3400 * compile/compile-object-load.c (compile_object_load): Update.
3401 * objfiles.h (make_cleanup_free_objfile): Remove.
3403 2017-11-04 Tom Tromey <tom@tromey.com>
3405 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
3406 (adi_read_versions): Change "tags" to "gdb_byte *".
3407 (adi_print_versions): Likewise.
3409 2017-11-04 Tom Tromey <tom@tromey.com>
3412 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
3413 from start_rbreak_breakpoints.
3414 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
3415 * breakpoint.h (class scoped_rbreak_breakpoints): New.
3416 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
3417 * symtab.c (do_end_rbreak_breakpoints): Remove.
3418 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
3420 2017-11-04 Tom Tromey <tom@tromey.com>
3422 * cp-namespace.c (reset_directive_searched): Remove.
3423 (cp_lookup_symbol_via_imports): Use scoped_restore.
3424 * cp-support.c (reset_directive_searched): Remove.
3425 (make_symbol_overload_list_using): Use scoped_restore.
3426 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
3427 (reset_directive_searched): Remove.
3429 2017-11-04 Tom Tromey <tom@tromey.com>
3431 * symfile.c (find_separate_debug_file_by_debuglink): Use
3434 2017-11-04 Tom Tromey <tom@tromey.com>
3436 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
3438 (compute_stack_depth): Likewise.
3439 (do_compile_dwarf_expr_to_c): Use std::vector.
3441 2017-11-04 Tom Tromey <tom@tromey.com>
3443 * compile/compile-object-load.c (link_callbacks_einfo): Use
3446 2017-11-04 Tom Tromey <tom@tromey.com>
3448 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3449 Use scoped_free_pendings.
3450 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
3451 scoped_free_pendings.
3452 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
3453 (xcoff_initial_scan): Likewise.
3454 * buildsym.c (reset_symtab_globals): Update comment.
3455 (scoped_free_pendings): Rename from really_free_pendings.
3456 (prepare_for_building): Update comment.
3457 (buildsym_init): Likewise.
3458 * buildsym.h (class scoped_free_pendings): New class.
3459 (really_free_pendings): Don't declare.
3461 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
3463 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
3464 output when converting a zero value to a special byteorder format.
3466 2017-11-02 Yao Qi <yao.qi@linaro.org>
3468 * frame.c (do_frame_register_read): Remove aspace.
3469 * jit.c (jit_frame_sniffer): Likwise.
3470 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3471 * regcache.c (regcache::regcache): Pass nullptr.
3472 (regcache_print): Caller updated.
3473 * regcache.h (regcache::regcache): Remove one constructor
3476 2017-11-02 Yao Qi <yao.qi@linaro.org>
3478 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
3480 2017-11-02 Yao Qi <yao.qi@linaro.org>
3482 * breakpoint.c (insert_single_step_breakpoints): Update.
3483 * frame.c (struct frame_info) <aspace>: Add const.
3484 (frame_save_as_regcache): Add const.
3485 (get_frame_address_space): Return const address_space *.
3486 * frame.h (get_frame_address_space): Update declaration.
3487 * infrun.c (struct step_over_info) <aspace>: Add const.
3488 (set_step_over_info): Make aspace const.
3489 (displaced_step_prepare_throw): Change variable const.
3491 (proceed): Likewise.
3492 (adjust_pc_after_break): Likewise.
3493 (save_waitstatus): Likewise.
3494 (handle_signal_stop): Likewise.
3495 (keep_going_pass_signal): Likewise.
3496 * jit.c (jit_frame_sniffer): Add const.
3497 * mips-tdep.c (mips_single_step_through_delay): Likewise.
3498 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3499 * record-full.c (record_full_wait_1): Likewise.
3500 * regcache.c (regcache::regcache): Change parameter to const.
3501 * regcache.h (regcache::regcache): Likewise.
3502 (regcache::aspace): Return const address_space *.
3503 (regcache) <m_aspace>: Add const.
3505 2017-11-02 Yao Qi <yao.qi@linaro.org>
3507 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
3508 * frame.c (create_sentinel_frame): Likewise.
3509 * infrun.c (displaced_step_prepare_throw): Likewise.
3511 (thread_still_needs_step_over_bp): Likewise.
3512 (proceed): Likewise.
3513 (do_target_wait): Likewise.
3514 (adjust_pc_after_break): Likewise.
3515 (handle_syscall_event): Likewise.
3516 (save_waitstatus): Likewise.
3517 (handle_inferior_event_1): Likewise.
3518 (handle_signal_stop): Likewise.
3519 (keep_going_pass_signal): Likewise.
3520 * linux-nat.c (status_callback): Likewise.
3521 (save_stop_reason): Likewise.
3522 (resume_stopped_resumed_lwps): Likewise.
3523 * record-full.c (record_full_exec_insn): Likewise.
3524 (record_full_wait_1): Likewise.
3525 * regcache.c (get_regcache_aspace): Remove.
3526 * regcache.h (get_regcache_aspace): Remove.
3528 2017-11-02 Yao Qi <yao.qi@linaro.org>
3530 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
3531 (init_regcache_descr): Use gdbarch_num_regs.
3532 (regcache::regcache): Likewise.
3533 (regcache::get_register_status): Likewise.
3534 (regcache::assert_raw_regnum): Likewise.
3535 (regcache::cooked_read): Likewise.
3536 (regcache::cooked_read_value): Likewise.
3537 (regcache::cooked_write): Likewise.
3538 (regcache::dump): Likewise.
3539 (regcache::num_raw_registers): New method.
3540 * regcache.h (class regcache) <num_raw_registers>: New.
3542 2017-11-02 Yao Qi <yao.qi@linaro.org>
3544 * regcache.c (regcache::assert_regnum): New method.
3545 (regcache::invalidate): Call assert_regnum.
3546 (regcache::raw_update): Likewise.
3547 (regcache::raw_write): Likewise.
3548 (regcache::raw_read_part): Likewise.
3549 (regcache::raw_write_part): Likewise.
3550 (regcache::raw_supply): Likewise.
3551 (regcache::raw_supply_integer): Likewise.
3552 (regcache::raw_supply_zeroed): Likewise.
3553 (regcache::raw_collect): Likewise.
3554 (regcache::raw_collect_integer): Likewise.
3555 * regcache.h (regcache::assert_regnum): Declare.
3557 2017-11-02 Yao Qi <yao.qi@linaro.org>
3559 * regcache.c (regcache::dump): Remove code.
3561 2017-11-02 Yao Qi <yao.qi@linaro.org>
3563 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
3565 <sizeof_cooked_register_status>: Remove.
3566 (init_regcache_descr): Update.
3567 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
3568 (regcache::save): Likewise.
3569 (regcache::dump): Likewise.
3571 2017-11-01 James Bowman <james.bowman@ftdichip.com>
3573 * ft32-tdep.c (ft32_fetch_instruction): New function.
3574 (ft32_analyze_prologue): Use ft32_fetch_instruction().
3576 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
3578 * cli/cli-script.c (execute_control_command): Rename to ...
3579 (execute_control_command_1): ... this.
3580 (execute_control_command): New function.
3582 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
3584 * tracepoint.c (tfind_command): Remove const_cast.
3586 2017-10-30 Mike Gulick <mgulick@mathworks.com>
3588 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
3590 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
3592 * common/common-utils.h (in_inclusive_range): New function.
3593 * arm-tdep.c (arm_record_extension_space): Use
3595 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
3596 * cris-tdep.c (cris_spec_reg_applicable): Use
3599 2017-10-30 Pedro Alves <palves@redhat.com>
3600 Simon Marchi <simon.marchi@ericsson.com>
3602 * remote.c (remote_set_syscall_catchpoint): Build a std::string
3603 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
3605 2017-10-30 Pedro Alves <palves@redhat.com>
3607 * common/common-utils.c (string_appendf, string_vappendf): New
3609 * common/common-utils.h (string_appendf, string_vappendf): New
3611 * unittests/common-utils-selftests.c (string_appendf_func)
3612 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
3613 (string_vappendf_tests): New functions.
3614 (_initialize_common_utils_selftests): Register "string_appendf" and
3615 "string_vappendf tests".
3617 2017-10-30 Pedro Alves <palves@redhat.com>
3619 * unittests/common-utils-selftests.c (format_func): New typedef.
3620 (string_printf_tests, string_vprintf_tests): Tests factored out
3622 (test_format_func): ... this new function.
3623 (string_printf_tests, string_vprintf_tests): Reimplement on top of
3626 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3628 * darwin-nat.c: Remove include of gdb.h.
3630 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3632 * xtensa-xtregs.c: Fix formatting issues.
3634 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3636 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
3638 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
3641 * python/py-infthread.c (thpy_get_inferior): Increment reference
3642 of inferior before returning it.
3644 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3646 * unittests/common-utils-selftests.c (format): Add
3649 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3651 * xml-syscall.c (struct syscall_desc): Add constructor.
3652 <name>: Change type to std::string.
3653 (syscall_desc_up): New typedef.
3654 (syscall_desc_p): Remove typeder.
3655 (DEF_VEC_P(syscall_desc_p)): Remove.
3656 (struct syscall_group_desc): Add constructor.
3657 <name>: Change type to std::string.
3658 <syscalls>: Change type to std::vector.
3659 (syscall_group_desc_up): New typedef.
3660 (syscall_group_desc_p): Remove typedef.
3661 (DEF_VEC_P(syscall_group_desc_p)): Remove.
3662 (struct syscalls_info) <syscalls>: Change type to std::vector of
3665 <my_gdb_datadir>: Change type to std::string.
3666 (syscalls_info_up): New typedef.
3667 (allocate_syscalls_info): Remove.
3668 (syscalls_info_free_syscalls_desc): Remove.
3669 (syscalls_info_free_syscall_group_desc): Remove.
3670 (free_syscalls_info): Remove.
3671 (make_cleanup_free_syscalls_info): Remove.
3672 (syscall_group_create_syscall_group_desc): Adjust.
3673 (syscall_group_add_syscall): Adjust.
3674 (syscall_create_syscall_desc): Adjust.
3675 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
3676 (init_syscalls_info): Adjust.
3677 (syscall_group_get_group_by_name): Adjust.
3678 (xml_get_syscall_number): Adjust.
3679 (xml_get_syscall_name): Adjust.
3680 (xml_list_of_syscalls): Adjust.
3681 (xml_list_syscalls_by_group): Adjust.
3682 (xml_list_of_groups): Adjust.
3684 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3686 * probe.h: Don't include gdb_vecs.h.
3687 (DEF_VEC_P (probe_p)): Remove.
3688 (find_probes_in_objfile): Return an std::vector.
3689 * probe.c (find_probes_in_objfile): Likewise.
3690 * breakpoint.c (breakpoint_objfile_data)
3691 <longjmp_probes>: Change type to std::vector.
3692 <exception_probes>: Likewise.
3693 (free_breakpoint_probes): Don't manually free vectors.
3694 (create_longjmp_master_breakpoint): Adjust.
3695 (create_exception_master_breakpoint): Adjust.
3696 * solib-svr4.c (svr4_create_probe_breakpoints): Change
3697 parameter type, adjust.
3698 (svr4_create_solib_event_breakpoints): Adjust.
3700 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3702 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
3703 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
3705 (free_breakpoint_probes): Rename to ...
3706 (free_breakpoint_objfile_data): ... this, and call delete on
3709 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3711 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
3712 (loaded_script_ptr): Remove typedef.
3713 (DEF_VEC_P (loaded_script_ptr)): Remove.
3714 (struct collect_matching_scripts_data): Add constructor.
3715 <scripts_p>: Change type to (pointer to) std::vector.
3716 (collect_matching_scripts_data): Adjust.
3717 (sort_scripts_by_name): Make suitable for std::sort.
3718 (print_scripts): Don't sort vector, adjust to std::vector.
3719 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
3721 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3723 * symfile.c (filename_language): Make struct, not typedef. Add
3725 <ext>: Change type to std::string.
3726 (DEF_VEC_O (filename_language)): Remove.
3727 (filename_language_table): Change type to std::vector.
3728 (add_filename_language): Adjust.
3729 (set_ext_lang_command): Adjust.
3730 (info_ext_lang_command): Adjust.
3731 (deduce_language_from_filename): Adjust.
3732 (class scoped_restore_filename_language_table): Remove.
3733 (test_filename_language): Use scoped_restore.
3734 (test_set_ext_lang_command): Use scoped_restore, adjust to
3737 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3739 * symfile.c: Include selftest.h.
3740 (class scoped_restore_filename_language_table): New.
3741 (test_filename_language): New test.
3742 (test_set_ext_lang_command): New test.
3743 (_initialize_symfile): Register tests.
3745 2017-10-27 Keith Seitz <keiths@redhat.com>
3747 * breakpoint.c (print_breakpoint_location): Use the symbol saved
3748 in the bp_location, falling back to find_pc_sect_function when
3750 (add_location_to_breakpoint): Save sal->symbol.
3751 * breakpoint.h (struct bp_location) <symbol>: New field.
3752 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
3753 * symtab.h (struct symtab_and_line) <symbol>: New field.
3755 2017-10-26 Patrick Frants <osscontribute@gmail.com>
3758 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
3761 2017-10-26 Pedro Alves <palves@redhat.com>
3763 * remote.c (remote_async_terminal_ours_p): Delete.
3764 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
3765 Remove references to 'remote_async_terminal_ours_p'.
3767 2017-10-26 Yao Qi <yao.qi@linaro.org>
3769 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
3771 2017-10-26 Yao Qi <yao.qi@linaro.org>
3773 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
3775 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
3777 * breakpoint.c (bpstat_check_location): Remove cast.
3778 (breakpoint_hit_catch_fork): Make aspce const.
3779 (breakpoint_hit_catch_solib): Likewise.
3780 (breakpoint_hit_catch_exec): Likewise.
3781 (breakpoint_hit_ranged_breakpoint): Likewise.
3782 (breakpoint_hit_watchpoint): Likewise.
3783 (base_breakpoint_breakpoint_hit): Likewise.
3784 (bkpt_breakpoint_hit): Likewise.
3785 (dprintf_breakpoint_hit): Likewise.
3786 (tracepoint_breakpoint_hit): Likewise.
3787 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
3789 2017-10-26 Yao Qi <yao.qi@linaro.org>
3791 * breakpoint.c (breakpoint_location_address_match): Change
3792 "struct address_space *" to "const address_space".
3793 (breakpoint_location_address_range_overlap): Likewise.
3794 (breakpoint_here_p): Likewise.
3795 (breakpoint_in_range_p): Likewise.
3796 (moribund_breakpoint_here_p): Likewise.
3797 (bp_location_inserted_here_p): Likewise.
3798 (software_breakpoint_inserted_here_p): Likewise.
3799 (hardware_breakpoint_inserted_here_p): Likewise.
3800 (hardware_watchpoint_inserted_in_range): Likewise.
3801 (bpstat_check_location): Likewise.
3802 (bpstat_stop_status): Likewise.
3803 (breakpoint_address_match): Likewise.
3804 (breakpoint_address_match_range): Likewise.
3805 (breakpoint_location_address_match): Likewise.
3806 (breakpoint_location_address_range_overlap): Likewise.
3807 (insert_single_step_breakpoint): Likewise.
3808 (breakpoint_has_location_inserted_here): Likewise.
3809 (single_step_breakpoint_inserted_here_p): Likewise.
3810 (pc_at_non_inline_function): Likewise.
3811 * breakpoint.h (bpstat_stop_status): Update declaration.
3812 (breakpoint_here_p): Likewise.
3813 (breakpoint_in_range_p): Likewise.
3814 (moribund_breakpoint_here_p): Likewise.
3815 (breakpoint_inserted_here_p): Likewise.
3816 (software_breakpoint_inserted_here_p): Likewise.
3817 (hardware_breakpoint_inserted_here_p): Likewise.
3818 (breakpoint_has_location_inserted_here): Likewise.
3819 (single_step_breakpoint_inserted_here_p): Likewise.
3820 (hardware_watchpoint_inserted_in_range): Likewise.
3821 (breakpoint_address_match): Likewise.
3822 (insert_single_step_breakpoint): Likewise.
3823 (pc_at_non_inline_function): Likewise.
3824 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
3825 * record.c (record_check_stopped_by_breakpoint): Likewise.
3826 * record.h (record_check_stopped_by_breakpoint): Likewise.
3827 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
3829 2017-10-25 Yao Qi <yao.qi@linaro.org>
3831 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
3832 regcache->arch () instead get_regcache_arch.
3833 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
3835 (aarch64_fbsd_store_inferior_registers): Likewise.
3836 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
3837 (store_gregs_to_thread): Likewise.
3838 (fetch_fpregs_from_thread): Likewise.
3839 (store_fpregs_to_thread): Likewise.
3840 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
3841 (aarch64_store_return_value): Likewise.
3842 (aarch64_software_single_step): Likewise.
3843 * aix-thread.c (aix_thread_wait): Likewise.
3844 (supply_reg32): Likewise.
3845 (supply_sprs64): Likewise.
3846 (supply_sprs32): Likewise.
3847 (fill_gprs64): Likewise.
3848 (fill_gprs32): Likewise.
3849 (fill_sprs64): Likewise.
3850 (fill_sprs32): Likewise.
3851 (store_regs_user_thread): Likewise.
3852 (store_regs_kernel_thread): Likewise.
3853 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
3854 (alphabsd_store_inferior_registers): Likewise.
3855 * alpha-tdep.c (alpha_extract_return_value): Likewise.
3856 (alpha_store_return_value): Likewise.
3857 (alpha_deal_with_atomic_sequence): Likewise.
3858 (alpha_next_pc): Likewise.
3859 (alpha_software_single_step): Likewise.
3860 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
3861 (amd64bsd_store_inferior_registers): Likewise.
3862 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
3864 (amd64_linux_store_inferior_registers): Likewise.
3865 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
3866 (amd64_collect_native_gregset): Likewise.
3867 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
3868 (amd64obsd_collect_uthread): Likewise.
3869 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
3870 (amd64_collect_fpregset): Likewise.
3871 (amd64_supply_fxsave): Likewise.
3872 (amd64_supply_xsave): Likewise.
3873 (amd64_collect_fxsave): Likewise.
3874 (amd64_collect_xsave): Likewise.
3875 * arc-tdep.c (arc_write_pc): Likewise.
3876 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
3877 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
3878 (arm_fbsd_store_inferior_registers): Likewise.
3879 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
3880 (store_vfp_regs): Likewise.
3881 (arm_linux_fetch_inferior_registers): Likewise.
3882 (arm_linux_store_inferior_registers): Likewise.
3883 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
3884 (arm_linux_sigreturn_next_pc): Likewise.
3885 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
3886 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
3887 (fetch_register): Likewise.
3888 (store_register): Likewise.
3889 * arm-tdep.c (arm_is_thumb): Likewise.
3890 (displaced_in_arm_mode): Likewise.
3891 (bx_write_pc): Likewise.
3892 (arm_get_next_pcs_addr_bits_remove): Likewise.
3893 (arm_software_single_step): Likewise.
3894 (arm_extract_return_value): Likewise.
3895 (arm_store_return_value): Likewise.
3896 (arm_write_pc): Likewise.
3897 * bfin-tdep.c (bfin_extract_return_value): Likewise.
3898 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
3899 (bsd_uthread_store_registers): Likewise.
3900 * core-regset.c (fetch_core_registers): Likewise.
3901 * corelow.c (get_core_registers): Likewise.
3902 * cris-tdep.c (cris_store_return_value): Likewise.
3903 (cris_extract_return_value): Likewise.
3904 (find_step_target): Likewise.
3905 (find_step_target): Likewise.
3906 (cris_software_single_step): Likewise.
3907 * ctf.c (ctf_fetch_registers): Likewise.
3908 * darwin-nat.c (cancel_breakpoint): Likewise.
3909 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
3910 * frv-tdep.c (frv_extract_return_value): Likewise.
3911 * ft32-tdep.c (ft32_store_return_value): Likewise.
3912 (ft32_extract_return_value): Likewise.
3913 * go32-nat.c (fetch_register): Likewise.
3914 (go32_fetch_registers): Likewise.
3915 (go32_store_registers): Likewise.
3916 (store_register): Likewise.
3917 * h8300-tdep.c (h8300_extract_return_value): Likewise.
3918 (h8300_store_return_value): Likewise.
3919 * hppa-linux-nat.c (fetch_register): Likewise.
3920 (store_register): Likewise.
3921 (hppa_linux_fetch_inferior_registers): Likewise.
3922 (hppa_linux_store_inferior_registers): Likewise.
3923 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
3924 (i386_darwin_store_inferior_registers): Likewise.
3925 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
3926 (gnu_store_registers): Likewise.
3927 * i386-linux-nat.c (fetch_register): Likewise.
3928 (store_register): Likewise.
3929 (supply_gregset): Likewise.
3930 (fill_gregset): Likewise.
3931 (i386_linux_fetch_inferior_registers): Likewise.
3932 (i386_linux_store_inferior_registers): Likewise.
3933 (i386_linux_resume): Likewise.
3934 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
3936 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
3937 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
3938 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
3939 (i386obsd_collect_uthread): Likewise.
3940 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3941 (i386_supply_gregset): Likewise.
3942 (i386_collect_gregset): Likewise.
3943 (i386_supply_fpregset): Likewise.
3944 (i386_collect_fpregset): Likewise.
3945 (i386_mpx_bd_base): Likewise.
3946 * i386-v4-nat.c (supply_fpregset): Likewise.
3947 (fill_fpregset): Likewise.
3948 * i387-tdep.c (i387_supply_fsave): Likewise.
3949 (i387_collect_fsave): Likewise.
3950 (i387_supply_fxsave): Likewise.
3951 (i387_collect_fxsave): Likewise.
3952 (i387_supply_xsave): Likewise.
3953 (i387_collect_xsave): Likewise.
3954 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
3955 (ia64_linux_store_registers): Likewise.
3956 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
3957 (ia64_extract_return_value): Likewise.
3958 (ia64_store_return_value): Likewise.
3959 (find_func_descr): Likewise.
3960 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
3961 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
3962 (inf_ptrace_store_registers): Likewise.
3963 * infrun.c (use_displaced_stepping): Likewise.
3964 (displaced_step_prepare_throw): Likewise.
3966 (proceed): Likewise.
3967 (do_target_wait): Likewise.
3968 (adjust_pc_after_break): Likewise.
3969 (handle_inferior_event_1): Likewise.
3970 (handle_signal_stop): Likewise.
3971 (save_infcall_suspend_state): Likewise.
3972 (restore_infcall_suspend_state): Likewise.
3973 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
3974 * jit.c (jit_frame_prev_register): Likewise.
3975 * linux-nat.c (save_stop_reason): Likewise.
3976 (linux_nat_wait_1): Likewise.
3977 (resume_stopped_resumed_lwps): Likewise.
3978 * linux-record.c (record_linux_sockaddr): Likewise.
3979 (record_linux_msghdr): Likewise.
3980 (record_linux_system_call): Likewise.
3981 * linux-tdep.c (linux_collect_thread_registers): Likewise.
3982 * lm32-tdep.c (lm32_extract_return_value): Likewise.
3983 (lm32_store_return_value): Likewise.
3984 * m32c-tdep.c (m32c_read_flg): Likewise.
3985 (m32c_pseudo_register_read): Likewise.
3986 (m32c_pseudo_register_write): Likewise.
3987 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
3988 (m32r_linux_collect_gregset): Likewise.
3989 * m32r-tdep.c (m32r_store_return_value): Likewise.
3990 (m32r_extract_return_value): Likewise.
3991 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
3992 (m68kbsd_collect_fpregset): Likewise.
3993 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
3994 * m68k-linux-nat.c (fetch_register): Likewise.
3995 (old_fetch_inferior_registers): Likewise.
3996 (old_store_inferior_registers): Likewise.
3997 (store_regs): Likewise.
3998 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
3999 (m68k_svr4_store_return_value): Likewise.
4000 * m88k-tdep.c (m88k_store_arguments): Likewise.
4001 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
4002 (mi_cmd_data_write_register_values): Likewise.
4003 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
4004 (mips_fbsd_store_inferior_registers): Likewise.
4005 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
4006 (mips_fbsd_supply_gregs): Likewise.
4007 (mips_fbsd_collect_fpregs): Likewise.
4008 (mips_fbsd_collect_gregs): Likewise.
4009 (mips_fbsd_supply_fpregset): Likewise.
4010 (mips_fbsd_collect_fpregset): Likewise.
4011 (mips_fbsd_supply_gregset): Likewise.
4012 (mips_fbsd_collect_gregset): Likewise.
4013 * mips-linux-nat.c (supply_gregset): Likewise.
4014 (fill_gregset): Likewise.
4015 (supply_fpregset): Likewise.
4016 (fill_fpregset): Likewise.
4017 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
4018 (mips_fill_gregset): Likewise.
4019 (mips_supply_fpregset): Likewise.
4020 (mips_fill_fpregset): Likewise.
4021 (mips64_supply_gregset): Likewise.
4022 (micromips_linux_sigframe_validate): Likewise.
4023 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
4024 (mipsnbsd_fetch_inferior_registers): Likewise.
4025 (mipsnbsd_store_inferior_registers): Likewise.
4026 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
4027 (mipsnbsd_supply_gregset): Likewise.
4028 (mipsnbsd_iterate_over_regset_sections): Likewise.
4029 (mipsnbsd_supply_reg): Likewise.
4030 (mipsnbsd_supply_fpreg): Likewise.
4031 * mips-tdep.c (mips_in_frame_stub): Likewise.
4032 (mips_dummy_id): Likewise.
4033 (is_octeon_bbit_op): Likewise.
4034 (micromips_bc1_pc): Likewise.
4035 (extended_mips16_next_pc): Likewise.
4036 (mips16_next_pc): Likewise.
4037 (deal_with_atomic_sequence): Likewise.
4038 * moxie-tdep.c (moxie_process_readu): Likewise.
4039 * nios2-tdep.c (nios2_get_next_pc): Likewise.
4040 * nto-procfs.c (procfs_store_registers): Likewise.
4041 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
4042 (ppcfbsd_store_inferior_registers): Likewise.
4043 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
4044 (fetch_altivec_register): Likewise.
4045 (get_spe_registers): Likewise.
4046 (fetch_spe_register): Likewise.
4047 (fetch_altivec_registers): Likewise.
4048 (fetch_all_gp_regs): Likewise.
4049 (fetch_all_fp_regs): Likewise.
4050 (store_vsx_register): Likewise.
4051 (store_altivec_register): Likewise.
4052 (set_spe_registers): Likewise.
4053 (store_spe_register): Likewise.
4054 (store_altivec_registers): Likewise.
4055 (store_all_gp_regs): Likewise.
4056 (store_all_fp_regs): Likewise.
4057 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4058 (ppc_linux_collect_gregset): Likewise.
4059 (ppc_canonicalize_syscall): Likewise.
4060 (ppc_linux_record_signal): Likewise.
4061 (ppu2spu_prev_register): Likewise.
4062 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4063 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4064 (ppcobsd_store_registers): Likewise.
4065 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4067 (ppc_ravenscar_generic_store_registers): Likewise.
4068 * procfs.c (procfs_fetch_registers): Likewise.
4069 (procfs_store_registers): Likewise.
4070 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4071 (ravenscar_store_registers): Likewise.
4072 (ravenscar_prepare_to_store): Likewise.
4073 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4074 * record-full.c (record_full_wait_1): Likewise.
4075 (record_full_registers_change): Likewise.
4076 (record_full_store_registers): Likewise.
4077 (record_full_core_fetch_registers): Likewise.
4078 (record_full_save): Likewise.
4079 (record_full_goto_insn): Likewise.
4080 * regcache.c (regcache_register_size): Likewise.
4081 (get_regcache_arch): Remove.
4082 (regcache_read_pc): Likewise.
4083 * regcache.h (get_regcache_arch): Remove.
4084 * remote-sim.c (gdbsim_fetch_register): Likewise.
4085 (gdbsim_store_register): Likewise.
4086 * remote.c (fetch_register_using_p): Likewise.
4087 (send_g_packet): Likewise.
4088 (remote_prepare_to_store): Likewise.
4089 (store_registers_using_G): Likewise.
4090 * reverse.c (save_bookmark_command): Likewise.
4091 (goto_bookmark_command): Likewise.
4092 * rs6000-aix-tdep.c (branch_dest): Likewise.
4093 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4094 (fetch_register): Likewise.
4095 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4096 (ppc_collect_reg): Likewise.
4097 (ppc_collect_gregset): Likewise.
4098 (ppc_collect_fpregset): Likewise.
4099 (ppc_collect_vsxregset): Likewise.
4100 (ppc_collect_vrregset): Likewise.
4101 (ppc_displaced_step_hw_singlestep): Likewise.
4102 (rs6000_pseudo_register_read): Likewise.
4103 (rs6000_pseudo_register_write): Likewise.
4104 * s390-linux-nat.c (supply_gregset): Likewise.
4105 (fill_gregset): Likewise.
4106 (s390_linux_fetch_inferior_registers): Likewise.
4107 * s390-linux-tdep.c (s390_write_pc): Likewise.
4108 (s390_software_single_step): Likewise.
4109 (s390_all_but_pc_registers_record): Likewise.
4110 (s390_linux_syscall_record): Likewise.
4111 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4112 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4113 (shnbsd_store_inferior_registers): Likewise.
4114 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4115 (sh_extract_return_value_fpu): Likewise.
4116 (sh_store_return_value_nofpu): Likewise.
4117 (sh_corefile_supply_regset): Likewise.
4118 (sh_corefile_collect_regset): Likewise.
4119 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4120 (sh64_store_return_value): Likewise.
4121 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4122 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4123 (sparc_store_inferior_registers): Likewise.
4124 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4125 (sparc_ravenscar_prepare_to_store): Likewise.
4126 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4127 (sparc_analyze_control_transfer): Likewise.
4128 (sparc_step_trap): Likewise.
4129 (sparc_software_single_step): Likewise.
4130 (sparc32_gdbarch_init): Likewise.
4131 (sparc_supply_rwindow): Likewise.
4132 (sparc_collect_rwindow): Likewise.
4133 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4134 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4135 (sparc64nbsd_collect_gregset): Likewise.
4136 (sparc64nbsd_supply_fpregset): Likewise.
4137 (sparc64nbsd_collect_fpregset): Likewise.
4138 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4139 (sparc64_supply_gregset): Likewise.
4140 (sparc64_collect_gregset): Likewise.
4141 (sparc64_supply_fpregset): Likewise.
4142 (sparc64_collect_fpregset): Likewise.
4143 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4144 * spu-tdep.c (spu_unwind_sp): Likewise.
4145 (spu2ppu_prev_register): Likewise.
4146 (spu_memory_remove_breakpoint): Likewise.
4147 * stack.c (return_command): Likewise.
4148 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4149 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4150 * tracefile.c (trace_save_ctf): Likewise.
4151 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4152 (do_windows_store_inferior_registers): Likewise.
4153 (windows_resume): Likewise.
4154 * xtensa-linux-nat.c (fill_gregset): Likewise.
4155 (supply_gregset_reg): Likewise.
4156 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4157 (xtensa_register_read_masked): Likewise.
4158 (xtensa_supply_gregset): Likewise.
4159 (xtensa_extract_return_value): Likewise.
4160 (xtensa_store_return_value): Likewise.
4162 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4164 * doublest.c (floatformat_from_string): New function.
4165 * doublest.h (floatformat_from_string): Add prototype.
4167 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4168 (OP_FLOAT): ... this.
4169 * expression.h: Do not include "doublest.h".
4170 (union exp_element): Replace doubleconst and decfloatconst by
4171 new element floatconst.
4172 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4173 (ada_evaluate_subexp): Likewise.
4174 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4175 OP_DOUBLE and OP_DECFLOAT.
4176 * expprint.c (print_subexp_standard): Likewise.
4177 (dump_subexp_body_standard): Likewise.
4178 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4180 * parse.c: Include "dfp.h".
4181 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4182 (write_exp_elt_floatcst): New function.
4183 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4185 (operator_check_standard): Likewise.
4186 (parse_float): Do not accept suffix. Take type as input. Return bool.
4187 Return target format buffer instead of host DOUBLEST.
4188 Use floatformat_from_string and decimal_from_string to parse
4189 either binary or decimal floating-point types.
4190 (parse_c_float): Remove.
4191 * parser-defs.h: Do not include "doublest.h".
4192 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4193 (write_exp_elt_floatcst): Add prototype.
4194 (parse_float): Update prototype.
4195 (parse_c_float): Remove.
4197 * c-exp.y: Do not include "dfp.h".
4198 (typed_val_float): Use byte buffer instead of DOUBLEST.
4199 (typed_val_decfloat): Remove.
4201 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4202 (parse_number): Update to new parse_float interface.
4203 Parse suffixes and determine type before calling parse_float.
4204 Handle decimal and binary FP types the same way.
4206 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4207 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4208 (parse_number): Update to new parse_float interface.
4209 Parse suffixes and determine type before calling parse_float.
4211 * f-exp.y: Replace dval by typed_val_float.
4212 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4213 (parse_number): Use parse_float instead of atof.
4215 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4216 (parse_go_float): Remove.
4217 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4218 (parse_number): Call parse_float instead of parse_go_float.
4219 Parse suffixes and determine type before calling parse_float.
4221 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4222 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4223 (parse_number): Update to new parse_float interface.
4224 Parse suffixes and determine type before calling parse_float.
4226 * m2-exp.y: Replace dval by byte buffer val.
4227 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4228 (parse_number): Call parse_float instead of atof.
4230 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4231 (lex_number): Call parse_float instead of strtod.
4232 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4233 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4234 Use write_exp_elt_floatcst.
4235 (unit_testing): Remove static variable.
4236 (rust_type): Do not check unit_testing.
4237 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4239 * ada-exp.y (type_float, type_double): Remove.
4240 (typed_val_float): Use byte buffer instead of DOUBLEST.
4241 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4242 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4244 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4246 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4247 * arch/aarch64.h: New file.
4249 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4251 * dfp.h (decimal_from_string): Use const reference for argument.
4252 * dfp.c (decimal_from_string): Likewise.
4254 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4256 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4257 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4258 * mips-tdep.c (mips_print_fp_register): Likewise.
4260 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4262 * common/format.h (enum argclass): Replace decfloat_arg by
4263 dec32float_arg, dec64float_arg, and dec128float_arg.
4264 * common/format.c (parse_format_string): Update to return
4265 new decimal float argument classes.
4267 * printcmd.c (printf_decfloat): Rename to ...
4268 (printf_floating): ... this. Add argclass argument, and use it
4269 instead of parsing the format string again. Add support for
4270 binary floating-point values, using floatformat_to_string.
4271 Convert value to the target format if it doesn't already match.
4272 (ui_printf): Call printf_floating instead of printf_decfloat,
4273 also for double_arg / long_double_arg. Pass argclass.
4275 * dfp.c (decimal_to_string): Add format string argument.
4276 * dfp.h (decimal_to_string): Likewise.
4278 * doublest.c (floatformat_to_string): Add format string argument.
4279 * doublest.h (floatformat_to_string): Likewise.
4281 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4283 * doublest.c (floatformat_precision): New routine.
4284 (floatformat_to_string): Likewise.
4285 * doublest.c (floatformat_to_string): Add prototype.
4287 * printcmd.c (print_scalar_formatted): Only call print_floating
4288 on floating-point types.
4289 * valprint.c: Do not include "floatformat.h".
4290 (generic_val_print_decfloat): Remove.
4291 (generic_val_print): Call generic_val_print_float for both
4292 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4293 (print_floating): Use floatformat_to_string. Handle decimal float.
4294 (print_decimal_floating): Remove, merge into floatformat_to_string.
4295 * value.h (print_decimal_floating): Remove.
4297 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4299 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4301 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4303 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4305 * memattr.h: Don't include vec.h.
4306 (struct mem_attrib): Initialize fields.
4307 <unknown>: New static method.
4308 (struct mem_region): Add constructors, operator<, initialize
4310 * memattr.c: Include algorithm.
4311 (default_mem_attrib, unknown_mem_attrib): Remove.
4312 (user_mem_region_list): New global.
4313 (target_mem_region_list, mem_region_list): Change type to
4314 std::vector<mem_region>.
4315 (mem_use_target): Now a function.
4316 (target_mem_regions_valid): Change type to bool.
4317 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4318 (require_user_regions): Adjust.
4319 (require_target_regions): Adjust.
4320 (create_mem_region): Adjust.
4321 (lookup_mem_region): Adjust.
4322 (invalidate_target_mem_regions): Adjust.
4323 (mem_clear): Rename to...
4324 (user_mem_clear): ... this, and adjust.
4325 (mem_command): Adjust.
4326 (info_mem_command): Adjust.
4327 (mem_enable, enable_mem_command, mem_disable,
4328 disable_mem_command): Adjust.
4329 (mem_delete): Adjust.
4330 (delete_mem_command): Adjust.
4331 * memory-map.h (parse_memory_map): Return an std::vector.
4332 * memory-map.c (parse_memory_map): Likewise.
4333 (struct memory_map_parsing_data): Add constructor.
4334 <memory_map>: Point to std::vector.
4335 (memory_map_start_memory): Adjust.
4336 (memory_map_end_memory): Adjust.
4337 (memory_map_end_property): Adjust.
4338 (clear_result): Remove.
4339 * remote.c (remote_memory_map): Return an std::vector.
4340 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4342 (target_debug_print_mem_region_vector): New.
4343 * target-delegates.c: Regenerate.
4344 * target.h (mem_region_vector): New typedef.
4345 (to_memory_map): Return mem_region_vector.
4346 (target_memory_map): Return an std::vector.
4347 * target.c (target_memory_map): Return an std::vector.
4348 (flash_erase_command): Adjust.
4350 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4352 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4353 Change type to std::string.
4354 (memory_map_start_property): Adjust.
4355 (memory_map_end_property): Adjust.
4357 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4359 * infrun.h: Include common/byte-vector.h.
4360 (struct displaced_step_closure): New struct.
4361 (struct buf_displaced_step_closure): New struct.
4362 * infrun.c (displaced_step_closure::~displaced_step_closure):
4363 Provide default implementation.
4364 (displaced_step_clear): Deallocate step closure with delete.
4365 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4366 (aarch64_displaced_step_closure): ... this, extend
4367 displaced_step_closure.
4368 (aarch64_displaced_step_data) <dsc>: Change type to
4369 aarch64_displaced_step_closure.
4370 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4372 (aarch64_displaced_step_fixup): Add cast for displaced step
4374 * amd64-tdep.c (displaced_step_closure): Rename to ...
4375 (amd64_displaced_step_closure): ... this, extend
4376 displaced_step_closure.
4377 <insn_buf>: Change type to std::vector<gdb_byte>.
4379 (fixup_riprel): Change type of DSC parameter, adjust to type
4381 (fixup_displaced_copy): Change type of DSC parameter.
4382 (amd64_displaced_step_copy_insn): Instantiate
4383 amd64_displaced_step_closure.
4384 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4385 to type change of insn_buf.
4386 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4388 (arm_linux_copy_svc): Likewise.
4389 (cleanup_kernel_helper_return): Likewise.
4390 (arm_catch_kernel_helper_return): Likewise.
4391 (arm_linux_displaced_step_copy_insn): Instantiate
4392 arm_displaced_step_closure.
4393 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4394 (displaced_read_reg): Change type of parameter DSC.
4395 (branch_write_pc): Likewise.
4396 (load_write_pc): Likewise.
4397 (alu_write_pc): Likewise.
4398 (displaced_write_reg): Likewise.
4399 (arm_copy_unmodified): Likewise.
4400 (thumb_copy_unmodified_32bit): Likewise.
4401 (thumb_copy_unmodified_16bit): Likewise.
4402 (cleanup_preload): Likewise.
4403 (install_preload): Likewise.
4404 (arm_copy_preload): Likewise.
4405 (thumb2_copy_preload): Likewise.
4406 (install_preload_reg): Likewise.
4407 (arm_copy_preload_reg): Likewise.
4408 (cleanup_copro_load_store): Likewise.
4409 (install_copro_load_store): Likewise.
4410 (arm_copy_copro_load_store) Likewise.
4411 (thumb2_copy_copro_load_store): Likewise.
4412 (cleanup_branch): Likewise.
4413 (install_b_bl_blx): Likewise.
4414 (arm_copy_b_bl_blx): Likewise.
4415 (thumb2_copy_b_bl_blx): Likewise.
4416 (thumb_copy_b): Likewise.
4417 (install_bx_blx_reg): Likewise.
4418 (arm_copy_bx_blx_reg): Likewise.
4419 (thumb_copy_bx_blx_reg): Likewise.
4420 (cleanup_alu_imm): Likewise.
4421 (arm_copy_alu_imm): Likewise.
4422 (thumb2_copy_alu_imm): Likewise.
4423 (cleanup_alu_reg): Likewise.
4424 (install_alu_reg): Likewise.
4425 (arm_copy_alu_reg): Likewise.
4426 (thumb_copy_alu_reg): Likewise.
4427 (cleanup_alu_shifted_reg): Likewise.
4428 (install_alu_shifted_reg): Likewise.
4429 (arm_copy_alu_shifted_reg): Likewise.
4430 (cleanup_load): Likewise.
4431 (cleanup_store): Likewise.
4432 (arm_copy_extra_ld_st): Likewise.
4433 (install_load_store): Likewise.
4434 (thumb2_copy_load_literal): Likewise.
4435 (thumb2_copy_load_reg_imm): Likewise.
4436 (arm_copy_ldr_str_ldrb_strb): Likewise.
4437 (cleanup_block_load_all): Likewise.
4438 (cleanup_block_store_pc): Likewise.
4439 (cleanup_block_load_pc): Likewise.
4440 (arm_copy_block_xfer): Likewise.
4441 (thumb2_copy_block_xfer): Likewise.
4442 (cleanup_svc): Likewise.
4443 (install_svc): Likewise.
4444 (arm_copy_svc): Likewise.
4445 (thumb_copy_svc): Likewise.
4446 (arm_copy_undef): Likewise.
4447 (thumb_32bit_copy_undef): Likewise.
4448 (arm_copy_unpred): Likewise.
4449 (arm_decode_misc_memhint_neon): Likewise.
4450 (arm_decode_unconditional): Likewise.
4451 (arm_decode_miscellaneous): Likewise.
4452 (arm_decode_dp_misc): Likewise.
4453 (arm_decode_ld_st_word_ubyte): Likewise.
4454 (arm_decode_media): Likewise.
4455 (arm_decode_b_bl_ldmstm): Likewise.
4456 (arm_decode_ext_reg_ld_st): Likewise.
4457 (thumb2_decode_dp_shift_reg): Likewise.
4458 (thumb2_decode_ext_reg_ld_st): Likewise.
4459 (arm_decode_svc_copro): Likewise.
4460 (thumb2_decode_svc_copro): Likewise.
4461 (install_pc_relative): Likewise.
4462 (thumb_copy_pc_relative_16bit): Likewise.
4463 (thumb_decode_pc_relative_16bit): Likewise.
4464 (thumb_copy_pc_relative_32bit): Likewise.
4465 (thumb_copy_16bit_ldr_literal): Likewise.
4466 (thumb_copy_cbnz_cbz): Likewise.
4467 (thumb2_copy_table_branch): Likewise.
4468 (cleanup_pop_pc_16bit_all): Likewise.
4469 (thumb_copy_pop_pc_16bit): Likewise.
4470 (thumb_process_displaced_16bit_insn): Likewise.
4471 (decode_thumb_32bit_ld_mem_hints): Likewise.
4472 (thumb_process_displaced_32bit_insn): Likewise.
4473 (thumb_process_displaced_insn): Likewise.
4474 (arm_process_displaced_insn): Likewise.
4475 (arm_displaced_init_closure): Likewise.
4476 (arm_displaced_step_fixup): Add cast for closure.
4477 * arm-tdep.h: Include infrun.h.
4478 (displaced_step_closure): Rename to ...
4479 (arm_displaced_step_closure): ... this, extend
4480 displaced_step_closure.
4481 <u::svc::copy_svc_os>: Change type of parameter DSC.
4482 <cleanup>: Likewise.
4483 (arm_process_displaced_insn): Likewise.
4484 (arm_displaced_init_closure): Likewise.
4485 (displaced_read_reg): Likewise.
4486 (displaced_write_reg): Likewise.
4487 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4489 * i386-tdep.h: Include infrun.h.
4490 (i386_displaced_step_closure): New typedef.
4491 * i386-tdep.c (i386_displaced_step_copy_insn): Use
4492 i386_displaced_step_closure.
4493 (i386_displaced_step_fixup): Adjust.
4494 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
4495 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
4497 (ppc_displaced_step_fixup): Adjust.
4498 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
4499 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
4501 (s390_displaced_step_fixup): Adjust.
4503 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4505 * interps.h (interp_resume, interp_suspend, interp_set_temp):
4506 Remove declarations.
4508 2017-10-20 Tom Tromey <tom@tromey.com>
4510 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
4512 (gdb_bfd_record_inclusion): Update.
4513 (bfdp): Remove typedef.
4515 2017-10-20 Tom Tromey <tom@tromey.com>
4517 * gdb_bfd.c (gdb_bfd_ref): Use new.
4518 (struct gdb_bfd_data): Add constructor, destructor, and member
4520 (gdb_bfd_unref): Use delete.
4522 2017-10-20 Tom Tromey <tom@tromey.com>
4524 * exec.c (exec_file_attach): Use new_bfd_ref.
4525 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
4526 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4527 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
4529 * gdb_bfd.h (new_bfd_ref): New function.
4531 2017-10-20 Pedro Alves <palves@redhat.com>
4533 * main.c (captured_command_loop): Add attribute noinline.
4535 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
4537 * interps.c (struct interp_factory): Add constructor.
4538 (interp_factory_p): Remove typedef.
4539 (DEF_VEC_P(interp_factory_p)): Remove.
4540 (interpreter_factories): Change type to std::vector.
4541 (interp_factory_register): Adjust.
4542 (interp_lookup): Adjust.
4543 (interpreter_completer): Adjust.
4545 2017-10-19 Tom Tromey <tom@tromey.com>
4547 * break-catch-syscall.c (catch_syscall_completer): Use
4548 std::string, gdb::unique_xmalloc_ptr.
4550 2017-10-19 Tom Tromey <tom@tromey.com>
4552 * infcall.c (call_function_by_hand_dummy): Use std::string.
4554 2017-10-19 Tom Tromey <tom@tromey.com>
4556 * mi/mi-main.c (mi_cmd_execute): Update.
4557 * top.h (prepare_execute_command): Return scoped_value_mark.
4558 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
4559 Add move constructor.
4560 * top.c (prepare_execute_command): Return scoped_value_mark.
4561 (execute_command): Update.
4563 2017-10-19 Pedro Alves <palves@redhat.com>
4565 * xml-support.c (xml_fetch_content_from_file): Check fread's
4568 2017-10-19 Pedro Alves <palves@redhat.com>
4570 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
4572 (handle_error_fd): New function.
4573 (ser_base_async): Add/delete an event loop file handler for
4576 2017-10-19 Pedro Alves <palves@redhat.com>
4578 * xml-support.c (xml_fetch_content_from_file): Don't read in
4579 chunks. Instead use fseek to determine the file's size, and read
4582 2017-11-18 Keith Seitz <keiths@redhat.com>
4584 * c-exp.y (oper): Canonicalize conversion operators of user-defined
4586 Add whitespace to front of type name.
4588 2017-10-18 Keith Seitz <keiths@redhat.com>
4590 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
4591 DW_AT_accessibility.
4593 2017-10-18 Yao Qi <yao.qi@linaro.org>
4595 * features/tic6x-c62x-linux.c: Remove.
4597 2017-10-17 Tom Tromey <tom@tromey.com>
4599 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
4600 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
4601 (do_mixed_source_and_assembly): Likewise.
4603 2017-10-17 Tom Tromey <tom@tromey.com>
4605 * regcache.c (regcache::xfer_part): Remove assertion.
4607 2017-10-17 Pedro Alves <palves@redhat.com>
4609 * xml-support.c (xml_fetch_content_from_file): Call
4610 unique_ptr::release() instead unique_ptr::get() when passing
4613 2017-10-17 Yao Qi <yao.qi@linaro.org>
4615 * regcache.c (regcache::xfer_part): Remove parameters read and
4616 write, add parameter is_raw. All callers are updated.
4618 2017-10-16 Keith Seitz <keiths@redhat.com>
4620 * c-typeprint.c (enum access_specifier): Moved here from
4622 (output_access_specifier): New function.
4623 (c_type_print_base): Consider typedefs when assessing
4624 whether access labels are needed.
4625 Use output_access_specifier as needed.
4626 Output access specifier for typedefs, if needed.
4627 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
4628 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
4630 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
4633 2017-10-16 Tom Tromey <tom@tromey.com>
4635 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
4636 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
4637 * target.c (target_fileio_read_stralloc): Update.
4638 * sparc64-tdep.c (adi_is_addr_mapped): Update.
4639 * target.h (target_fileio_read_stralloc): Return
4642 2017-10-16 Tom Tromey <tom@tromey.com>
4644 * xml-syscall.c (xml_init_syscalls_info): Update.
4645 * xml-support.c (xinclude_start_include): Update.
4646 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
4647 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
4648 (xml_fetch_content_from_file): Likewise.
4649 * osdata.c (get_osdata): Update.
4650 * target.h (target_read_stralloc, target_get_osdata): Return
4652 * solib-aix.c (solib_aix_get_library_list): Update.
4653 * solib-target.c (solib_target_current_sos): Update.
4654 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
4655 * xml-tdesc.c (fetch_available_features_from_target): Update.
4656 (target_fetch_description_xml): Update.
4657 (file_read_description_xml): Update.
4658 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
4659 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
4660 (remote_pid_to_exec_file): Update.
4661 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
4662 (target_get_osdata): Likewise.
4664 2017-10-16 Tom Tromey <tom@tromey.com>
4666 * remote.c (remote_register_number_and_offset): Use std::vector.
4667 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
4668 (putpkt_binary): Use gdb::def_vector.
4669 (compare_sections_command): Use gdb::byte_vector.
4671 2017-10-16 Tom Tromey <tom@tromey.com>
4673 * ppc-linux-nat.c (hwdebug_insert_point): Use
4674 gdb::unique_xmalloc_ptr, XDUP.
4676 2017-10-16 Tom Tromey <tom@tromey.com>
4678 * probe.c (parse_probes): Use std::string.
4679 (info_probes_for_ops, enable_probes_command)
4680 (disable_probes_command): Remove cleanups.
4682 2017-10-16 Tom Tromey <tom@tromey.com>
4684 * buildsym.c (block_compar): Remove.
4685 (end_symtab_get_static_block): Use std::vector.
4687 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
4689 * memrange.h (struct mem_range): Define operator< and operator==.
4690 (mem_range_s): Remove.
4691 (DEF_VEC_O (mem_range_s)): Remove.
4692 (normalize_mem_ranges): Change parameter type to std::vector.
4693 * memrange.c (compare_mem_ranges): Remove.
4694 (normalize_mem_ranges): Change parameter type to std::vector,
4695 adjust to vector change.
4696 * exec.c (section_table_available_memory): Return vector, remove
4698 (section_table_read_available_memory): Adjust to std::vector
4700 * remote.c (remote_read_bytes): Adjust to std::vector
4702 * tracepoint.h (traceframe_available_memory): Change parameter
4703 type to std::vector.
4704 * tracepoint.c (traceframe_available_memory): Change parameter
4705 type to std::vector, adjust.
4706 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
4708 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4709 unittests/memrange-selftests.c.
4710 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
4711 * gdb/unittests/memrange-selftests.c: New file.
4713 2017-10-16 Pedro Alves <palves@redhat.com>
4715 * elfread.c (probe_key_free): Rename range-for variable.
4716 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
4717 (find_probe_by_pc, collect_probes): Rename range-for variable.
4719 2017-10-16 Yao Qi <yao.qi@linaro.org>
4721 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
4722 * features/tic6x-c62x.c: Remove.
4723 * features/tic6x-c64x-linux.c: Remove.
4724 * features/tic6x-c64x.c: Remove.
4725 * features/tic6x-c64xp-linux.c: Remove.
4726 * features/tic6x-c64xp.c: Remove.
4727 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
4728 initialize_tdesc_tic6x_*_linux functions.
4729 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
4730 initialize_tdesc_tic6x_* functions.
4732 2017-10-16 Yao Qi <yao.qi@linaro.org>
4734 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
4736 * regformats/tic6x-c62x.dat: Remove.
4737 * regformats/tic6x-c64x.dat: Remove.
4738 * regformats/tic6x-c64xp.dat: Remove.
4740 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
4742 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
4743 (the !HAVE_LIBEXPAT version).
4745 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4747 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
4750 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4752 * target.h: Include tracepoint.h.
4753 (enum trace_find_type): Move to tracepoint.h.
4754 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
4755 * tracepoint.h: Don't include target.h
4756 (enum trace_find_type): Move from target.h.
4757 (parse_traceframe_info): Return a unique ptr.
4758 * tracepoint.c (current_traceframe_info): Change type to unique
4760 (free_traceframe_info): Remove.
4761 (clear_traceframe_info): Don't manually free
4762 current_traceframe_info.
4763 (free_result): Remove.
4764 (parse_traceframe_info): Return a unique ptr.
4765 (get_traceframe_info): Adjust to unique ptr.
4766 * ctf.c (ctf_traceframe_info): Return a unique ptr.
4767 * remote.c (remote_traceframe_info): Return a unique ptr.
4768 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
4770 * target-debug.h (target_debug_print_traceframe_info_up): New
4772 * target-delegates.c: Regenerate.
4774 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4776 * memrange.h (struct mem_range): Add constructors.
4777 * tracepoint.h (struct traceframe_info) <memory>: Change type to
4778 std::vector<mem_range>.
4779 * tracepoint.c (free_traceframe_info): Don't manually free
4781 (traceframe_info_start_memory): Adjust to vector change.
4782 (traceframe_available_memory): Likewise.
4783 * tracefile-tfile.c (build_traceframe_info): Likewise.
4784 * ctf.c (ctf_traceframe_info): Likewise.
4786 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4788 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
4790 * tracepoint.c (free_traceframe_info): Deallocate with delete.
4791 (traceframe_info_start_tvar): Adjust to vector change.
4792 (parse_traceframe_info): Allocate with new.
4793 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
4795 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
4797 tfile_traceframe_info): Allocate with new.
4798 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
4801 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4803 * tracepoint.c (traceframe_info): Rename to...
4804 (current_traceframe_info): ...this.
4805 (clear_traceframe_info): Adjust.
4806 (get_traceframe_info): Adjust.
4808 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4810 * nat/linux-osdata.c: Include algorithm.
4811 (compare_processes): Remove.
4812 (struct pid_pgid_entry): New struct.
4813 (linux_xfer_osdata_processgroups): Use std::vector instead of
4816 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4818 * objfiles.h: Don't include symfile.h.
4819 (struct partial_symbol): Remove forward-declaration.
4820 (struct objfile) <global_psymbols, static_psymbols>: Change type
4821 to std::vector<partial_symbol *>.
4822 * objfiles.c (objfile::objfile): Don't memset those fields.
4823 (objfile::~objfile): Don't free those fields.
4824 * psympriv.h (struct psymbol_allocation_list): Remove
4825 forward-declaration.
4826 (add_psymbol_to_list): Change psymbol_allocation_list parameter
4828 (start_psymtab_common): Change parameters to std::vector.
4829 * psymtab.c: Include algorithm.
4830 (require_partial_symbols): Call shrink_to_fit.
4831 (find_pc_sect_psymbol): Adjust to vector change.
4832 (match_partial_symbol): Likewise.
4833 (lookup_partial_symbol): Likewise.
4834 (psym_relocate): Likewise.
4835 (dump_psymtab): Likewise.
4836 (recursively_search_psymtabs): Likewise.
4837 (compare_psymbols): Remove.
4838 (sort_pst_symbols): Adjust to vector change.
4839 (start_psymtab_common): Likewise.
4840 (end_psymtab_common): Likewise.
4841 (psymbol_bcache_full): De-constify return value.
4842 (add_psymbol_to_bcache): Likewise.
4843 (extend_psymbol_list): Remove.
4844 (append_psymbol_to_list): Adjust to vector change.
4845 (add_psymbol_to_list): Likewise.
4846 (init_psymbol_list): Likewise.
4847 (maintenance_info_psymtabs): Likewise.
4848 (maintenance_check_psymtabs): Likewise.
4849 * symfile.h (struct psymbol_allocation_list): Remove.
4850 * symfile.c (reread_symbols): Adjust to vector change.
4851 * dbxread.c (start_psymtab): Change type of parameters.
4852 (dbx_symfile_read): Adjust to vector change.
4853 (read_dbx_symtab): Likewise.
4854 (start_psymtab): Change type of parameters.
4855 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
4856 (create_partial_symtab): Likewise.
4857 (add_partial_symbol): Likewise.
4858 (write_one_signatured_type): Likewise.
4859 (recursively_write_psymbols): Likewise.
4860 * mdebugread.c (parse_partial_symbols): Likewise.
4861 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
4862 (scan_xcoff_symtab): Adjust to vector change.
4863 (xcoff_initial_scan): Likewise.
4865 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
4867 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
4869 2017-10-13 Yao Qi <yao.qi@linaro.org>
4871 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
4872 Remove s390x-*-expedite, add s390x-expedite.
4874 2017-10-13 Yao Qi <yao.qi@linaro.org>
4876 * features/s390-gs-linux64.c: Regenerated.
4877 * features/s390x-gs-linux64.c: Regenerated.
4879 2017-10-13 Tom Tromey <tom@tromey.com>
4881 * compile/compile-object-run.c (do_module_cleanup): Use delete.
4882 * solib.c (update_solib_list, reload_shared_libraries_1): Use
4884 * symfile.c (symbol_file_add_with_addrs): Use new.
4885 (symbol_file_add_separate): Update comment.
4886 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
4887 * jit.c (jit_object_close_impl): Use new.
4888 (jit_unregister_code): Use delete.
4889 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
4890 (~objfile): Rename from free_objfile.
4891 (free_objfile_separate_debug, do_free_objfile_cleanup)
4892 (free_all_objfiles, objfile_purge_solibs): Use delete.
4893 * objfiles.h (struct objfile): Add constructor and destructor.
4894 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
4895 (allocate_objfile, free_objfile): Don't declare.
4896 (struct objstats): Add initializers.
4898 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4900 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
4901 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
4902 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
4903 * gdbarch.h: Regenerate.
4904 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4906 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
4907 (i386_displaced_step_fixup): Adjust comment.
4908 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
4910 2017-10-12 Tom Tromey <tom@tromey.com>
4912 * prologue-value.h (pv_area::store_would_trash): Return bool.
4913 (pv_area::find_reg): Likewise.
4914 * prologue-value.c (pv_area::store_would_trash): Return bool.
4915 (pv_area::find_reg): Likewise.
4917 2017-10-12 Tom Tromey <tom@tromey.com>
4919 * s390-linux-tdep.c (s390_store, s390_load)
4920 (s390_check_for_saved, s390_analyze_prologue): Update.
4921 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
4922 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
4923 * prologue-value.h (class pv_area): Move from prologue-value.c.
4924 Change names of members. Add constructor, destructor, member
4926 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
4927 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
4928 (pv_area_fetch, pv_area_scan): Don't declare.
4929 * prologue-value.c (struct pv_area::area_entry): Now member of
4931 (struct pv_area): Move to prologue-value.h.
4932 (pv_area::pv_area): Rename from make_pv_area.
4933 (pv_area::~pv_area): Rename from free_pv_area.
4934 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
4935 (clear_entries, find_entry, overlaps, store_would_trash, store)
4936 (fetch, find_reg, scan): Now member of pv_area.
4937 Remove "area" argument. Update.
4938 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
4940 * mn10300-tdep.c (push_reg, check_for_saved)
4941 (mn10300_analyze_prologue): Update.
4942 * mep-tdep.c (is_arg_spill, check_for_saved)
4943 (mep_analyze_prologue): Update.
4944 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
4945 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
4946 (m32c_is_struct_return, m32c_analyze_prologue): Update.
4947 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
4949 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
4950 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
4952 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4954 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
4955 * linux-nat.c (linux_nat_delete_thread): New variable.
4956 (lwp_free): Invoke linux_nat_delete_thread if set.
4957 (linux_nat_set_delete_thread): New function.
4958 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
4959 thread delete callback.
4960 * arm-linux-nat.c (arm_linux_delete_thread): New function.
4961 (_initialize_arm_linux_nat): Assign thread delete callback.
4962 * s390-linux-nat.c (s390_delete_thread): New function.
4963 (_initialize_s390_nat): Assign thread delete callback.
4964 * x86-linux-nat.c (x86_linux_add_target): Likewise.
4965 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
4967 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
4969 * nat/x86-linux.c (x86_linux_delete_thread): New function.
4970 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
4972 2017-10-09 Tom Tromey <tom@tromey.com>
4974 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
4976 * tui/tui-layout.c (enum tui_status): Use std::string.
4978 2017-10-11 Tom Tromey <tom@tromey.com>
4980 * gdbthread.h (thread_command): Constify.
4981 * inferior.h (detach_command): Constify.
4982 * top.h (set_history, show_history): Constify.
4983 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
4984 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
4985 * bsd-kvm.c (bsd_kvm_cmd): Constify.
4986 * printcmd.c (set_command): Constify.
4987 (non_const_set_command): New function.
4988 * dcache.c (set_dcache_command, show_dcache_command): Constify.
4989 * breakpoint.c (enable_command, disable_command, delete_command)
4990 (catch_command, tcatch_command, set_breakpoint_cmd)
4991 (show_breakpoint_cmd): Constify.
4992 * macrocmd.c (macro_command): Constify.
4993 * infcmd.c (unset_command, kill_command, detach_command)
4994 (info_proc_cmd): Constify.
4995 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
4996 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
4997 (info_auto_load_cmd): Constify.
4998 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4999 (unset_tdesc_cmd): Constify.
5000 * ada-lang.c (set_ada_command, show_ada_command)
5001 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
5002 * guile/guile.c (set_guile_command, show_guile_command)
5003 (info_guile_command): Constify.
5004 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
5006 * skip.c (skip_command): Constify.
5007 * compile/compile.c (_initialize_compile): Constify.
5008 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
5009 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5010 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5011 (maint_btrace_pt_show_cmd): Constify.
5012 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
5014 * python/python.c (user_show_python, user_set_python): Constify.
5015 * mips-tdep.c (set_mips_command, show_mips_command)
5016 (set_mipsfpu_command): Constify.
5017 * record-btrace.c (cmd_record_btrace_start)
5018 (cmd_set_record_btrace, cmd_show_record_btrace)
5019 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
5020 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
5021 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
5023 * symfile.c (overlay_command): Constify.
5024 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
5025 * cli/cli-logging.c (set_logging_command, show_logging_command):
5027 * cli/cli-dump.c (dump_command, append_command)
5028 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5029 (tekhex_dump_command, binary_dump_command)
5030 (binary_append_command): Constify.
5031 * cli/cli-decode.c (struct cmd_list_element): Change type of
5033 * cli/cli-cmds.c (info_command, show_command, set_debug)
5034 (show_debug): Constify.
5035 (show_command): Add non-const overload.
5036 * top.c (set_history, show_history): Constify.
5037 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
5038 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
5039 * target.c (target_command): Constify.
5040 * sparc64-tdep.c (info_adi_command): Constify.
5041 * record-full.c (cmd_record_full_start): Constify.
5042 (set_record_full_command): Constify. Fix typo.
5043 (show_record_full_command): Constify.
5044 * thread.c (thread_command, thread_apply_command): Constify.
5045 * memattr.c (dummy_cmd): Constify.
5046 * value.c (function_command): Constify.
5047 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
5048 * probe.c (info_probes_command): Constify.
5049 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5050 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5051 (show_thread_cmd, set_thread_default_cmd)
5052 (show_thread_default_cmd): Constify.
5053 (check_empty): Constify.
5054 * tracepoint.c (tfind_command): Constify.
5055 * cp-support.c (maint_cplus_command): Constify.
5056 * windows-tdep.c (info_w32_command): Constify.
5057 * record.c (cmd_record_start, set_record_command)
5058 (show_record_command, info_record_command, cmd_record_goto):
5060 * ravenscar-thread.c (set_ravenscar_command)
5061 (show_ravenscar_command): Constify.
5062 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5064 (add_internal_problem_command): Remove casts.
5065 * arc-tdep.c (maintenance_print_arc_command): Constify.
5066 * valprint.c (set_print, show_print, set_print_raw)
5067 (show_print_raw): Constify.
5068 * maint.c (maintenance_command, maintenance_info_command)
5069 (maintenance_print_command, maintenance_set_cmd)
5070 (maintenance_show_cmd, set_per_command_cmd)
5071 (show_per_command_cmd, maintenance_check_command): Constify.
5072 * language.c (set_check, show_check): Constify.
5073 * typeprint.c (show_print_type, set_print_type): Constify.
5074 * go32-nat.c (go32_info_dos_command): Constify.
5076 2017-10-11 Tom Tromey <tom@tromey.com>
5078 * breakpoint.c (prepare_re_set_context): Remove.
5079 (breakpoint_re_set_one): Update. Don't use cleanups.
5080 (breakpoint_re_set): Use scoped_restore, std::string, and
5081 scoped_restore_current_language.
5083 2017-10-11 Tom Tromey <tom@tromey.com>
5085 * breakpoint.c (commands_command_1): Use std::string.
5086 (cleanup_executing_breakpoints): Remove.
5087 (bpstat_do_actions_1): Use scoped_restore.
5088 (bpstat_check_watchpoint): Use std::string.
5089 (decode_static_tracepoint_spec): Likewise.
5090 (break_range_command): Likewise.
5091 (watch_command_1): Likewise.
5092 (compare_breakpoints): Change argument types.
5093 (clear_command): Use std::vector.
5094 (cleanup_executing_breakpoints): Remove.
5095 (update_global_location_list): Use unique_xmalloc_ptr.
5096 (strace_command): Remove unused declaration.
5098 2017-10-11 John Baldwin <jhb@FreeBSD.org>
5100 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5101 * NEWS: Mention new FreeBSD/arm native configuration.
5102 * configure.host: Add arm*-*-freebsd*.
5103 * configure.nat: Likewise.
5104 * arm-fbsd-nat.c: New file.
5106 2017-10-11 John Baldwin <jhb@FreeBSD.org>
5108 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5109 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5110 * NEWS: Mention new FreeBSD/arm target.
5111 * configure.tgt: Add arm*-*-freebsd*.
5112 * arm-fbsd-tdep.c: New file.
5113 * arm-fbsd-tdep.h: New file.
5115 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5117 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5118 `gdbarch_elfcore_write_linux_prpsinfo'.
5119 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5121 (elf_internal_linux_prpsinfo): Remove declaration.
5122 * gdbarch.h: Regenerate.
5123 * gdbarch.c: Regenerate.
5125 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5127 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5128 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5130 2017-10-11 Pedro Alves <palves@redhat.com>
5132 * breakpoint.c (reattach_breakpoints): Delete.
5133 * breakpoint.h (reattach_breakpoints): Delete.
5135 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5137 * symfile.c (registered_sym_fns): Make struct, not typedef.
5138 (DEF_VEC_O (registered_sym_fns)): Remove.
5139 (symtab_fns): Change type to std::vector.
5140 (add_symtab_fns): Adjust.
5141 (find_sym_fns): Adjust.
5143 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5145 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5146 * arc-tdep.h (arc_arch_is_em): New function.
5147 (arc_arch_is_hs): Likewise.
5149 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5151 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5152 parentheses in the declaration.
5153 (macro_lookup_inclusion): Likewise.
5154 (macro_lookup_definition): Likewise.
5155 * p-lang.h (pascal_builtin_types): Likewise.
5156 * tui/tui-data.c (tui_win_list): Likewise.
5157 * tui/tui-data.h (tui_win_list): Likewise.
5158 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5160 2017-10-11 Mark Rages <markrages@gmail.com>
5162 * target-memory.c (block_boundaries): Fix for block address not
5163 aligned on block size.
5165 2017-10-10 Pedro Alves <palves@redhat.com>
5166 Tom Tromey <tom@tromey.com>
5168 * breakpoint.c (struct captured_breakpoint_query_args)
5169 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5170 (print_breakpoint): New.
5171 * breakpoint.h (print_breakpoint): Declare.
5172 * common/common-exceptions.h (enum return_reason): Remove
5173 references to catch_exceptions.
5174 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5176 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5177 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5179 * gdbthread.h (thread_select): Declare.
5180 * mi/mi-cmd-break.c: Don't include gdb.h.
5181 (breakpoint_notify): Use print_breakpoint.
5182 * mi/mi-cmd-catch.c: Don't include gdb.h.
5183 * mi/mi-interp.c: Don't include gdb.h.
5184 (mi_print_breakpoint_for_event): New.
5185 (mi_breakpoint_created, mi_breakpoint_modified): Use
5186 mi_print_breakpoint_for_event.
5187 * mi/mi-main.c: Don't include gdb.h.
5188 (mi_cmd_thread_select): Parse the global thread ID here. Use
5189 thread_select instead of gdb_thread_select.
5190 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5191 of using gdb_list_thread_ids.
5192 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5194 (remote_fileio_request): Use TRY/CATCH instead of
5196 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5197 (symbol_file_add_from_memory_wrapper): Delete.
5198 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5199 * thread.c: Don't include gdb.h.
5200 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5201 (thread_alive): Use thread_select.
5202 (do_captured_thread_select): Delete, parts salvaged as ...
5203 (thread_select): ... this new function.
5204 (gdb_thread_select): Delete.
5206 2017-10-10 Pedro Alves <palves@redhat.com>
5207 Tom Tromey <tom@tromey.com>
5209 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5211 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5212 No longer macros. Instead ...
5213 (enum wp_check_result): They're now values of this new
5215 (watchpoint_check): Change return type to wp_check_result and
5216 parameter type to bpstat.
5217 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5218 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5219 catch_errors. Reverse logic of watchpoint_check call.
5220 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5221 pointer as parameter.
5222 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5223 * common/common-exceptions.c (throw_exception_sjlj): Update
5224 comments to avoid mentioning catch_errors.
5225 * exceptions.c (catch_errors): Delete.
5226 * exceptions.h: Update comments to avoid mentioning catch_errors.
5227 (catch_errors_ftype, catch_errors): Delete.
5228 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5229 (hook_stop_stub): Delete.
5230 (restore_selected_frame): Change return type to void, and
5231 parameter type to const frame_id &.
5232 (restore_infcall_control_state): Use TRY/CATCH instead of
5234 * main.c (captured_command_loop): Return void and remove
5235 parameter. Remove references to catch_errors.
5236 (captured_main): Use TRY/CATCH instead of catch_errors.
5237 * objc-lang.c (objc_submethod_helper_data)
5238 (find_objc_msgcall_submethod_helper): Delete.
5239 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5241 * record-full.c (record_full_message): Return void.
5242 (record_full_message_args, record_full_message_wrapper): Delete.
5243 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5244 instead of catch_errors.
5245 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5246 parameter type to int.
5247 * solib-darwin.c (open_symbol_file_object): Ditto.
5248 * solib-dsbt.c (open_symbol_file_object): Ditto.
5249 * solib-frv.c (open_symbol_file_object): Ditto.
5250 * solib-svr4.c (open_symbol_file_object): Ditto.
5251 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5252 * solib.c (update_solib_list): Use TRY/CATCH instead of
5254 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5256 * symmisc.c (struct print_symbol_args): Remove.
5257 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5258 (print_symbol): Change type.
5259 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5260 and remove parameters.
5261 (catch_errors): New.
5262 (get_windows_debug_event): Adjust.
5264 2017-10-09 Tom Tromey <tom@tromey.com>
5266 * mi/mi-main.c (free_splay_tree): Remove.
5267 (list_available_thread_groups): Use splay_tree_up.
5268 * common/gdb_splay_tree.h: New file.
5270 2017-10-09 Tom Tromey <tom@tromey.com>
5272 * mi/mi-main.c (do_nothing): Remove.
5273 (list_available_thread_groups): Update.
5275 2017-10-09 Pedro Alves <palves@redhat.com>
5277 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5278 reading registers when switching context.
5280 2017-10-09 John Baldwin <jhb@FreeBSD.org>
5282 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5283 (fbsd_convert_siginfo): Likewise.
5284 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5286 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5288 * configure.ac (try_guile_versions): Remove guile-2.2.
5289 * configure: Regenerate.
5291 2017-10-09 Tom Tromey <tom@tromey.com>
5293 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5294 (COMPILE.pre): Use $(CXX).
5296 2017-10-09 Pedro Alves <palves@redhat.com>
5298 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5300 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5301 * cp-support.h (cp_remove_params): Now returns a
5302 gdb::unique_xmalloc_ptr.
5303 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5304 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5305 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5306 returning a gdb::unique_xmalloc_ptr.
5307 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5308 * stack.c (find_frame_funname): Adjust to cp_remove_params
5309 returning a gdb::unique_xmalloc_ptr.
5311 2017-10-08 Tom Tromey <tom@tromey.com>
5313 * dwarf2read.c (dwarf2_get_dwz_file): Use
5314 gdb::unique_xmalloc_ptr.
5315 (find_slot_in_mapped_hash): Likewise.
5316 (dwarf2_physname): Likewise.
5317 (create_dwo_unit_in_dwp_v1): Use std::string.
5318 (create_dwo_unit_in_dwp_v2): Likewise.
5319 (lookup_dwo_cutu): Likewise.
5320 (inherit_abstract_dies): Use std::vector.
5321 (read_array_type): Likewise.
5322 (dwarf_decode_macros): Remove unused declaration.
5323 (unsigned_int_compar): Remove.
5324 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5325 (psymtabs_addrmap_cleanup): Remove.
5327 2017-10-08 Tom Tromey <tom@tromey.com>
5329 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5330 * frame.h (frame_cleanup_after_sniffer): Declare.
5331 (frame_prepare_for_sniffer): Return void.
5332 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5334 (frame_prepare_for_sniffer): Return void.
5336 2017-10-08 Tom Tromey <tom@tromey.com>
5338 * utils.h (make_cleanup_value_free): Remove.
5339 * utils.c (do_value_free, struct cleanup): Remove.
5340 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5342 * value.h (struct value_deleter): New.
5343 (gdb_value_up): New typedef.
5345 2017-10-08 Tom Tromey <tom@tromey.com>
5347 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5348 (make_cleanup_free_search_symbols): Remove.
5349 (search_symbols): Return std::vector.
5350 (symbol_search::compare_search_syms): Now member of
5351 symbol_search. Change arguments.
5352 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5353 (symtab_symbol_info, rbreak_command): Update.
5354 * symtab.h (struct symbol_search) <next>: Remove.
5356 (symbol_search::operator<): New function.
5357 (symbol_search::operator==): New function.
5358 (search_symbols): Remove std::vector.
5359 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5360 (symbol_search::compare_search_syms): Declare.
5362 2017-10-06 Yao Qi <yao.qi@linaro.org>
5364 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5365 arch/aarch64-insn.o.
5367 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5369 2017-10-06 Yao Qi <yao.qi@linaro.org>
5371 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5372 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5373 arch/arm-linux.o respectively.
5374 * configure.tgt: Likewise.
5376 2017-10-06 Yao Qi <yao.qi@linaro.org>
5378 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5379 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5381 2017-10-06 Pedro Alves <palves@redhat.com>
5383 * windows-nat.c: Include <algorithm>.
5385 2017-10-06 Yao Qi <yao.qi@linaro.org>
5387 * configure.tgt (i386_tobjs): New variable.
5388 (amd64_tobjs): New variable.
5389 Set $cpu_obs and $os_obs.
5391 2017-10-06 Yao Qi <yao.qi@linaro.org>
5393 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5394 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
5395 (clean): Remove object files and dependency files.
5396 (distclean): Remove the directory.
5397 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5398 * configure: Re-generated.
5399 * configure.tgt: Replace amd64.o with arch/amd64.o.
5401 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
5404 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
5407 2017-10-05 Pedro Alves <palves@redhat.com>
5409 * linux-nat.c (linux_child_follow_fork): When following the parent
5410 and detaching the child, consult the parent thread's architecture
5411 instead of the child's.
5413 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5415 * ax.h: Do not include "doublest.h".
5416 (union agent_val): Remove.
5418 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5420 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
5421 (decimal_to_string): Return std::string object.
5422 (decimal_from_string): Accept std::string object. Return bool.
5423 (decimal_from_integral, decimal_from_doublest): Remove.
5424 (decimal_from_longest): Add prototype.
5425 (decimal_from_ulongest): Likewise.
5426 (decimal_to_longest): Likewise.
5427 (decimal_from_doublest): Likewise.
5428 * dfp.c: Do not include "gdbtypes.h" or "value.h".
5429 (MAX_DECIMAL_STRING): Move here.
5430 (decimal_to_string): Return std::string object.
5431 (decimal_from_string): Accept std::string object. Return bool.
5432 (decimal_from_integral): Remove, replace by ...
5433 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
5434 (decimal_to_longest): New function.
5435 (decimal_from_floating): Remove, replace by ...
5436 (decimal_from_doublest): ... this new function.
5437 (decimal_to_doublest): Update to new decimal_to_string interface.
5439 * value.c (unpack_long): Use decimal_to_longest.
5440 * valops.c (value_cast): Use decimal_from_doublest instead of
5441 decimal_from_floating. Use decimal_from_[u]longest isntead of
5442 decimal_from_integral.
5443 * valarith.c (value_args_as_decimal): Likewise.
5444 * valprint.c (print_decimal_floating): Update to new
5445 decimal_to_string interface.
5446 * printcmd.c (printf_decfloat): Likewise.
5447 * c-exp.y (parse_number): Update to new decimal_from_string interface.
5449 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5451 * doublest.h: Do not include "floatformat.h". Remove stale comments.
5452 * gdbtypes.c: Include "floatformat.h".
5453 * value.c: Likewise.
5454 * m68k-tdep.c: Likewise.
5456 * findvar.c: Do not include "floatformat.h".
5457 * amd64-darwin-tdep.c: Likewise.
5458 * arm-linux-tdep.c: Likewise.
5459 * i386-darwin-tdep.c: Likewise.
5460 * i387-tdep.c: Likewise.
5461 * m68k-linux-tdep.c: Likewise.
5462 * mep-tdep.c: Likewise.
5463 * mips-tdep.c: Likewise.
5464 * nios2-tdep.c: Likewise.
5465 * s390-linux-tdep.c: Likewise.
5466 * sparc-obsd-tdep.c: Likewise.
5467 * sparc-tdep.c: Likewise.
5468 * sparc64-tdep.c: Likewise.
5469 * spu-tdep.c: Likewise.
5470 * tic6x-tdep.c: Likewise.
5471 * tilegx-tdep.c: Likewise.
5472 * vax-tdep.c: Likewise.
5473 * xstormy16-tdep.c: Likewise.
5474 * xtensa-tdep.c: Likewise.
5476 * top.c: Do not include "doublest.h".
5477 * aarch64-tdep.c: Likewise.
5478 * alpha-tdep.c: Likewise.
5479 * arm-linux-tdep.c: Likewise.
5480 * m68k-linux-tdep.c: Likewise.
5481 * tilegx-tdep.c: Likewise.
5482 * xstormy16-tdep.c: Likewise.
5484 2017-10-05 John Baldwin <jhb@FreeBSD.org>
5486 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
5487 (mipsn32_fbsd_sigframe): Define.
5488 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
5489 for FreeBSD/mipsn32.
5491 2017-10-05 John Baldwin <jhb@FreeBSD.org>
5493 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
5496 2017-10-05 Tristan Gingold <tgingold@free.fr>
5498 * MAINTAINERS (Misc): Update my email address.
5500 2017-10-04 Pedro Alves <palves@redhat.com>
5502 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
5503 it instead of target_gdbarch.
5504 (get_remote_state, get_remote_packet_size): Adjust
5505 get_remote_arch_state calls, passing down target_gdbarch
5507 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
5508 'gdbarch' and use it instead of target_gdbarch.
5509 (get_memory_packet_size): Adjust get_remote_arch_state calls,
5510 passing down target_gdbarch explicitly.
5511 (struct stop_reply) <arch>: New field.
5512 (remote_parse_stop_reply): Use the stopped thread's architecture,
5513 not the current inferior's. Save the architecture in the
5515 (process_stop_reply): Use the stop reply's architecture.
5516 (process_g_packet, remote_fetch_registers)
5517 (remote_prepare_to_store, store_registers_using_G)
5518 (remote_store_registers): Adjust get_remote_arch_state calls,
5519 using the regcache's architecture.
5520 (remote_get_trace_status): Adjust get_remote_arch_state calls,
5521 passing down target_gdbarch explicitly.
5522 * spu-multiarch.c (spu_thread_architecture): Defer to the target
5523 beneath instead of calling target_gdbarch.
5524 * target.c (default_thread_architecture): Use the specified
5525 inferior's architecture, instead of the current inferior's
5526 architecture (via target_gdbarch).
5528 2017-10-04 Pedro Alves <palves@redhat.com>
5530 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
5532 (regcache_print): Handle !target_has_registers here instead.
5534 2017-10-04 Pedro Alves <palves@redhat.com>
5536 * frame.c (create_test_frame): Delete.
5537 * frame.h (create_test_frame): Delete.
5538 * gdbarch-selftests.c: Include gdbthread.h and target.h.
5539 (class regcache_test): Delete.
5540 (test_target_has_registers, test_target_has_stack)
5541 (test_target_has_memory, test_target_prepare_to_store)
5542 (test_target_store_registers): New functions.
5543 (test_target_ops): New class.
5544 (register_to_value_test): Error out if there's already a
5545 process_stratum (or higher) target pushed. Create a fuller mock
5546 environment, with mock target_ops, inferior, address space, thread
5548 * progspace.c (struct address_space): Move to ...
5549 * progspace.h (struct address_space): ... here.
5550 * regcache.h (regcache::~regcache, regcache::raw_write)
5551 [GDB_SELF_TEST]: No longer virtual.
5553 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
5555 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
5557 2017-10-04 Pedro Alves <palves@redhat.com>
5559 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
5560 out of 'between TRY and CATCH'.
5562 2017-10-04 Pedro Alves <palves@redhat.com>
5564 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
5565 * common/common-exceptions.h (TRY): Open an outermost scope.
5566 Expand intro comment.
5568 (END_CATCH): Close the outermost scope.
5569 * completer.c (complete_line_internal): Add missing END_CATCH.
5571 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5573 * NEWS (Changes since GDB 8.0): Add entry about new
5574 'set-cwd-on-gdbserver' feature.
5575 (New remote packets): Add entry for QSetWorkingDir.
5576 * common/common-inferior.h (set_inferior_cwd): New prototype.
5577 * infcmd.c (set_inferior_cwd): Remove "static".
5578 (show_cwd_command): Expand text to include remote debugging.
5579 * remote.c: Add PACKET_QSetWorkingDir.
5580 (remote_protocol_features) <QSetWorkingDir>: New entry for
5581 PACKET_QSetWorkingDir.
5582 (extended_remote_set_inferior_cwd): New function.
5583 (extended_remote_create_inferior): Call
5584 "extended_remote_set_inferior_cwd".
5585 (_initialize_remote): Call "add_packet_config_cmd" for
5588 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5590 * NEWS (New commands): Mention "set/show cwd".
5591 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
5592 "cd" command's help text.
5593 * common/common-inferior.h (get_inferior_cwd): New prototype.
5594 * infcmd.c (inferior_cwd_scratch): New global variable.
5595 (set_inferior_cwd): New function.
5596 (get_inferior_cwd): Likewise.
5597 (set_cwd_command): Likewise.
5598 (show_cwd_command): Likewise.
5599 (_initialize_infcmd): Add "set/show cwd" commands.
5600 * inferior.h (class inferior) <cwd>: New field.
5601 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
5602 (fork_inferior): Change inferior's cwd before its execution.
5603 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
5606 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5608 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
5609 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
5610 (COMMON_OBS): Add gdb_tilde_expand.o.
5611 * common/gdb_tilde_expand.c: New file.
5612 * common/gdb_tilde_expand.h: Likewise.
5614 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
5616 * gdbarch.sh (objfile): Remove duplicate declaration.
5617 * gdbarch.h: Regenerate.
5619 2017-10-03 Tom Tromey <tom@tromey.com>
5621 * utils.c (internal_vproblem): Use string_vprintf.
5623 2017-10-03 Tom Tromey <tom@tromey.com>
5625 * printcmd.c (info_symbol_command): Use std::string.
5627 2017-10-03 Tom Tromey <tom@tromey.com>
5629 * top.c (gdb_safe_append_history): Use std::string.
5631 2017-10-03 Tom Tromey <tom@tromey.com>
5633 * event-top.c (stdin_event_handler): Update.
5634 * main.c (captured_main_1): Update.
5635 * top.h (make_delete_ui_cleanup): Remove.
5636 (struct ui): Add constructor and destructor.
5637 (new_ui, delete_ui): Remove.
5638 * top.c (make_delete_ui_cleanup): Remove.
5639 (new_ui_command): Use std::unique_ptr.
5640 (delete_ui_cleanup): Remove.
5641 (ui::ui): Rename from new_ui. Update.
5643 (ui::~ui): Rename from delete_ui. Update.
5645 2017-10-03 Tom Tromey <tom@tromey.com>
5647 * symfile.c (load_progress): Use gdb::byte_vector.
5649 2017-10-03 Tom Tromey <tom@tromey.com>
5651 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
5653 * printcmd.c (x_command): Remove unused declaration.
5654 * symfile.c (symbol_file_command): Remove unused declaration.
5656 2017-10-03 Tom Tromey <tom@tromey.com>
5658 * utils.c (internal_vproblem): Use std::string.
5659 (defaulted_query): Likewise.
5661 2017-10-03 Tom Tromey <tom@tromey.com>
5663 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
5664 * top.c (execute_command_to_string): Update.
5665 * utils.c (make_cleanup_restore_page_info): Remove.
5666 (do_restore_page_info_cleanup): Remove.
5667 (set_batch_flag_and_restore_page_info):
5669 (make_cleanup_restore_page_info): Remove.
5670 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5671 (~set_batch_flag_and_restore_page_info): New
5672 (make_cleanup_restore_uinteger): Remove.
5673 (make_cleanup_restore_integer): Remove.
5674 (struct restore_integer_closure): Remove.
5675 (restore_integer): Remove.
5676 * utils.h (struct set_batch_flag_and_restore_page_info): New
5678 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5679 (make_cleanup_restore_page_info): Remove.
5680 (make_cleanup_restore_uinteger) Remove.
5681 (make_cleanup_restore_integer) Remove.
5683 2017-10-03 Tom Tromey <tom@tromey.com>
5685 * record-full.h (record_full_gdb_operation_disable_set): Return
5686 scoped_restore_tmpl<int>.
5687 * infrun.c (adjust_pc_after_break): Update.
5688 (handle_signal_stop): Update.
5689 * record-full.c (record_full_gdb_operation_disable_set): Return
5690 scoped_restore_tmpl<int>.
5691 (record_full_wait_1, record_full_insert_breakpoint)
5692 (record_full_remove_breakpoint, record_full_save)
5693 (record_full_goto_insn): Update.
5695 2017-10-02 Tom Tromey <tom@tromey.com>
5698 * rust-lang.c (rust_val_print_str): New function.
5699 (val_print_struct): Call it.
5700 (rust_subscript): Preserve name of slice type.
5702 2017-10-02 Tom Tromey <tom@tromey.com>
5704 * rust-lang.c (rust_subscript): Handle slices in
5705 EVAL_AVOID_SIDE_EFFECTS case.
5707 2017-10-02 Tom Tromey <tom@tromey.com>
5709 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
5711 2017-10-02 Tom Tromey <tom@tromey.com>
5713 * rust-lang.h (rust_slice_type): Add "extern".
5715 2017-10-02 Tom Tromey <tom@tromey.com>
5716 Pedro Alves <palves@redhat.com>
5718 * ada-lang.h (ada_exc_info::operator<): Make const.
5719 (ada_exc_info::operator==): Make const.
5720 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
5723 2017-09-29 Tom Tromey <tom@tromey.com>
5725 * target.c (read_whatever_is_readable): Change type of "result".
5727 (free_memory_read_result_vector): Remove.
5728 (read_memory_robust): Change return type. Update.
5729 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
5730 bin2hex, std::string.
5731 * target.h (memory_read_result_s): Remove typedef.
5732 (free_memory_read_result_vector): Remove.
5733 (read_memory_robust): Return std::vector.
5735 2017-09-29 Tom Tromey <tom@tromey.com>
5737 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
5739 2017-09-29 Tom Tromey <tom@tromey.com>
5741 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
5742 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
5743 operator< and operator==.
5744 (ada_exceptions_list): Return a std::vector.
5745 * ada-lang.c (ada_exc_info::operator<): Rename from
5746 compare_ada_exception_info.
5747 (ada_exc_info::operator==): New.
5748 (sort_remove_dups_ada_exceptions_list): Change type of
5750 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
5751 (ada_add_global_exceptions): Likewise.
5752 (ada_exceptions_list_1): Return a std::vector.
5753 (ada_exceptions_list): Likewise.
5755 2017-09-29 Tom Tromey <tom@tromey.com>
5757 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
5759 (print_one_inferior): Update.
5760 (free_vector_of_ints): Remove.
5761 (list_available_thread_groups): Change "ids" to std::set.
5762 (mi_cmd_list_thread_groups): Update.
5763 (struct collect_cores_data) <core>: Now a std::set.
5764 (collect_cores): Update.
5766 (print_one_inferior): Update.
5768 2017-09-29 Tom Tromey <tom@tromey.com>
5770 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
5771 (mi_execute_async_cli_command): Likewise.
5772 (mi_cmd_trace_frame_collected): Use field_fmt.
5774 2017-09-29 Tom Tromey <tom@tromey.com>
5776 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
5779 2017-09-29 Tom Tromey <tom@tromey.com>
5781 * mi/mi-parse.c (mi_parse): Remove unused declaration.
5783 2017-09-29 Tom Tromey <tom@tromey.com>
5785 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
5787 2017-09-29 Tom Tromey <tom@tromey.com>
5789 * varobj.h (varobj_gen_name): Return std::string.
5790 * varobj.c (varobj_gen_name): Return std::string.
5791 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
5792 (mi_cmd_var_delete): Don't copy "name".
5794 2017-09-29 Tom Tromey <tom@tromey.com>
5796 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
5797 (mi_cmd_break_insert_1): Update.
5799 2017-09-29 Tom Tromey <tom@tromey.com>
5801 * target.h (make_scoped_defer_target_commit_resume): Update.
5802 * target.c (make_scoped_defer_target_commit_resume): Rename from
5803 make_cleanup_defer_target_commit_resume. Return a
5805 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
5807 2017-09-29 Tom Tromey <tom@tromey.com>
5809 * main.c (captured_main_1): Remove unused declaration.
5810 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
5812 2017-09-29 Tom Tromey <tom@tromey.com>
5814 * symtab.c (search_symbols): Remove unused outer cleanup.
5815 (make_source_files_completion_list): Remove unused declaration.
5817 2017-09-29 Tom Tromey <tom@tromey.com>
5819 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
5821 2017-09-29 Tom Tromey <tom@tromey.com>
5823 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
5826 2017-09-29 Tom Tromey <tom@tromey.com>
5828 * complaints.c (vcomplaint): Use std::string.
5830 2017-09-29 Tom Tromey <tom@tromey.com>
5832 * tracepoint.c (trace_variable_command): Use std::string.
5833 (encode_actions_1): Remove unused declarations.
5834 (create_tsv_from_upload): Use std::string.
5836 2017-09-29 Tom Tromey <tom@tromey.com>
5838 * cp-support.c (gdb_demangle): Use std::string.
5840 2017-09-29 Tom Tromey <tom@tromey.com>
5842 * stack.c (parse_frame_specification): Use std::string
5843 (info_frame_command): Use gdb::unique_xmalloc_ptr.
5845 2017-09-29 Tom Tromey <tom@tromey.com>
5847 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
5849 2017-09-29 Tom Tromey <tom@tromey.com>
5851 * utils.c (vfprintf_maybe_filtered): Use std::string.
5852 (vfprintf_unfiltered): Likewise.
5854 2017-09-29 Tom Tromey <tom@tromey.com>
5856 * event-top.c (top_level_prompt): Return std::string.
5857 (display_gdb_prompt): Update.
5859 2017-09-29 Tom Tromey <tom@tromey.com>
5861 * unittests/common-utils-selftests.c (format): New function.
5862 (string_vprintf_tests): New function.
5863 (_initialize_common_utils_selftests): Register new tests.
5864 * common/common-utils.c (string_vprintf): New function.
5865 * common/common-utils.h (string_vprintf): Declare.
5867 2017-09-29 Pedro Alves <palves@redhat.com>
5869 * common/rsp-low.c (unpack_varlen_hex): Constify.
5870 * common/rsp-low.h (unpack_varlen_hex): Constify.
5871 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
5873 * remote.c (remote_set_permissions, read_ptid)
5874 (remote_current_thread, remote_get_threads_with_qthreadinfo)
5875 (remote_static_tracepoint_marker_at)
5876 (remote_static_tracepoint_markers_by_strid)
5877 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
5878 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
5879 (parse_tracepoint_definition, parse_tsv_definition)
5880 (parse_static_tracepoint_marker_definition): Constify.
5881 * tracepoint.h (parse_static_tracepoint_marker_definition)
5882 (parse_trace_status, parse_tracepoint_status)
5883 (parse_tracepoint_definition, parse_tsv_definition): Constify.
5885 2017-09-29 Pedro Alves <palves@redhat.com>
5887 * remote.c (target_buf, target_buf_size): Delete.
5888 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
5889 Use the connection's packet buffer instead.
5890 All callers adjusted.
5891 (_initialize_remote): Remove references to target_buf and
5894 2017-09-28 Pedro Alves <palves@redhat.com>
5896 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5897 unittests/common-utils-selftests.c.
5898 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
5899 (COMMON_OBS): Remove utils-selftests.o.
5900 * utils-selftests.c: Move to ...
5901 * unittests/common-utils-selftests.c: ... here and rename self
5902 test to "string_printf".
5904 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
5906 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
5907 having NULL cus or tus.
5909 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5911 * arm-tdep.c: (convert_from_extended): Remove.
5912 (convert_to_extended): Likewise.
5913 (arm_extract_return_value): Use convert_typed_floating.
5914 (arm_store_return_value): Likewise.
5916 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5917 * sh-tdep.c: Do not include "floatformat.h".
5918 (sh_littlebyte_bigword_type): New function.
5919 (sh_register_convert_to_virtual): Use convert_typed_floating.
5920 (sh_register_convert_to_raw): Likewise.
5921 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5922 (sh64_littlebyte_bigword_type): New function.
5923 (sh64_extract_return_value): Use convert_typed_floating.
5924 (sh64_register_convert_to_virtual): Likewise.
5925 (sh64_register_convert_to_raw): Likewise.
5927 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5929 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
5930 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
5932 * gdbtypes.h (union type_specific): Make field floatformat hold
5933 just a single struct floatformat, not an array.
5934 (floatformat_from_type): Move here.
5935 * gdbtypes.c (floatformat_from_type): Move here. Update to
5936 changed TYPE_FLOATFORMAT definition.
5937 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
5938 (recursive_dump_type): Likewise.
5939 (init_float_type): Install correct floatformat for byte order.
5940 (arch_float_type): Likewise.
5942 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5944 * gdbtypes.c (init_type): Change incoming argument from
5945 length-in-bytes to length-in-bits. Assert length is a
5946 multiple of TARGET_CHAR_BITS.
5947 (arch_type, arch_flags_type): Likewise.
5948 (init_integer_type): Update call to init_type.
5949 (init_character_type): Likewise.
5950 (init_boolean_type): Likewise.
5951 (init_float_type): Likewise.
5952 (init_decfloat_type): Likewise.
5953 (init_complex_type): Likewise.
5954 (init_pointer_type): Likewise.
5955 (objfile_type): Likewise.
5956 (arch_integer_type): Update call to arch_type.
5957 (arch_character_type): Likewise.
5958 (arch_boolean_type): Likewise.
5959 (arch_float_type): Likewise.
5960 (arch_decfloat_type): Likewise.
5961 (arch_complex_type): Likewise.
5962 (arch_pointer_type): Likewise.
5963 (gdbtypes_post_init): Likewise.
5965 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
5966 (read_base_type): Likewise.
5967 * mdebugread.c (basic_type): Likewise.
5968 * stabsread.c (dbx_init_float_type): Likewise.
5969 (rs6000_builtin_type): Likewise.
5970 (read_range_type): Likewise. Also, fix call to init_integer_type
5971 with erroneous length argument.
5973 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
5974 * d-lang.c (build_d_types): Likewise.
5975 * f-lang.c (build_fortran_types): Likewise.
5976 * go-lang.c (build_go_types): Likewise.
5977 * opencl-lang.c (build_opencl_types): Likewise.
5978 * jit.c (finalize_symtab): Likewise.
5979 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
5980 (build_std_type_info_type): Likewise.
5981 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
5982 update call to arch_flags_type.
5984 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
5986 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
5987 * windows-tdep.c (windows_get_tlb_type): Likewise.
5989 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
5990 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5991 * m32c-tdep.c (make_types): Likewise.
5992 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
5993 (rl78_psw_type): Update call to arch_flags_type.
5994 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
5995 * rx-tdep.c (rx_psw_type): Likewise.
5996 (rx_fpsw_type): Likewise.
5997 * sparc-tdep.c (sparc_psr_type): Likewise.
5998 (sparc_fsr_type): Likewise.
5999 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
6000 (sparc64_ccr_type): Likewise.
6001 (sparc64_fsr_type): Likewise.
6002 (sparc64_fprs_type): Likewise.
6004 2017-09-27 Tom Tromey <tom@tromey.com>
6006 * findcmd.c (find_command): Constify.
6008 2017-09-27 Tom Tromey <tom@tromey.com>
6010 * ada-tasks.c (task_command_1, task_command): Constify.
6012 2017-09-27 Tom Tromey <tom@tromey.com>
6014 * symtab.c (maintenance_print_symbol_cache)
6015 (maintenance_flush_symbol_cache)
6016 (maintenance_print_symbol_cache_statistics): Constify.
6018 2017-09-27 Tom Tromey <tom@tromey.com>
6020 * inferior.c (detach_inferior_command, kill_inferior_command)
6021 (inferior_command): Constify.
6023 2017-09-27 Tom Tromey <tom@tromey.com>
6025 * regcache.c (regcache_print, maintenance_print_registers)
6026 (maintenance_print_raw_registers)
6027 (maintenance_print_cooked_registers)
6028 (maintenance_print_register_groups)
6029 (maintenance_print_remote_registers): Constify.
6031 2017-09-27 Tom Tromey <tom@tromey.com>
6033 * printcmd.c (map_display_numbers, undisplay_command)
6034 (enable_disable_display_command, enable_display_command)
6035 (disable_display_command): Constify.
6037 2017-09-27 Tom Tromey <tom@tromey.com>
6039 * breakpoint.h (delete_command): Don't declare.
6040 * breakpoint.c (delete_command, enable_once_command)
6041 (enable_count_command, enable_delete_command, breakpoint_1)
6042 (maintenance_info_breakpoints, stopin_command, stopat_command)
6043 (delete_command, delete_trace_command, save_breakpoints)
6044 (save_breakpoints_command, save_tracepoints_command): Constify.
6046 2017-09-27 Tom Tromey <tom@tromey.com>
6048 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6049 (skip_ws, extract_identifier, macro_define_command)
6050 (macro_undef_command, macro_list_command): Constify.
6052 2017-09-27 Tom Tromey <tom@tromey.com>
6054 * infcmd.c (environment_info, set_environment_command)
6055 (unset_environment_command, path_info, info_proc_cmd_1)
6056 (info_proc_cmd_mappings, info_proc_cmd_stat)
6057 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6058 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6060 2017-09-27 Tom Tromey <tom@tromey.com>
6062 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6065 2017-09-27 Tom Tromey <tom@tromey.com>
6067 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6069 2017-09-27 Tom Tromey <tom@tromey.com>
6071 * demangle.c (demangle_command): Constify.
6073 2017-09-27 Tom Tromey <tom@tromey.com>
6075 * progspace.c (maintenance_info_program_spaces_command):
6078 2017-09-27 Tom Tromey <tom@tromey.com>
6080 * compile/compile.c (check_raw_argument, compile_file_command)
6081 (compile_code_command, compile_print_command): Constify.
6083 2017-09-27 Tom Tromey <tom@tromey.com>
6085 * reggroups.c (maintenance_print_reggroups): Constify.
6087 2017-09-27 Tom Tromey <tom@tromey.com>
6089 * dwarf2read.c (save_gdb_index_command): Constify.
6091 2017-09-27 Tom Tromey <tom@tromey.com>
6093 * stap-probe.c (info_probes_stap_command): Constify.
6095 2017-09-27 Tom Tromey <tom@tromey.com>
6097 * fork-child.c (unset_exec_wrapper_command): Constify.
6099 2017-09-27 Tom Tromey <tom@tromey.com>
6101 * btrace.c (get_uint, get_context_size, no_chunk)
6102 (maint_btrace_packet_history_cmd)
6103 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6104 (maint_info_btrace_cmd): Constify.
6106 2017-09-27 Tom Tromey <tom@tromey.com>
6108 * reverse.c (delete_bookmark_command): Constify.
6110 2017-09-27 Tom Tromey <tom@tromey.com>
6112 * remote.c (set_memory_packet_size)
6113 (set_memory_write_packet_size, show_memory_write_packet_size)
6114 (set_memory_read_packet_size, show_memory_read_packet_size)
6115 (compare_sections_command, packet_command, remote_put_command)
6116 (remote_get_command, remote_delete_command): Constify.
6118 2017-09-27 Tom Tromey <tom@tromey.com>
6120 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6121 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6122 (set_mipsfpu_auto_command): Constify.
6124 2017-09-27 Tom Tromey <tom@tromey.com>
6126 * cli/cli-cmds.h (cd_command): Constify.
6127 * cli/cli-cmds.c (cd_command): Constify.
6129 2017-09-27 Tom Tromey <tom@tromey.com>
6131 * thread.c (thread_name_command, thread_find_command): Constify.
6133 2017-09-27 Tom Tromey <tom@tromey.com>
6135 * probe.c (enable_probes_command, disable_probes_command):
6138 2017-09-27 Tom Tromey <tom@tromey.com>
6140 * symfile.c (symbol_file_command): Constify.
6141 * gdbcore.h (deprecated_file_changed_hook): Constify.
6142 * exec.c (deprecated_file_changed_hook, exec_file_command)
6143 (file_command): Constify.
6144 * defs.h (symbol_file_command): Constify.
6146 2017-09-27 Tom Tromey <tom@tromey.com>
6148 * remote-fileio.c (set_system_call_allowed)
6149 (show_system_call_allowed): Constify.
6151 2017-09-27 Tom Tromey <tom@tromey.com>
6153 * tracepoint.c (delete_trace_variable_command)
6154 (tfind_end_command, tfind_start_command, tfind_pc_command)
6155 (tfind_tracepoint_command, tfind_line_command)
6156 (tfind_range_command, tfind_outside_command): Constify.
6158 2017-09-27 Tom Tromey <tom@tromey.com>
6160 * ax-gdb.c (maint_agent_printf_command, agent_command)
6161 (agent_eval_command): Constify.
6163 2017-09-27 Tom Tromey <tom@tromey.com>
6165 * tracepoint.c (info_scope_command): Constify.
6166 * python/python.c (gdbpy_decode_line): Constify.
6167 * python/py-breakpoint.c (bppy_init): Constify.
6168 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6169 * location.h: (new_linespec_location)
6170 (string_to_event_location_basic, string_to_event_location):
6172 * location.c (new_linespec_location)
6173 (string_to_event_location_basic, string_to_event_location):
6175 * linespec.h (decode_line_with_current_source)
6176 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6177 * linespec.c (linespec_lex_to_end)
6178 (decode_line_with_current_source)
6179 (decode_line_with_last_displayed): Constify.
6180 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6182 * cli/cli-cmds.c (edit_command, list_command): Constify.
6183 * breakpoint.h (until_break_command, watch_command_wrapper)
6184 (awatch_command_wrapper, rwatch_command_wrapper)
6185 (init_ada_exception_breakpoint): Constify.
6186 * breakpoint.c (break_command_1, dprintf_command)
6187 (break_range_command, watch_command_wrapper)
6188 (rwatch_command_wrapper, awatch_command_wrapper)
6189 (until_break_command, init_ada_exception_breakpoint)
6190 (strace_marker_create_sals_from_location, trace_command)
6191 (ftrace_command, strace_command, struct tracepoint): Constify.
6192 * ax-gdb.c (agent_command_1): Constify.
6193 * ada-lang.c (ada_exception_sal): Constify.
6195 2017-09-27 Tom Tromey <tom@tromey.com>
6197 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6198 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6199 (get_context_size, no_chunk, get_insn_history_modifiers)
6200 (cmd_record_insn_history, get_call_history_modifiers)
6201 (cmd_record_call_history): Constify.
6203 2017-09-27 Tom Tromey <tom@tromey.com>
6205 * source.c (show_substitute_path_command)
6206 (unset_substitute_path_command, set_substitute_path_command):
6209 2017-09-27 Tom Tromey <tom@tromey.com>
6211 * typeprint.c (maintenance_print_type): Constify.
6212 * maint.c (maintenance_dump_me, maintenance_demangle)
6213 (maintenance_time_display, maintenance_info_sections)
6214 (maintenance_print_statistics, maintenance_deprecate)
6215 (maintenance_undeprecate): Constify.
6216 (maintenance_do_deprecate): Constify. Use std::string.
6217 (maintenance_selftest): Constify.
6218 * gdbtypes.h (maintenance_print_type): Constify.
6220 2017-09-27 Tom Tromey <tom@tromey.com>
6222 * hppa-tdep.c (unwind_command): Constify.
6224 2017-09-27 Tom Tromey <tom@tromey.com>
6226 * target-descriptions.c (unset_tdesc_filename_cmd)
6227 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6230 2017-09-27 Tom Tromey <tom@tromey.com>
6232 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6234 2017-09-27 Tom Tromey <tom@tromey.com>
6236 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6238 2017-09-27 Tom Tromey <tom@tromey.com>
6240 * tui/tui-regs.c (tui_reg_command): Constify.
6242 2017-09-27 Tom Tromey <tom@tromey.com>
6244 * skip.c (skip_file_command, skip_function_command)
6245 (skip_enable_command, skip_disable_command, skip_delete_command):
6248 2017-09-27 Tom Tromey <tom@tromey.com>
6250 * record-btrace.c (cmd_record_btrace_bts_start)
6251 (cmd_record_btrace_pt_start): Constify.
6253 2017-09-27 Tom Tromey <tom@tromey.com>
6255 * symmisc.c (maintenance_print_symbols)
6256 (maintenance_print_msymbols, maintenance_print_objfiles)
6257 (maintenance_info_symtabs, maintenance_check_symtabs)
6258 (maintenance_expand_symtabs, maintenance_info_line_tables):
6261 2017-09-27 Tom Tromey <tom@tromey.com>
6263 * top.c (new_ui_command): Constify.
6265 2017-09-27 Tom Tromey <tom@tromey.com>
6267 * symfile.c (add_symbol_file_command)
6268 (remove_symbol_file_command, list_overlays_command)
6269 (map_overlay_command, unmap_overlay_command)
6270 (overlay_auto_command, overlay_manual_command)
6271 (overlay_off_command, overlay_load_command): Constify.
6273 2017-09-27 Tom Tromey <tom@tromey.com>
6275 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6276 (info_spu_mailbox_command, info_spu_dma_command)
6277 (info_spu_proxydma_command): Constify.
6279 2017-09-27 Tom Tromey <tom@tromey.com>
6281 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6283 2017-09-27 Tom Tromey <tom@tromey.com>
6285 * cli/cli-script.c (user_defined_command): Constify.
6287 2017-09-27 Tom Tromey <tom@tromey.com>
6289 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6290 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6291 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6292 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6293 (dump_binary_value, append_binary_memory, append_binary_value):
6295 (struct dump_context) <func>: Constify.
6296 (add_dump_command): Update.
6298 2017-09-27 Tom Tromey <tom@tromey.com>
6300 * cli/cli-cmds.c (show_version, show_configuration)
6301 (source_command, show_user): Constify.
6303 2017-09-27 Tom Tromey <tom@tromey.com>
6305 * target.c (maintenance_print_target_stack): Constify.
6307 2017-09-27 Tom Tromey <tom@tromey.com>
6309 * interps.c (interpreter_exec_cmd): Constify.
6311 2017-09-27 Tom Tromey <tom@tromey.com>
6313 * record-full.c (cmd_record_full_restore): Constify.
6315 2017-09-27 Tom Tromey <tom@tromey.com>
6317 * memattr.c (enable_mem_command, disable_mem_command)
6318 (delete_mem_command): Constify.
6320 2017-09-27 Tom Tromey <tom@tromey.com>
6322 * value.c (show_convenience): Constify.
6324 2017-09-27 Tom Tromey <tom@tromey.com>
6326 * gdbcore.h (core_file_command): Update.
6327 * corefile.c (core_file_command): Constify.
6329 2017-09-27 Tom Tromey <tom@tromey.com>
6331 * user-regs.c (maintenance_print_user_registers): Constify.
6333 2017-09-27 Tom Tromey <tom@tromey.com>
6335 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6337 2017-09-27 Tom Tromey <tom@tromey.com>
6339 * cp-support.c (first_component_command): Constify.
6341 2017-09-27 Tom Tromey <tom@tromey.com>
6343 * psymtab.c (maintenance_print_psymbols)
6344 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6347 2017-09-27 Tom Tromey <tom@tromey.com>
6349 * windows-tdep.c (display_tib): Constify.
6351 2017-09-27 Tom Tromey <tom@tromey.com>
6353 * linux-fork.c (delete_checkpoint_command)
6354 (detach_checkpoint_command): Constify.
6356 2017-09-27 Tom Tromey <tom@tromey.com>
6358 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6360 2017-09-27 Tom Tromey <tom@tromey.com>
6362 * arc-tdep.c (dump_arc_instruction_command): Constify.
6364 2017-09-27 Tom Tromey <tom@tromey.com>
6366 * valprint.c (set_radix, show_radix): Constify.
6368 2017-09-27 Tom Tromey <tom@tromey.com>
6370 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6372 2017-09-27 Tom Tromey <tom@tromey.com>
6374 * command.h (not_just_help_class_command): Update.
6375 * cli/cli-decode.h (not_just_help_class_command): Update.
6376 * cli/cli-decode.c (not_just_help_class_command): Constify.
6378 2017-09-27 Tom Tromey <tom@tromey.com>
6380 * gdb_bfd.c (maintenance_info_bfds): Constify.
6382 2017-09-27 Tom Tromey <tom@tromey.com>
6384 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6386 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6387 (do_const_cfunc): New function.
6388 (cmd_cfunc_eq): New overload.
6389 (cli_user_command_p): Check do_const_cfunc.
6390 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6392 * command.h (add_cmd): Add const overload and no-function
6394 (set_cmd_cfunc): Add const overload.
6395 (cmd_const_cfunc_ftype): Declare.
6396 (cmd_cfunc_eq): Add const overload.
6397 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
6398 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
6401 2017-09-27 Tom Tromey <tom@tromey.com>
6403 * macroexp.c (get_next_token_for_substitution): New function.
6404 (substitute_args): Call it. Check for __VA_OPT__.
6406 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6407 Pedro Alves <palves@redhat.com>
6409 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
6410 producer_is_icc_lt_14.
6411 (producer_is_icc_lt_14): New function.
6412 (check_producer): Add code for checking version of ICC.
6413 (producer_is_icc): Move to producer.c.
6414 (read_structure_type): Restrict ICC workaround to ICC<14.
6415 * producer.c: Include selftest.h.
6416 (producer_is_icc, producer_parsing_tests, _initialize_producer):
6418 * producer.h (producer_is_icc): New declaration.
6420 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6422 * Makefile.in (SFILES): Add producer.c.
6423 (COMMON_OBS): Add producer.o
6424 * amd64-tdep.c (producer.h): Add new include.
6425 * dwarf2read.c (producer.h): Add new include.
6426 * producer.c: New file.
6427 * producer.h: New file.
6428 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
6430 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
6433 2017-09-26 Matthias Klose <doko@ubuntu.com>
6435 * configure.ac: Search ncursesw before ncurses.
6436 Check ncursesw/ncurses.h before ncurses/ncurses.h.
6437 * gdb_curses.h: Include <ncursesw/ncurses.h>
6438 * config.in, configure: Regenerate.
6440 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6443 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
6445 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
6446 Remove i386sol2 support.
6447 * configure.nat <i386sol2>: Remove.
6448 <sol2-64>: Fold into ...
6450 Move common settings to default section.
6452 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
6453 x86_64-*-solaris2.1[0-9]*>: Rename to ...
6454 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
6455 <i[34567]86-*-solaris*>: Remove.
6456 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
6458 * configure.ac: Remove wctype in libw check.
6459 (_MSE_INT_H): Don't define on Solaris 7-9.
6460 <solaris*>: Remove libthread_db.so.1 check.
6461 * configure: Regenerate.
6462 * config.in: Regenerate.
6464 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
6465 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
6466 (gdb_ps_size_t): Remove.
6467 Use base types in users.
6468 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
6470 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
6472 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6475 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
6476 (adi_is_addr_mapped): Likewise.
6477 (PSR_ICC): Don't redefine.
6478 (PSR_IMPL): Likewise.
6480 2017-09-25 Tom Tromey <tom@tromey.com>
6482 * regcache.c (regcache::dump): Use string_printf.
6484 2017-09-25 Tom Tromey <tom@tromey.com>
6486 * regcache.c (class regcache_invalidator): New.
6487 (struct register_to_invalidate): Remove.
6488 (make_cleanup_regcache_invalidate): Remove.
6489 (regcache::raw_write): Use regcache_invalidator.
6491 2017-09-25 Tom Tromey <tom@tromey.com>
6493 * spu-tdep.c (spu2ppu_sniffer): Update.
6494 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
6495 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
6497 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
6498 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
6499 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
6500 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
6501 (frame_pop): Update.
6503 2017-09-25 Tom Tromey <tom@tromey.com>
6505 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
6506 * regcache.h (regcache_xfree): Don't declare.
6507 * regcache.c (regcache_xfree): Remove.
6508 (do_regcache_xfree): Use delete.
6509 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
6510 * linux-fork.c (free_fork): Use delete.
6511 (fork_save_infrun_state): Likewise.
6512 * jit.c (jit_dealloc_cache): Use delete.
6513 * infrun.c (discard_infcall_suspend_state): Use delete.
6515 2017-09-25 Tom Tromey <tom@tromey.com>
6517 * regcache.h (regcache_xmalloc): Don't declare.
6518 (regcache_raw_set_cached_value): Update comment.
6519 * regcache.c (regcache_xmalloc): Remove.
6520 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
6521 * jit.c (jit_frame_sniffer): Use new.
6522 * frame.c (frame_save_as_regcache): Use new.
6524 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6526 * NEWS: Advertise support for guarded-storage registers on IBM z.
6528 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6530 * s390-linux-nat.c (have_regset_gs): New static variable.
6531 (s390_linux_fetch_inferior_registers): Handle guarded-storage
6532 control block and guarded-storage broadcast control regsets.
6533 (s390_read_description): Detect whether the target has
6534 guarded-storage support, return appropriate tdesc.
6535 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
6536 (features/s390x-gs-linux64.c): Likewise.
6537 (struct gdbarch_tdep) <have_gs>: New field.
6538 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
6539 (s390_gsbc_regset): New variables.
6540 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
6541 and s390_gsbc_regset, if applicable.
6542 (s390_core_read_description): Check whether core file was from a
6543 target with guarded-storage support; include appropriate regsets.
6544 (s390_gdbarch_init): Add registers for guarded-storage support.
6545 (_initialize_s390_tdep): Initialize new target descriptions that
6546 include registers for guarded-storage support.
6547 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
6548 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
6549 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
6550 (S390_NUM_REGS): Adjust macro definition.
6551 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
6552 (tdesc_s390x_gs_linux64): New declarations.
6554 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6556 * features/s390-gs-linux64.xml: New file.
6557 * features/s390-gs.xml: New file.
6558 * features/s390-gsbc.xml: New file.
6559 * features/s390x-gs-linux64.xml: New file.
6560 * features/Makefile (WHICH): Add s390-gs-linux64 and
6562 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
6563 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
6564 * features/s390-gs-linux64.c: New generated file.
6565 * features/s390x-gs-linux64.c: New file.
6566 * regformats/s390-gs-linux64.dat: New file.
6567 * regformats/s390x-gs-linux64.dat: New file.
6569 2017-09-23 Tom Tromey <tom@tromey.com>
6571 * defs.h (make_cleanup_override_quit_handler): Don't declare.
6573 2017-09-22 Tom Tromey <tom@tromey.com>
6575 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
6576 type to scoped_restore_tmpl.
6577 <scoped_input_handler>: Initialize m_quit_handler directly.
6579 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6581 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
6582 (cd_command): Likewise. Free "current_directory" before
6584 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
6585 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
6586 * top.c (gdb_dirbuf): Remove global declaration.
6587 * top.h (gdb_dirbuf): Likewise.
6589 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6591 * gnulib/aclocal.m4: Regenerate.
6592 * gnulib/config.in: Regenerate.
6593 * gnulib/configure: Regenerate.
6594 * gnulib/import/Makefile.am: Regenerate.
6595 * gnulib/import/Makefile.in: Regenerate.
6596 * gnulib/import/assure.h: New file.
6597 * gnulib/import/at-func.c: Likewise
6598 * gnulib/import/chdir-long.c: New file.
6599 * gnulib/import/chdir-long.h: New file.
6600 * gnulib/import/cloexec.c: New file.
6601 * gnulib/import/cloexec.h: New file.
6602 * gnulib/import/close.c: New file.
6603 * gnulib/import/closedir.c: New file.
6604 * gnulib/import/dirent-private.h: New file.
6605 * gnulib/import/dup-safer.c: New file.
6606 * gnulib/import/dup.c: New file.
6607 * gnulib/import/dup2.c: New file.
6608 * gnulib/import/error.c: New file.
6609 * gnulib/import/error.h: New file.
6610 * gnulib/import/exitfail.c: New file.
6611 * gnulib/import/exitfail.h: New file.
6612 * gnulib/import/fchdir.c: New file.
6613 * gnulib/import/fcntl.c: New file.
6614 * gnulib/import/fcntl.in.h: New file.
6615 * gnulib/import/fd-hook.c: New file.
6616 * gnulib/import/fd-hook.h: New file.
6617 * gnulib/import/fd-safer.c: New file.
6618 * gnulib/import/fdopendir.c: New file.
6619 * gnulib/import/filename.h: New file.
6620 * gnulib/import/filenamecat-lgpl.c: New file.
6621 * gnulib/import/filenamecat.h: New file.
6622 * gnulib/import/fstat.c: New file.
6623 * gnulib/import/fstatat.c: New file.
6624 * gnulib/import/getcwd-lgpl.c: New file.
6625 * gnulib/import/getcwd.c: New file.
6626 * gnulib/import/getdtablesize.c: New file.
6627 * gnulib/import/getlogin_r.c: New file.
6628 * gnulib/import/getprogname.c: New file.
6629 * gnulib/import/getprogname.h: New file.
6630 * gnulib/import/gettext.h: New file.
6631 * gnulib/import/glob-libc.h: New file.
6632 * gnulib/import/glob.c: New file.
6633 * gnulib/import/glob.in.h: New file.
6634 * gnulib/import/intprops.h: New file.
6635 * gnulib/import/m4/chdir-long.m4: New file.
6636 * gnulib/import/m4/close.m4: New file.
6637 * gnulib/import/m4/closedir.m4: New file.
6638 * gnulib/import/m4/d-ino.m4: New file.
6639 * gnulib/import/m4/d-type.m4: New file.
6640 * gnulib/import/m4/dup.m4: New file.
6641 * gnulib/import/m4/dup2.m4: New file.
6642 * gnulib/import/m4/error.m4: New file.
6643 * gnulib/import/m4/fchdir.m4: New file.
6644 * gnulib/import/m4/fcntl.m4: New file.
6645 * gnulib/import/m4/fcntl_h.m4: New file.
6646 * gnulib/import/m4/fdopendir.m4: New file.
6647 * gnulib/import/m4/filenamecat.m4: New file.
6648 * gnulib/import/m4/fstat.m4: New file.
6649 * gnulib/import/m4/fstatat.m4: New file.
6650 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
6651 * gnulib/import/m4/getcwd-path-max.m4: New file.
6652 * gnulib/import/m4/getcwd.m4: New file.
6653 * gnulib/import/m4/getdtablesize.m4: New file.
6654 * gnulib/import/m4/getlogin_r.m4: New file.
6655 * gnulib/import/m4/getprogname.m4: New file.
6656 * gnulib/import/m4/glob.m4: New file.
6657 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
6658 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
6659 * gnulib/import/m4/mempcpy.m4: New file.
6660 * gnulib/import/m4/memrchr.m4: New file.
6661 * gnulib/import/m4/mode_t.m4: New file.
6662 * gnulib/import/m4/msvc-inval.m4: New file.
6663 * gnulib/import/m4/msvc-nothrow.m4: New file.
6664 * gnulib/import/m4/open.m4: New file.
6665 * gnulib/import/m4/openat.m4: New file.
6666 * gnulib/import/m4/opendir.m4: New file.
6667 * gnulib/import/m4/readdir.m4: New file.
6668 * gnulib/import/m4/realloc.m4: New file.
6669 * gnulib/import/m4/rewinddir.m4: New file.
6670 * gnulib/import/m4/save-cwd.m4: New file.
6671 * gnulib/import/m4/strdup.m4: New file.
6672 * gnulib/import/m4/strerror.m4: New file.
6673 * gnulib/import/m4/unistd-safer.m4: New file.
6674 * gnulib/import/mempcpy.c: New file.
6675 * gnulib/import/memrchr.c: New file.
6676 * gnulib/import/msvc-inval.c: New file.
6677 * gnulib/import/msvc-inval.h: New file.
6678 * gnulib/import/msvc-nothrow.c: New file.
6679 * gnulib/import/msvc-nothrow.h: New file.
6680 * gnulib/import/open.c: New file.
6681 * gnulib/import/openat-die.c: New file.
6682 * gnulib/import/openat-priv.h: New file.
6683 * gnulib/import/openat-proc.c: New file.
6684 * gnulib/import/openat.c: New file.
6685 * gnulib/import/openat.h: New file.
6686 * gnulib/import/opendir.c: New file.
6687 * gnulib/import/pipe-safer.c: New file.
6688 * gnulib/import/readdir.c: New file.
6689 * gnulib/import/realloc.c: New file.
6690 * gnulib/import/rewinddir.c: New file.
6691 * gnulib/import/save-cwd.c: New file.
6692 * gnulib/import/save-cwd.h: New file.
6693 * gnulib/import/strdup.c: New file.
6694 * gnulib/import/strerror-override.c: New file.
6695 * gnulib/import/strerror-override.h: New file.
6696 * gnulib/import/strerror.c: New file.
6697 * gnulib/import/unistd--.h: New file.
6698 * gnulib/import/unistd-safer.h: New file.
6699 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
6700 "getcwd" and "glob".
6701 * ser-tcp.c: Undefine "close" before redefining it.
6703 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6705 * guile/scm-value.c (gdbscm_value_address): Initialize address,
6708 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6710 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
6711 <sol2,sparc>: Likewise.
6712 <sol2-64,i386>: Likewise.
6714 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
6715 -Wdeprecated-declarations on *-*-solaris*.
6716 * configure: Regenerate.
6718 * procfs.c: Include "nat/inferior.h".
6719 (procfs_info_proc): Fix typo.
6721 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6723 * remote.c (vector): Include.
6724 (struct private_thread_info): Add field, thread_handle.
6725 (free_private_thread_info): Deallocate storage associated with
6727 (get_private_info_thread): Initialize `thread_handle' field.
6728 (struct thread_item): Add field, thread_handle.
6729 (clear_threads_listing_context): Deallocate storage associated
6731 (start_thread): Add support for "handle" attribute.
6732 (thread_attributes): Add "handle".
6733 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
6735 (remote_update_thread_list): Update thread_handle.
6736 (remote_thread_handle_to_thread_info): New function.
6737 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
6739 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6741 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
6743 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
6744 * python/python-internal.h (thread_object_type): Declare.
6746 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6748 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
6749 (target_thread_handle_to_thread_info): Declare.
6750 * target.c (target_thread_handle_to_thread_info): New function.
6751 * target-delegates.c: Regenerate.
6752 * gdbthread.h (find_thread_by_handle): Declare.
6753 * thread.c (find_thread_by_handle): New function.
6754 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
6756 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
6758 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6760 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
6762 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6764 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
6766 2017-09-21 Yao Qi <yao.qi@linaro.org>
6768 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
6771 2017-09-20 Tom Tromey <tom@tromey.com>
6773 * breakpoint.c (struct counted_command_line): Remove.
6774 (breakpoint_commands): Update.
6775 (alloc_counted_command_line, incref_counted_command_line)
6776 (decref_counted_command_line, do_cleanup_counted_command_line)
6777 (make_cleanup_decref_counted_command_line): Remove.
6778 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
6779 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
6780 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
6781 (save_breakpoints): Update.
6782 * breakpoint.h (counted_command_line): Now a typedef to
6784 (struct breakpoint) <commands>: Now a counted_command_line.
6785 (struct bpstats) <command>: Likewise.
6787 2017-09-20 Tom Tromey <tom@tromey.com>
6789 * breakpoint.c (struct commands_info, do_map_commands_command):
6791 (commands_command_1): Update.
6792 (iterate_over_related_breakpoints): Take a function_view.
6793 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
6794 (delete_command): Update.
6795 (map_breakpoint_numbers): Take a function_view.
6796 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
6797 (disable_command): Update.
6798 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
6799 (enable_command): Update.
6800 (struct disp_data, do_enable_breakpoint_disp)
6801 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
6802 (do_map_enable_delete_breakpoint): Remove.
6803 (enable_once_command, enable_count_command, enable_delete_command)
6804 (delete_trace_variable_command): Update.
6806 2017-09-20 Tom Tromey <tom@tromey.com>
6808 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
6809 (bpstat_clear): Use delete.
6810 (bpstats): New constructors.
6811 (bpstat_copy, bpstat_stop_status): Use new.
6812 (dprintf_after_condition_true): Update.
6813 * breakpoint.h (bpstats::bpstats): Add constructors.
6814 (bpstats::~bpstats): Add destructor.
6816 2017-09-20 Pedro Alves <palves@redhat.com>
6818 * eval.c (make_params): Delete, refactored as ...
6819 (class fake_method): ... this new type's ctor.
6820 (fake_method::~fake_method): New.
6821 (evaluate_subexp_standard): Use 'fake_method'.
6823 2017-09-20 Tom Tromey <tom@tromey.com>
6825 * windows-nat.c (get_windows_debug_event, windows_wait)
6826 (do_initial_windows_stuff, windows_attach): Update.
6827 * utils.c (vwarning, internal_vproblem): Update.
6828 (ui_unregister_input_event_handler_cleanup)
6829 (prepare_to_handle_input): Remove.
6830 (class scoped_input_handler): New.
6831 (defaulted_query, prompt_for_continue): Update.
6832 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
6834 * top.c (undo_terminal_modifications_before_exit): Update.
6835 * target/target.h (target_terminal_init, target_terminal_inferior)
6836 (target_terminal_ours): Don't declare.
6837 (class target_terminal): New.
6838 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
6839 (target_terminal_ours_for_output)
6840 (make_cleanup_restore_target_terminal): Don't declare.
6841 (target_terminal_info): Remove.
6842 * target.c (enum terminal_state, terminal_state): Remove.
6843 (target_terminal::terminal_state): Define.
6844 (target_terminal::init): Rename from target_terminal_init.
6845 (target_terminal::inferior): Rename from
6846 target_terminal_inferior.
6847 (target_terminal::ours): Rename from target_terminal_ours.
6848 (target_terminal::ours_for_output): Rename from
6849 target_terminal_ours_for_output.
6850 (target_terminal::info): New method.
6851 (cleanup_restore_target_terminal)
6852 (make_cleanup_restore_target_terminal): Remove.
6853 * solib.c (handle_solib_event): Update.
6854 * remote.c (remote_serial_quit_handler): Update.
6855 (remote_terminal_inferior, remote_wait_as): Update.
6856 * record-full.c (record_full_wait_1): Update.
6857 * nto-procfs.c (procfs_create_inferior): Update.
6858 * nat/fork-inferior.c (startup_inferior): Update.
6859 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
6860 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
6861 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
6862 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
6863 (mi_breakpoint_created, mi_breakpoint_deleted)
6864 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
6865 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6866 (mi_user_selected_context_changed, report_initial_inferior):
6868 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
6869 (linux_nat_terminal_inferior): Update.
6870 * infrun.c (follow_fork_inferior)
6871 (handle_vfork_child_exec_or_exit, do_target_resume)
6872 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
6873 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
6875 * inflow.c (child_terminal_init, info_terminal_command): Update.
6876 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
6877 (attach_command): Update.
6878 * infcall.c (call_thread_fsm_should_stop): Update.
6879 * gnu-nat.c (gnu_attach): Update.
6880 * extension.c (struct active_ext_lang_state)
6881 (restore_active_ext_lang): Update.
6882 * exceptions.c (print_flush): Update.
6883 * event-top.c (async_enable_stdin, default_quit_handler): Update.
6884 (struct quit_handler_cleanup_data, restore_quit_handler)
6885 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
6887 * cp-support.c (gdb_demangle): Update.
6888 * breakpoint.c (update_inserted_breakpoint_locations)
6889 (insert_breakpoint_locations, handle_jit_event)
6890 (disable_breakpoints_in_unloaded_shlib): Update.
6891 * annotate.c (annotate_breakpoints_invalid)
6892 (annotate_frames_invalid): Update.
6894 2017-09-20 Tom Tromey <tom@tromey.com>
6896 * main.c (catch_command_errors): Rename from
6897 catch_command_errors_const.
6898 (captured_main_1): Update.
6900 2017-09-20 Pedro Alves <palves@redhat.com>
6902 * cli/cli-cmds.c (list_command): Use print_sal_location.
6903 (print_sal_location): New function.
6904 (ambiguous_line_spec): Use print_sal_location.
6905 * linespec.c (symbol_to_sal): Record the symbol in the sal.
6906 * symtab.c (find_function_start_sal): Likewise.
6907 * symtab.h (symtab_and_line::symbol): New field.
6909 2017-09-20 Pedro Alves <palves@redhat.com>
6911 * linespec.c (minsym_found): Handle non-text minsyms.
6912 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
6914 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6916 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
6919 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6921 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
6922 vmovups instead vmovaps.
6923 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
6925 2017-09-19 John Baldwin <jhb@FreeBSD.org>
6927 * NEWS (Changes since GDB 8.0): Add starti.
6928 * infcmd.c (enum run_break): New.
6929 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
6931 (run_command): Use enum run_how.
6932 (start_command): Likewise.
6933 (starti_command): New function.
6934 (RUN_ARGS_HELP): New macro.
6935 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
6936 commands. Add starti command.
6938 2017-09-19 Yao Qi <yao.qi@linaro.org>
6940 * Makefile.in (monitor.o): Remove the rule.
6942 2017-09-19 Yao Qi <yao.qi@linaro.org>
6944 * annotate.h (struct annotate_arg_emitter): Use
6945 DISABLE_COPY_AND_ASSIGN.
6946 * common/refcounted-object.h (refcounted_object): Likewise.
6947 * completer.h (struct completion_result): Likewise.
6948 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
6949 * filename-seen-cache.h (filename_seen_cache): Likewise.
6950 * gdbcore.h (thread_section_name): Likewise.
6951 * gdb_regex.h (compiled_regex): Likewise.
6952 * gdbthread.h (scoped_restore_current_thread): Likewise.
6953 * inferior.h (scoped_restore_current_inferior): Likewise.
6954 * jit.c (jit_reader): Likewise.
6955 * linespec.h (struct linespec_result): Likewise.
6956 * mi/mi-parse.h (struct mi_parse): Likewise.
6957 * nat/fork-inferior.c (execv_argv): Likewise.
6958 * progspace.h (scoped_restore_current_program_space): Likewise.
6959 * python/python-internal.h (class gdbpy_enter): Likewise.
6960 * regcache.h (regcache): Likewise.
6961 * target-descriptions.c (struct tdesc_reg): Likewise.
6962 (struct tdesc_type): Likewise.
6963 (struct tdesc_feature): Likewise.
6964 * ui-out.h (ui_out_emit_type): Likewise.
6966 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
6968 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
6969 label abort_expression.
6971 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6973 * common/buffer.c (buffer_xml_printf): Adjust.
6974 * common/xml-utils.c (xml_escape_text): Change return type to
6975 std::string, update code accordingly.
6976 * common/xml-utils.h (xml_escape_text): Change return type to
6978 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
6979 * windows-tdep.c (windows_xfer_shared_library): Adjust.
6980 * unittests/xml-utils-selftests.c (test_xml_escape_text):
6983 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6985 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
6986 (SUBDIR_UNITTESTS_OBS): Add new object file.
6987 * unittests/xml-utils-selftests.c: New file.
6989 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6991 * common/selftest.h (selftest): New struct/interface.
6992 (register_test): Add name parameter, add new overload.
6993 (run_tests): Add filter parameter.
6994 (for_each_selftest_ftype): New typedef.
6995 (for_each_selftest): New declaration.
6996 * common/selftest.c (tests): Change type to
6997 map<string, unique_ptr<selftest>>.
6998 (simple_selftest): New struct.
6999 (register_test): New function.
7000 (register_test): Add name parameter and use it.
7001 (run_tests): Add filter parameter and use it. Add prints.
7002 Adjust to vector -> map change.
7003 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
7004 registering selftests.
7005 * arm-tdep.c (_initialize_arm_tdep): Likewise.
7006 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
7007 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
7008 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
7009 * findvar.c (_initialize_findvar): Likewise.
7010 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
7011 * maint.c (maintenance_selftest): Update call to run_tests.
7012 (maintenance_info_selftests): New function.
7013 (_initialize_maint_cmds): Register "maintenance info selftests"
7014 command. Update "maintenance selftest" doc.
7015 * regcache.c (_initialize_regcache): Add names when registering
7017 * rust-exp.y (_initialize_rust_exp): Likewise.
7018 * selftest-arch.c (gdbarch_selftest): New struct.
7019 (gdbarch_tests): Remove.
7020 (register_test_foreach_arch): Add name parameter. Call
7022 (tests_with_arch): Remove, move most content to
7023 gdbarch_selftest::operator().
7024 (_initialize_selftests_foreach_arch): Remove.
7025 * selftest-arch.h (register_test_foreach_arch): Add name
7027 (run_tests_with_arch): New declaration.
7028 * utils-selftests.c (_initialize_utils_selftests): Add names
7029 when registering selftests.
7030 * utils.c (_initialize_utils): Likewise.
7031 * unittests/array-view-selftests.c
7032 (_initialize_array_view_selftests): Likewise.
7033 * unittests/environ-selftests.c (_initialize_environ_selftests):
7035 * unittests/function-view-selftests.c
7036 (_initialize_function_view_selftests): Likewise.
7037 * unittests/offset-type-selftests.c
7038 (_initialize_offset_type_selftests): Likewise.
7039 * unittests/optional-selftests.c
7040 (_initialize_optional_selftests): Likewise.
7041 * unittests/scoped_restore-selftests.c
7042 (_initialize_scoped_restore_selftests): Likewise.
7043 * NEWS: Document "maintenance selftest" and "maint info
7046 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7048 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7051 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7053 * mi/mi-main.c (mi_load_progress): Make uiout variable
7056 2017-09-15 Pedro Alves <palves@redhat.com>
7058 * compile/compile-c-types.c (convert_enum, convert_int)
7059 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7061 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7063 * dwarf2read.c (copy_string): Remove.
7064 (parse_macro_definition): Replace copy_string with savestring.
7066 2017-09-15 Yao Qi <yao.qi@linaro.org>
7068 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7070 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7072 (i[34567]86-*-linux*): Likewise.
7074 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7076 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7077 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7078 <stack>: Change type to std::vector.
7079 <stack_len, stack_allocated>: Remove.
7080 <grow_stack>: Remove.
7081 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7082 (dwarf_expr_context::~dwarf_expr_context): Remove.
7083 (dwarf_expr_context::grow_stack): Remove.
7084 (dwarf_expr_context::push): Adjust.
7085 (dwarf_expr_context::pop): Adjust.
7086 (dwarf_expr_context::fetch): Adjust.
7087 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7088 (dwarf_expr_context::stack_empty_p): Adjust.
7089 (dwarf_expr_context::execute_stack_op): Adjust.
7091 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7093 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7094 return type to bool.
7095 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7097 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7099 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7100 Change type to bool.
7101 (dwarf_stack_value) <in_stack_memory>: Likewise.
7102 (dwarf_expr_context) <push_address>: Change parameter type to
7104 <fetch_in_stack_memory>: Change return type to bool.
7105 <push>: Change parameter type to bool.
7106 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7108 (dwarf_expr_context::push_address): Likewise.
7109 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7111 (dwarf_expr_context::execute_stack_op): Adjust.
7112 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7114 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7116 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7117 (struct dwarf_expr_context) <n_pieces>: Remove.
7118 <pieces>: Change type to std::vector.
7119 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7120 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7122 (dwarf_expr_context::add_piece): Adjust.
7123 * dwarf2loc.c (struct piece_closure): Initialize fields.
7125 <pieces>: Change type to std::vector.
7126 (allocate_piece_closure): Adjust, change parameter to
7127 std::vector rvalue and std::move it to piece_closure.
7128 (rw_pieced_value): Adjust.
7129 (check_pieced_synthetic_pointer): Adjust.
7130 (indirect_synthetic_pointer): Adjust.
7131 (coerce_pieced_ref): Adjust.
7132 (free_pieced_value_closure): Adjust. Use delete to free
7134 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7135 to allocate_piece_closure.
7136 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7138 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7140 * probe.h (probe_ops_cp): Remove typedef.
7141 (DEF_VEC_P (probe_ops_cp)): Remove.
7142 (all_probe_ops): Change type to std::vector.
7143 * probe.c (info_probes_for_ops): Adjust to vector change.
7144 (probe_linespec_to_ops): Likewise.
7145 (all_probe_ops): Change type to std::vector.
7146 (_initialize_probe): Adjust to vector change.
7147 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7148 * elfread.c (elf_get_probes): Likewise.
7149 * stap-probe.c (_initialize_stap_probe): Likewise.
7151 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7153 * probe.h (struct bound_probe): Define constructors.
7154 * probe.c (bound_probe_s): Remove typedef.
7155 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7156 (collect_probes): Change return type to std::vector, remove
7158 (compare_probes): Return bool, change parameter type. Change
7159 semantic to "less than".
7160 (gen_ui_out_table_header_info): Change parameter to std::vector
7162 (exists_probe_with_pops): Likewise.
7163 (info_probes_for_ops): Update to std::vector change.
7164 (enable_probes_command): Likewise.
7165 (disable_probes_command): Likewise.
7167 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7169 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7171 * probe.c (parse_probes_in_pspace): Update.
7172 (find_probes_in_objfile): Update.
7173 (find_probe_by_pc): Update.
7174 (collect_probes): Update.
7175 (probe_any_get_probes): Update.
7176 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7177 return type to reference to std::vector.
7178 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7179 std::vector and update.
7180 (dtrace_process_dof): Likewise.
7181 (dtrace_get_probes): Likewise.
7182 * elfread.c (elf_get_probes): Change return type to std::vector,
7183 store an std::vector in bfd_data.
7184 (probe_key_free): Update to std::vector.
7185 * stap-probe.c (handle_stap_probe): Change parameter to
7186 std::vector and update.
7187 (stap_get_probes): Likewise.
7188 * symfile-debug.c (debug_sym_get_probes): Change return type to
7189 std::vector and update.
7191 2017-09-11 Tom Tromey <tom@tromey.com>
7193 * breakpoint.c (program_breakpoint_here_p): Update.
7194 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7195 from make_show_memory_breakpoints_cleanup. Return a
7196 scoped_restore_tmpl<int>.
7197 (restore_show_memory_breakpoints): Remove.
7198 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7199 * mem-break.c (memory_validate_breakpoint): Update.
7200 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7201 (ia64_memory_remove_breakpoint): Update.
7202 (ia64_breakpoint_from_pc): Update.
7203 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7204 from make_show_memory_breakpoints_cleanup.
7206 2017-09-11 Tom Tromey <tom@tromey.com>
7208 * d-namespace.c (d_lookup_symbol): Use std::string.
7209 (find_symbol_in_baseclass): Likewise.
7211 2017-09-11 Tom Tromey <tom@tromey.com>
7213 * ctf.c (ctf_start): Use std::string.
7215 2017-09-11 Tom Tromey <tom@tromey.com>
7217 * ada-lang.c (is_known_support_routine): Update.
7218 (ada_unhandled_exception_name_addr_from_raise): Update.
7219 * guile/scm-frame.c (gdbscm_frame_name): Update.
7220 * python/py-frame.c (frapy_name): Update.
7221 (frapy_function): Update.
7222 * stack.h (find_frame_funname): Update.
7223 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7224 (print_frame): Update.
7226 2017-09-11 Tom Tromey <tom@tromey.com>
7228 * findcmd.c (put_bits): Take a gdb::byte_vector.
7229 (parse_find_args): Return gdb::byte_vector. "args" now const.
7230 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7232 (find_command): Update.
7234 2017-09-11 Tom Tromey <tom@tromey.com>
7236 * cli/cli-script.c (class scoped_restore_hook_in): New.
7237 (clear_hook_in_cleanup): Remove.
7238 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7239 scoped_restore_hook_in.
7241 2017-09-11 Tom Tromey <tom@tromey.com>
7243 * cli/cli-script.c (restore_interp): Remove.
7244 (read_command_lines): Use scoped_restore_interp.
7245 * interps.c (scoped_restore_interp::set_temp): Rename from
7247 * interps.h (class scoped_restore_interp): New.
7248 (interp_set_temp): Remove.
7250 2017-09-11 Tom Tromey <tom@tromey.com>
7252 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7253 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7254 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7256 (mi_cmd_break_insert_1): Update.
7257 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7260 2017-09-11 Tom Tromey <tom@tromey.com>
7262 * demangle.c (demangle_command): Update.
7263 * breakpoint.c (disable_command): Update.
7264 (enable_command): Update.
7265 (find_location_by_number): Make "number" const. Use
7267 * cli/cli-utils.c (extract_arg): Return std::string.
7268 * probe.c (parse_probe_linespec): Update. Change types.
7269 (collect_probes): Take string arguments.
7270 (parse_probe_linespec): Likewise.
7271 (info_probes_for_ops): Update.
7272 (enable_probes_command): Update.
7273 (disable_probes_command): Update.
7274 * break-catch-sig.c (catch_signal_split_args): Update.
7275 * mi/mi-parse.c (mi_parse): Update.
7277 2017-09-11 Tom Tromey <tom@tromey.com>
7279 * language.h (language_enum): Make argument const.
7280 * language.c (language_enum): Make argument const.
7282 2017-09-11 Tom Tromey <tom@tromey.com>
7284 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7286 (skip_to_space): Rename from skip_to_space_const.
7287 * common/common-utils.c (skip_to_space): New function.
7288 (skip_to_space): Rename from skip_to_space_const.
7289 * cli/cli-utils.h (get_number): Rename from get_number_const.
7290 (extract_arg): Rename from extract_arg_const.
7291 * cli/cli-utils.c (get_number): Rename from get_number_const.
7292 (extract_arg): Rename from extract_arg_const.
7293 (number_or_range_parser::get_number): Use ::get_number.
7294 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7295 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7296 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7297 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7298 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7299 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7300 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7301 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7303 2017-09-11 Tom Tromey <tom@tromey.com>
7305 * python/python.c (do_start_initialization): Use
7306 py-event-types.def to initialize types.
7307 Define all object type structures.
7308 * python/python-internal.h: Don't declare event initialization
7310 * python/py-threadevent.c (thread_event_object_type): Don't
7312 * python/py-stopevent.c (stop_event_object_type): Don't define.
7313 * python/py-signalevent.c (signal_event_object_type): Don't
7315 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7316 (clear_objfiles_event_object_type): Don't declare or define.
7317 * python/py-infevents.c (inferior_call_pre_event_object_type)
7318 (inferior_call_post_event_object_type)
7319 (register_changed_event_object_type)
7320 (memory_changed_event_object_type): Don't declare or define.
7321 * python/py-inferior.c (new_thread_event_object_type)
7322 (new_inferior_event_object_type)
7323 (inferior_deleted_event_object_type): Don't declare or define.
7324 * python/py-exitedevent.c (exited_event_object_type): Don't
7326 * python/py-evts.c (gdbpy_initialize_py_events): Use
7328 * python/py-events.h (thread_event_object_type): Don't declare.
7329 (events_object): Use py-all-events.def.
7330 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7332 * python/py-event-types.def: New file.
7333 * python/py-continueevent.c (create_continue_event_object): Don't
7335 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7337 * python/py-all-events.def: New file.
7339 2017-09-11 Tom Tromey <tom@tromey.com>
7341 * python/py-threadevent.c (create_thread_event_object): Return
7343 * python/py-stopevent.h (create_stop_event_object)
7344 (create_breakpoint_event_object, create_signal_event_object):
7346 * python/py-stopevent.c (create_stop_event_object): Return
7348 (emit_stop_event): Update.
7349 * python/py-signalevent.c (create_signal_event_object): Return
7351 * python/py-infevents.c (create_inferior_call_event_object):
7353 * python/py-event.h (create_event_object)
7354 (create_thread_event_object): Update.
7355 * python/py-event.c (create_event_object): Return gdbpy_ref.
7356 * python/py-continueevent.c: Return gdbpy_ref.
7357 * python/py-bpevent.c (create_breakpoint_event_object): Return
7360 2017-09-11 Tom Tromey <tom@tromey.com>
7364 * python/python.c (do_start_initialization): Initialize new event
7366 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7367 (gdbpy_initialize_inferior_deleted_event)
7368 (gdbpy_initialize_new_thread_event): Declare.
7369 * python/py-threadevent.c (create_thread_event_object): Add option
7371 * python/py-inferior.c (new_thread_event_object_type)
7372 (new_inferior_event_object_type)
7373 (inferior_deleted_event_object_type): Declare.
7374 (python_new_inferior, python_inferior_deleted): New functions.
7375 (add_thread_object): Emit new_thread event.
7376 (gdbpy_initialize_inferior): Attach new functions to corresponding
7378 (new_thread, new_inferior, inferior_deleted): Define new event
7380 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7382 * python/py-events.h (events_object) <new_inferior,
7383 inferior_deleted, new_thread>: New fields.
7384 * python/py-event.h (create_thread_event_breakpoint): Add optional
7387 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7389 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7390 check current_ui instead.
7391 (internal_vproblem): Likewise.
7393 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7395 * thread.c (print_thread_info_1): Remove unnecessary calls to
7396 uiout->is_mi_like_p.
7398 2017-09-09 Tom Tromey <tom@tromey.com>
7400 * namespace.h (add_using_directive): Update.
7401 * namespace.c (add_using_directive): Change type of excludes to
7403 * dwarf2read.c (read_import_statement): Use std::vector.
7404 (read_namespace): Update.
7405 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
7407 2017-09-09 Tom Tromey <tom@tromey.com>
7409 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
7411 2017-09-09 Tom Tromey <tom@tromey.com>
7413 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
7415 2017-09-09 Tom Tromey <tom@tromey.com>
7417 * stack.c (func_command): Use gdb::def_vector.
7419 2017-09-09 Tom Tromey <tom@tromey.com>
7421 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
7422 ui_out_emit_list, ui_out_emit_tuple.
7423 (mi_cmd_var_update): Likewise.
7425 2017-09-09 Tom Tromey <tom@tromey.com>
7427 * mi/mi-interp.c (mi_user_selected_context_changed): Use
7428 ui_out_redirect_pop.
7429 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7430 ui_out_redirect_pop.
7431 * utils.c (do_ui_out_redirect_pop)
7432 (make_cleanup_ui_out_redirect_pop): Remove.
7433 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
7434 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
7435 * ui-out.h (ui_out_redirect_pop): New class.
7437 2017-09-09 Tom Tromey <tom@tromey.com>
7439 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
7440 (list_available_thread_groups, mi_cmd_list_thread_groups)
7441 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
7442 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
7445 2017-09-09 Tom Tromey <tom@tromey.com>
7447 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
7450 2017-09-09 Tom Tromey <tom@tromey.com>
7452 * target.c (flash_erase_command): Use ui_out_emit_tuple.
7453 * stack.c (print_frame): Use ui_out_emit_tuple.
7454 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
7455 (info_spu_mailbox_command, info_spu_dma_command)
7456 (info_spu_proxydma_command): Likewise.
7457 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
7458 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
7459 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7461 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
7463 2017-09-09 Tom Tromey <tom@tromey.com>
7465 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
7466 (class ui_out_emit_table): Update comment.
7467 * ui-out.c (do_cleanup_table_end)
7468 (make_cleanup_ui_out_table_begin_end): Remove.
7469 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
7470 (info_spu_dma_cmdlist): Likewise.
7471 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
7472 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
7475 2017-09-09 Tom Tromey <tom@tromey.com>
7477 * thread.c (print_thread_info_1): Use ui_out_emit_table,
7478 ui_out_emit_list, gdb::optional.
7480 2017-09-09 John Baldwin <jhb@FreeBSD.org>
7482 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
7484 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
7486 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
7488 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
7489 * ada-exp.y: Remove _initialize_ada_exp prototype.
7490 * ada-lang.c: Remove _initialize_ada_language prototype.
7491 * ada-tasks.c: Remove _initialize_tasks prototype.
7492 * addrmap.c: Remove _initialize_addrmap prototype.
7493 * agent.c: Remove _initialize_agent prototype.
7494 * aix-thread.c: Remove _initialize_aix_thread prototype.
7495 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
7496 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
7497 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
7499 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
7500 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
7501 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
7502 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
7504 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
7506 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
7507 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
7508 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
7509 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
7511 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
7512 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
7513 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
7514 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
7515 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7516 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
7517 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
7519 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
7521 * annotate.c: Remove _initialize_annotate prototype.
7522 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
7523 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
7524 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
7525 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
7526 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
7527 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
7528 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
7529 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
7531 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
7532 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
7533 * auto-load.c: Remove _initialize_auto_load prototype.
7534 * auxv.c: Remove _initialize_auxv prototype.
7535 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
7536 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
7537 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
7538 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
7539 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
7540 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
7542 * break-catch-throw.c: Remove _initialize_break_catch_throw
7544 * breakpoint.c: Remove _initialize_breakpoint prototype.
7545 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
7546 * btrace.c: Remove _initialize_btrace prototype.
7547 * charset.c: Remove _initialize_charset prototype.
7548 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
7549 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
7550 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
7551 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
7552 * cli/cli-script.c: Remove _initialize_cli_script prototype.
7553 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
7554 * coffread.c: Remove _initialize_coffread prototype.
7555 * compile/compile.c: Remove _initialize_compile prototype.
7556 * complaints.c: Remove _initialize_complaints prototype.
7557 * completer.c: Remove _initialize_completer prototype.
7558 * copying.awk: Remove _initialize_copying prototype.
7559 * copying.c: Regenerate.
7560 * core-regset.c: Remove _initialize_core_regset prototype.
7561 * corefile.c: Remove _initialize_core prototype.
7562 * corelow.c: Remove _initialize_corelow prototype.
7563 * cp-abi.c: Remove _initialize_cp_abi prototype.
7564 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
7565 * cp-support.c: Remove _initialize_cp_support prototype.
7566 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
7567 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
7568 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
7569 * ctf.c: Remove _initialize_ctf prototype.
7570 * d-lang.c: Remove _initialize_d_language prototype.
7571 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
7573 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
7574 * dbxread.c: Remove _initialize_dbxread prototype.
7575 * dcache.c: Remove _initialize_dcache prototype.
7576 * demangle.c: Remove _initialize_demangler prototype.
7577 * disasm-selftests.c: Remove _initialize_disasm_selftests
7579 * disasm.c: Remove _initialize_disasm prototype.
7580 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
7581 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
7582 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
7584 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
7585 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
7586 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
7587 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
7588 * elfread.c: Remove _initialize_elfread prototype.
7589 * exec.c: Remove _initialize_exec prototype.
7590 * extension.c: Remove _initialize_extension prototype.
7591 * f-lang.c: Remove _initialize_f_language prototype.
7592 * f-valprint.c: Remove _initialize_f_valprint prototype.
7593 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
7594 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
7595 * filesystem.c: Remove _initialize_filesystem prototype.
7596 * findcmd.c: Remove _initialize_mem_search prototype.
7597 * fork-child.c: Remove _initialize_fork_child prototype.
7598 * frame-base.c: Remove _initialize_frame_base prototype.
7599 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
7600 * frame.c: Remove _initialize_frame prototype.
7601 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
7602 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
7603 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
7604 * gcore.c: Remove _initialize_gcore prototype.
7605 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
7606 * gdbarch.c: Regenerate.
7607 * gdbarch.sh: Remove _initialize_gdbarch prototype.
7608 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
7609 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
7610 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
7611 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
7612 * go-lang.c: Remove _initialize_go_language prototype.
7613 * go32-nat.c: Remove _initialize_go32_nat prototype.
7614 * guile/guile.c: Remove _initialize_guile prototype.
7615 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
7616 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
7617 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
7618 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
7619 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
7620 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
7621 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
7622 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
7623 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
7624 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
7626 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
7628 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
7629 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
7630 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
7631 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
7632 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
7633 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
7634 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
7635 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
7636 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
7637 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
7638 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
7639 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
7640 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
7641 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7642 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
7643 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
7645 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
7647 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
7648 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
7649 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
7650 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
7651 * infcall.c: Remove _initialize_infcall prototype.
7652 * infcmd.c: Remove _initialize_infcmd prototype.
7653 * inferior.c: Remove _initialize_inferiors prototype.
7654 * inflow.c: Remove _initialize_inflow prototype.
7655 * infrun.c: Remove _initialize_infrun prototype.
7656 * interps.c: Remove _initialize_interpreter prototype.
7657 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
7658 * jit.c: Remove _initialize_jit prototype.
7659 * language.c: Remove _initialize_language prototype.
7660 * linux-fork.c: Remove _initialize_linux_fork prototype.
7661 * linux-nat.c: Remove _initialize_linux_nat prototype.
7662 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
7663 * linux-thread-db.c: Remove _initialize_thread_db prototype.
7664 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
7665 * m2-lang.c: Remove _initialize_m2_language prototype.
7666 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
7667 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
7668 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
7669 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
7670 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
7671 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7672 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7673 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
7674 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
7675 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
7676 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7677 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7678 * machoread.c: Remove _initialize_machoread prototype.
7679 * macrocmd.c: Remove _initialize_macrocmd prototype.
7680 * macroscope.c: Remove _initialize_macroscope prototype.
7681 * maint.c: Remove _initialize_maint_cmds prototype.
7682 * mdebugread.c: Remove _initialize_mdebugread prototype.
7683 * memattr.c: Remove _initialize_mem prototype.
7684 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
7685 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
7686 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
7687 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
7688 * mi/mi-main.c: Remove _initialize_mi_main prototype.
7689 * microblaze-linux-tdep.c: Remove
7690 _initialize_microblaze_linux_tdep prototype.
7691 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
7692 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
7693 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
7694 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
7695 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
7696 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
7697 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
7698 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
7699 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
7700 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
7701 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
7703 * mipsread.c: Remove _initialize_mipsread prototype.
7704 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
7706 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
7707 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
7708 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
7709 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
7710 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
7711 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
7713 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
7714 * nto-procfs.c: Remove _initialize_procfs prototype.
7715 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
7716 * objc-lang.c: Remove _initialize_objc_language prototype.
7717 * objfiles.c: Remove _initialize_objfiles prototype.
7718 * observer.c: Remove observer_test_first_notification_function,
7719 observer_test_second_notification_function,
7720 observer_test_third_notification_function, and
7721 _initialize_observer prototypes.
7722 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
7723 * osabi.c: Remove _initialize_gdb_osabi prototype.
7724 * osdata.c: Remove _initialize_osdata prototype.
7725 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
7726 * parse.c: Remove _initialize_parse prototype.
7727 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
7728 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
7729 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
7730 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
7731 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
7732 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
7733 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
7734 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
7735 * printcmd.c: Remove _initialize_printcmd prototype.
7736 * probe.c: Remove _initialize_probe prototype.
7737 * proc-api.c: Remove _initialize_proc_api prototype.
7738 * proc-events.c: Remove _initialize_proc_events prototype.
7739 * proc-service.c: Remove _initialize_proc_service prototype.
7740 * procfs.c: Remove _initialize_procfs prototype.
7741 * psymtab.c: Remove _initialize_psymtab prototype.
7742 * python/python.c: Remove _initialize_python prototype.
7743 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
7744 * record-btrace.c: Remove _initialize_record_btrace prototype.
7745 * record-full.c: Remove _initialize_record_full prototype.
7746 * record.c: Remove _initialize_record prototype.
7747 * regcache.c: Remove _initialize_regcache prototype.
7748 * reggroups.c: Remove _initialize_reggroup prototype.
7749 * remote-notif.c: Remove _initialize_notif prototype.
7750 * remote-sim.c: Remove _initialize_remote_sim prototype.
7751 * remote.c: Remove _initialize_remote prototype.
7752 * reverse.c: Remove _initialize_reverse prototype.
7753 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
7754 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
7755 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
7757 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
7758 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
7759 * rust-exp.y: Remove _initialize_rust_exp prototype.
7760 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
7761 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
7762 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
7763 * score-tdep.c: Remove _initialize_score_tdep prototype.
7764 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
7766 * ser-go32.c: Remove _initialize_ser_dos prototype.
7767 * ser-mingw.c: Remove _initialize_ser_windows prototype.
7768 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
7769 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
7770 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
7771 * serial.c: Remove _initialize_serial prototype.
7772 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
7773 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
7774 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
7775 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
7776 * skip.c: Remove _initialize_step_skip prototype.
7777 * sol-thread.c: Remove _initialize_sol_thread prototype.
7778 * solib-aix.c: Remove _initialize_solib_aix prototype.
7779 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
7780 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
7781 * solib-frv.c: Remove _initialize_frv_solib prototype.
7782 * solib-spu.c: Remove _initialize_spu_solib prototype.
7783 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
7784 * solib-target.c: Remove _initialize_solib_target prototype.
7785 * solib.c: Remove _initialize_solib prototype.
7786 * source.c: Remove _initialize_source prototype.
7787 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
7788 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
7790 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
7791 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
7792 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
7793 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
7795 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
7796 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
7797 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
7798 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
7800 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
7802 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
7804 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
7806 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
7807 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
7809 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
7811 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
7813 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
7815 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
7817 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
7818 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
7819 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
7820 * stabsread.c: Remove _initialize_stabsread prototype.
7821 * stack.c: Remove _initialize_stack prototype.
7822 * stap-probe.c: Remove _initialize_stap_probe prototype.
7823 * std-regs.c: Remove _initialize_frame_reg prototype.
7824 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
7825 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
7826 * symfile.c: Remove _initialize_symfile prototype.
7827 * symmisc.c: Remove _initialize_symmisc prototype.
7828 * symtab.c: Remove _initialize_symtab prototype.
7829 * target-dcache.c: Remove _initialize_target_dcache prototype.
7830 * target-descriptions.c: Remove _initialize_target_descriptions
7832 * thread.c: Remove _initialize_thread prototype.
7833 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
7835 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
7836 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
7837 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
7839 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
7840 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
7841 * tracefile.c: Remove _initialize_tracefile prototype.
7842 * tracepoint.c: Remove _initialize_tracepoint prototype.
7843 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
7844 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
7845 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
7846 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
7847 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
7848 * tui/tui-win.c: Remove _initialize_tui_win prototype.
7849 * tui/tui.c: Remove _initialize_tui prototype.
7850 * typeprint.c: Remove _initialize_typeprint prototype.
7851 * user-regs.c: Remove _initialize_user_regs prototype.
7852 * utils.c: Remove _initialize_utils prototype.
7853 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
7854 * valarith.c: Remove _initialize_valarith prototype.
7855 * valops.c: Remove _initialize_valops prototype.
7856 * valprint.c: Remove _initialize_valprint prototype.
7857 * value.c: Remove _initialize_values prototype.
7858 * varobj.c: Remove _initialize_varobj prototype.
7859 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
7860 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
7861 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
7862 * windows-nat.c: Remove _initialize_windows_nat,
7863 _initialize_check_for_gdb_ini, and _initialize_loadable
7865 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
7866 * xcoffread.c: Remove _initialize_xcoffread prototype.
7867 * xml-support.c: Remove _initialize_xml_support prototype.
7868 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
7869 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
7871 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
7873 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
7875 2017-09-08 Keith Seitz <keiths@redhat.com>
7877 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
7880 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
7882 * f-valprint.c (f_val_print): Remove check for one byte
7883 sized integers. Remove printing of character type.
7885 2017-09-08 Frank Penczek <frank.penczek@intel.com>
7886 Christoph Weinmann <christoph.t.weinmann@intel.com>
7887 Bernhard Heckel <bernhard.heckel@intel.com>
7889 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
7890 to maintain proper indentation when printing pointers/refs.
7892 2017-09-07 Joel Brobecker <brobecker@adacore.com>
7896 2017-09-07 Joel Brobecker <brobecker@adacore.com>
7898 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
7900 2017-09-05 Tom Tromey <tom@tromey.com>
7902 * parse.c (funcall_chain): Now a std::vector.
7903 (start_arglist, end_arglist): Simplify.
7904 (free_funcalls): Remove.
7905 (parse_exp_in_context_1): Remove cleanup.
7907 2017-09-05 Tom Tromey <tom@tromey.com>
7909 * go-exp.y (go_parse): Don't create a cleanup.
7911 2017-09-05 Tom Tromey <tom@tromey.com>
7913 * d-exp.y (PrimaryExpression): Use std::string.
7914 (d_parse): Don't create a cleanup.
7916 2017-09-05 Tom Tromey <tom@tromey.com>
7918 * utils.c (do_clear_parser_state): Remove.
7919 (make_cleanup_clear_parser_state): Remove.
7920 * p-exp.y (pascal_parse): Use scoped_restore.
7921 * m2-exp.y (m2_parse): Use scoped_restore.
7922 * f-exp.y (f_parse): Use scoped_restore.
7923 * d-exp.y (d_parse): Use scoped_restore.
7924 * c-exp.y (c_parse): Use scoped_restore.
7925 * ada-exp.y (ada_parse): Use scoped_restore.
7926 * utils.h (make_cleanup_clear_parser_state): Remove.
7928 2017-09-06 Keith Seitz <keiths@redhat.com>
7930 * dwarf2read.c (dw2_linkage_name_attr): New function.
7931 (dw2_linkage_name): New function.
7932 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
7933 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
7934 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
7936 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7938 * config/djgpp/djconfig.sh: Correct shell portability issue.
7940 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7942 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
7944 2017-09-06 John Baldwin <jhb@FreeBSD.org>
7946 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
7947 * NEWS: Mention new FreeBSD/mips native configuration.
7948 * configure.host: Add aarch64*-*-freebsd*.
7949 * configure.nat: Likewise.
7950 * aarch64-fbsd-nat.c: New file.
7952 2017-09-06 John Baldwin <jhb@FreeBSD.org>
7954 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
7955 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
7956 * NEWS: Mention new FreeBSD/aarch64 target.
7957 * configure.tgt: Add aarch64*-*-freebsd*.
7958 * aarch64-fbsd-tdep.c: New file.
7959 * aarch64-fbsd-tdep.h: New file.
7961 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7963 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
7965 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7967 * parse.c (find_minsym_type_and_address): Don't relocate addresses
7970 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7972 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
7975 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7977 * infrun.c (follow_exec): Call add_thread after
7978 target_find_description.
7980 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7982 * infrun.c (handle_inferior_event_1): When exec'ing, read
7983 stop_pc after follow_exec.
7985 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7987 * remote.c (process_g_packet): Update error message.
7989 2017-09-05 Yao Qi <yao.qi@linaro.org>
7991 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
7994 2017-09-05 Pedro Alves <palves@redhat.com>
7996 * eval.c (eval_call, evaluate_funcall): New functions, factored
7998 (evaluate_subexp_standard): ... this.
8000 2017-09-05 Yao Qi <yao.qi@linaro.org>
8002 * amd64-tdep.c (amd64_target_description): Create target
8004 (_initialize_amd64_tdep): Don't call functions
8005 initialize_tdesc_amd64_*. Add self tests.
8006 * arch/amd64.c (amd64_create_target_description): Add parameter
8007 is_linux. Call set_tdesc_osabi if is_linux is true.
8008 * arch/amd64.h (amd64_create_target_description): Update the
8010 * arch/i386.c (i386_create_target_description): Add parameter
8011 is_linux. Call set_tdesc_osabi if is_linux is true.
8012 * arch/i386.h (i386_create_target_description): Update
8014 * configure.tgt: Add i386.o to gdb_target_obs.
8015 * features/Makefile (XMLTOC): Remove i386/*.xml.
8016 * features/i386/amd64-avx-avx512.c: Remove.
8017 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
8018 * features/i386/amd64-avx-mpx.c: Remove.
8019 * features/i386/amd64-avx.c: Remove.
8020 * features/i386/amd64-mpx.c: Remove.
8021 * features/i386/amd64.c: Remove.
8022 * features/i386/i386-avx-avx512.c: Remove.
8023 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
8024 * features/i386/i386-avx-mpx.c: Remove.
8025 * features/i386/i386-avx.c: Remove.
8026 * features/i386/i386-mmx.c: Remove.
8027 * features/i386/i386-mpx.c: Remove.
8028 * features/i386/i386.c: Remove.
8029 * i386-tdep.c: Don't include features/i386/i386*.c., include
8030 target-descriptions.h and arch/i386.h.
8031 (i386_target_description): Create target descriptions.
8032 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
8033 functions. Do self tests.
8035 2017-09-05 Yao Qi <yao.qi@linaro.org>
8037 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
8038 * features/i386/amd64-avx-avx512-linux.c: Removed.
8039 * features/i386/amd64-avx-linux.c: Removed.
8040 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
8041 * features/i386/amd64-avx-mpx-linux.c: Removed.
8042 * features/i386/amd64-linux.c: Removed.
8043 * features/i386/amd64-mpx-linux.c: Removed.
8044 * features/i386/x32-avx-avx512-linux.c: Removed.
8045 * features/i386/x32-avx-linux.c: Removed.
8046 * features/i386/x32-linux.c: Removed.
8048 2017-09-05 Yao Qi <yao.qi@linaro.org>
8050 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8052 (amd64_linux_read_description): Call
8053 amd64_create_target_description.
8054 * arch/amd64.c: New file.
8055 * arch/amd64.h: New file.
8056 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8057 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8059 2017-09-05 Yao Qi <yao.qi@linaro.org>
8061 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8062 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8063 (amd64_linux_read_description): Create target descriptions.
8064 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8065 functions. Add unit tests.
8066 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8068 * features/i386/64bit-avx.c: Generated.
8069 * features/i386/64bit-avx512.c: Generated.
8070 * features/i386/64bit-core.c: Generated.
8071 * features/i386/64bit-linux.c: Generated.
8072 * features/i386/64bit-mpx.c: Generated.
8073 * features/i386/64bit-pkeys.c: Generated.
8074 * features/i386/64bit-segments.c: Generated.
8075 * features/i386/64bit-sse.c: Generated.
8076 * features/i386/x32-core.c: Generated.
8077 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8078 c files for amd64-linux and x32-linux.
8080 2017-09-05 Yao Qi <yao.qi@linaro.org>
8082 * amd64-linux-tdep.c (amd64_linux_read_description): New
8084 (amd64_linux_core_read_description): Call
8085 amd64_linux_read_description.
8086 (amd64_linux_init_abi): Likewise.
8087 (amd64_x32_linux_init_abi): Likewise.
8088 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8089 * x86-linux-nat.c (x86_linux_read_description): Call
8090 amd64_linux_read_description.
8092 2017-09-05 Yao Qi <yao.qi@linaro.org>
8094 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8097 2017-09-05 Yao Qi <yao.qi@linaro.org>
8099 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8100 * features/i386/i386-avx-avx512-linux.c: Remove.
8101 * features/i386/i386-avx-linux.c: Remove.
8102 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8103 * features/i386/i386-avx-mpx-linux.c: Remove.
8104 * features/i386/i386-linux.c: Remove.
8105 * features/i386/i386-mmx-linux.c: Remove.
8106 * features/i386/i386-mpx-linux.c: Remove.
8108 2017-09-05 Yao Qi <yao.qi@linaro.org>
8110 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8111 (SFILES): Add arch/i386.c.
8112 (HFILES_NO_SRCDIR): Add arch/i386.h.
8113 * arch/i386.c: New file.
8114 * arch/i386.h: New file.
8115 * arch/tdesc.h (allocate_target_description): Declare.
8116 (set_tdesc_architecture): Declare.
8117 (set_tdesc_osabi): Declare.
8118 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8119 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8120 include arch/i386.h.
8121 (i386_linux_read_description): Remove code and call
8122 i386_create_target_description.
8123 (set_tdesc_architecture): New function.
8124 (set_tdesc_osabi): New function.
8125 * target-descriptions.h (allocate_target_description): Remove.
8127 2017-09-05 Yao Qi <yao.qi@linaro.org>
8129 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8130 * target-descriptions.c (tdesc_create_feature): Likewise, and
8132 * features/i386/32bit-avx.c: Re-generated.
8133 * features/i386/32bit-avx512.c: Re-generated.
8134 * features/i386/32bit-core.c: Re-generated.
8135 * features/i386/32bit-linux.c: Re-generated.
8136 * features/i386/32bit-mpx.c: Re-generated.
8137 * features/i386/32bit-pkeys.c: Re-generated.
8138 * features/i386/32bit-sse.c: Re-generated.
8140 2017-09-05 Yao Qi <yao.qi@linaro.org>
8142 * regformats/regdef.h (struct reg): Override operator == and !=.
8144 2017-09-05 Yao Qi <yao.qi@linaro.org>
8146 * arch/tdesc.h: New file.
8147 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8148 * target-descriptions.c: Update comments.
8149 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8151 * features/i386/32bit-avx.c: Re-generated.
8152 * features/i386/32bit-avx512.c: Re-generated.
8153 * features/i386/32bit-core.c: Re-generated.
8154 * features/i386/32bit-linux.c: Re-generated.
8155 * features/i386/32bit-mpx.c: Re-generated.
8156 * features/i386/32bit-pkeys.c: Re-generated.
8157 * features/i386/32bit-sse.c: Re-generated.
8159 2017-09-05 Yao Qi <yao.qi@linaro.org>
8161 * regformats/regdat.sh: Update generated code.
8163 2017-09-05 Yao Qi <yao.qi@linaro.org>
8165 * regformats/regdat.sh: Adjust code order.
8167 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8169 * expprint.c (dump_subexp_body_standard): Use constant format
8170 string in fprintf_filtered call.
8172 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8174 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8176 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8178 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8180 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8182 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8184 * bsd-kvm.o: Define _KMEMUSER.
8185 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8186 * configure: Regenerate.
8188 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8190 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8191 * i386-fbsd-nat.c: Likewise.
8193 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8195 * unittests/array-view-selftests.c: Add include of <array>.
8197 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8199 * spu-tdep.c (flush_ea_cache): Add missing argument to
8200 call_function_by_hand.
8202 2017-09-04 Pedro Alves <palves@redhat.com>
8204 * NEWS (Safer support for debugging with no debug info): New.
8206 2017-09-04 Pedro Alves <palves@redhat.com>
8208 * c-exp.y (function_method, function_method_void): Add current
8209 instance flags to TYPE_INSTANCE.
8210 * dwarf2read.c (check_modifier): New.
8211 (compute_delayed_physnames): Assert that only C++ adds delayed
8212 physnames. Mark fn_fields as const/volatile depending on
8214 * eval.c (make_params): New type_instance_flags parameter. Use
8215 it as the new type's instance flags.
8216 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8217 flags element and pass it to make_params.
8218 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8219 instance flags element.
8220 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8221 * gdbtypes.h: Include "enum-flags.h".
8222 (type_instance_flags): New enum-flags type.
8223 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8224 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8225 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8226 (follow_type_instance_flags): New function.
8227 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8228 * parser-defs.h (follow_type_instance_flags): Declare.
8229 * valops.c (value_struct_elt_for_reference): const/volatile must
8232 2017-09-04 Pedro Alves <palves@redhat.com>
8234 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8235 function/method scopes; lookup the nested name as a function local
8238 2017-09-04 Pedro Alves <palves@redhat.com>
8240 (%type <voidval>): Add function_method.
8241 * c-exp.y (exp): New production for calls with no arguments.
8242 (function_method, function_method_void_or_typelist): New
8244 (exp): New production for "method()::static_var".
8245 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8246 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8247 Handle OP_FUNC_STATIC_VAR.
8248 * parse.c (operator_length_standard):
8249 Handle OP_FUNC_STATIC_VAR.
8251 2017-09-04 Pedro Alves <palves@redhat.com>
8253 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8255 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8257 * parse.c (operator_length_standard, operator_check_standard):
8259 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8261 2017-09-04 Pedro Alves <palves@redhat.com>
8263 * ax-gdb.c: Include "typeprint.h".
8264 (gen_expr_for_cast): New function.
8265 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8266 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8268 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8269 nodebug_data_symbol.
8270 * eval.c: Include "typeprint.h".
8271 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8272 Error out if symbol has unknown type.
8273 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8274 evaluate_subexp_for_cast.
8275 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8277 (evaluate_subexp_for_cast): New function.
8278 * gdbtypes.c (init_nodebug_var_type): New function.
8279 (objfile_type): Use it to initialize types of variables with no
8281 * typeprint.c (error_unknown_type): New.
8282 * typeprint.h (error_unknown_type): New declaration.
8283 * compile/compile-c-types.c (convert_type_basic): Handle
8284 TYPE_CODE_ERROR; warn and fallback to int for variables with
8287 2017-09-04 Pedro Alves <palves@redhat.com>
8289 * eval.c (evaluate_var_value): New function, factored out from ...
8290 (evaluate_subexp_standard): ... here.
8292 2017-09-04 Pedro Alves <palves@redhat.com>
8294 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8295 Remove useless assignments to 'op'.
8297 2017-09-04 Pedro Alves <palves@redhat.com>
8299 * eval.c (eval_skip_value): New function.
8300 (evaluate_subexp_standard): Use it.
8302 2017-09-04 Pedro Alves <palves@redhat.com>
8304 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8305 function name from symbol/minsym and pass it to
8306 error_call_unknown_return_type.
8308 2017-09-04 Pedro Alves <palves@redhat.com>
8310 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8311 * ax-gdb.c (gen_msym_var_ref): New function.
8312 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8313 * eval.c (evaluate_var_msym_value): New function.
8314 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8315 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8316 to call_function_by_hand.
8317 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8318 Handle OP_VAR_MSYM_VALUE.
8319 (union exp_element) <msymbol>: New field.
8320 * minsyms.h (struct type): Forward declare.
8321 (find_minsym_type_and_address): Declare.
8322 * parse.c (write_exp_elt_msym): New function.
8323 (write_exp_msymbol): Delete, refactored as ...
8324 (find_minsym_type_and_address): ... this new function.
8325 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8326 (operator_length_standard, operator_check_standard): Handle
8328 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8330 2017-09-04 Pedro Alves <palves@redhat.com>
8332 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8333 TYPE_GNU_IFUNC specially here. Throw error if return type is
8335 * ada-typeprint.c (print_func_type): Handle functions with unknown
8337 * c-typeprint.c (c_type_print_base): Handle functions and methods
8338 with unknown return type.
8339 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8340 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8341 * compile/compile-c-types.c: Include "objfiles.h".
8342 (convert_func): For functions with unknown return type, warn and
8344 * compile/compile-object-run.c (compile_object_run): Adjust call
8345 to call_function_by_hand_dummy.
8346 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8347 call_function_by_hand.
8348 * eval.c (evaluate_subexp_standard): Adjust calls to
8349 call_function_by_hand. Handle functions and methods with unknown
8350 return type. Pass expect_type to call_function_by_hand.
8351 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8353 * gcore.c (call_target_sbrk): Adjust call to
8354 call_function_by_hand.
8355 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8356 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8357 an integer address type instead of nodebug.
8358 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8359 call_function_by_hand.
8360 * infcall.c (error_call_unknown_return_type): New function.
8361 (call_function_by_hand): New "default_return_type" parameter.
8363 (call_function_by_hand_dummy): New "default_return_type"
8364 parameter. Use it instead of defaulting to int. If there's no
8365 default and the return type is unknown, throw an error. If
8366 there's a default return type, and the called function has no
8367 debug info, then assume the function is prototyped.
8368 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8369 New "default_return_type" parameter.
8370 (error_call_unknown_return_type): New declaration.
8371 * linux-fork.c (call_lseek): Cast return type of lseek.
8372 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8373 call_function_by_hand.
8374 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8375 calls to call_function_by_hand.
8376 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8378 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8379 (value_nsstring, print_object_command): Adjust calls to
8380 call_function_by_hand.
8381 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8382 functions with unknown return type.
8383 (pascal_type_print_func_varspec_suffix): New function.
8384 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8385 TYPE_CODE_METHOD>: Use it.
8386 * python/py-value.c (valpy_call): Adjust call to
8387 call_function_by_hand.
8388 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8389 call_function_by_hand.
8390 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8391 call_function_by_hand.
8392 * valops.c (value_allocate_space_in_inferior): Adjust call to
8393 call_function_by_hand.
8394 * typeprint.c (type_print_unknown_return_type): New function.
8395 * typeprint.h (type_print_unknown_return_type): New declaration.
8397 2017-09-04 Pedro Alves <palves@redhat.com>
8399 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
8400 types with more than one parameter as prototyped.
8402 2017-09-04 Pedro Alves <palves@redhat.com>
8404 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
8405 (disassemble_command): Use gdb_disassembly_flags instead of bare
8407 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
8408 (dump_insns, do_mixed_source_and_assembly_deprecated)
8409 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
8410 Use gdb_disassembly_flags instead of bare int.
8411 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
8412 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
8413 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
8414 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
8415 (enum gdb_disassembly_flag): ... values of this new enumeration.
8416 (gdb_disassembly_flags): Define.
8418 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
8419 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
8420 gdb_disassembly_flags instead of bare int.
8421 * record-btrace.c (btrace_insn_history)
8422 (record_btrace_insn_history, record_btrace_insn_history_range)
8423 (record_btrace_insn_history_from): Use gdb_disassembly_flags
8424 instead of bare int.
8425 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
8426 Use gdb_disassembly_flags instead of bare int.
8427 * target-debug.h (target_debug_print_gdb_disassembly_flags):
8429 * target-delegates.c: Regenerate.
8430 * target.c (target_insn_history, target_insn_history_from)
8431 (target_insn_history_range): Use gdb_disassembly_flags instead of
8433 * target.h: Include "disasm.h".
8434 (struct target_ops) <to_insn_history, to_insn_history_from,
8435 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
8437 (target_insn_history, target_insn_history_from)
8438 (target_insn_history_range): Use gdb_disassembly_flags instead of
8441 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8443 * cli/cli-script.c (build_command_line): For if/while commands,
8444 check whether args is empty.
8446 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8448 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
8449 (enum command_control_type): Likewise.
8450 (struct command_line): Likewise.
8451 (free_command_lines): Likewise.
8452 (struct command_lines_deleter): Likewise.
8453 (command_line_up): Likewise.
8454 (read_command_lines): Likewise.
8455 (read_command_lines_1): Likewise.
8456 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
8457 (enum command_control_type): Likewise.
8458 (struct command_line): Likewise.
8459 (free_command_lines): Likewise.
8460 (struct command_lines_deleter): Likewise.
8461 (command_line_up): Likewise.
8462 (read_command_lines): Likewise.
8463 (read_command_lines_1): Likewise.
8464 * breakpoint.h: Include cli/cli-script.h.
8465 * extension-priv.h: Likewise.
8466 * gdbcmd.h: Likewise.
8468 2017-09-04 Pedro Alves <palves@redhat.com>
8470 * ada-lang.c (is_known_support_routine): Move sal declaration to
8471 where it is initialized.
8472 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
8473 (parse_breakpoint_sals, decode_static_tracepoint_spec)
8474 (clear_command, update_static_tracepoint): Remove init_sal
8475 references. Move declarations closer to initializations.
8476 * cli/cli-cmds.c (list_command): Move sal declarations closer to
8478 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
8479 references. Move sal declarations closer to initializations.
8480 * frame.c (find_frame_sal): Return a symtab_and_line via function
8481 return instead of output parameter. Remove init_sal references.
8482 * frame.h (find_frame_sal): Return a symtab_and_line via function
8483 return instead of output parameter.
8484 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
8485 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
8487 (gdbscm_find_pc_line): Remove init_sal reference.
8488 * infcall.c (call_function_by_hand_dummy): Remove init_sal
8489 references. Move declarations closer to initializations.
8490 * infcmd.c (set_step_frame): Update. Move declarations closer to
8492 (finish_backward): Remove init_sal references. Move declarations
8493 closer to initializations.
8494 * infrun.c (process_event_stop_test, handle_step_into_function)
8495 (insert_hp_step_resume_breakpoint_at_frame)
8496 (insert_step_resume_breakpoint_at_caller): Likewise.
8497 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
8498 (symbol_to_sal): Likewise.
8499 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
8500 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
8501 to its initialization.
8502 * reverse.c (save_bookmark_command): Use new/delete. Remove
8503 init_sal references. Move declarations closer to initializations.
8504 * source.c (get_current_source_symtab_and_line): Remove brace
8506 (set_current_source_symtab_and_line): Now takes the sal by const
8507 reference. Remove brace initialization.
8508 (line_info): Remove init_sal reference.
8509 * source.h (set_current_source_symtab_and_line): Now takes a
8510 symtab_and_line via const reference.
8511 * stack.c (set_current_sal_from_frame): Adjust.
8512 (print_frame_info): Adjust.
8513 (get_last_displayed_sal): Return the sal via function return
8514 instead of via output parameter. Simplify.
8515 (frame_info): Adjust.
8516 * stack.h (get_last_displayed_sal): Return the sal via function
8517 return instead of via output parameter.
8518 * symtab.c (init_sal): Delete.
8519 (find_pc_sect_line): Remove init_sal references. Move
8520 declarations closer to initializations.
8521 (find_function_start_sal): Remove init_sal references. Move
8522 declarations closer to initializations.
8523 * symtab.h (struct symtab_and_line): In-class initialize all
8525 * tracepoint.c (set_traceframe_context)
8526 (print_one_static_tracepoint_marker): Remove init_sal references.
8527 Move declarations closer to initializations.
8528 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
8529 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
8530 declarations closer to initializations.
8531 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
8532 init_sal references. Adjust.
8534 2017-09-04 Pedro Alves <palves@redhat.com>
8536 * ax-gdb.c (agent_command_1): Use range-for.
8537 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8538 * breakpoint.c: Include "common/array-view.h".
8539 (init_breakpoint_sal, create_breakpoint_sal): Change sals
8540 parameter from struct symtabs_and_lines to
8541 array_view<symtab_and_line>. Adjust. Use range-for. Update.
8542 (breakpoint_sals_to_pc): Change sals parameter from struct
8543 symtabs_and_lines to std::vector reference.
8544 (check_fast_tracepoint_sals): Change sals parameter from struct
8545 symtabs_and_lines to std::array_view. Use range-for.
8546 (decode_static_tracepoint_spec): Return a std::vector instead of
8547 symtabs_and_lines. Update.
8548 (create_breakpoint): Update.
8549 (break_range_command, until_break_command, clear_command): Update.
8550 (base_breakpoint_decode_location, bkpt_decode_location)
8551 (bkpt_probe_create_sals_from_location)
8552 (bkpt_probe_decode_location, tracepoint_decode_location)
8553 (tracepoint_probe_decode_location)
8554 (strace_marker_create_sals_from_location): Return a std::vector
8555 instead of symtabs_and_lines.
8556 (strace_marker_create_breakpoints_sal): Update.
8557 (strace_marker_decode_location): Return a std::vector instead of
8558 symtabs_and_lines. Update.
8559 (update_breakpoint_locations): Change struct symtabs_and_lines
8560 parameters to gdb::array_view. Adjust.
8561 (location_to_sals): Return a std::vector instead of
8562 symtabs_and_lines. Update.
8563 (breakpoint_re_set_default): Use std::vector instead of struct
8565 (decode_location_default): Return a std::vector instead of
8566 symtabs_and_lines. Update.
8567 * breakpoint.h: Include "common/array-view.h".
8568 (struct breakpoint_ops) <decode_location>: Now returns a
8569 std::vector instead of returning a symtabs_and_lines via output
8571 (update_breakpoint_locations): Change sals parameters to use
8573 * cli/cli-cmds.c (edit_command, list_command): Update to use
8574 std::vector and gdb::array_view.
8575 (ambiguous_line_spec): Adjust to use gdb::array_view and
8577 (compare_symtabs): Rename to ...
8578 (cmp_symtabs): ... this. Change parameters to symtab_and_line
8579 const reference and adjust.
8580 (filter_sals): Rewrite using std::vector and standard algorithms.
8581 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
8582 (jump_command): Update to use std::vector.
8583 * linespec.c (struct linespec_state) <canonical_names>: Update
8585 (add_sal_to_sals_basic): Delete.
8586 (add_sal_to_sals, filter_results, convert_results_to_lsals)
8587 (decode_line_2, create_sals_line_offset)
8588 (convert_address_location_to_sals, convert_linespec_to_sals)
8589 (convert_explicit_location_to_sals, parse_linespec)
8590 (event_location_to_sals, decode_line_full, decode_line_1)
8591 (decode_line_with_current_source)
8592 (decode_line_with_last_displayed, decode_objc)
8593 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
8594 (linespec_result::~linespec_result): Adjust to use std::vector
8595 instead of symtabs_and_lines.
8596 * linespec.h (linespec_sals::sals): Now a std::vector.
8597 (struct linespec_result): Use std::vector, bool, and in-class
8599 (decode_line_1, decode_line_with_current_source)
8600 (decode_line_with_last_displayed): Return std::vector.
8601 * macrocmd.c (info_macros_command): Use std::vector.
8602 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
8603 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
8605 * probe.h (parse_probes): Return a std::vector.
8606 * python/python.c (gdbpy_decode_line): Use std::vector and
8608 * source.c (select_source_symtab, line_info): Use std::vector.
8609 * stack.c (func_command): Use std::vector.
8610 * symtab.h (struct symtabs_and_lines): Delete.
8611 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
8613 2017-09-04 Pedro Alves <palves@redhat.com>
8615 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8616 unittests/array-view-selftests.c.
8617 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
8618 * common/array-view.h: New file.
8619 * unittests/array-view-selftests.c: New file.
8621 2017-09-04 Pedro Alves <palves@redhat.com>
8623 * cli/cli-cmds.c (edit_command): Pass message to
8624 ambiguous_line_spec.
8625 (list_command): Pass message to ambiguous_line_spec. Say
8626 "first"/"last" instead of "start" and "end" to be consistent with
8628 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
8629 them to print formatted message.
8631 2017-09-04 Pedro Alves <palves@redhat.com>
8633 * btrace.c (ftrace_add_pt): Pass btrace_insn to
8634 ftrace_update_insns by reference instead of pointer.
8636 2017-09-04 Yao Qi <yao.qi@linaro.org>
8638 * i386-go32-tdep.c: Include x86-xstate.h.
8639 (i386_go32_init_abi): Call i386_target_description.
8640 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
8641 if xcr0 is X86_XSTATE_X87_MASK.
8642 * i386-tdep.h (tdesc_i386): Remove the declaration.
8643 (tdesc_i386_mmx): Likewise.
8645 2017-09-04 Yao Qi <yao.qi@linaro.org>
8647 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
8648 X86_XSTATE_SSE_MASK instead of 0.
8650 2017-09-04 Yao Qi <yao.qi@linaro.org>
8652 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
8653 i386_target_description.
8654 * i386-fbsd-nat.c (i386fbsd_read_description): Call
8655 i386_target_description.
8656 * i386-tdep.c (i386_gdbarch_init): Likewise.
8658 2017-09-04 Yao Qi <yao.qi@linaro.org>
8660 * amd64-darwin-tdep.c: Include "x86-xstate.h".
8661 (x86_darwin_init_abi_64): Call amd64_target_description.
8662 * amd64-dicos-tdep.c: Likewise.
8663 * amd64-fbsd-nat.c: Likewise.
8664 * amd64-fbsd-tdep.c: Likewise.
8665 * amd64-nbsd-tdep.c: Likewise.
8666 * amd64-obsd-tdep.c: Likewise.
8667 * amd64-sol2-tdep.c: Likewise.
8668 * amd64-windows-tdep.c: Likewise.
8669 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
8671 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8673 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
8674 (btrace_function) <insn>: Change type to use std::vector.
8675 * btrace.c (ftrace_debug, ftrace_call_num_insn,
8676 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
8677 ftrace_update_insns, ftrace_compute_global_level_offset,
8678 btrace_stitch_bts, btrace_clear, btrace_insn_get,
8679 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
8680 change to std::vector.
8681 (ftrace_update_insns): Adjust to change to std::vector, change
8682 type of INSN parameter.
8683 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
8684 * record-btrace.c (btrace_call_history_insn_range,
8685 btrace_compute_src_line_range,
8686 record_btrace_frame_prev_register): Adjust to change to
8688 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
8689 to change to std::vector.
8691 2017-09-03 Tom Tromey <tom@tromey.com>
8693 * corefile.c (reopen_exec_file): Use std::string.
8695 2017-09-03 Tom Tromey <tom@tromey.com>
8697 * compile/compile.c (compile_register_name_mangled): Return
8699 * compile/compile-loc2c.c (pushf_register_address): Update.
8700 (pushf_register): Update.
8701 * compile/compile-c-types.c (convert_array): Update.
8702 * compile/compile-c-symbols.c (generate_vla_size): Update.
8703 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
8704 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
8705 (convert_one_symbol): Update.
8706 (generate_c_for_for_one_variable): Update.
8707 * compile/compile-c-support.c (c_get_range_decl_name): Return a
8709 (generate_register_struct): Update.
8710 * compile/compile-internal.h (c_get_range_decl_name): Return a
8712 (compile_register_name_mangled): Return std::string.
8714 2017-09-03 Tom Tromey <tom@tromey.com>
8716 * utils.c (perror_string): Return a std::string.
8717 (throw_perror_with_name, perror_warning_with_name): Update.
8719 2017-09-03 Tom Tromey <tom@tromey.com>
8721 * demangle.c (demangle_command): Use std::string,
8724 2017-09-03 Tom Tromey <tom@tromey.com>
8726 * cli/cli-setshow.c (do_set_command): Use std::string.
8728 2017-09-03 Tom Tromey <tom@tromey.com>
8730 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
8732 2017-09-03 Tom Tromey <tom@tromey.com>
8734 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
8736 2017-09-03 Tom Tromey <tom@tromey.com>
8738 * mi/mi-cmd-env.c (env_execute_cli_command): Use
8739 gdb::unique_xmalloc_ptr.
8741 2017-09-03 Tom Tromey <tom@tromey.com>
8743 * thread.c (print_thread_info_1): Use string_printf.
8744 (thread_apply_command, thread_apply_all_command): Use
8747 2017-09-03 Tom Tromey <tom@tromey.com>
8749 * valprint.c (val_print_string): Update.
8750 * gdbcore.h (memory_error_message): Return std::string.
8751 * corefile.c (memory_error_message): Return std::string.
8752 (memory_error): Update.
8753 * breakpoint.c (insert_bp_location): Update.
8755 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
8757 * target/waitstatus.h (target_waitstatus_to_string): Change
8758 return type to std::string.
8759 * target/waitstatus.c (target_waitstatus_to_string): Return
8761 * target.h (target_waitstatus_to_string): Remove declaration.
8762 * infrun.c (resume, clear_proceed_status_thread,
8763 print_target_wait_results, do_target_wait, save_waitstatus,
8764 stop_all_threads): Adjust.
8765 * record-btrace.c (record_btrace_wait): Adjust.
8767 (target_debug_print_struct_target_waitstatus_p): Adjust.
8769 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8772 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
8775 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
8777 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
8778 for setting/unsetting environment variables on the remote target.
8779 (New remote packets): Add entries for QEnvironmentHexEncoded,
8780 QEnvironmentUnset and QEnvironmentReset.
8781 * common/environ.c (gdb_environ::operator=): Extend method to
8782 handle m_user_set_env_list and m_user_unset_env_list.
8783 (gdb_environ::clear): Likewise.
8784 (match_var_in_string): Change type of first parameter from 'char
8785 *' to 'const char *'.
8786 (gdb_environ::set): Extend method to handle
8787 m_user_set_env_list and m_user_unset_env_list.
8788 (gdb_environ::unset): Likewise.
8789 (gdb_environ::clear_user_set_env): New method.
8790 (gdb_environ::user_set_envp): Likewise.
8791 (gdb_environ::user_unset_envp): Likewise.
8792 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
8793 m_user_unset_env_list on move constructor/assignment.
8794 (unset): Add new default parameter 'update_unset_list = true'.
8795 (clear_user_set_env): New method.
8796 (user_set_envp): Likewise.
8797 (user_unset_envp): Likewise.
8798 (m_user_set_env_list): New std::set.
8799 (m_user_unset_env_list): Likewise.
8800 * common/rsp-low.c (hex2str): New function.
8801 (bin2hex): New overload for bin2hex function.
8802 * common/rsp-low.c (hex2str): New prototype.
8803 (str2hex): New overload prototype.
8804 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
8805 QEnvironmentUnset and QEnvironmentReset.
8806 (remote_protocol_features): Add QEnvironmentHexEncoded,
8807 QEnvironmentUnset and QEnvironmentReset packets.
8808 (send_environment_packet): New function.
8809 (extended_remote_environment_support): Likewise.
8810 (extended_remote_create_inferior): Call
8811 extended_remote_environment_support.
8812 (_initialize_remote): Add QEnvironmentHexEncoded,
8813 QEnvironmentUnset and QEnvironmentReset packet configs.
8814 * unittests/environ-selftests.c (gdb_selftest_env_var):
8816 (test_vector_initialization): New function.
8817 (test_init_from_host_environ): Likewise.
8818 (test_reinit_from_host_environ): Likewise.
8819 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
8821 (test_unset_set_empty_vector): Likewise.
8822 (test_vector_clear): Likewise.
8823 (test_std_move): Likewise.
8824 (test_move_constructor):
8825 (test_self_move): Likewise.
8826 (test_set_unset_reset): Likewise.
8827 (run_tests): Rewrite in terms of the functions above.
8829 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
8831 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
8832 (adi_available): Use a temp variable of type CORE_ADDR as argument
8833 3 when calling target_auxv_search.
8834 (adi_normalize_address): Use masks and xor operators to calculate
8836 (adi_read_versions, adi_write_versions, adi_print_versions)
8837 (do_examine, do_assign): Use paddress.
8839 2017-08-29 John Baldwin <jhb@FreeBSD.org>
8841 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
8842 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
8843 out of loop and add supply of FIR.
8844 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
8847 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
8850 * cli/cli-script.c (define_command): Don't convert command name
8853 2017-08-25 Joel Brobecker <brobecker@adacore.com>
8855 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
8856 Update all callers accordingly. Remove all code blocks handling
8857 the case where DISPP is not NULL.
8859 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8862 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
8863 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8864 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
8866 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8868 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
8869 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
8870 (read_comp_units_from_section): New parameter abbrev_section, use
8871 read_and_check_comp_unit_head, allocate signatured_type if needed.
8872 (create_all_comp_units): Update read_comp_units_from_section caller.
8874 2017-08-23 Pedro Alves <palves@redhat.com>
8877 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
8878 to null_ptid and switch to thread without reading the registers
8879 after adding the inferior.
8881 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8883 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
8885 * compile/compile.c (compile_gcc, show_compile_gcc): New.
8886 (compile_to_object): Implement compile_gcc.
8887 (_initialize_compile): Install "set compile-gcc". Initialize
8890 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8892 * compile/compile.c (compile_to_object): Conditionally call
8893 set_verbose. Conditionally call compile or compile_v0.
8895 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
8897 * sparc64-tdep.h: (adi_normalize_address): New export.
8898 * sparc-nat.h: (open_adi_tag_fd): New export.
8899 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
8900 * sparc64-linux-tdep.c:
8901 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
8902 (sparc64_linux_handle_segmentation_fault): New function.
8903 (sparc64_linux_init_abi): Register
8904 sparc64_linux_handle_segmentation_fault
8905 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
8906 (sparc64_addr_bits_remove): New function.
8907 (sparc64_init_abi): Register sparc64_addr_bits_remove.
8908 (MAX_PROC_NAME_SIZE): New macro.
8909 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
8910 (sparc64adilist): New variable.
8911 (adi_proc_list): New variable.
8912 (find_adi_info): New function.
8913 (add_adi_info): New function.
8914 (get_adi_info_proc): New function.
8915 (get_adi_info): New function.
8916 (info_adi_command): New function.
8917 (read_maps_entry): New function.
8918 (adi_available): New function.
8919 (adi_normalize_address): New function.
8920 (adi_align_address): New function.
8921 (adi_convert_byte_count): New function.
8922 (adi_tag_fd): New function.
8923 (adi_is_addr_mapped): New function.
8924 (adi_read_versions): New function.
8925 (adi_write_versions): New function.
8926 (adi_print_versions): New function.
8927 (do_examine): New function.
8928 (do_assign): New function.
8929 (adi_examine_command): New function.
8930 (adi_assign_command): New function.
8931 (_initialize_sparc64_adi_tdep): New function.
8933 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
8935 * breakpoint.c (breakpoints_info): Rename to ...
8936 (info_breakpoints_command): ... this.
8937 (watchpoints_info): Rename to ...
8938 (info_watchpoints_command): ... this.
8939 (tracepoints_info): Rename to ...
8940 (info_tracepoints_command): ... this.
8941 (_initialize_breakpoint): Adjust.
8942 * dcache.c (dcache_info): Rename to ...
8943 (info_display_command): ... this.
8944 (_initialize_dcache): Adjust.
8945 * frame.h (args_info): Rename to ...
8946 (info_args_command): ... this.
8947 (locals_info): Rename to ...
8948 (info_locals_command): ... this.
8949 * infcmd.c (nofp_registers_info): Rename to ...
8950 (info_registers_command): ... this.
8951 (float_info): Rename to ...
8952 (info_float_command): ... this.
8953 (program_info): Rename to ...
8954 (info_program_command): ... this.
8955 (all_registers_info): Rename to ...
8956 (info_all_registers_command): ... this.
8957 (vector_info): Rename to ...
8958 (info_vector_command): ... this.
8959 (float_info): Rename to ...
8960 (info_float_command): ... this.
8961 (_initialize_infcmd): Adjust.
8962 * inferior.h (term_info): Rename to ...
8963 (info_terminal_command): ... this.
8964 * inflow.c (term_info): Rename to ...
8965 (info_terminal_command): ... this.
8966 (_initialize_inflow): Adjust.
8967 * infrun.c (signals_info): Rename to ...
8968 (info_signals_command): ... this.
8969 (_initialize_infrun): Adjust.
8970 * objc-lang.c (classes_info): Rename to ...
8971 (info_classes_command): ... this.
8972 (selectors_info): Rename to ...
8973 (info_selectors_command): ... this.
8974 (_initialize_objc_language): Adjust.
8975 * printcmd.c (sym_info): Rename to ...
8976 (info_symbol_command): ... this.
8977 (address_info): Rename to ...
8978 (info_address_command): ... this.
8979 (display_info): Rename to ...
8980 (info_display_command): ... this.
8981 (_initialize_printcmd): Adjust.
8982 * reverse.c (bookmarks_info): Rename to ...
8983 (info_breakpoints_command): ... this.
8984 (_initialize_reverse): Adjust.
8985 * ser-go32.c (dos_info): Rename to ...
8986 (info_serial_command): ... this.
8987 (_initialize_ser_dos): Adjust.
8988 * skip.c (skip_info): Rename to ...
8989 (info_skip_command): ... this.
8990 (_initialize_step_skip): Adjust.
8991 * source.c (line_info): Rename to ...
8992 (info_line_command): ... this.
8993 (source_info): Rename to ...
8994 (info_source_command)
8995 * stack.c (frame_info): Rename to ...
8996 (info_frame_command): ... this.
8997 (locals_info): Rename to ...
8998 (info_locals_command): ... this.
8999 (args_info): Rename to ...
9000 (info_args_command): ... this.
9001 (_initialize_stack): Adjust.
9002 * symtab.c (sources_info): Rename to ...
9003 (info_sources_command): ... this.
9004 (variables_info): Rename to ...
9005 (info_variables_command): ... this.
9006 (functions_info): Rename to ...
9007 (info_functions_command): ... this.
9008 (types_info): Rename to ...
9009 (info_types_command): ... this.
9010 (_initialize_symtab): Adjust.
9011 * target.c (target_info): Rename to ...
9012 (info_target_command): ... this.
9013 (initialize_targets): Adjust.
9014 * tracepoint.c (tvariables_info): Rename to ...
9015 (info_tvariables_command): ... this.
9016 (scope_info): Rename to ...
9017 (info_scope_command): ... this.
9018 (trace_dump_actions): Adjust.
9019 (_initialize_tracepoint): Adjust.
9021 2017-08-22 Tom Tromey <tom@tromey.com>
9023 * breakpoint.h (install_breakpoint): Update.
9024 * breakpoint.c (add_solib_catchpoint): Update.
9025 (install_breakpoint): Change argument to a std::unique_ptr.
9026 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
9027 (create_breakpoint_sal, create_breakpoint): Update.
9028 (watch_command_1, catch_exec_command_1)
9029 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
9030 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
9031 Return the breakpoint.
9032 (set_raw_breakpoint_without_location, set_raw_breakpoint)
9033 (new_single_step_breakpoint): Update.
9034 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
9036 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9038 * break-catch-sig.c (create_signal_catchpoint): Use
9040 * ada-lang.c (create_ada_exception_catchpoint): Use
9043 2017-08-22 Tom Tromey <tom@tromey.com>
9045 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
9047 2017-08-22 Tom Tromey <tom@tromey.com>
9049 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9050 (lookup_partial_symbol): Update.
9052 2017-08-22 Tom Tromey <tom@tromey.com>
9054 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9055 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9056 (find_and_open_source, symtab_to_fullname): Update.
9057 * psymtab.c (psymtab_to_fullname): Update.
9059 2017-08-22 Tom Tromey <tom@tromey.com>
9061 * exec.c (exec_file_attach): Update.
9062 * linux-thread-db.c (try_thread_db_load): Update.
9063 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9064 * utils.c (gdb_realpath): Change return type.
9065 (gdb_realpath_keepfile): Update.
9066 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9067 (_initialize_utils): Register the new self test.
9068 * source.c (openp): Update.
9069 (find_and_open_source): Update.
9070 * nto-tdep.c (nto_find_and_open_solib): Update.
9071 * main.c (set_gdb_data_directory): Update.
9072 (captured_main_1): Update.
9073 * dwarf2read.c (dwarf2_get_dwz_file): Update
9074 (dw2_map_symbol_filenames): Update.
9075 * auto-load.c (auto_load_safe_path_vec_update): Update.
9076 (filename_is_in_auto_load_safe_path_vec): Change type of
9078 (auto_load_objfile_script): Update.
9079 (file_is_auto_load_safe): Update. Use std::string.
9080 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9082 2017-08-22 Tom Tromey <tom@tromey.com>
9084 * utils.c (gdb_realpath_keepfile): Return a
9085 gdb::unique_xmalloc_ptr.
9086 * exec.c (exec_file_attach): Update.
9087 * utils.h (gdb_realpath_keepfile): Return a
9088 gdb::unique_xmalloc_ptr.
9090 2017-08-22 Tom Tromey <tom@tromey.com>
9092 * compile/compile.c (compile_file_command): Use
9093 gdb::unique_xmalloc_ptr, std::string.
9094 * utils.c (gdb_abspath): Change return type.
9095 * source.c (openp): Update.
9096 * objfiles.c (allocate_objfile): Update.
9097 * main.c (set_gdb_data_directory): Update.
9098 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9100 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9102 * cli-cmds.c (list_commands): List actual code around more than
9105 2017-08-21 John Baldwin <jhb@FreeBSD.org>
9107 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9109 2017-08-21 Pedro Alves <palves@redhat.com>
9112 * c-exp.y (variable production): Handle function aliases.
9113 * minsyms.c (msymbol_is_text): New function.
9114 * minsyms.h (msymbol_is_text): Declare.
9115 * symtab.c (find_function_alias_target): New function.
9116 * symtab.h (find_function_alias_target): Declare.
9118 2017-08-21 Pedro Alves <palves@redhat.com>
9120 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9122 * typeprint.c (whatis_exp): If handling "whatis", and expression
9123 is OP_TYPE, strip one typedef level. Otherwise don't strip
9125 * valops.c (value_cast): Save "to" type before resolving
9126 stubs/typedefs. Use that type as resulting value's type.
9128 2017-08-18 Tom Tromey <tom@tromey.com>
9129 Pedro Alves <palves@redhat.com>
9131 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9132 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9133 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9134 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9135 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9136 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9137 (linux_get_siginfo_data): Add "thread" argument. Use
9139 * linux-nat.c (linux_child_follow_fork)
9140 (check_stopped_by_watchpoint): Use scoped_restore.
9141 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9142 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9143 (restore_inferior_ptid, save_inferior_ptid): Remove.
9144 * btrace.c (btrace_fetch): Use scoped_restore.
9145 * bsd-uthread.c (bsd_uthread_fetch_registers)
9146 (bsd_uthread_store_registers): Use scoped_restore.
9147 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9149 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9150 (aix_thread_xfer_partial): Use scoped_restore.
9151 * inferior.h (save_inferior_ptid): Remove.
9153 2017-08-18 Yao Qi <yao.qi@linaro.org>
9156 * arm-tdep.c (gdb_print_insn_arm): Mark
9157 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9159 2017-08-18 Yao Qi <yao.qi@linaro.org>
9161 * NEWS: Mention GDBserver's new option "--selftest".
9162 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9163 * selftest.c: Move it to common/selftest.c.
9164 * selftest.h: Move it to common/selftest.h.
9165 * selftest-arch.c (reset): New function.
9166 (tests_with_arch): Call reset.
9168 2017-08-18 Yao Qi <yao.qi@linaro.org>
9170 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9171 instead of exception_fprintf and printf_filtered.
9173 2017-08-18 Yao Qi <yao.qi@linaro.org>
9175 * selftest.c (register_self_test): Rename it to
9176 selftests::register_test.
9177 (run_self_tests): selftest::run_tests.
9178 * selftest.h: Update declarations.
9179 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9180 selftests::register_test_foreach_arch.
9181 * selftest-arch.h: Update declaration.
9182 * aarch64-tdep.c: Update.
9183 * arm-tdep.c: Likewise.
9184 * disasm-selftests.c: Likewise.
9185 * dwarf2loc.c: Likewise.
9186 * dwarf2-frame.c: Likewise.
9187 * findvar.c: Likewise.
9188 * gdbarch-selftests.c: Likewise.
9189 * maint.c (maintenance_selftest): Likewise.
9190 * regcache.c: Likewise.
9191 * rust-exp.y: Likewise.
9192 * selftest-arch.c: Likewise.
9193 * unittests/environ-selftests.c: Likewise.
9194 * unittests/function-view-selftests.c: Likewise.
9195 * unittests/offset-type-selftests.c: Likewise.
9196 * unittests/optional-selftests.c: Likewise.
9197 * unittests/scoped_restore-selftests.c: Likewise.
9198 * utils-selftests.c: Likewise.
9200 2017-08-17 Pedro Alves <palves@redhat.com>
9202 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9205 2017-08-17 Pedro Alves <palves@redhat.com>
9207 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9209 (reset_die_in_process): Delete, replaced by ...
9210 (process_die_scope): ... this new class. Make it responsible for
9211 freeing cu->line_header too.
9212 (process_die): Use process_die_scope.
9213 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9214 cu->line_header_die_owner. Don't release the line header if it's
9216 (setup_type_unit_groups): Make the CU/DIE own the line header.
9217 Don't release the line header here.
9219 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9221 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9223 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9225 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9228 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9230 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9233 2017-08-15 Stafford Horne <shorne@gmail.com>
9235 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9237 2017-08-15 Stafford Horne <shorne@gmail.com>
9239 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9241 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9244 * infcmd.c (unset_environment_command): Use the 'clear' method on
9245 the environment instead of resetting it.
9247 2017-08-15 John Baldwin <jhb@FreeBSD.org>
9249 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9252 2017-08-14 Tom Tromey <tom@tromey.com>
9254 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9255 (print_binary_chars): Likewise.
9256 (BITS_IN_BYTES): Remove.
9258 2017-08-14 Tom Tromey <tom@tromey.com>
9261 * valprint.c (LOW_ZERO): Change value to 034.
9262 (print_octal_chars): Add static_asserts for octal constants.
9263 * printcmd.c (print_scalar_formatted): Add 'd' case.
9265 2017-08-11 Tom Tromey <tom@tromey.com>
9267 * symfile.c (add_symbol_file_command): Use std::vector.
9269 2017-08-14 Tom Tromey <tom@tromey.com>
9271 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9272 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9274 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9276 2017-08-11 Pedro Alves <palves@redhat.com>
9278 * infrun.c (process_event_stop_test): Adjust
9279 function_name_is_marked_for_skip call.
9280 * skip.c: Include <list>.
9281 (skiplist_entry): Make it a class with private fields, and
9283 (skiplist_entry_chain): Delete.
9284 (skiplist_entries): New.
9285 (skiplist_entry_count): Delete.
9286 (highest_skiplist_entry_num): New.
9287 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9288 (add_skiplist_entry): Delete.
9289 (skiplist_entry::skiplist_entry): New.
9290 (skiplist_entry::add_entry): New.
9291 (skip_file_command, skip_function): Adjust.
9292 (compile_skip_regexp): Delete.
9293 (skip_command): Don't compile regexp here. Adjust to use
9294 skiplist_entry::add_entry.
9295 (skip_info): Adjust to use range-for and getters.
9296 (skip_enable_command, skip_disable_command): Adjust to use
9297 range-for and setters.
9298 (skip_delete_command): Adjust to use std::list.
9299 (add_skiplist_entry): Delete.
9300 (skip_file_p): Delete, refactored as ...
9301 (skiplist_entry::do_skip_file_p): ... this new method.
9302 (skip_gfile_p): Delete, refactored as ...
9303 (skiplist_entry::do_gskip_file_p): ... this new method.
9304 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9305 (skiplist_entry::skip_function_p): ... this new method.
9306 (function_name_is_marked_for_skip): Now returns bool, and takes
9307 the function sal by const reference. Adjust to use range-for and
9308 skiplist_entry methods.
9309 (_initialize_step_skip): Remove references to
9310 skiplist_entry_chain, skiplist_entry_count.
9311 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9312 takes the function sal by const reference.
9314 2017-08-11 Yao Qi <yao.qi@linaro.org>
9316 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9317 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9318 (dwarf2_frame_cache):
9319 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9320 RETURN_MASK_ALL and set *this_case to NULL.
9321 * frame-unwind.h: Update comments.
9323 2017-08-11 Yao Qi <yao.qi@linaro.org>
9325 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9326 (dwarf2_frame_state_copy_regs): Remove.
9327 (dwarf2_frame_state_free_regs): Remove.
9328 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9329 (dwarf2_restore_rule): Call method .alloc_regs instead of
9330 dwarf2_frame_state_alloc_regs.
9331 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9332 constructor. Call std::move.
9333 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9334 (dwarf2_frame_cache): Likewise.
9336 [GDB_SELF_TEST]: Include selftest.h and
9338 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9339 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9340 execute_cfa_program_test.
9342 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9343 copy ctor, assignment operator, move assignment.
9344 <alloc_regs>: New method.
9346 (struct dwarf2_frame_state): Delete dtor.
9347 (dwarf2_frame_state_alloc_regs): Remove declaration.
9348 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9349 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9351 2017-08-11 Yao Qi <yao.qi@linaro.org>
9353 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9354 (dwarf2_frame_state::dwarf2_frame_state): New.
9355 (dwarf2_frame_state::~dwarf2_frame_state): New.
9356 (dwarf2_fetch_cfa_info): Update.
9357 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9358 rather than a pointer. Update code.
9359 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9361 <data_align, code_align, retaddr_column>: Change them to const.
9362 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9365 2017-08-11 Yao Qi <yao.qi@linaro.org>
9367 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9368 <loc.exp>: New field.
9369 * dwarf2-frame.c (execute_cfa_program): Update.
9370 (dwarf2_frame_prev_register): Update.
9372 2017-08-10 Pedro Alves <palves@redhat.com>
9374 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9376 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9378 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9379 (fbsd_pending_children): Use std::list.
9380 (fbsd_remember_child): Likewise.
9381 (fbsd_is_child_pending): Likewise.
9382 (fbsd_pending_vfork_done): Use std::forward_list.
9383 (fbsd_add_vfork_done): Likewise.
9384 (fbsd_is_vfork_done_pending): Likewise.
9385 (fbsd_next_vfork_done): Likewise.
9387 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9389 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9390 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9391 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9393 (fbsd_xfer_partial): Use gdb::byte_vector.
9394 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
9396 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9398 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
9400 (fbsd_find_memory_regions): Fix `mapfile' initialization.
9402 2017-08-09 Tom Tromey <tom@tromey.com>
9404 * skip.c (skiplist_entry): New constructor.
9405 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
9406 (skiplist_entry::file_is_glob): Now bool.
9407 (skiplist_entry::file, skiplist_entry::function): Now
9409 (make_skip_entry): Return a unique_ptr. Use new.
9410 (free_skiplist_entry, free_skiplist_entry_cleanup)
9411 (make_free_skiplist_entry_cleanup): Remove.
9412 (skip_command, skip_disable_command, add_skiplist_entry)
9413 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
9414 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
9415 (function_name_is_marked_for_skip): Update.
9416 (skip_delete_command): Update. Use delete.
9418 2017-08-09 Jiong Wang <jiong.wang@arm.com>
9420 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
9421 (aarch64_linux_core_read_description): New function.
9422 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
9424 2017-08-09 Pedro Alves <palves@redhat.com>
9426 * cp-name-parser.y (cp_comp_to_string): Return a
9427 gdb::unique_xmalloc_ptr<char>.
9428 * cp-support.c (replace_typedefs_qualified_name)
9429 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
9430 (cp_canonicalize_string_full): Use op= instead of explicit
9432 (cp_class_name_from_physname, method_name_from_physname)
9433 (cp_func_name, cp_remove_params): Adjust to use
9434 gdb::unique_xmalloc_ptr<char>.
9435 * cp-support.h (cp_comp_to_string): Return a
9436 gdb::unique_xmalloc_ptr<char>.
9437 * python/py-type.c (typy_lookup_type): Adjust to use
9438 gdb::unique_xmalloc_ptr<char>.
9440 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
9442 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
9444 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
9445 Yao Qi <yao.qi@linaro.org>
9447 * cp-support.c (cp_canonicalize_string_full): Use
9448 gdb::unique_xmalloc_ptr<char>.
9449 (cp_canonicalize_string): Likewise.
9451 2017-08-09 Yao Qi <yao.qi@linaro.org>
9453 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
9454 * regformats/i386/amd64-avx-avx512.dat: Remove.
9455 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
9456 * regformats/i386/amd64-avx-mpx.dat:Remove.
9457 * regformats/i386/amd64-avx.dat: Remove.
9458 * regformats/i386/amd64-mpx.dat: Remove.
9459 * regformats/i386/i386-avx-avx512.dat: Remove.
9460 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
9461 * regformats/i386/i386-avx-mpx.dat: Remove.
9462 * regformats/i386/i386-mmx.dat: Remove.
9463 * regformats/i386/i386-mpx.dat: Remove.
9465 2017-08-09 Yao Qi <yao.qi@linaro.org>
9467 * amd64-tdep.h (tdesc_x32): Remove the declaration.
9468 * amd64-tdep.c: Don't include features/i386/x32*.c.
9469 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
9471 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
9472 and i386/x32-avx-avx512.
9473 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
9475 * features/i386/x32-avx-avx512.c: Removed.
9476 * features/i386/x32-avx-avx512.xml: Removed.
9477 * features/i386/x32-avx.c: Removed.
9478 * features/i386/x32-avx.xml: Removed.
9479 * features/i386/x32.c: Removed.
9480 * features/i386/x32.xml: Removed.
9481 * regformats/i386/x32-avx-avx512.dat: Removed.
9482 * regformats/i386/x32-avx.dat: Removed.
9483 * regformats/i386/x32.dat: Removed.
9485 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9487 PR breakpoints/21886
9488 * mem-break.c (default_memory_insert_breakpoint): Use
9489 `->placed_address' rather than `->reqstd_address' for the
9490 breakpoint location.
9492 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9494 * arch-utils.c (default_print_insn): Remove arch/mach/endian
9497 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9499 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
9500 a union of `tdep_info', `tdesc_data' and `id'.
9501 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
9502 rather than `info.tdep_info'.
9503 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
9504 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9505 * i386-tdep.c (i386_gdbarch_init): Likewise.
9506 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
9507 * mips-tdep.c (mips_gdbarch_init): Likewise.
9508 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9509 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9510 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
9512 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
9514 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9515 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
9517 * spu-tdep.c (spu_gdbarch_init): Likewise.
9518 * gdbarch.h: Regenerate.
9520 2017-08-07 Leszek Swirski <leszeks@google.com>
9523 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
9525 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
9527 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
9528 (gdbsim_open): Rename gdb_argv args object to argv.
9530 2017-08-05 Tom Tromey <tom@tromey.com>
9532 * compile/compile-object-load.c (compile_object_load): Use
9533 gdb::unique_xmalloc_ptr.
9534 * cli/cli-dump.c (scan_filename): Rename from
9535 scan_filename_with_cleanup. Change return type.
9536 (scan_expression): Rename from scan_expression_with_cleanup.
9538 (dump_memory_to_file, dump_value_to_file, restore_command):
9539 Use gdb::unique_xmalloc_ptr. Update.
9540 * cli/cli-cmds.c (find_and_open_script): Use
9541 gdb::unique_xmalloc_ptr.
9542 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
9543 * symmisc.c (maintenance_print_symbols)
9544 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
9545 * symfile.c (symfile_bfd_open, generic_load)
9546 (add_symbol_file_command, remove_symbol_file_command): Use
9547 gdb::unique_xmalloc_ptr.
9548 * source.c (openp): Use gdb::unique_xmalloc_ptr.
9549 * psymtab.c (maintenance_print_psymbols): Use
9550 gdb::unique_xmalloc_ptr.
9551 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
9552 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
9553 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
9554 (reload_shared_libraries_1): Likewise.
9556 2017-08-05 Tom Tromey <tom@tromey.com>
9558 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
9559 (rust_op_vector, rust_set_vector): New typedefs.
9560 (current_parser): New global.
9561 (work_obstack): Change to pointer type. Update all users.
9562 (rust_ast, pstate): Remove globals.
9563 (struct rust_parser): New.
9564 (%union) <params, field_inits>: Change type.
9565 (start, tuple_expr, unit_expr, struct_expr_list, literal)
9566 (field_expr, expr_list, maybe_expr_list, type_list): Update.
9567 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
9568 (convert_params_to_types, convert_params_to_expression): Change
9570 (ast_string): Change type of "fields".
9571 (rust_parse): Make a rust_parser. Remove cleanups.
9572 (rust_lex_tests): Make and install an auto_obstack.
9574 2017-08-04 Yao Qi <yao.qi@linaro.org>
9576 * configure.srv (ipa_x32_linux_regobj): New.
9577 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
9578 instead of X86_TDESC_AVX512.
9579 (initialize_low_tracepoint): Call
9580 init_registers_x32_avx_avx512_linux.
9582 2017-08-04 Yao Qi <yao.qi@linaro.org>
9584 * utils.h (gdb_argv): Add namespace std for nullptr_t.
9586 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
9588 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
9590 2017-08-03 Tom Tromey <tom@tromey.com>
9592 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
9594 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
9596 2017-08-03 Tom Tromey <tom@tromey.com>
9598 * python/py-param.c (compute_enum_values): Use gdb_argv.
9600 2017-08-03 Tom Tromey <tom@tromey.com>
9602 * utils.h (struct gdb_argv_deleter): New.
9603 (gdb_argv): New class.
9604 * utils.c (gdb_argv::reset): New method.
9605 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
9606 * tracefile.c (tsave_command): Use gdb_argv.
9607 * top.c (new_ui_command): Use gdb_argv.
9608 * symmisc.c (maintenance_print_symbols)
9609 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
9610 * symfile.c (symbol_file_command, generic_load)
9611 (remove_symbol_file_command): Use gdb_argv.
9612 * stack.c (backtrace_command): Use gdb_argv.
9613 * source.c (add_path, show_substitute_path_command)
9614 (unset_substitute_path_command, set_substitute_path_command):
9616 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
9617 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
9618 * remote.c (extended_remote_run, remote_put_command)
9619 (remote_get_command, remote_delete_command): Use gdb_argv.
9620 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
9621 (gdbsim_open): Use gdb_argv.
9622 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
9623 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
9624 * procfs.c (procfs_info_proc): Use gdb_argv.
9625 * interps.c (interpreter_exec_cmd): Use gdb_argv.
9626 * infrun.c (handle_command): Use gdb_argv.
9627 * inferior.c (add_inferior_command, clone_inferior_command):
9629 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
9630 * exec.c (exec_file_command): Use gdb_argv.
9631 * cli/cli-cmds.c (alias_command): Use gdb_argv.
9632 * compile/compile.c (build_argc_argv): Use gdb_argv.
9634 2017-08-03 Tom Tromey <tom@tromey.com>
9636 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
9638 2017-08-03 Tom Tromey <tom@tromey.com>
9640 * python/python.c (compute_python_string): Return std::string.
9641 (gdbpy_eval_from_control_command): Update.
9642 (do_start_initialization): Use std::string.
9643 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
9645 * python/py-breakpoint.c (local_setattro): Use string_printf, not
9648 2017-08-03 Tom Tromey <tom@tromey.com>
9650 * top.h (do_restore_instream_cleanup): Remove.
9651 * top.c (do_restore_instream_cleanup): Remove.
9652 (read_command_file): Use scoped_restore.
9653 * cli/cli-script.c (execute_user_command): Use scoped_restore.
9655 2017-08-03 Tom Tromey <tom@tromey.com>
9657 * cli/cli-script.c (execute_user_command)
9658 (execute_control_command): Use scoped_restore.
9660 2017-08-03 Tom Tromey <tom@tromey.com>
9662 * cli/cli-script.c (do_restore_user_call_depth): Remove.
9663 (execute_user_command): Remove user_call_depth; use
9664 user_args_stack's size instead.
9666 2017-08-03 Tom Tromey <tom@tromey.com>
9668 * top.h (in_user_command): Remove.
9669 * top.c (in_user_command): Remove.
9670 * cli/cli-script.c (do_restore_user_call_depth)
9671 (execute_user_command): Update.
9673 2017-08-03 Tom Tromey <tom@tromey.com>
9675 * valops.c (search_struct_method): Use gdb::byte_vector.
9676 * valarith.c (value_concat): Use std::vector.
9677 * target.c (memory_xfer_partial): Use gdb::byte_vector.
9678 (simple_search_memory): Likewise.
9679 * printcmd.c (find_string_backward): Use gdb::byte_vector.
9680 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
9681 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
9682 * elfread.c (elf_rel_plt_read): Use std::string.
9683 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
9684 * cli/cli-dump.c (restore_section_callback): Use
9687 2017-08-03 Tom Tromey <tom@tromey.com>
9689 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
9691 2017-08-03 Tom Tromey <tom@tromey.com>
9693 * tui/tui-regs.c (tui_restore_gdbout): Remove.
9694 (tui_register_format): Use scoped_restore.
9696 2017-08-03 Tom Tromey <tom@tromey.com>
9698 * reverse.c (exec_direction_default): Remove.
9699 (exec_reverse_once): Use scoped_restore.
9700 * remote.c (restore_remote_timeout): Remove.
9701 (remote_flash_erase, remote_flash_write, remote_flash_done)
9702 (readchar, remote_serial_write): Use scoped_restore.
9703 * cli/cli-script.c (struct source_cleanup_lines_args)
9704 (source_cleanup_lines): Remove.
9705 (script_from_file): Use scoped_restore.
9706 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
9707 (source_command): Use scoped_restore.
9709 2017-08-03 Tom Tromey <tom@tromey.com>
9711 * utils.h (make_cleanup_free_so): Remove.
9712 * utils.c (do_free_so, make_cleanup_free_so): Remove.
9713 * solist.h (struct so_deleter): New.
9714 (so_list_up): New typedef.
9715 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
9717 2017-08-03 Tom Tromey <tom@tromey.com>
9719 * utils.h (make_cleanup_restore_current_language): Remove.
9720 * utils.c (do_restore_current_language)
9721 (make_cleanup_restore_current_language): Remove.
9722 * parse.c (parse_exp_in_context_1)
9723 (parse_expression_with_language): Use
9724 scoped_restore_current_language.
9725 * mi/mi-main.c (mi_cmd_execute): Use
9726 scoped_restore_current_language.
9727 * language.h (scoped_restore_current_language): New class.
9729 2017-08-03 Tom Tromey <tom@tromey.com>
9731 * compile/compile.c (cleanup_unlink_file): Remove.
9732 (compile_to_object): Use gdb::unlinker.
9733 (eval_compile_command): Likewise.
9735 2017-08-03 Tom Tromey <tom@tromey.com>
9737 * utils.h (make_cleanup_fclose): Remove.
9738 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
9740 2017-08-03 Tom Tromey <tom@tromey.com>
9742 * top.c (open_terminal_stream): Return gdb_file_up.
9743 (new_ui_command): Update.
9745 2017-08-03 Tom Tromey <tom@tromey.com>
9747 * source.c (print_source_lines_base, forward_search_command)
9748 (reverse_search_command): Use gdb_file_up.
9750 2017-08-03 Tom Tromey <tom@tromey.com>
9752 * fbsd-nat.c (fbsd_find_memory_regions): Update.
9754 2017-08-03 Tom Tromey <tom@tromey.com>
9756 * cli/cli-cmds.c (find_and_open_script): Change return type.
9757 Remove "streamp" and "full_path" parameters.
9758 (source_script_with_search): Update.
9759 * auto-load.c (source_script_file): Update.
9760 * cli/cli-cmds.h (find_and_open_script): Change type.
9761 (open_script): New struct.
9763 2017-08-03 Tom Tromey <tom@tromey.com>
9765 * xml-support.c (xml_fetch_content_from_file): Update.
9766 * ui-file.c (stdio_file::open): Update.
9767 * tracefile-tfile.c (tfile_start): Update.
9768 * remote.c (remote_file_put, remote_file_get): Update.
9769 * nat/linux-procfs.c (linux_proc_get_int)
9770 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
9771 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
9772 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
9773 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
9774 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
9775 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
9776 * linux-nat.c (linux_proc_pending_signals): Update.
9777 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
9778 (file_closer): Remove.
9779 * compile/compile.c (compile_to_object): Update.
9780 * common/filestuff.h (struct gdb_file_deleter): New.
9781 (gdb_file_up): New typedef.
9782 (gdb_fopen_cloexec): Change return type.
9783 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
9784 * cli/cli-dump.c (fopen_with_cleanup): Remove.
9785 (dump_binary_file, restore_binary_file): Update.
9786 * auto-load.c (auto_load_objfile_script_1): Update.
9788 2017-08-03 Tom Tromey <tom@tromey.com>
9790 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
9791 (info_static_tracepoint_markers_command): Likewise.
9792 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
9793 * skip.c (skip_info): Use ui_out_emit_table.
9794 * progspace.c (print_program_space): Use ui_out_emit_table.
9795 * osdata.c (info_osdata): Use ui_out_emit_table.
9796 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
9798 * linux-thread-db.c (info_auto_load_libthread_db): Use
9800 * inferior.c (print_inferior): Use ui_out_emit_table.
9801 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
9802 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
9803 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
9804 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
9805 * ui-out.h (class ui_out_emit_table): New.
9807 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
9809 * mips-tdep.c (mips_fpu_type_str): New function.
9810 (mips_dump_tdep): Call it.
9812 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
9814 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
9817 2017-07-31 Xavier Roirand <roirand@adacore.com>
9819 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
9821 2017-07-27 Xavier Roirand <roirand@adacore.com>
9823 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
9825 2017-07-26 Yao Qi <yao.qi@linaro.org>
9827 * cli/cli-cmds.c (maintenancechecklist): New variable.
9828 * gdbcmd.h (maintenancechecklist): Declare it.
9829 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
9830 Call i386_linux_read_description with different masks.
9831 * maint.c (maintenance_check_command): New function.
9832 (_initialize_maint_cmds): Call add_prefix_cmd.
9833 * target-descriptions.c (tdesc_reg): override operator != and ==.
9834 (tdesc_type): Likewise.
9835 (tdesc_feature): Likewise.
9836 (target_desc): Likewise.
9837 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
9838 (maintenance_check_xml_descriptions): New function.
9839 (_initialize_target_descriptions) Add command "xml-descriptions".
9840 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
9842 2017-07-26 Yao Qi <yao.qi@linaro.org>
9844 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
9845 Include features/i386/32bit-*.c.
9846 (i386_linux_read_description): Generate target description if it
9848 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
9850 * features/i386/32bit-linux.c: Re-generated.
9851 * features/i386/32bit-sse.c: Likewise.
9852 * target-descriptions.c (print_c_feature::visit): Print code to
9853 set register number if needed.
9854 (print_c_feature) <m_next_regnum>: New field.
9856 2017-07-26 Yao Qi <yao.qi@linaro.org>
9858 * features/Makefile (CFILES): Rename with TDESC_CFILES.
9859 (FEATURE_XMLFILES): New.
9860 (FEATURE_CFILES): New.
9862 (clean-cfiles): Remove generated c files.
9863 * features/i386/32bit-avx.c: Generated.
9864 * features/i386/32bit-avx512.c: Generated.
9865 * features/i386/32bit-core.c: Generated.
9866 * features/i386/32bit-linux.c: Generated.
9867 * features/i386/32bit-mpx.c: Generated.
9868 * features/i386/32bit-pkeys.c: Generated.
9869 * features/i386/32bit-sse.c: Generated.
9870 * target-descriptions.c: Include algorithm.
9871 (tdesc_element_visitor): Add method visit_end.
9872 (print_c_tdesc): Implement visit_end.
9873 (print_c_tdesc:: m_filename_after_features): Move it to
9875 (print_c_feature): New class.
9876 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
9877 name starts with "i386/32bit-".
9879 2017-07-26 Yao Qi <yao.qi@linaro.org>
9881 * target-descriptions.c (tdesc_element_visitor): New class.
9882 (tdesc_element): New class.
9883 (tdesc_reg): Inherit from tdesc_element.
9884 (tdesc_reg::accept): New function.
9885 (tdesc_type): Inherit from tdesc_element.
9886 (tdesc_type::accept): New function.
9887 (tdesc_feature): Inherit from tdesc_element.
9888 (tdesc_feature::accept): New function.
9889 (target_desc): Inherit from tdesc_element.
9890 (target_desc::target_desc): New.
9891 (target_desc::~target_desc): New.
9892 (target_desc::accept): New.
9893 (allocate_target_description): Use new.
9894 (free_target_description): Use delete.
9895 (print_c_tdesc): New class.
9896 (maint_print_c_tdesc_cmd): Adjust.
9898 * features/aarch64.c: Re-generated.
9899 * features/arc-arcompact.c: Re-generated.
9900 * features/arc-v2.c: Re-generated.
9901 * features/arm/arm-with-iwmmxt.c: Re-generated.
9902 * features/arm/arm-with-m.c: Re-generated.
9903 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
9904 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
9905 * features/arm/arm-with-neon.c: Re-generated.
9906 * features/arm/arm-with-vfpv2.c: Re-generated.
9907 * features/arm/arm-with-vfpv3.c: Re-generated.
9908 * features/i386/amd64-avx-avx512.c: Re-generated.
9909 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9910 * features/i386/amd64-avx.c: Re-generated.
9911 * features/i386/amd64-avx-linux.c: Re-generated.
9912 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
9913 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9914 * features/i386/amd64-avx-mpx.c: Re-generated.
9915 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
9916 * features/i386/amd64.c: Re-generated.
9917 * features/i386/amd64-linux.c: Re-generated.
9918 * features/i386/amd64-mpx.c: Re-generated.
9919 * features/i386/amd64-mpx-linux.c: Re-generated.
9920 * features/i386/i386-avx-avx512.c: Re-generated.
9921 * features/i386/i386-avx-avx512-linux.c: Re-generated.
9922 * features/i386/i386-avx.c: Re-generated.
9923 * features/i386/i386-avx-linux.c: Re-generated.
9924 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
9925 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
9926 * features/i386/i386-avx-mpx.c: Re-generated.
9927 * features/i386/i386-avx-mpx-linux.c: Re-generated.
9928 * features/i386/i386.c: Re-generated.
9929 * features/i386/i386-linux.c: Re-generated.
9930 * features/i386/i386-mmx.c: Re-generated.
9931 * features/i386/i386-mmx-linux.c: Re-generated.
9932 * features/i386/i386-mpx.c: Re-generated.
9933 * features/i386/i386-mpx-linux.c: Re-generated.
9934 * features/i386/x32-avx-avx512.c: Re-generated.
9935 * features/i386/x32-avx-avx512-linux.c: Re-generated.
9936 * features/i386/x32-avx.c: Re-generated.
9937 * features/i386/x32-avx-linux.c: Re-generated.
9938 * features/i386/x32.c: Re-generated.
9939 * features/i386/x32-linux.c: Re-generated.
9940 * features/microblaze.c: Re-generated.
9941 * features/microblaze-with-stack-protect.c: Re-generated.
9942 * features/mips64-dsp-linux.c: Re-generated.
9943 * features/mips64-linux.c: Re-generated.
9944 * features/mips-dsp-linux.c: Re-generated.
9945 * features/mips-linux.c: Re-generated.
9946 * features/nds32.c: Re-generated.
9947 * features/nios2.c: Re-generated.
9948 * features/nios2-linux.c: Re-generated.
9949 * features/rs6000/powerpc-32.c: Re-generated.
9950 * features/rs6000/powerpc-32l.c: Re-generated.
9951 * features/rs6000/powerpc-403.c: Re-generated.
9952 * features/rs6000/powerpc-403gc.c : Re-generated.
9953 * features/rs6000/powerpc-405.c: Re-generated.
9954 * features/rs6000/powerpc-505.c: Re-generated.
9955 * features/rs6000/powerpc-601.c: Re-generated.
9956 * features/rs6000/powerpc-602.c: Re-generated.
9957 * features/rs6000/powerpc-603.c: Re-generated.
9958 * features/rs6000/powerpc-604.c: Re-generated.
9959 * features/rs6000/powerpc-64.c: Re-generated.
9960 * features/rs6000/powerpc-64l.c: Re-generated.
9961 * features/rs6000/powerpc-7400.c: Re-generated.
9962 * features/rs6000/powerpc-750.c: Re-generated.
9963 * features/rs6000/powerpc-860.c: Re-generated.
9964 * features/rs6000/powerpc-altivec32.c: Re-generated.
9965 * features/rs6000/powerpc-altivec32l.c: Re-generated.
9966 * features/rs6000/powerpc-altivec64.c: Re-generated.
9967 * features/rs6000/powerpc-altivec64l.c: Re-generated.
9968 * features/rs6000/powerpc-cell32l.c: Re-generated.
9969 * features/rs6000/powerpc-cell64l.c: Re-generated.
9970 * features/rs6000/powerpc-e500.c: Re-generated.
9971 * features/rs6000/powerpc-e500l.c: Re-generated.
9972 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
9973 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
9974 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
9975 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
9976 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
9977 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
9978 * features/rs6000/powerpc-vsx32.c: Re-generated.
9979 * features/rs6000/powerpc-vsx32l.c: Re-generated.
9980 * features/rs6000/powerpc-vsx64.c: Re-generated.
9981 * features/rs6000/powerpc-vsx64l.c: Re-generated.
9982 * features/rs6000/rs6000.c: Re-generated.
9983 * features/s390-linux32.c: Re-generated.
9984 * features/s390-linux32v1.c: Re-generated.
9985 * features/s390-linux32v2.c: Re-generated.
9986 * features/s390-linux64.c: Re-generated.
9987 * features/s390-linux64v1.c: Re-generated.
9988 * features/s390-linux64v2.c: Re-generated.
9989 * features/s390-te-linux64.c: Re-generated.
9990 * features/s390-tevx-linux64.c: Re-generated.
9991 * features/s390-vx-linux64.c: Re-generated.
9992 * features/s390x-linux64.c: Re-generated.
9993 * features/s390x-linux64v1.c: Re-generated.
9994 * features/s390x-linux64v2.c: Re-generated.
9995 * features/s390x-te-linux64.c: Re-generated.
9996 * features/s390x-tevx-linux64.c: Re-generated.
9997 * features/s390x-vx-linux64.c: Re-generated.
9998 * features/sparc/sparc32-solaris.c: Re-generated.
9999 * features/sparc/sparc64-solaris.c: Re-generated.
10000 * features/tic6x-c62x.c: Re-generated.
10001 * features/tic6x-c62x-linux.c: Re-generated.
10002 * features/tic6x-c64x.c: Re-generated.
10003 * features/tic6x-c64x-linux.c: Re-generated.
10004 * features/tic6x-c64xp.c: Re-generated.
10005 * features/tic6x-c64xp-linux.c: Re-generated.
10007 2017-07-26 Yao Qi <yao.qi@linaro.org>
10009 * i386-linux-tdep.c (i386_linux_read_description): New function.
10010 (i386_linux_core_read_description): Call
10011 i386_linux_read_description.
10012 * i386-linux-tdep.h (i386_linux_read_description): Declare.
10013 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
10014 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
10015 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
10016 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
10017 * x86-linux-nat.c (x86_linux_read_description): Call
10018 i386_linux_read_description.
10020 2017-07-26 Yao Qi <yao.qi@linaro.org>
10022 * NEWS: Mention it.
10023 * features/Makefile (%.c: %.xml): Pass the xml file name to
10024 command "maint print c-tdesc".
10025 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
10028 2017-07-26 Yao Qi <yao.qi@linaro.org>
10030 * target-descriptions.c (target_desc): Add ctor and dtor. Do
10031 in-class initialization.
10032 (tdesc_create_feature): Call new instead of XCNEW.
10033 (free_target_description): Ue delete.
10035 2017-07-25 John Baldwin <jhb@FreeBSD.org>
10037 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
10039 2017-07-25 Yao Qi <yao.qi@linaro.org>
10041 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
10043 (amd64_x32_init_abi): Likewise.
10044 * amd64-tdep.h (amd64_init_abi): Update declaration.
10045 (amd64_x32_init_abi): Likewise.
10047 2017-07-25 Yao Qi <yao.qi@linaro.org>
10050 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10051 condition for FPSCR.
10052 (arm_linux_store_inferior_registers): Likewise.
10054 2017-07-22 Tom Tromey <tom@tromey.com>
10056 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10057 <syscalls_counts>: Now a std::vector.
10058 (get_catch_syscall_inferior_data): Use "new".
10059 (catch_syscall_inferior_data_cleanup): Use "delete".
10060 (insert_catch_syscall, remove_catch_syscall)
10061 (clear_syscall_counts): Update.
10063 2017-07-22 Tom Tromey <tom@tromey.com>
10065 * break-catch-syscall.c (syscall_catchpoint)
10066 <syscalls_to_be_caught>: Now a std::vector<int>
10067 (~syscall_catchpoint): Remove.
10068 (insert_catch_syscall, remove_catch_syscall)
10069 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10070 (print_mention_catch_syscall, print_recreate_catch_syscall):
10072 (create_syscall_event_catchpoint): Change type of "filter"
10074 (catch_syscall_split_args): Return a std::vector.
10075 (catch_syscall_command_1, catching_syscall_number_1): Update.
10077 2017-07-22 Tom Tromey <tom@tromey.com>
10079 * break-catch-throw.c (struct exception_catchpoint)
10080 <exception_rx>: Now a std::string.
10081 (~exception_catchpoint): Remove.
10082 (print_one_detail_exception_catchpoint): Update.
10083 (handle_gnu_v3_exceptions): Change type of except_rx.
10084 (extract_exception_regexp): Return a std::string.
10085 (catch_exception_command_1): Update.
10087 2017-07-22 Tom Tromey <tom@tromey.com>
10089 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10090 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10092 <catch_all>: Now a bool.
10093 (~signal_catchpoint): Remove.
10094 (signal_catchpoint_insert_location)
10095 (signal_catchpoint_remove_location)
10096 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10097 (signal_catchpoint_print_mention)
10098 (signal_catchpoint_print_recreate)
10099 (signal_catchpoint_explains_signal): Update.
10100 (create_signal_catchpoint): Change type of "filter" and
10102 (catch_signal_split_args): Return a std::vector. Change type of
10104 (catch_signal_command): Update.
10106 2017-07-20 Pedro Alves <palves@redhat.com>
10108 * ada-lang.c (ada_language_defn): Make extern.
10109 (_initialize_ada_language): Remove add_language call.
10110 * c-lang.c (c_language_defn, cplus_language_defn)
10111 (asm_language_defn, minimal_language_defn): Make extern.
10112 (_initialize_c_language): Delete.
10113 * completer.c (compare_cstrings): Delete, moved to utils.h.
10114 * d-lang.c (d_language_defn): Make extern.
10115 (_initialize_d_language): Remove add_language calls.
10116 * defs.h (enum language): Add comment.
10117 * f-lang.c (f_language_defn): Make extern.
10118 (_initialize_f_language): Remove add_language call.
10119 * go-lang.c (go_language_defn): Make extern.
10120 (_initialize_go_language): Remove add_language call.
10121 * language.c: Include <algorithm>.
10122 (languages): Redefine as const array.
10123 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10124 (set_language_command): Handle "local". Use for-range loop.
10125 (set_language): Remove loop.
10126 (language_enum): Rewrite.
10127 (language_def, language_str): Remove loops.
10128 (add_language): Delete.
10129 (add_set_language_command): New, based on add_languages.
10130 (skip_language_trampoline): Adjust.
10131 (local_language_defn): Delete.
10132 (language_gdbarch_post_init): Adjust.
10133 (_initialize_language): Remove add_language calls. Call
10134 add_set_language_command.
10135 * language.h (add_language): Delete.
10136 (auto_language_defn)
10137 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10138 (asm_language_defn, c_language_defn, cplus_language_defn)
10139 (d_language_defn, f_language_defn, go_language_defn)
10140 (m2_language_defn, objc_language_defn, opencl_language_defn)
10141 (pascal_language_defn, rust_language_defn): Declare.
10142 * m2-lang.c (m2_language_defn): Make extern.
10143 (_initialize_m2_language): Remove add_language call.
10144 * objc-lang.c (objc_language_defn): Make extern.
10145 (_initialize_objc_language): Remove add_language call.
10146 * opencl-lang.c (opencl_language_defn): Make extern.
10147 (_initialize_opencl_language): Remove add_language call.
10148 * p-lang.c (pascal_language_defn): Make extern.
10149 (_initialize_pascal_language): Delete.
10150 * rust-lang.c (rust_language_defn): Make extern.
10151 (_initialize_rust_language): Delete.
10152 * utils.h (compare_cstrings): New static inline function.
10154 2017-07-20 Pedro Alves <palves@redhat.com>
10156 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10157 (get_var_value): Constify parameters.
10158 (get_int_var_value): Change prototype.
10159 (to_fixed_range_type): Adjust.
10160 * ada-lang.h (get_int_var_value): Change prototype.
10162 2017-07-20 Pedro Alves <palves@redhat.com>
10164 * dwarf2read.c (dw2_lookup_symbol): Use
10165 SYMBOL_MATCHES_SEARCH_NAME.
10166 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10168 2017-07-20 Pedro Alves <palves@redhat.com>
10170 * block.c (block_iter_name_step, block_iter_name_first)
10171 (block_iter_name_next): Delete.
10172 (block_lookup_symbol_primary): Adjust to use
10173 dict_iter_match_first/dict_iter_match_next.
10174 * block.h (block_iter_name_first, block_iter_name_next): Delete
10176 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10177 dict_iter_match_first/dict_iter_match_next.
10179 2017-07-20 Pedro Alves <palves@redhat.com>
10181 * cp-support.c (cp_find_first_component_aux): Add missing case for
10184 2017-07-18 David Blaikie <dblaikie@gmail.com>
10186 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10187 of dwo_cu's dwo_file.
10189 2017-07-18 Yao Qi <yao.qi@linaro.org>
10191 * remote.c (store_registers_using_G): Remove one line comment.
10193 2017-07-18 Yao Qi <yao.qi@linaro.org>
10195 * regcache.c (regcache_cpy): Simplify it.
10196 (regcache::cpy_no_passthrough): Remove it.
10197 * regcache.h (cpy_no_passthrough): Remove it.
10198 (regcache_dup, regcache_cpy): Update comments.
10200 2017-07-18 Pedro Alves <palves@redhat.com>
10202 * remote-sim.c (sim_command_completer): Adjust to work with a
10203 completion_tracker instead of a VEC.
10205 2017-07-17 Pedro Alves <palves@redhat.com>
10207 * completer.c (complete_source_filenames): New function.
10208 (complete_address_and_linespec_locations): New function.
10209 (location_completer): Use complete_address_and_linespec_locations.
10210 (completion_tracker::build_completion_result): Honor the tracker's
10211 request to suppress append.
10212 * completer.h (completion_tracker::suppress_append_ws)
10213 (completion_tracker::set_suppress_append_ws): New methods.
10214 (completion_tracker::m_suppress_append_ws): New field.
10215 (complete_source_filenames): New declaration.
10216 * linespec.c (linespec_complete_what): New.
10217 (struct ls_parser) <complete_what, completion_word,
10218 completion_quote_char, completion_quote_end, completion_tracker>:
10220 (string_find_incomplete_keyword_at_end): New.
10221 (linespec_lexer_lex_string): Record quote char. If in completion
10223 (linespec_lexer_consume_token): Advance the completion word point.
10224 (linespec_lexer_peek_token): Save/restore completion info.
10225 (save_stream_and_consume_token): New.
10226 (set_completion_after_number): New.
10227 (linespec_parse_basic): Set what to complete next depending on
10228 token. Handle function and label completions specially.
10229 (parse_linespec): Disable objc shortcut in completion mode. Set
10230 what to complete next depending on token type. Skip keyword if in
10232 (complete_linespec_component, linespec_complete): New.
10233 * linespec.h (linespec_complete): Declare.
10235 2017-07-17 Pedro Alves <palves@redhat.com>
10237 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10238 Handle 'operator<' / 'operator<<'.
10240 2017-07-17 Pedro Alves <palves@redhat.com>
10242 * completer.c (collect_explicit_location_matches): Handle
10244 (convert_explicit_location_to_linespec): New, factored out from
10246 (convert_explicit_location_to_sals): ... this.
10247 (complete_label): New.
10248 (linespec_complete_label, find_label_symbols_in_block): New.
10249 (find_label_symbols): Add completion_mode parameter and adjust to
10250 call find_label_symbols_in_block.
10251 * linespec.h (linespec_complete_label): Declare.
10253 2017-07-17 Pedro Alves <palves@redhat.com>
10255 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10256 complete_symbol_mode parameter.
10257 * cli/cli-cmds.c (complete_command): Get the completion result out
10258 of the handle_brkchars tracker if used a custom word point.
10259 * completer.c: Include "linespec.h".
10260 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10261 (advance_to_expression_complete_word_point): New.
10262 (completion_tracker::completes_to_completion_word): New.
10263 (complete_files_symbols): Pass down
10264 complete_symbol_mode::EXPRESSION.
10265 (explicit_options, probe_options): New.
10266 (collect_explicit_location_matches): Complete on the
10267 explictit_loc->foo instead of word. Use
10268 linespec_complete_function. Handle MATCH_LINE. Handle offering
10269 keyword and options completions.
10270 (backup_text_ptr): Delete.
10271 (skip_keyword): New.
10272 (complete_explicit_location): Remove 'word' parameter. Add
10273 language, quoted_arg_start and quoted_arg_end parameters.
10274 Rewrite, parsing left to right.
10275 (location_completer): Rewrite.
10276 (location_completer_handle_brkchars): New function.
10277 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10278 (enum complete_line_internal_reason): Adjust comments.
10279 (completion_tracker::discard_completions): New.
10280 (completer_handle_brkchars_func_for_completer): Handle
10281 location_completer.
10282 (gdb_custom_word_point_brkchars)
10283 (gdb_org_rl_basic_quote_characters): New.
10284 (gdb_completion_word_break_characters_throw)
10285 (completion_find_completion_word): Handle trackers that use a
10287 (completion_tracker::advance_custom_word_point_by): New.
10288 (completion_tracker::build_completion_result): Don't rely on
10289 readline appending the quote char.
10290 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10291 use a custom word point.
10292 (gdb_rl_attempted_completion_function): Restore
10293 rl_basic_quote_characters.
10294 * completer.h (class completion_tracker): Extend intro comment.
10295 (completion_tracker::set_quote_char)
10296 (completion_tracker::quote_char)
10297 (completion_tracker::set_use_custom_word_point)
10298 (completion_tracker::use_custom_word_point)
10299 (completion_tracker::custom_word_point)
10300 (completion_tracker::set_custom_word_point)
10301 (completion_tracker::advance_custom_word_point_by)
10302 (completion_tracker::completes_to_completion_word)
10303 (completion_tracker::discard_completions): New methods.
10304 (completion_tracker::m_quote_char)
10305 (completion_tracker::m_use_custom_word_point)
10306 (completion_tracker::m_custom_word_point): New fields.
10307 (advance_to_expression_complete_word_point): Declare.
10308 * f-lang.c (f_collect_symbol_completion_matches): Add
10309 complete_symbol_mode parameter.
10310 * language.h (struct language_defn)
10311 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10313 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10314 (linespec_complete_function): New function.
10315 (linespec_lexer_lex_keyword): Adjust.
10316 * linespec.h (linespec_keywords, linespec_complete_function): New
10318 * location.c (find_end_quote): New function.
10319 (explicit_location_lex_one): Add explicit_completion_info
10320 parameter. Save quoting info. Don't throw if being called for
10321 completion. Don't handle Ada operators here.
10322 (is_cp_operator, skip_op_false_positives, first_of)
10323 (explicit_location_lex_one_function): New function.
10324 (string_to_explicit_location): Replace 'dont_throw' parameter with
10325 an explicit_completion_info pointer parameter. Handle it. Don't
10326 use explicit_location_lex_one to lex function names. Use
10327 explicit_location_lex_one_function instead.
10328 * location.h (struct explicit_completion_info): New.
10329 (string_to_explicit_location): Replace 'dont_throw' parameter with
10330 an explicit_completion_info pointer parameter.
10331 * symtab.c (default_collect_symbol_completion_matches_break_on):
10332 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10333 (default_collect_symbol_completion_matches)
10334 (collect_symbol_completion_matches): Add complete_symbol_mode
10336 (collect_symbol_completion_matches_type): Pass down
10337 complete_symbol_mode::EXPRESSION.
10338 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10339 parameter. Handle LINESPEC mode.
10340 * symtab.h (complete_symbol_mode): New.
10341 (default_collect_symbol_completion_matches_break_on)
10342 (default_collect_symbol_completion_matches)
10343 (collect_symbol_completion_matches)
10344 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10347 2017-07-17 Pedro Alves <palves@redhat.com>
10349 * utils.c (enum class strncmp_iw_mode): New.
10350 (strcmp_iw): Rename to ...
10351 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10352 parameters. Handle them.
10354 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10355 * utils.h (strncmp_iw): Declare.
10356 (strcmp_iw): Move describing comments here.
10358 2017-07-17 Pedro Alves <palves@redhat.com>
10360 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10362 * c-typeprint.c (is_type_conversion_operator): Use
10364 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10365 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10367 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10368 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10369 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10370 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10372 * location.c: Include "cp-support.h".
10373 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10375 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10378 2017-07-17 Pedro Alves <palves@redhat.com>
10380 * cli/cli-cmds.c (complete_command): Use a completion tracker
10381 along with completion_find_completion_word for handle_brkchars
10383 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10384 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10385 (struct gdb_rl_completion_word_info): New.
10386 (gdb_rl_find_completion_word): New.
10387 (completion_find_completion_word): New.
10388 * completer.h (completion_find_completion_word): Declare.
10390 2017-07-17 Pedro Alves <palves@redhat.com>
10392 * ada-lang.c (symbol_completion_match): Adjust comments.
10393 (symbol_completion_add): Replace vector parameter with
10394 completion_tracker parameter. Use it.
10395 (ada_make_symbol_completion_list): Rename to...
10396 (ada_collect_symbol_completion_matches): ... this. Add
10397 completion_tracker parameter and use it.
10398 (ada_language_defn): Adjust.
10399 * break-catch-syscall.c (catch_syscall_completer): Adjust
10400 prototype and work with completion_tracker instead of VEC.
10401 * breakpoint.c (condition_completer): Adjust prototype and work
10402 with completion_tracker instead of VEC.
10403 * c-lang.c (c_language_defn, cplus_language_defn)
10404 (asm_language_defn, minimal_language_defn): Adjust to renames.
10405 * cli/cli-cmds.c (complete_command): Rework using
10406 completion_tracker. Catch exceptions when completing.
10407 * cli/cli-decode.c (integer_unlimited_completer)
10408 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
10409 with completion_tracker instead of VEC.
10410 * command.h (struct completion_tracker): Forward declare.
10411 (completer_ftype, completer_handle_brkchars_ftype): Change
10413 (complete_on_cmdlist, complete_on_enum): Adjust.
10414 * completer.c: Include <algorithm>.
10415 (struct gdb_completer_state): New.
10416 (current_completion): New global.
10417 (readline_line_completion_function): Delete.
10418 (noop_completer, filename_completer)
10419 (filename_completer_handle_brkchars, complete_files_symbols)
10420 (linespec_location_completer): Adjust to work with a
10421 completion_tracker instead of a VEC.
10422 (string_or_empty): New.
10423 (collect_explicit_location_matches): Adjust to work with a
10424 completion_tracker instead of a VEC.
10425 (explicit_location_completer): Rename to ...
10426 (complete_explicit_location): ... this and adjust to work with a
10427 completion_tracker instead of a VEC.
10428 (location_completer): Adjust to work with a completion_tracker
10430 (add_struct_fields): Adjust to work with a completion_list instead
10432 (expression_completer): Rename to ...
10433 (complete_expression): ... this and adjust to work with a
10434 completion_tracker instead of a VEC. Use complete_files_symbols.
10435 (expression_completer): Reimplement on top of complete_expression.
10436 (symbol_completer): Adjust to work with a completion_tracker
10438 (enum complete_line_internal_reason): Add describing comments.
10439 (complete_line_internal_normal_command): Adjust to work with a
10440 completion_tracker instead of a VEC.
10441 (complete_line_internal): Rename to ...
10442 (complete_line_internal_1): ... this and adjust to work with a
10443 completion_tracker instead of a VEC. Assert TEXT is NULL in the
10444 handle_brkchars phase.
10445 (new_completion_tracker): Delete.
10446 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
10447 complete_line_internal_1.
10448 (free_completion_tracker): Delete.
10449 (INITIAL_COMPLETION_HTAB_SIZE): New.
10450 (completion_tracker::completion_tracker)
10451 (completion_tracker::~completion_tracker): New.
10452 (maybe_add_completion): Delete.
10453 (completion_tracker::maybe_add_completion)
10454 (completion_tracker::add_completion)
10455 (completion_tracker::add_completions): New.
10456 (throw_max_completions_reached_error): Delete.
10457 (complete_line): Adjust to work with a completion_tracker instead
10458 of a VEC. Don't create a completion_tracker_t or check for max
10460 (command_completer, command_completer_handle_brkchars)
10461 (signal_completer, reg_or_group_completer_1)
10462 (reg_or_group_completer, default_completer_handle_brkchars):
10463 Adjust to work with a completion_tracker.
10464 (gdb_completion_word_break_characters_throw): New.
10465 (gdb_completion_word_break_characters): Reimplement.
10466 (line_completion_function): Delete.
10467 (completion_tracker::recompute_lowest_common_denominator)
10468 (expand_preserving_ws)
10469 (completion_tracker::build_completion_result)
10470 (completion_result::completion_result)
10471 (completion_result::completion_result)
10472 (completion_result::~completion_result)
10473 (completion_result::completion_result)
10474 (completion_result::release_match_list, compare_cstrings)
10475 (completion_result::sort_match_list)
10476 (completion_result::reset_match_list)
10477 (gdb_rl_attempted_completion_function_throw)
10478 (gdb_rl_attempted_completion_function): New.
10479 * completer.h (completion_list, struct completion_result)
10480 (class completion_tracker): New.
10481 (complete_line): Add completion_tracker parameter.
10482 (readline_line_completion_function): Delete.
10483 (gdb_rl_attempted_completion_function): New.
10484 (noop_completer, filename_completer, expression_completer)
10485 (location_completer, symbol_completer, command_completer)
10486 (signal_completer, reg_or_group_completer): Update prototypes.
10487 (completion_tracker_t, new_completion_tracker)
10488 (make_cleanup_free_completion_tracker): Delete.
10489 (enum maybe_add_completion_enum): Delete.
10490 (maybe_add_completion): Delete.
10491 (throw_max_completions_reached_error): Delete.
10492 * corefile.c (complete_set_gnutarget): Adjust to work with a
10493 completion_tracker instead of a VEC.
10494 * cp-abi.c (cp_abi_completer): Adjust to work with a
10495 completion_tracker instead of a VEC.
10496 * d-lang.c (d_language_defn): Adjust.
10497 * disasm.c (disassembler_options_completer): Adjust to work with a
10498 completion_tracker instead of a VEC.
10499 * f-lang.c (f_make_symbol_completion_list): Rename to ...
10500 (f_collect_symbol_completion_matches): ... this. Adjust to work
10501 with a completion_tracker instead of a VEC.
10502 (f_language_defn): Adjust.
10503 * go-lang.c (go_language_defn): Adjust.
10504 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
10505 Adjust to work with a completion_tracker instead of a VEC.
10506 * infrun.c (handle_completer): Likewise.
10507 * interps.c (interpreter_completer): Likewise.
10508 * interps.h (interpreter_completer): Likewise.
10509 * language.c (unknown_language_defn, auto_language_defn)
10510 (local_language_defn): Adjust.
10511 * language.h (language_defn::la_make_symbol_completion_list):
10513 (language_defn::la_collect_symbol_completion_matches): ... this
10514 and adjust to work with a completion_tracker instead of a VEC.
10515 * m2-lang.c (m2_language_defn): Adjust.
10516 * objc-lang.c (objc_language_defn): Adjust.
10517 * opencl-lang.c (opencl_language_defn): Adjust.
10518 * p-lang.c (pascal_language_defn): Adjust.
10519 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
10520 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
10521 with a completion_tracker.
10522 * rust-lang.c (rust_language_defn): Adjust.
10523 * symtab.c (free_completion_list, do_free_completion_list)
10524 (return_val, completion_tracker): Delete.
10525 (completion_list_add_name, completion_list_add_symbol)
10526 (completion_list_add_msymbol, completion_list_objc_symbol)
10527 (completion_list_add_fields, add_symtab_completions): Add
10528 completion_tracker parameter and use it.
10529 (default_make_symbol_completion_list_break_on_1): Rename to...
10530 (default_collect_symbol_completion_matches_break_on): ... this.
10531 Add completion_tracker parameter and use it instead of allocating
10532 a completion tracker here.
10533 (default_make_symbol_completion_list_break_on): Delete old
10535 (default_make_symbol_completion_list): Delete.
10536 (default_collect_symbol_completion_matches): New.
10537 (make_symbol_completion_list): Delete.
10538 (collect_symbol_completion_matches): New.
10539 (make_symbol_completion_type): Rename to ...
10540 (collect_symbol_completion_matches_type): ... this. Add
10541 completion_tracker parameter and use it instead of VEC.
10542 (make_file_symbol_completion_list_1): Rename to...
10543 (collect_file_symbol_completion_matches): ... this. Add
10544 completion_tracker parameter and use it instead of VEC.
10545 (make_file_symbol_completion_list): Delete.
10546 (add_filename_to_list): Use completion_list instead of a VEC.
10547 (add_partial_filename_data::list): Now a completion_list.
10548 (make_source_files_completion_list): Work with a completion_list
10550 * symtab.h: Include "completer.h".
10551 (default_make_symbol_completion_list_break_on)
10552 (default_make_symbol_completion_list, make_symbol_completion_list)
10553 (make_symbol_completion_type, make_file_symbol_completion_list)
10554 (make_source_files_completion_list): Delete.
10555 (default_collect_symbol_completion_matches_break_on)
10556 (default_collect_symbol_completion_matches)
10557 (collect_symbol_completion_matches)
10558 (collect_symbol_completion_matches_type)
10559 (collect_file_symbol_completion_matches)
10560 (make_source_files_completion_list): New.
10561 * top.c (init_main): Don't install a rl_completion_entry_function
10562 hook. Install a rl_attempted_completion_function hook instead.
10563 * tui/tui-layout.c (layout_completer): Adjust to work with a
10564 completion_tracker.
10565 * tui/tui-regs.c (tui_reggroup_completer):
10566 * tui/tui-win.c (window_name_completer, focus_completer)
10567 (winheight_completer): Adjust to work with a completion_tracker.
10568 * value.c: Include "completer.h".
10569 (complete_internalvar): Adjust to work with a completion_tracker.
10570 * value.h (complete_internalvar): Likewise.
10572 2017-07-17 Pedro Alves <palves@redhat.com>
10574 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
10576 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
10577 comments to completer_ftype's declaration.
10578 <completer_handle_brkchars>: Change type to
10579 completer_handle_brkchars_ftype.
10580 * command.h (completer_ftype): Add describing comment and give
10581 names to parameters.
10582 (completer_ftype_void): Rename to ...
10583 (completer_handle_brkchars_ftype) ... this. Add describing comment.
10584 (set_cmd_completer_handle_brkchars): Adjust.
10585 * completer.c (filename_completer_handle_brkchars): New function.
10586 (complete_line_internal_normal_command): New function, factored
10588 (complete_line_internal): ... here.
10589 (command_completer_handle_brkchars)
10590 (default_completer_handle_brkchars)
10591 (completer_handle_brkchars_func_for_completer): New functions.
10592 * completer.h (set_gdb_completion_word_break_characters): Delete
10594 (completer_handle_brkchars_func_for_completer): New declaration.
10595 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
10596 completer_handle_brkchars_func_for_completer.
10598 2017-07-17 Pedro Alves <palves@redhat.com>
10600 * completer.c (symbol_completer): New function, based on
10601 make_symbol_completion_list_fn.
10602 * completer.h (symbol_completer): New declaration.
10603 * guile/scm-cmd.c (cmdscm_completers): Adjust.
10604 * python/py-cmd.c (completers): Adjust.
10605 * symtab.c (make_symbol_completion_list_fn): Delete.
10606 * symtab.h (make_symbol_completion_list_fn): Delete.
10607 * cli/cli-decode.c (add_cmd): Adjust.
10609 2017-07-17 Pedro Alves <palves@redhat.com>
10611 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
10612 * dwarf2read.c: Include "filename-seen-cache.h".
10613 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
10614 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
10615 * filename-seen-cache.c: New file.
10616 * filename-seen-cache.h: New file.
10617 * symtab.c: Include "filename-seen-cache.h".
10618 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
10619 (create_filename_seen_cache, clear_filename_seen_cache)
10620 (delete_filename_seen_cache, filename_seen): Delete, parts moved
10621 to filename-seen-cache.h/filename-seen-cache.c.
10622 (output_source_filename, sources_info)
10623 (maybe_add_partial_symtab_filename)
10624 (make_source_files_completion_list): Adjust to use
10625 filename_seen_cache.
10627 2017-07-17 Pedro Alves <palves@redhat.com>
10629 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
10631 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
10632 dwarf2_debug_sections*)): New.
10633 (dwarf2_per_objfile::dwarf2_per_objfile(const
10634 dwarf2_per_objfile&)): Declare as deleted.
10635 (dwarf2_per_objfile::operator=): Declare as deleted.
10636 (dwarf2_per_objfile::dwarf2_per_objfile)
10637 (dwarf2_per_objfile::~dwarf2_per_objfile)
10638 (dwarf2_per_objfile::free_cached_comp_units): New.
10639 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
10640 ctor. Call dwarf2_per_objfile's ctor manually.
10641 (dwarf2_locate_sections): Deleted/refactored as ...
10642 (dwarf2_per_objfile::locate_sections): ... this new method.
10643 (free_cached_comp_units): Defer to
10644 dwarf2_per_objfile::free_cached_comp_units.
10645 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
10647 2017-07-14 Tom Tromey <tom@tromey.com>
10650 * rust-exp.y (convert_ast_to_expression): Add "want_type"
10652 <UNOP_SIZEOF>: Split into separate case.
10653 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
10655 2017-07-14 Tom Tromey <tom@tromey.com>
10658 * symtab.c (symbol_matches_domain): Add language_rust to special
10660 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
10661 treat LOC_TYPEDEF symbols as variables.
10663 2017-07-14 Pedro Alves <palves@redhat.com>
10665 * symtab.c (make_file_symbol_completion_list_1): Iterate over
10666 symtabs matching all symtabs with SRCFILE as file name instead of
10667 only considering the first hit, with lookup_symtab.
10669 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10671 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
10672 operator_name parameters.
10673 (gen_expr): Update function call.
10675 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10677 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
10679 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
10681 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
10682 parameter, use agent_expr::gdbarch instead, update function
10684 (locexpr_tracepoint_var_ref): Likewise.
10685 (loclist_tracepoint_var_ref): Likewise.
10686 * ax-gdb.c (gen_trace_static_fields): Likewise.
10687 (gen_traced_pop): Likewise.
10688 (gen_frame_args_address): Likewise.
10689 (gen_frame_locals_address): Likewise.
10690 (gen_var_ref): Likewise.
10691 (gen_struct_ref_recursive): Likewise.
10692 (gen_static_field): Likewise.
10693 (gen_maybe_namespace_elt): Likewise.
10694 (gen_expr): Likewise.
10695 (gen_trace_for_var): Likewise.
10696 (gen_trace_for_expr): Likewise.
10697 (gen_trace_for_return_address): Likewise.
10699 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10701 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
10703 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
10705 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10707 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
10708 from ax, update calls.
10709 (gen_usual_arithmetic): Likewise.
10710 (gen_integral_promotions): Likewise.
10711 (gen_bitfield_ref): Likewise.
10712 (gen_primitive_field): Likewise.
10713 (gen_struct_ref_recursive): Likewise.
10714 (gen_struct_ref): Likewise.
10715 (gen_maybe_namespace_elt): Likewise.
10716 (gen_struct_elt_for_reference): Likewise.
10717 (gen_namespace_elt): Likewise.
10718 (gen_aggregate_elt_ref): Likewise.
10719 (gen_expr): Get gdbarch from ax, update calls.
10720 (gen_expr_binop_rest): Likewise.
10722 2017-07-13 Pedro Alves <palves@redhat.com>
10724 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
10726 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
10727 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
10728 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
10729 tdesc_amd64_linux as default tdesc. Get final tdesc from the
10731 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
10732 Get final tdesc from the tdep.
10733 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
10735 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
10736 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
10737 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
10738 Use it as default tdesc.
10739 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
10740 down to amd_init_abi. No longer handle fallback tdesc here.
10741 * amd64-tdep.h (tdesc_x32): Declare.
10742 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
10744 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
10747 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10749 * s390-linux-tdep.c (s390_process_record): Add support for
10750 instructions new in arch12.
10752 2017-07-11 John Baldwin <jhb@FreeBSD.org>
10754 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
10755 PT_GETFSBASE and PT_GETGSBASE.
10756 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
10759 2017-07-11 John Baldwin <jhb@FreeBSD.org>
10761 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
10762 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
10763 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
10765 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
10766 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
10767 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
10768 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
10769 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
10770 * features/i386/amd64.xml: Add 64bit-segments.xml.
10771 * features/i386/amd64-avx-avx512.c: Regenerated.
10772 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
10773 * features/i386/amd64-avx-mpx.c: Regenerated.
10774 * features/i386/amd64-avx.c: Regenerated.
10775 * features/i386/amd64-mpx.c: Regenerated.
10776 * features/i386/amd64.c: Regenerated.
10777 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
10778 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10779 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
10780 * regformats/i386/amd64-avx.dat: Regenerated.
10781 * regformats/i386/amd64-mpx.dat: Regenerated.
10782 * regformats/i386/amd64.dat: Regenerated.
10784 2017-07-10 Yao Qi <yao.qi@linaro.org>
10786 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10787 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10789 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
10791 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
10793 * gnulib/aclocal.m4: Regenerate.
10794 * gnulib/config.in: Regenerate.
10795 * gnulib/configure: Regenerate.
10796 * gnulib/import/Makefile.am: Regenerate.
10797 * gnulib/import/Makefile.in: Regenerate.
10798 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
10799 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
10800 * gnulib/import/m4/environ.m4: New file.
10801 * gnulib/import/m4/setenv.m4: New file.
10802 * gnulib/import/setenv.c: New file.
10803 * gnulib/import/unsetenv.c: New file.
10805 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
10807 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
10808 address when op is DW_OP_addr.
10810 2017-07-09 Tom Tromey <tom@tromey.com>
10812 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
10813 check and apply to outer type.
10815 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10817 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
10818 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
10819 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
10820 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
10822 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10824 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
10826 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10828 * corelow.c (get_core_siginfo): Remove.
10829 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
10830 instead of get_core_siginfo.
10831 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
10832 * gdbarch.h: Re-generate.
10833 * gdbarch.c: Re-generate.
10834 * linux-tdep.c (linux_core_xfer_siginfo): New.
10835 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
10837 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10839 * corelow.c (thread_section_name): Move to ...
10840 * gdbcore.h (thread_section_name): ... here.
10842 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10844 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
10845 (struct siginfo32): New.
10846 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
10847 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
10848 via ptrace(PT_LWPINFO).
10850 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10852 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
10853 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
10854 (fbsd_get_siginfo_type): New.
10855 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
10856 (_initialize_fbsd_tdep): New.
10858 2017-07-06 David Blaikie <dblaikie@gmail.com>
10860 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
10861 a singular dwo_unit*) to support multiple CUs in the same way that
10862 multiple TUs are supported.
10863 (create_cus_hash_table): Replace create_dwo_cu with a function for
10864 parsing multiple CUs from a DWO file.
10865 (open_and_init_dwo_file): Use create_cus_hash_table rather than
10867 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
10868 htab_find, rather than comparing the signature to a singleton CU in
10871 2017-07-06 Pedro Alves <palves@redhat.com>
10873 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
10875 2017-07-04 Pedro Alves <palves@redhat.com>
10877 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
10878 * gdbtypes.h (TYPE_STATIC): Delete.
10879 (struct fn_field) <is_public, is_abstract, is_static, is_final,
10880 is_synchronized, is_native>: Delete.
10882 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
10883 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
10884 (TYPE_FN_FIELD_ABSTRACT): Delete.
10886 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
10888 * buffer.h (buffer_finish): Fix spelling mistakes.
10890 2017-07-01 Eli Zaretskii <eliz@gnu.org>
10892 * .dir-locals.el: Automatically switch to C-style comments in
10893 versions of Emacs that support the feature.
10895 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10896 Pedro Alves <palves@redhat.com>
10899 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
10900 (process_next_line): New variable 'inline_cmd'.
10901 Adjust 'if' clauses for "python", "compile" and "guile" to use
10902 'command_name_equals' and check for '!inline_cmd'.
10904 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10907 * cli/cli-script.c (command_name_equals_not_inline): New function.
10908 (process_next_line): Adjust 'if' clauses for "python", "compile"
10909 and "guile" to use command_name_equals_not_inline.
10911 2017-06-29 Pedro Alves <palves@redhat.com>
10913 * completer.c (expression_completer): Call
10914 linespec_location_completer instead of location_completer.
10916 2017-06-29 Pedro Alves <palves@redhat.com>
10918 * completer.c (expression_completer): Remove code that recomputes
10919 'text' from 'word'.
10921 2017-06-29 Yao Qi <yao.qi@linaro.org>
10923 * regformats/regdat.sh: Generate code with
10924 "ifndef IN_PROCESS_AGENT".
10926 2017-06-28 Pedro Alves <palves@redhat.com>
10928 * command.h: Include "common/scoped_restore.h".
10930 2017-06-28 Yao Qi <yao.qi@linaro.org>
10932 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
10933 instead of obstack_grow.
10935 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
10938 * symfile.c (reread_symbols): Call objfiles_changed just before
10941 2017-06-27 Pedro Alves <palves@redhat.com>
10943 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
10944 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
10945 (completion_list_add_symbol, completion_list_add_msymbol):
10946 ... these new functions.
10947 (add_symtab_completions)
10948 (default_make_symbol_completion_list_break_on_1): Adjust.
10950 2017-06-27 Pedro Alves <palves@redhat.com>
10952 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
10953 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
10954 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
10956 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
10957 'storage_obstack' field an auto_obstack. In-class initialize all
10958 non-bitfield fields. Make minsyms_read bool.
10959 * symfile.c (read_symbols): Adjust.
10961 2017-06-27 Alan Hayward <alan.hayward@arm.com>
10963 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
10964 (gdbsim_store_register): Likewise.
10966 2017-06-27 Pedro Alves <palves@redhat.com>
10968 * c-exp.y (name_obstack): Now an auto_obstack.
10969 (yylex): Use auto_obstack::clear.
10970 (c_parse): Use auto_obstack::clear instead of reinitializing and
10971 freeing the obstack.
10972 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
10973 * d-exp.y (name_obstack): Now an auto_obstack.
10974 (yylex): Use auto_obstack::clear.
10975 (d_parse): Use auto_obstack::clear instead of reinitializing and
10976 freeing the obstack.
10977 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
10979 * dwarf2read.c (create_addrmap_from_index)
10980 (dwarf2_build_psymtabs_hard)
10981 (update_enumeration_type_from_children): Likewise.
10982 * gdb_obstack.h (auto_obstack): New type.
10983 * go-exp.y (name_obstack): Now an auto_obstack.
10984 (build_packaged_name): Use auto_obstack::clear.
10985 (go_parse): Use auto_obstack::clear instead of reinitializing and
10986 freeing the obstack.
10987 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
10989 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
10990 * rust-exp.y (work_obstack): Now an auto_obstack.
10991 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
10992 reinitializing and freeing the obstack.
10993 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
10994 (host_char_to_target): Use auto_obstack.
10995 * utils.h (make_cleanup_obstack_free): Delete declaration.
10996 * valprint.c (generic_emit_char, generic_printstr): Use
10999 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
11001 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
11003 (darwin_init_thread_list): Don't update dummy thread.
11004 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
11006 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11008 * record-full.c (netorder16): Remove.
11010 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11012 * common/diagnostics.h: Define macros for GCC.
11013 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
11014 * common/vec.h: Include diagnostics.h.
11015 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
11016 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
11019 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11021 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
11023 * ada-lex.l: Ignore deprecated register warnings.
11025 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11027 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
11028 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
11030 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11032 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
11035 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11037 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
11039 2017-06-23 Alan Hayward <alan.hayward@arm.com>
11041 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
11042 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
11043 (xtensa_register_read_masked): Likewise.
11045 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
11047 * common/environ.c (gdb_environ::unset): Update comment.
11049 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11051 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11054 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11056 * record-full.c (record_full_exec_insn): Use byte_vector.
11058 2017-06-22 Yao Qi <yao.qi@linaro.org>
11060 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11061 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11063 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11065 * remote.c (cached_reg): Move from here...
11066 * regcache.h (cached_reg): ...to here.
11067 * python/py-unwind.c (struct reg_info): Remove.
11068 (cached_frame_info): Use cached_reg_t.
11069 (pyuw_prev_register): Likewise.
11070 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11071 (pyuw_dealloc_cache): Free all registers.
11073 2017-06-22 Pedro Alves <palves@redhat.com>
11074 Simon Marchi <simon.marchi@ericsson.com>
11076 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11078 * common/diagnostics.h: New file.
11080 2017-06-22 Pedro Alves <palves@redhat.com>
11082 * common/agent.h: Add include guards.
11084 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11086 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11087 talk about addressable units instead of bytes.
11089 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11091 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11092 of '::const_iterator'.
11094 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11096 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11097 'unittests/environ-selftests.c'.
11098 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11099 * charset.c (find_charset_names): Declare object 'iconv_env'.
11100 Update code to use 'iconv_env' object. Remove call to
11102 * common/environ.c: Include <utility>.
11103 (make_environ): Delete function.
11104 (free_environ): Delete function.
11105 (gdb_environ::clear): New function.
11106 (gdb_environ::operator=): New function.
11107 (gdb_environ::get): Likewise.
11108 (environ_vector): Delete function.
11109 (set_in_environ): Delete function.
11110 (gdb_environ::set): New function.
11111 (unset_in_environ): Delete function.
11112 (gdb_environ::unset): New function.
11113 (gdb_environ::envp): Likewise.
11114 * common/environ.h: Include <vector>.
11115 (struct gdb_environ): Delete; transform into...
11116 (class gdb_environ): ... this class.
11117 (free_environ): Delete prototype.
11118 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11119 environ_vector): Likewise.
11120 * infcmd.c (run_command_1): Update code to call
11121 'envp' from 'gdb_environ' class.
11122 (environment_info): Update code to call methods from 'gdb_environ'
11124 (unset_environment_command): Likewise.
11125 (path_info): Likewise.
11126 (path_command): Likewise.
11127 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11128 (inferior::inferior): Initialize 'environment' using the host's
11130 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11131 Include "environ.h".
11132 (class inferior) <environment>: Change type from 'struct
11133 gdb_environ' to 'gdb_environ'.
11134 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11135 methods from 'gdb_environ' class.
11136 * solib.c (solib_find_1): Likewise
11137 * unittests/environ-selftests.c: New file.
11139 2017-06-20 Yao Qi <yao.qi@linaro.org>
11141 * features/i386/i386-linux.xml: Exchange the order of including
11142 32bit-linux.xml and 32bit-sse.xml.
11143 * features/i386/i386-linux.c: Regenerated.
11145 2017-06-20 Yao Qi <yao.qi@linaro.org>
11147 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11148 Delete copy ctor and assignment operator.
11149 (tdesc_type): Likewise.
11150 (tdesc_feature): Likewise.
11151 (tdesc_free_reg): Remove.
11152 (tdesc_create_reg): Use new.
11153 (tdesc_free_type): Remove.
11154 (tdesc_create_vector): Use new.
11155 (tdesc_create_union): Likewise.
11156 (tdesc_create_flags): Likewise.
11157 (tdesc_create_enum): Likewise.
11158 (tdesc_free_feature): Delete.
11159 (free_target_description): Use delete.
11161 2017-06-19 John Baldwin <jhb@FreeBSD.org>
11163 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11166 2017-06-19 Pedro Alves <palves@redhat.com>
11168 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11169 after gdb::unlinker.
11171 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11173 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11174 gdb_environ to access an environment variable.
11176 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11178 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11181 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11183 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11185 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11187 * configure: Re-generate.
11188 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11190 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11192 * configure: Re-generate.
11193 * warning.m4: Pass -Werror to compiler when checking for
11194 supported warning flags.
11196 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11198 * Makefile.in (COMPILE.pre): Add "-x c++".
11200 2017-06-16 Alan Hayward <alan.hayward@arm.com>
11201 Pedro Alves <palves@redhat.com>
11202 Yao Qi <yao.qi@linaro.org>
11204 * defs.h (RequireLongest): New.
11205 (extract_integer): Declare function template.
11206 (extract_signed_integer): Remove the declaration, but define it
11208 (extract_unsigned_integer): Likewise.
11209 (store_integer): Declare function template.
11210 (store_signed_integer): Remove the declaration, but define it
11212 (store_unsigned_integer): Likewise.
11213 * findvar.c (extract_integer): New function template.
11214 (extract_signed_integer): Remove.
11215 (extract_unsigned_integer): Remove.
11216 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11218 (store_integer): New function template.
11219 (store_signed_integer): Remove.
11220 (store_unsigned_integer): Remove.
11221 (store_integer): Explicit instantiations.
11222 * regcache.c (regcache_raw_read_signed): Update.
11223 (regcache::raw_read): New function.
11224 (regcache::raw_read_signed): Remove.
11225 (regcache::raw_read_unsigned): Remove.
11226 (regcache_raw_read_unsigned): Update.
11227 (regcache_raw_write_unsigned): Update.
11228 (regcache::raw_write_signed): Remove.
11229 (regcache::raw_write): New function.
11230 (regcache_cooked_read_signed): Update.
11231 (regcache::raw_write_unsigned): Remove.
11232 (regcache::cooked_read_signed): Remove.
11233 (regcache_cooked_read_unsigned): Update.
11234 (regcache::cooked_read_unsigned): Remove.
11235 (regcache_cooked_write_signed): Update.
11236 (regcache_cooked_write_unsigned): Update.
11237 * regcache.h (regcache) <raw_read_signed>: Remove.
11238 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11239 <raw_read, raw_write>: New.
11240 <cooked_read_signed, cooked_write_signed>: Remove.
11241 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11242 <cooked_read, cooked_write>: New.
11243 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11244 (sh64_pseudo_register_write): Update.
11246 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11248 * arc-tdep.c (arc_disassembler_options): New variable.
11249 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11250 of default_print_insn.
11251 (arc_delayed_print_insn): Set info->section when needed,
11252 use default_print_insn to retrieve a disassembler.
11254 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11257 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11258 to mention $SHELL and startup-with-shell.
11260 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11262 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11264 2017-06-14 Yao Qi <yao.qi@linaro.org>
11266 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11267 default_print_insn instead of print_insn_aarch64.
11268 * arm-tdep.c (gdb_print_insn_arm): Call
11269 default_print_insn instead of print_insn_big_arm
11270 and print_insn_little_arm.
11271 * i386-tdep.c (i386_print_insn): Call default_print_insn
11272 instead of print_insn_i386.
11273 * ia64-tdep.c (ia64_print_insn): Call
11274 default_print_insn instead of print_insn_ia64.
11275 * mips-tdep.c (gdb_print_insn_mips): Call
11276 default_print_insn instead of print_insn_big_mips
11277 and print_insn_little_mips.
11278 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11279 instead of print_insn_spu.
11281 2017-06-14 Pedro Alves <palves@redhat.com>
11283 * ada-lang.c: Include "common/byte-vector.h".
11284 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11285 * charset.c (wchar_iterator::iterate): Resize the vector instead
11287 * common/byte-vector.h: Include "common/def-vector.h".
11288 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11289 * cli/cli-dump.c: Include "common/byte-vector.h".
11290 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11291 * common/byte-vector.h: New file.
11292 * common/def-vector.h: New file.
11293 * common/default-init-alloc.h: New file.
11294 * dwarf2loc.c: Include "common/byte-vector.h".
11295 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11296 instead of reserving it.
11297 * dwarf2read.c: Include "common/byte-vector.h".
11298 (data_buf::m_vec): Now a gdb::byte_vector.
11299 * gdb_regex.c: Include "common/def-vector.h".
11300 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11301 * mi/mi-main.c: Include "common/byte-vector.h".
11302 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11303 * printcmd.c: Include "common/byte-vector.h".
11304 (print_scalar_formatted): Use gdb::byte_vector.
11305 * valprint.c: Include "common/byte-vector.h".
11306 (maybe_negate_by_bytes, print_decimal_chars): Use
11309 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11311 * darwin-nat.c: Include "nat/fork-inferior.h".
11313 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11315 * configure.nat: Factor out Darwin bits that are not
11316 architecture-specific. Add fork-inferior.o.
11318 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11320 * configure.nat: Factor out AIX bits that are not
11321 architecture-specific. Add fork-inferior.o.
11323 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11325 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11326 (read_pieced_value, write_pieced_value): ...here. Reduce to
11327 wrappers that just call rw_pieced_value.
11329 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11331 * dwarf2loc.c (write_pieced_value): When writing the data for a
11332 memory piece, use write_memory_with_notification instead of
11335 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11337 * valops.c (read_value_memory): Change embedded_offset to
11338 represent a bit offset instead of a byte offset.
11339 * value.h (read_value_memory): Adjust comment.
11341 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11343 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11344 dest_offset_bits and source_offset_bits.
11345 (write_pieced_value): Likewise.
11347 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11349 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11350 given by DW_OP_bit_piece.
11351 (write_pieced_value): Likewise.
11353 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11355 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11356 some other preparations to the places where sufficient information
11358 (write_pieced_value): Likewise.
11360 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11362 * dwarf2loc.c (bits_to_bytes): New function.
11363 (read_pieced_value): Fix offset calculations for register pieces
11364 on big-endian targets.
11365 (write_pieced_value): Likewise.
11367 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11369 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11370 (write_pieced_value): Likewise.
11372 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11374 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11375 transfer the source value's least significant bits, instead of its
11376 lowest-addressed ones. Rename type_len to max_offset.
11377 (read_pieced_value): Mirror above changes to write_pieced_value as
11380 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11382 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11383 truncate full bytes from dest_offset_bits before using it as an
11384 offset into the buffer.
11386 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11388 * dwarf2loc.c (write_pieced_value): Include transfer size in
11391 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11393 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11394 calculation of this_size.
11396 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11398 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
11399 when targeting a bit-field.
11400 (write_pieced_value): Likewise.
11402 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11404 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
11405 (allocate_piece_closure): Drop addr_size parameter.
11406 (dwarf2_evaluate_loc_desc_full): Adjust call to
11407 allocate_piece_closure.
11409 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11412 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
11413 the LSB end, independent of endianness.
11415 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11417 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
11420 2017-06-13 Yao Qi <yao.qi@linaro.org>
11422 * mips-linux-nat.c: Move include features/mips*-linux.c to
11424 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
11425 to mips-linux-tdep.c.
11426 * mips-linux-tdep.c: Include features/mips*-linux.c
11427 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
11429 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
11430 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
11431 (tdesc_mips64_dsp_linux): Declare.
11433 2017-06-12 Tom Tromey <tom@tromey.com>
11435 * valprint.h (val_print_type_code_int): Remove.
11436 * valprint.c (generic_val_print_int): Always call
11437 val_print_scalar_formatted.
11438 (val_print_type_code_int): Remove.
11439 * printcmd.c (print_scalar_formatted): Handle options->format==0.
11440 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
11441 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
11442 * ada-valprint.c (ada_val_print_num): Use
11443 val_print_scalar_formatted.
11445 2017-06-12 Tom Tromey <tom@tromey.com>
11447 * printcmd.c (print_scalar_formatted): Unify the two switches.
11448 Don't convert scalars to LONGEST.
11450 2017-06-12 Tom Tromey <tom@tromey.com>
11453 * valprint.h (print_decimal_chars): Update.
11454 * valprint.c (maybe_negate_by_bytes): New function.
11455 (print_decimal_chars): Add "is_signed" argument.
11456 * printcmd.c (print_scalar_formatted): Update.
11458 2017-06-12 Tom Tromey <tom@tromey.com>
11461 * valprint.h (print_binary_chars, print_hex_chars): Update.
11462 * valprint.c (val_print_type_code_int): Update.
11463 (print_binary_chars): Add "zero_pad" argument.
11464 (emit_octal_digit): New function.
11465 (print_octal_chars): Don't zero-pad.
11466 (print_decimal_chars): Likewise.
11467 (print_hex_chars): Add "zero_pad" argument.
11468 * sh64-tdep.c (sh64_do_fp_register): Update.
11469 * regcache.c (regcache::dump): Update.
11470 * printcmd.c (print_scalar_formatted): Update.
11471 * infcmd.c (default_print_one_register_info): Update.
11473 2017-06-12 Pedro Alves <palves@redhat.com>
11474 Alan Hayward <alan.hayward@arm.com>
11476 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
11477 (mips_eabi_push_dummy_call): Rename local 'regsize' to
11478 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
11479 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
11480 Assert that abi_regsize bytes fit in 'ref_valbuf'.
11482 2017-06-12 Pedro Alves <palves@redhat.com>
11484 * dwarf2read.c (mapped_symtab::data): Now a vector of
11485 symtab_index_entry instead of vector of
11486 std::unique_ptr<symtab_index_entry>. All users adjusted to check
11487 whether an element's name is NULL instead of checking whether the
11488 element itself is NULL.
11489 (find_slot): Change return type. Adjust.
11490 (hash_expand, , add_index_entry, uniquify_cu_indices)
11491 (write_hash_table): Adjust.
11493 2017-06-12 Pedro Alves <palves@redhat.com>
11495 * dwarf2read.c (recursively_count_psymbols): New function.
11496 (write_psymtabs_to_index): Call it to compute number of psyms and
11497 pass estimate size of psyms_seen to unordered_set's ctor.
11499 2017-06-12 Pedro Alves <palves@redhat.com>
11501 * dwarf2read.c (write_hash_table): Check if key already exists
11504 2017-06-12 Pedro Alves <palves@redhat.com>
11506 * dwarf2read.c (data_buf::append_space): Rename to...
11507 (data_buf::grow): ... this, and make private. Adjust all callers.
11508 (data_buf::append_uint): New method.
11509 (add_address_entry, write_one_signatured_type)
11510 (write_psymtabs_to_index): Use it.
11512 2017-06-12 Pedro Alves <palves@redhat.com>
11514 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
11515 (file_write (FILE *, const std::vector<Elem>&)): Delete.
11516 (data_buf::file_write): Call ::fwrite directly.
11518 2017-06-12 Pedro Alves <palves@redhat.com>
11520 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
11521 std::vector::erase.
11523 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11525 Code cleanup: C++ify .gdb_index producer.
11526 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
11527 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
11528 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
11529 (create_strtab, add_string): Remove.
11530 (file_write, data_buf): New.
11531 (struct symtab_index_entry): Use std::vector for cu_indices.
11532 (struct mapped_symtab): Use std::vector for data.
11533 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
11534 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
11536 (find_slot): Change return type. Update it to the new data structures.
11537 (hash_expand, add_index_entry): Update it to the new data structures.
11538 (offset_type_compare): Remove.
11539 (uniquify_cu_indices): Update it to the new data structures.
11540 (c_str_view, c_str_view_hasher, vector_hasher): New.
11541 (add_indices_to_cpool): Remove.
11542 (write_hash_table): Update it to the new data structures.
11543 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
11544 (eq_psymtab_cu_index): Remove.
11545 (psym_index_map): New typedef.
11546 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
11547 reference and std::unordered_map for cu_index_htab.
11548 (add_address_entry, add_address_entry_worker, write_address_map)
11549 (write_psymbols): Update it to the new data structures.
11550 (write_obstack): Remove.
11551 (struct signatured_type_index_data): Change types_list to a data_buf
11552 reference and psyms_seen to a std::unordered_set reference.
11553 (write_one_signatured_type, recursively_write_psymbols)
11554 (write_psymtabs_to_index): Update it to the new data structures.
11556 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
11558 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
11559 separate-debug-file commands.
11560 * symfile.h (separate_debug_file_debug): New global.
11561 * symfile.c (separate_debug_file_debug): New global.
11562 (separate_debug_file_exists, find_separate_debug_file): Add
11564 (_initialize_symfile): Add "set debug separate-debug-file"
11566 * build-id.c (build_id_to_debug_bfd,
11567 find_separate_debug_file_by_buildid): Add debug output.
11569 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
11571 * gdbarch.sh (displaced_step_free_closure): Remove.
11572 * gdbarch.h, gdbarch.c: Re-generate.
11573 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
11574 displaced_step_free_closure.
11575 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
11576 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
11577 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
11578 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11579 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
11580 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11581 * arch-utils.h (simple_displaced_step_free_closure): Remove.
11582 * arch-utils.c (simple_displaced_step_free_closure): Remove.
11583 * infrun.c (displaced_step_clear): Call xfree instead of
11584 gdbarch_displaced_step_free_closure.
11586 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
11588 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
11591 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11593 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
11594 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
11595 (mn10300_push_dummy_call): Likewise.
11597 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11599 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
11601 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11603 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
11605 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11607 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
11608 able to start inferiors using a shell.
11609 (New remote packets): Announce new packet "QStartupWithShell".
11610 * remote.c: Add PACKET_QStartupWithShell.
11611 (extended_remote_create_inferior): Handle new
11612 PACKET_QStartupWithShell.
11613 (remote_protocol_features) <QStartupWithShell>: New entry for
11614 PACKET_QStartupWithShell.
11615 (_initialize_remote): Call "add_packet_config_cmd" for
11618 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11619 Pedro Alves <palves@redhat.com>
11621 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
11622 and "nat/fork-inferior.h".
11623 * common/common-inferior.h: New file, with contents from
11625 * commom/common-utils.c: Include "common-utils.h".
11626 (stringify_argv): New function.
11627 * common/common-utils.h (stringify_argv): New prototype.
11628 * configure.nat: Add "fork-inferior.o" as a dependency for
11629 "*linux*", "fbsd*" and "nbsd*" hosts.
11630 * corefile.c (get_exec_file): Update comment.
11631 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
11632 instead of "startup_inferior".
11633 (darwin_create_inferior): Call "add_thread_silent" after
11635 * fork-child.c: Cleanup unnecessary includes.
11636 (SHELL_FILE): Move to "common/common-fork-child.c".
11637 (environ): Likewise.
11638 (exec_wrapper): Initialize.
11639 (get_exec_wrapper): New function.
11640 (breakup_args): Move to "common/common-fork-child.c"; rename to
11641 "breakup_args_for_exec".
11642 (escape_bang_in_quoted_argument): Move to
11643 "common/common-fork-child.c".
11644 (saved_ui): New variable.
11645 (prefork_hook): New function.
11646 (postfork_hook): Likewise.
11647 (postfork_child_hook): Likewise.
11648 (gdb_startup_inferior): Likewise.
11649 (fork_inferior): Move to "common/common-fork-child.c". Update
11650 function to support gdbserver.
11651 (startup_inferior): Likewise.
11652 * gdbcore.h (get_exec_file): Remove declaration.
11653 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
11654 instead of "startup_inferior". Call "add_thread_silent" after
11656 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
11657 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
11658 instead of "startup_inferior". Call "add_thread_silent" after
11660 * inferior.h: Include "common-inferior.h".
11661 (trace_start_error): Move to "common/common-utils.h".
11662 (trace_start_error_with_name): Likewise.
11663 (fork_inferior): Move prototype to "nat/fork-inferior.h".
11664 (startup_inferior): Likewise.
11665 (gdb_startup_inferior): New prototype.
11666 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
11667 * nat/fork-inferior.h: New file.
11668 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
11669 instead of "startup_inferior". Call "add_thread_silent" after
11671 * target.h (target_terminal_init): Move prototype to
11673 (target_terminal_inferior): Likewise.
11674 (target_terminal_ours): Likewise.
11675 * target/target.h (target_terminal_init): New prototype, moved
11677 (target_terminal_inferior): Likewise.
11678 (target_terminal_ours): Likewise.
11679 * utils.c (gdb_flush_out_err): New function.
11681 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11683 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
11684 * common/common-gdbthread.h: New file, with parts from
11686 * gdbthread.h: Include "common-gdbthread.h".
11687 (switch_to_thread): Moved to "common/common-gdbthread.h".
11689 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11691 * Makefile.in (SFILES): Add "common/job-control.c".
11692 (HFILES_NO_SRCDIR): Add "common/job-control.h".
11693 (COMMON_OBS): Add "job-control.o".
11694 * common/job-control.c: New file, with contents from
11696 * common/job-control.h: New file, with contents from "terminal.h".
11697 * fork-child.c: Include "job-control.h".
11698 * inflow.c: Include "job-control.h".
11699 (gdb_setpgid): Move to "common/common-inflow.c".
11700 (_initialize_inflow): Move setting of "job_control" to
11701 "handle_job_control".
11702 * terminal.h (job_control): Moved to "common/common-terminal.h".
11703 (gdb_setpgid): Likewise.
11704 * top.c: Include "job_control.h".
11705 * utils.c: Likewise.
11706 (job_control): Moved to "job-control.c".
11708 2017-06-07 Pedro Alves <palves@redhat.com>
11710 * Makefile.in (SFILES): Add gdb_regex.c.
11711 (COMMON_OBS): Add gdb_regex.o.
11712 * ada-lang.c (ada_add_standard_exceptions)
11713 (ada_add_exceptions_from_frame, name_matches_regex)
11714 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
11715 parameter type to compiled_regex. Adjust.
11716 (ada_exceptions_list): Use compiled_regex.
11717 * break-catch-throw.c (exception_catchpoint::pattern): Now a
11718 std::unique_ptr<compiled_regex>.
11719 (exception_catchpoint::~exception_catchpoint): Remove regfree
11721 (check_status_exception_catchpoint): Adjust to use compiled_regex.
11722 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
11723 * breakpoint.c (solib_catchpoint::compiled): Now a
11724 std::unique_ptr<compiled_regex>.
11725 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
11726 (check_status_catch_solib): Adjust to use compiled_regex.
11727 (add_solib_catchpoint): Adjust to use compiled_regex.
11728 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
11729 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
11730 compiled_regex reference. Adjust to use it.
11731 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
11732 declaration. Include "gdb_regex.h".
11733 (apropos_cmd): Change regex parameter to compiled_regex reference.
11734 * gdb_regex.c: New file.
11735 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
11737 (class compiled_regex): New.
11738 * linux-tdep.c: Include "common/gdb_optional.h".
11739 (struct mapping_regexes): New, factored out from
11740 mapping_is_anonymous_p, and adjusted to use compiled_regex.
11741 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
11742 gdb::optional and remove cleanups. Adjust to compiled_regex.
11743 * probe.c: Include "common/gdb_optional.h".
11744 (collect_probes): Use compiled_regex and gdb::optional and remove
11746 * skip.c: Include "common/gdb_optional.h".
11747 (skiplist_entry::compiled_function_regexp): Now a
11748 gdb::optional<compiled_regex>.
11749 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
11750 (free_skiplist_entry): Remove regfree call.
11751 (compile_skip_regexp, skip_rfunction_p): Adjust to use
11752 compiled_regex and gdb::optional.
11753 * symtab.c: Include "common/gdb_optional.h".
11754 (search_symbols): Use compiled_regex and gdb::optional.
11755 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
11756 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
11759 2017-06-07 Alan Hayward <alan.hayward@arm.com>
11761 * regcache.c (regcache::save): Avoid buffer use.
11762 (regcache::dump): Likewise.
11764 2017-06-07 Alan Hayward <alan.hayward@arm.com>
11766 * sh-tdep.c (sh_pseudo_register_read): Remove
11768 (sh_pseudo_register_write): Likewise.
11769 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
11770 (sh64_pseudo_register_write): Likewise
11772 2017-06-07 Alan Hayward <alan.hayward@arm.com>
11774 * aarch64-tdep.c (aarch64_store_return_value): Use
11776 (aarch64_pseudo_read_value): Likewise.
11777 (aarch64_pseudo_write): Likewise.
11779 2017-06-06 Yao Qi <yao.qi@linaro.org>
11781 * regformats/regdef.h (set_register_cache): Remove the
11784 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11786 * frame.c (frame_unwind_register_signed): Use
11787 frame_unwind_register_value.
11789 2017-06-06 Pedro Alves <palves@redhat.com>
11791 PR breakpoints/21553
11792 * breakpoint.c (create_breakpoints_sal_default)
11793 (init_breakpoint_sal, create_breakpoint_sal): Use
11794 gdb::unique_xmalloc_ptr for string parameters.
11795 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11796 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
11797 (base_breakpoint_create_breakpoints_sal)
11798 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
11799 (strace_marker_create_breakpoints_sal)
11800 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
11802 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
11803 gdb::unique_xmalloc_ptr for string parameters.
11804 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11807 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11809 * alpha-tdep.c (alpha_register_to_value): Use
11810 get_frame_register_value.
11811 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
11813 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11815 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
11816 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
11817 (ia64_value_to_register): Likewise.
11818 (ia64_extract_return_value): Likewise.
11819 (ia64_store_return_value): Likewise.
11820 (ia64_push_dummy_call): Likewise.
11822 2017-06-04 Joel Brobecker <brobecker@adacore.com>
11826 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
11828 * x86-linux-nat.c (struct arch_lwp_info): Remove.
11830 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
11832 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
11834 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
11836 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
11838 * event-loop.c (poll_timers): Unallocate timer using delete
11841 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11843 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
11844 (struct breakpoint) <~breakpoint>: New.
11845 (struct watchpoint): Inherit from breakpoint.
11846 <~watchpoint>: New.
11848 (struct tracepoint): Inherit from breakpoint.
11850 * breakpoint.c (longjmp_breakpoint_ops): Remove.
11851 (struct longjmp_breakpoint): Inherit from breakpoint.
11852 <~longjmp_breakpoint>: New.
11854 (new_breakpoint_from_type): Remove casts.
11855 (watchpoint_in_thread_scope): Remove reference to base field.
11856 (watchpoint_del_at_next_stop): Likewise.
11857 (update_watchpoint): Likewise.
11858 (watchpoint_check): Likewise.
11859 (bpstat_check_watchpoint): Likewise.
11860 (set_longjmp_breakpoint): Likewise.
11861 (struct fork_catchpoint): Inherit from breakpoint.
11863 (struct solib_catchpoint): Inherit from breakpoint.
11864 <~solib_catchpoint>: New.
11866 (dtor_catch_solib): Change to ...
11867 (solib_catchpoint::~solib_catchpoint): ... this.
11868 (breakpoint_hit_catch_solib): Remove reference to base field.
11869 (add_solib_catchpoint): Likewise.
11870 (create_fork_vfork_event_catchpoint): Likewise.
11871 (struct exec_catchpoint): Inherit from breakpoint.
11872 <~exec_catchpoint>: New.
11874 (dtor_catch_exec): Change to ...
11875 (exec_catchpoint::~exec_catchpoint): ... this.
11876 (dtor_watchpoint): Change to ...
11877 (watchpoint::~watchpoint): ... this.
11878 (watch_command_1): Remove reference to base field.
11879 (catch_exec_command_1): Likewise.
11880 (base_breakpoint_dtor): Change to ...
11881 (breakpoint::~breakpoint): ... this.
11882 (base_breakpoint_ops): Remove dtor field value.
11883 (longjmp_bkpt_dtor): Change to ...
11884 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
11885 (strace_marker_create_breakpoints_sal): Remove reference to base
11887 (delete_breakpoint): Don't manually call breakpoint destructor.
11888 (create_tracepoint_from_upload): Remove reference to base field.
11889 (trace_pass_set_count): Likewise.
11890 (initialize_breakpoint_ops): Don't initialize
11891 momentary_breakpoint_ops, don't set dtors.
11892 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
11893 <~ada_catchpoint>: New.
11895 (create_excep_cond_exprs): Remove reference to base field.
11896 (dtor_exception): Change to ...
11897 (ada_catchpoint::~ada_catchpoint): ... this.
11898 (dtor_catch_exception): Remove.
11899 (dtor_catch_exception_unhandled): Remove.
11900 (dtor_catch_assert): Remove.
11901 (create_ada_exception_catchpoint): Remove reference to base
11903 (initialize_ada_catchpoint_ops): Don't set dtors.
11904 * break-catch-sig.c (struct signal_catchpoint): Inherit from
11906 <~signal_catchpoint>: New.
11908 (signal_catchpoint_dtor): Change to ...
11909 (signal_catchpoint::~signal_catchpoint): ... this.
11910 (create_signal_catchpoint): Remove reference to base field.
11911 (initialize_signal_catchpoint_ops): Don't set dtor.
11912 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
11914 <~syscall_catchpoint>: New.
11916 (dtor_catch_syscall): Change to ...
11917 (syscall_catchpoint::~syscall_catchpoint): ... this.
11918 (create_syscall_event_catchpoint): Remove reference to base
11920 (initialize_syscall_catchpoint_ops): Don't set dtor.
11921 * break-catch-throw.c (struct exception_catchpoint): Inherit
11923 <~exception_catchpoint>: New.
11925 (dtor_exception_catchpoint): Change to ...
11926 (exception_catchpoint::~exception_catchpoint): ... this.
11927 (handle_gnu_v3_exceptions): Remove reference to base field.
11928 (initialize_throw_catchpoint_ops): Don't set dtor.
11929 * ctf.c (ctf_get_traceframe_address): Remove reference to base
11931 * remote.c (remote_get_tracepoint_status): Likewise.
11932 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
11933 * tracefile.c (tracefile_fetch_registers): Likewise.
11934 * tracepoint.c (actions_command): Likewise.
11935 (validate_actionline): Likewise.
11936 (tfind_1): Likewise.
11937 (get_traceframe_location): Likewise.
11938 (find_matching_tracepoint_location): Likewise.
11939 (parse_tracepoint_status): Likewise.
11940 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
11942 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11944 * breakpoint.c (struct longjmp_breakpoint): New struct.
11945 (is_tracepoint_type): Change return type to bool.
11946 (is_longjmp_type): New function.
11947 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
11948 (set_raw_breakpoint_without_location): Use
11949 new_breakpoint_from_type.
11950 (set_raw_breakpoint): Likewise.
11952 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11954 * breakpoint.c (new_breakpoint_from_type): New function.
11955 (create_breakpoint_sal): Use new_breakpoint_from_type and
11957 (create_breakpoint): Likewise.
11959 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
11961 * memattr.c (mem_info_command): Rename to ...
11962 (info_mem_command): ... this.
11963 (mem_enable_command): Rename to ...
11964 (enable_mem_command): ... this.
11965 (mem_disable_command): Rename to ...
11966 (disable_mem_command): ... this.
11967 (mem_delete_command): Rename to ...
11968 (delete_mem_command): ... this.
11969 (_initialize_mem): Adjust function names.
11971 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11973 * btrace.c (handle_pt_insn_events): New.
11974 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
11975 STATUS. Split into this and ...
11976 (handle_pt_insn_event_flags): ... this.
11978 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11980 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
11981 and struct pt_insn.resynced.
11982 * configure: Regenerated.
11983 * config.in: Regenerated.
11985 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11987 * btrace.c (ftrace_find_call_by_number): New function.
11988 (ftrace_new_function): Store objects, not pointers.
11989 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
11990 ftrace_new_gap, ftrace_update_function,
11991 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
11992 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
11993 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
11994 btrace_ends_with_single_insn, btrace_call_get): Account for
11995 btrace_thread_info::functions now storing objects.
11996 * btrace.h (struct btrace_thread_info): Add constructor.
11997 (struct btrace_thread_info) <functions>: Make std::vector.
11998 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
11999 Initialize with default values.
12000 * record-btrace.c (record_btrace_frame_sniffer): Account for
12001 btrace_thread_info::functions now storing objects.
12003 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12005 * btrace.c: Remove typedef bfun_s.
12006 (ftrace_new_gap): Directly add gaps to the list of gaps.
12007 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
12008 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
12009 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
12010 instead of gdb VEC.
12012 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12014 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
12015 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
12016 with btrace_thread_info::next_segment and
12017 btrace_thread_info::prev_segment.
12018 * btrace.h: Remove struct btrace_func_link.
12019 (struct btrace_function): Replace pair of function segment pointers
12020 with pair of indices.
12021 * python/py-record-btrace.c (btpy_call_prev_sibling,
12022 btpy_call_next_sibling): Replace references to
12023 btrace_thread_info::segment with btrace_thread_info::next_segment and
12024 btrace_thread_info::prev_segment.
12025 * record-btrace.c (record_btrace_frame_this_id): Use
12026 btrace_find_call_by_number.
12028 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12030 * btrace.c (ftrace_new_function, ftrace_fixup_level,
12031 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
12032 btrace_insn_next, btrace_insn_prev): Remove references to
12033 btrace_thread_info::flow.
12034 * btrace.h (struct btrace_function): Remove FLOW.
12036 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12038 * btrace.c (ftrace_find_call_by_number): New function.
12039 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
12040 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
12041 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
12042 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
12044 * btrace.h (struct btrace_function): Turn UP into an index.
12045 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
12047 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
12048 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12049 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12051 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12053 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12054 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12055 ftrace_update_function, ftrace_compute_global_level_offset,
12056 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12057 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12058 btrace_insn_end, btrace_is_empty): Remove references to
12059 btrace_thread_info::begin and btrace_thread_info::end.
12060 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12061 (struct btrace_thread_info) <functions>: Adjust comment.
12062 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12063 btrace_thread_info::begin.
12065 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12067 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12068 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12069 ftrace_update_function): Remove arguments that implicitly were always
12071 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12072 Don't pass BTINFO->END.
12074 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12076 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12077 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12078 btrace_find_insn_by_number): Replace function segment pointer with
12080 (btrace_insn_cmp): Simplify.
12081 * btrace.h: (struct btrace_insn_iterator) Rename index to
12082 insn_index. Replace function segment pointer with index into function
12084 * record-btrace.c (record_btrace_call_history): Replace function
12085 segment pointer use with index.
12086 (record_btrace_frame_sniffer): Retrieve function call segment through
12088 (record_btrace_set_replay): Remove defunc't safety check.
12090 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12092 * btrace.c (btrace_ends_with_single_insn): New function.
12093 (btrace_call_get, btrace_call_number, btrace_call_begin,
12094 btrace_call_end, btrace_call_next, btrace_call_prev,
12095 btrace_find_call_by_number): Use index into call segment vector
12096 instead of pointer.
12097 (btrace_call_cmp): Simplify.
12098 * btrace.h (struct btrace_call_iterator): Replace function call segment
12099 pointer with index into vector.
12100 * record-btrace.c (record_btrace_call_history): Use index instead of
12103 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12105 * btrace.c (btrace_insn_begin, btrace_insn_end,
12106 btrace_find_insn_by_number): Add btinfo to iterator.
12107 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12109 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12111 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12112 and save pointers directly.
12113 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12114 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12115 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12116 changed signature of functions.
12117 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12118 (btrace_fetch): Remove code that adds btrace_function pointers to
12119 vector of btrace_functions.
12120 (btrace_clear): Simplify freeing vector of btrace_functions.
12122 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12124 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12125 Replace VEC_* with std::vector functions.
12126 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12127 (struct btrace_thread_info)<functions>: Change type to std::vector.
12129 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12131 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12132 "Removed targets and native configurations" up. Merge duplicate
12133 "New commands" sub-sections. Add "New options" sub-sections.
12135 2017-05-26 Alan Hayward <alan.hayward@arm.com>
12137 * defs.h (copy_integer_to_size): New declaration.
12138 * findvar.c (copy_integer_to_size): New function.
12139 (do_cint_test): New selftest function.
12140 (copy_integer_to_size_test): Likewise.
12141 (_initialize_findvar): Likewise.
12142 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12143 (mips_fbsd_collect_reg): Use raw_collect_integer.
12144 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12145 (mips64_fill_gregset): Use raw_collect_integer
12146 (mips64_fill_fpregset): Use raw_supply_integer.
12147 * regcache.c (regcache::raw_supply_integer): New function.
12148 (regcache::raw_collect_integer): Likewise.
12149 * regcache.h: (regcache::raw_supply_integer): New declaration.
12150 (regcache::raw_collect_integer): Likewise.
12152 2017-05-24 Yao Qi <yao.qi@linaro.org>
12154 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12155 (COMMON_OBS): Add gdbarch-selftests.o.
12156 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12157 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12158 * gdbarch-selftests.c: New file.
12159 * regcache.h (regcache) <~regcache>: Mark it virtual if
12161 <raw_write>: Likewise.
12163 2017-05-24 Yao Qi <yao.qi@linaro.org>
12165 * regcache.c (current_regcache): Change it to
12166 regcache::current_regcache.
12167 (regcache_observer_target_changed): Update.
12168 (regcache_thread_ptid_changed): Make it a regcache static
12170 (regcache_thread_ptid_changed): Update.
12171 (class regcache_access): New.
12172 (current_regcache_test): Update.
12173 (_initialize_regcache): Update.
12174 * regcache.h: Include forward_list.
12175 (regcache): Declare regcache_thread_ptid_changed and declare
12176 registers_changed_ptid as friend.
12178 2017-05-24 Yao Qi <yao.qi@linaro.org>
12180 * i387-tdep.c (i387_register_to_value): Use register_size
12181 instead of TYPE_LENGTH.
12182 * m68k-tdep.c (m68k_register_to_value): Likewise.
12184 2017-05-24 Yao Qi <yao.qi@linaro.org>
12186 * i387-tdep.c (i387_convert_register_p): Return false if type
12187 code isn't TYPE_CODE_FLT.
12189 2017-05-24 Yao Qi <yao.qi@linaro.org>
12191 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12193 (alpha_register_to_value): Remove type length check.
12194 (alpha_value_to_register): Likewise.
12196 2017-05-24 Yao Qi <yao.qi@linaro.org>
12198 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12201 2017-05-24 Yao Qi <yao.qi@linaro.org>
12203 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12204 TYPE_CODE_FLT or not.
12206 2017-05-24 Yao Qi <yao.qi@linaro.org>
12208 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12209 * avr-tdep.c (avr_gdbarch_init): Likewise.
12210 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12211 * cris-tdep.c (cris_gdbarch_init): Likewise.
12212 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12213 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12214 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12215 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12216 * mep-tdep.c (mep_gdbarch_init): Likewise.
12217 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12218 * mips-tdep.c (mips_gdbarch_init): Likewise.
12219 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12220 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12221 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12222 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12223 * v850-tdep.c (v850_gdbarch_init): Likewise.
12225 2017-05-24 Yao Qi <yao.qi@linaro.org>
12227 * selftest-arch.c (tests_with_arch): Call registers_changed
12228 and reinit_frame_cache.
12229 * selftest.c (run_self_tests): Likewise.
12231 2017-05-24 Yao Qi <yao.qi@linaro.org>
12233 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12234 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12236 2017-05-24 Yao Qi <yao.qi@linaro.org>
12238 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12239 set_gdbarch_print_insn.
12241 2017-05-24 Yao Qi <yao.qi@linaro.org>
12243 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12244 set_gdbarch_print_insn.
12246 2017-05-24 Yao Qi <yao.qi@linaro.org>
12248 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12249 set_gdbarch_print_insn.
12250 * arc-tdep.c (arc_gdbarch_init): Likewise.
12251 * arch-utils.c: include dis-asm.h.
12252 (default_print_insn): New function.
12253 * arch-utils.h (default_print_insn): Declare.
12254 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12255 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12256 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12257 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12258 * frv-tdep.c (frv_gdbarch_init): Likewise.
12259 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12260 * gdbarch.sh (print_insn): Use default_print_insn.
12261 * gdbarch.c: Regenerated.
12262 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12263 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12264 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12265 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12266 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12267 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12268 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12269 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12270 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12271 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12272 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12273 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12274 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12275 * mt-tdep.c (mt_gdbarch_init): Likewise.
12276 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12277 * nios2-tdep.c (nios2_print_insn): Remove.
12278 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12279 * rx-tdep.c (rx_gdbarch_init): Likewise.
12280 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12281 * score-tdep.c (score_print_insn): Remove.
12282 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12283 * sh-tdep.c (sh_gdbarch_init): Likewise.
12284 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12285 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12286 * tic6x-tdep.c (tic6x_print_insn): Remove.
12287 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12288 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12289 * v850-tdep.c (v850_gdbarch_init): Likewise.
12290 * vax-tdep.c (vax_gdbarch_init): Likewise.
12291 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12292 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12294 2017-05-23 John Baldwin <jhb@FreeBSD.org>
12296 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12297 (MIPS_FP0_REGNUM): Remove.
12298 (MIPS_FSR_REGNUM): Remove.
12299 (mips_fbsd_supply_fpregs): Use mips_regnum.
12300 (mips_fbsd_supply_gregs): Likewise.
12301 (mips_fbsd_collect_fpregs): Likewise.
12302 (mips_fbsd_collect_gregs): Likewise.
12304 2017-05-23 John Baldwin <jhb@FreeBSD.org>
12306 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12307 (getpfpregs_supplies): New function.
12308 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12309 getfpregs_supplies.
12310 (mips_fbsd_store_inferior_registers): Likewise.
12312 2017-05-22 Pedro Alves <palves@redhat.com>
12314 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12317 2017-05-22 Alan Hayward <alan.hayward@arm.com>
12319 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12320 (store_register): Likewise.
12321 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12322 (get_decimal_float_return_value): Likewise.
12323 (do_ppc_sysv_return_value): Likewise.
12324 (ppc64_sysv_abi_push_integer): Likewise.
12325 (ppc64_sysv_abi_push_freg): Likewise.
12326 (ppc64_sysv_abi_return_value_base): Likewise.
12327 (ppc64_sysv_abi_return_value): Likewise.
12328 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12329 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12330 * rs6000-nat.c: Likewise.
12331 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12332 (rs6000_value_to_register): Likewise.
12333 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12335 2017-05-21 Tom Tromey <tom@tromey.com>
12338 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12339 arrays as "[T]", not "[T; ]".
12341 2017-05-19 Tom Tromey <tom@tromey.com>
12344 * rust-lang.c (exp_descriptor_rust): New function.
12345 (rust_language_defn): Use it.
12346 * p-lang.c (pascal_language_defn): Update.
12347 * opencl-lang.c (opencl_language_defn): Update.
12348 * objc-lang.c (objc_language_defn): Update.
12349 * m2-lang.c (m2_language_defn): Update.
12350 * language.h (struct language_defn)
12351 <la_watch_location_expression>: New member.
12352 * language.c (unknown_language_defn, auto_language_defn)
12353 (local_language_defn): Update.
12354 * go-lang.c (go_language_defn): Update.
12355 * f-lang.c (f_language_defn): Update.
12356 * d-lang.c (d_language_defn): Update.
12357 * c-lang.h (c_watch_location_expression): Declare.
12358 * c-lang.c (c_watch_location_expression): New function.
12359 (c_language_defn, cplus_language_defn, asm_language_defn)
12360 (minimal_language_defn): Use it.
12361 * breakpoint.c (watch_command_1): Call
12362 la_watch_location_expression.
12363 * ada-lang.c (ada_language_defn): Update.
12365 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12368 * gdb_curses.h (NOMACROS): Define.
12369 (NCURSES_NOMACROS): Define.
12371 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12374 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12376 * tui/tui-wingeneral.c (box_win): Likewise.
12377 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12378 (tui_show_source_line): Likewise.
12379 (tui_show_exec_info_content): Likewise.
12381 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12383 * sparc-tdep.c (sparc_structure_return_p)
12384 (sparc_arg_on_registers_p): New functions.
12385 (sparc32_store_arguments): Use them.
12386 * sparc64-tdep.c (sparc64_16_byte_align_p)
12387 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12388 Handle TYPE_CODE_ARRAY.
12390 2017-05-17 Yao Qi <yao.qi@linaro.org>
12392 * cli/cli-decode.c (add_alias_cmd): New function.
12393 * command.h (add_alias_cmd): Declare.
12394 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
12395 instead call add_alias_cmd.
12397 2017-05-17 Pedro Alves <palves@redhat.com>
12399 * Makefile.in (nat_extra_makefile_frag): Rename to ...
12400 (nat_makefile_frag): ... this. All references updated.
12401 * configure.ac: Likewise.
12402 * configure.nat: Likewise. Enhance comments.
12403 * configure: Regenerate.
12405 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12407 * procfs.c (procfs_create_inferior): Change prototype to match
12410 2017-05-13 Eli Zaretskii <eliz@gnu.org>
12412 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
12413 C++ compiler warning.
12415 2017-05-12 Tom Tromey <tom@tromey.com>
12418 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
12419 recurse, just call value_struct_elt directly.
12421 2017-05-12 Tom Tromey <tom@tromey.com>
12423 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
12424 OP_RUST_ARRAY>: Fix.
12426 2017-05-12 Tom Tromey <tom@tromey.com>
12428 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
12430 2017-05-09 Yao Qi <yao.qi@linaro.org>
12432 * regcache.c: Include <forward_list>.
12433 (struct regcache_list): Remove.
12434 (current_regcache): Update.
12435 (get_thread_arch_aspace_regcache): Update for std::forward_list.
12436 (regcache_thread_ptid_changed): Likewise.
12437 (registers_changed_ptid): Likewise.
12438 (current_regcache_size): Likewise.
12440 2017-05-09 Yao Qi <yao.qi@linaro.org>
12442 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
12443 (current_regcache_size): New function.
12444 (current_regcache_test): New function.
12445 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
12447 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12449 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
12450 (print_gp_register_row): Use get_frame_register_value.
12452 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12454 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
12455 (mips_supply_fpregset): Likewise.
12456 (mips64_supply_gregset): Likewise.
12458 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12460 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
12461 regcache->raw_supply_zeroed.
12463 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12465 * configure.nat: Rearrange 'case' statements to match
12468 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12470 * Makefile.in: Remove "@host_makefile_frag@". Add variables
12471 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
12472 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
12473 "@nat_extra_makefile_frag@".
12474 (Makefile): Remove dependency on "@frags@".
12475 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
12476 (data-directory/Makefile): Likewise.
12477 * config/aarch64/linux.mh: Deleted; moved contents to
12478 "gdb/configure.nat".
12479 * config/alpha/alpha-linux.mh: Likewise.
12480 * config/alpha/nbsd.mh: Likewise.
12481 * config/arm/linux.mh: Likewise.
12482 * config/arm/nbsdelf.mh: Likewise.
12483 * config/i386/cygwin.mh: Likewise.
12484 * config/i386/cygwin64.mh: Likewise.
12485 * config/i386/darwin.mh: Likewise.
12486 * config/i386/fbsd.mh: Likewise.
12487 * config/i386/fbsd64.mh: Likewise.
12488 * config/i386/go32.mh: Likewise.
12489 * config/i386/i386gnu.mh: Likewise.
12490 * config/i386/i386sol2.mh: Likewise.
12491 * config/i386/linux.mh: Likewise.
12492 * config/i386/linux64.mh: Likewise.
12493 * config/i386/mingw.mh: Likewise.
12494 * config/i386/mingw64.mh: Likewise.
12495 * config/i386/nbsd64.mh: Likewise.
12496 * config/i386/nbsdelf.mh: Likewise.
12497 * config/i386/nto.mh: Likewise.
12498 * config/i386/obsd.mh: Likewise.
12499 * config/i386/obsd64.mh: Likewise.
12500 * config/i386/sol2-64.mh: Likewise.
12501 * config/ia64/linux.mh: Likewise.
12502 * config/m32r/linux.mh: Likewise.
12503 * config/m68k/linux.mh: Likewise.
12504 * config/m68k/nbsdelf.mh: Likewise.
12505 * config/m68k/obsd.mh: Likewise.
12506 * config/m88k/obsd.mh: Likewise.
12507 * config/mips/fbsd.mh: Likewise.
12508 * config/mips/linux.mh: Likewise.
12509 * config/mips/nbsd.mh: Likewise.
12510 * config/mips/obsd64.mh: Likewise.
12511 * config/pa/linux.mh: Likewise.
12512 * config/pa/nbsd.mh: Likewise.
12513 * config/pa/obsd.mh: Likewise.
12514 * config/powerpc/aix.mh: Likewise.
12515 * config/powerpc/fbsd.mh: Likewise.
12516 * config/powerpc/linux.mh: Likewise.
12517 * config/powerpc/nbsd.mh: Likewise.
12518 * config/powerpc/obsd.mh: Likewise.
12519 * config/powerpc/ppc64-linux.mh: Likewise.
12520 * config/powerpc/spu-linux.mh: Likewise.
12521 * config/s390/linux.mh: Likewise.
12522 * config/sh/nbsd.mh: Likewise.
12523 * config/sparc/fbsd.mh: Likewise.
12524 * config/sparc/linux.mh: Likewise.
12525 * config/sparc/linux64.mh: Likewise.
12526 * config/sparc/nbsd64.mh: Likewise.
12527 * config/sparc/nbsdelf.mh: Likewise.
12528 * config/sparc/obsd64.mh: Likewise.
12529 * config/sparc/sol2.mh: Likewise.
12530 * config/tilegx/linux.mh: Likewise.
12531 * config/vax/nbsdelf.mh: Likewise.
12532 * config/vax/obsd.mh: Likewise.
12533 * config/xtensa/linux.mh: Likewise.
12534 * config/i386/i386gnu.mn: New file, with excerpts from
12535 "config/i386/i386gnu.mh".
12536 * configure: Regenerate.
12537 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
12538 *.mh files under "gdb/config".
12539 * configure.nat: New file, with contents from the
12540 "gdb/config/*/*.mh" files.
12542 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
12544 * btrace.c (btrace_clear): Free insn vector.
12546 2017-05-05 Pedro Alves <palves@redhat.com>
12548 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
12549 * configure: Regenerate.
12551 2017-05-04 Pedro Alves <palves@redhat.com>
12553 * Makefile.in (SFILES): Add progspace-and-thread.c.
12554 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
12555 (COMMON_OBS): Add progspace-and-thread.o.
12556 * breakpoint.c: Include "progspace-and-thread.h".
12557 (update_inserted_breakpoint_locations)
12558 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
12559 Use scoped_restore_current_pspace_and_thread.
12560 (create_std_terminate_master_breakpoint): Use
12561 scoped_restore_current_program_space.
12562 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
12563 (print_breakpoint_location): Use
12564 scoped_restore_current_program_space.
12565 (bp_loc_is_permanent): Use
12566 scoped_restore_current_pspace_and_thread.
12567 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
12568 (download_tracepoint_locations): Use
12569 scoped_restore_current_pspace_and_thread.
12570 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
12571 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
12572 (enum step_over_calls_kind): Moved from inferior.h.
12573 (class scoped_restore_current_thread): New class.
12574 * gdbthread.h (make_cleanup_restore_current_thread): Delete
12576 (scoped_restore_current_thread): New class.
12577 * infcmd.c: Include "common/gdb_optional.h".
12578 (continue_1, proceed_after_attach): Use
12579 scoped_restore_current_thread.
12580 (notice_new_inferior): Use scoped_restore_current_thread.
12581 * inferior.c: Include "progspace-and-thread.h".
12582 (restore_inferior, save_current_inferior): Delete.
12583 (add_inferior_command, clone_inferior_command): Use
12584 scoped_restore_current_pspace_and_thread.
12585 * inferior.h (scoped_restore_current_inferior): New class.
12586 * infrun.c: Include "progspace-and-thread.h" and
12587 "common/gdb_optional.h".
12588 (follow_fork_inferior): Use
12589 scoped_restore_current_pspace_and_thread.
12590 (scoped_restore_exited_inferior): New class.
12591 (handle_vfork_child_exec_or_exit): Use
12592 scoped_restore_exited_inferior,
12593 scoped_restore_current_pspace_and_thread,
12594 scoped_restore_current_thread and scoped_restore.
12595 (fetch_inferior_event): Use scoped_restore_current_thread.
12596 * linespec.c (decode_line_full, decode_line_1): Use
12597 scoped_restore_current_program_space.
12598 * mi/mi-main.c: Include "progspace-and-thread.h".
12599 (exec_continue): Use scoped_restore_current_thread.
12600 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
12601 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
12602 * proc-service.c (ps_pglobal_lookup): Use
12603 scoped_restore_current_program_space.
12604 * progspace-and-thread.c: New file.
12605 * progspace-and-thread.h: New file.
12606 * progspace.c (release_program_space, clone_program_space): Use
12607 scoped_restore_current_program_space.
12608 (restore_program_space, save_current_program_space)
12609 (save_current_space_and_thread): Delete.
12610 (switch_to_program_space_and_thread): Moved to
12611 progspace-and-thread.c.
12612 * progspace.h (save_current_program_space)
12613 (save_current_space_and_thread): Delete declarations.
12614 (scoped_restore_current_program_space): New class.
12615 * remote.c (remote_btrace_maybe_reopen): Use
12616 scoped_restore_current_thread.
12617 * symtab.c: Include "progspace-and-thread.h".
12618 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
12619 * thread.c (print_thread_info_1): Use
12620 scoped_restore_current_thread.
12621 (struct current_thread_cleanup): Delete.
12622 (do_restore_current_thread_cleanup)
12623 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
12624 (scoped_restore_current_thread::~scoped_restore_current_thread):
12626 (make_cleanup_restore_current_thread): Rename/convert to ...
12627 (scoped_restore_current_thread::scoped_restore_current_thread):
12629 (thread_apply_all_command): Use scoped_restore_current_thread.
12630 (thread_apply_command): Use scoped_restore_current_thread.
12631 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
12632 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
12634 2017-05-04 Pedro Alves <palves@redhat.com>
12636 * thread.c (make_cleanup_restore_current_thread): Move
12637 find_thread_ptid call before the is_stopped call. Assert that the
12638 thread is found. Replace is_stopped call by checking the thread's
12639 state directly. Remove unnecessary NULL-thread check.
12641 2017-05-04 Pedro Alves <palves@redhat.com>
12643 * corelow.c (thread_section_name): New class.
12644 (get_core_register_section, get_core_siginfo): Use it.
12646 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
12648 * corelow.c (sniff_core_bfd): Remove extra semicolon.
12649 (get_core_register_section): Remove xfree of NULL pointer.
12651 2017-05-03 Alan Hayward <alan.hayward@arm.com>
12653 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
12654 * regcache.c (regcache::raw_supply_zeroed): New function.
12655 * regcache.h (regcache::raw_supply_zeroed): New declaration.
12657 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
12659 * gdbarch.sh: Remove commented out definition of
12661 * gdbarch.h: Re-generate.
12663 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
12665 * configure: Regenerate.
12667 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
12669 * solib-target.c (solib_target_relocate_section_addresses):
12670 Remove num_section_bases, num_bases, segment_bases variables.
12672 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12674 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
12676 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12678 * solib-target.c: Include <vector>
12679 (struct lm_info_target) <~lm_info_target>: Remove.
12680 <segment_bases, section_bases>: Change type to
12681 std::vector<CORE_ADDR>.
12682 (library_list_start_segment, library_list_start_section,
12683 library_list_end_library,
12684 solib_target_relocate_section_addresses): Adjust.
12686 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12688 * gdbarch.sh (software_single_step): Change return type to
12689 std::vector<CORE_ADDR>.
12690 * gdbarch.c, gdbarch.h: Re-generate.
12691 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
12693 (arm_deal_with_atomic_sequence_raw): Adjust.
12694 (thumb_get_next_pcs_raw): Adjust.
12695 (arm_get_next_pcs_raw): Adjust.
12696 (arm_get_next_pcs): Adjust.
12697 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
12698 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
12699 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
12700 (alpha_software_single_step): Adjust.
12701 * alpha-tdep.h (alpha_software_single_step): Adjust.
12702 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
12703 * arm-tdep.c (arm_software_single_step): Adjust.
12704 (arm_breakpoint_kind_from_current_state): Adjust.
12705 * arm-tdep.h (arm_software_single_step): Adjust.
12706 * breakpoint.c (insert_single_step_breakpoint): Adjust.
12707 * cris-tdep.c (cris_software_single_step): Adjust.
12708 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
12709 (micromips_deal_with_atomic_sequence): Adjust.
12710 (deal_with_atomic_sequence): Adjust.
12711 (mips_software_single_step): Adjust.
12712 * mips-tdep.h (mips_software_single_step): Adjust.
12713 * moxie-tdep.c (moxie_software_single_step): Adjust.
12714 * nios2-tdep.c (nios2_software_single_step): Adjust.
12715 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
12716 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
12717 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
12718 * s390-linux-tdep.c (s390_software_single_step): Adjust.
12719 * sparc-tdep.c (sparc_software_single_step): Adjust.
12720 * spu-tdep.c (spu_software_single_step): Adjust.
12721 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
12723 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12725 * gdbarch.sh: Use semi-colon as field separator instead of colon.
12726 * gdbarch.h: Re-generate.
12728 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12730 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
12731 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
12732 * python/py-instruction.c, python/py-instruction.h: New file.
12733 * python/py-record.c: Add py-instruction.h include.
12734 (gdbpy_initialize_record): Make gdb.Instruction a super class of
12735 gdb.RecordInstruction.
12736 * python/python-internal.h: Add gdbpy_initialize_instruction
12738 * python/python.c (do_start_initialization): Add
12739 gdbpy_initialize_instruction.
12741 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12743 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
12745 (btrace_func_from_recpy_func): New function.
12746 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
12747 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
12748 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
12749 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
12750 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
12751 Also, use new helper functions.
12752 (btpy_list_item): Use new helper functions.
12753 (recpy_bt_function_call_history): Use new type name.
12754 (btpy_call_getset): Remove.
12755 (gdbpy_initialize_btrace): Remove code to initialize
12756 gdb.BtraceFunctionCall.
12757 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
12758 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
12759 recpy_bt_func_prev, recpy_bt_func_next): New export.
12760 * python/py-record.c (recpy_func_type): New static object.
12761 (recpy_func_new, recpy_func_level, recpy_func_symbol,
12762 recpy_func_instructions, recpy_func_up, recpy_func_prev,
12763 recpy_func_next): New function.
12764 (recpy_element_hash, recpy_element_richcompare): Updated comment.
12765 (recpy_func_getset): New static object.
12766 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
12767 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
12769 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12771 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
12772 (btpy_object, btpy_insn_type, btpy_new): Remove.
12773 (btpy_list_object): Use gdb.RecordInstruction type instead of
12774 gdb.BtraceInstruction type.
12775 (btrace_insn_from_recpy_insn): New function.
12776 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
12778 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
12779 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
12780 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
12781 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
12782 instead of btpy_object.
12783 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12784 btpy_insn_data, btpy_insn_decode): Rename to ...
12785 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
12786 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
12787 recpy_bt_insn_decode): This. Also, use new helper functions.
12788 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
12790 (btpy_insn_getset): Remove.
12791 (gdbpy_initialize_btrace): Remove code to initialize
12792 gdb.BtraceInstruction. Use recpy_element_object.
12793 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
12794 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
12795 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
12796 * python/py-record.c (recpy_insn_type): New static object.
12797 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
12798 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
12799 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
12801 (recpy_insn_getset): New static object.
12802 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
12803 * python/py-record.h (recpy_element_object): New typedef.
12804 (recpy_insn_type, recpy_insn_new): New export.
12806 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12808 * py-record-btrace.c (btpy_insn_new): Removed.
12809 (btpy_insn_or_gap_new): New function.
12810 (btpy_insn_error): Removed.
12811 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12812 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
12813 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
12814 btpy_insn_or_gap_new instead of btpy_insn_new.
12815 (btpy_insn_getset): Remove btpy_insn_error.
12816 * py-record.c (recpy_gap_type): New static object.
12817 (recpy_gap_object): New typedef.
12818 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
12819 recpy_gap_reason_string): New function.
12820 (recpy_gap_getset): New static object.
12821 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
12822 * py-record.h (recpy_gap_new): New export.
12824 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12826 * python/py-record.c (recpy_ptid): Remove.
12827 (recpy_record_getset): Remove recpy_ptid.
12829 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12831 * btrace.c (btrace_fetch): Set inferior_ptid.
12832 * python/py-record-btrace.c: Add "py-record.h" include.
12833 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
12834 recpy_bt_end, recpy_bt_instruction_history,
12835 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
12836 in gdb.Record object instead of current ptid.
12837 * python/py-record.c: Include new "py-record.h" file.
12838 (recpy_record_object): Moved to py-record.h.
12839 * python/py-record.h: New file.
12841 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12843 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
12844 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
12847 2017-05-01 Joel Brobecker <brobecker@adacore.com>
12849 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
12850 the past maintainers section.
12852 2017-04-28 Yao Qi <yao.qi@linaro.org>
12854 * infcmd.c (get_return_value): Use regcache ctor, and remove
12857 2017-04-28 Yao Qi <yao.qi@linaro.org>
12858 Pedro Alves <palves@redhat.com>
12860 * regcache.c (regcache::regcache): New tag dispatch ctor.
12861 (do_cooked_read): Moved above.
12862 (regcache_dup): Use the tag dispatch ctor..
12863 * regcache.h (regcache): Declare ctor, delete copy ctor and
12864 assignment operator, remove friend regcache_dup.
12866 2017-04-28 Yao Qi <yao.qi@linaro.org>
12868 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
12869 call method save instead of regcache_cpy.
12870 * regcache.h (struct regcache): Make regcache_dup a friend.
12872 2017-04-28 Yao Qi <yao.qi@linaro.org>
12874 * regcache.c (struct regcache): Move to regcache.h
12875 (regcache::arch): New method.
12876 (regcache_get_ptid): Update.
12877 (get_regcache_arch): Call arch method.
12878 (get_regcache_aspace): Call method aspace.
12879 (register_buffer): Change it to method.
12880 (regcache_save): Change it to regcache::save.
12881 (regcache_restore): Likewise.
12882 (regcache_cpy_no_passthrough): Remove the declaration.
12883 (regcache_cpy): Call methods restore and cpy_no_passthrough.
12884 (regcache_cpy_no_passthrough): Change it to method
12885 cpy_no_passthrough.
12886 (regcache_register_status): Change it to method
12887 get_register_status.
12888 (regcache_invalidate): Change it to method invalidate.
12889 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
12890 (regcache_raw_update): Change it to method raw_update.
12891 (regcache_raw_read): Likewise.
12892 (regcache_raw_read_signed): Likewise.
12893 (regcache_raw_read_unsigned): Likewise.
12894 (regcache_raw_write_signed): Likewise.
12895 (regcache_raw_write_unsigned): Likewise.
12896 (regcache_cooked_read): Likewise.
12897 (regcache_cooked_read_value): Likewise.
12898 (regcache_cooked_read_signed): Likewise.
12899 (regcache_cooked_read_unsigned): Likewise.
12900 (regcache_cooked_write_signed): Likewise.
12901 (regcache_cooked_write_unsigned): Likewise.
12902 (regcache_raw_set_cached_value): Likewise.
12903 (regcache_raw_write): Likewise.
12904 (regcache_cooked_write): Likewise.
12905 (regcache_xfer_part): Likewise.
12906 (regcache_raw_read_part): Likewise.
12907 (regcache_raw_write_part): Likewise.
12908 (regcache_cooked_read_part): Likewise.
12909 (regcache_cooked_write_part): Likewise.
12910 (regcache_raw_supply): Likewise.
12911 (regcache_raw_collect): Likewise.
12912 (regcache_transfer_regset): Likewise.
12913 (regcache_supply_regset): Likewise.
12914 (regcache_collect_regset): Likewise.
12915 (regcache_debug_print_register): Likewise.
12916 (enum regcache_dump_what): Move it to regcache.h.
12917 (regcache_dump): Change it to method dump.
12918 * regcache.h (enum regcache_dump_what): New.
12919 (class regcache): New.
12920 * target.c (target_fetch_registers): Call method
12921 debug_print_register.
12922 (target_store_registers): Likewise.
12924 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12926 * windows-nat.c (struct lm_info_windows): Initialize field.
12927 (windows_make_so): Allocate lm_info_windows with new.
12928 (windows_free_so): Free lm_info_windows with delete.
12930 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12932 * solib-darwin.c (struct lm_info_darwin): Initialize field.
12933 (darwin_current_sos): Allocate lm_info_darwin with new, remove
12935 (darwin_free_so): Free lm_info_darwin with delete.
12937 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12939 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
12940 <l_addr_p>: Change type to bool.
12941 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
12942 (svr4_free_so): Free lm_info_svr4 with delete.
12943 (svr4_copy_library_list): Replace memcpy with call to copy
12945 (library_list_start_library, svr4_default_sos): Allocate
12946 lm_info_svr4 with new.
12948 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12950 * solib-target.c (struct lm_info_target): Add destructor,
12952 <name>: Change type to std::string.
12953 (library_list_start_library): Allocate lm_info_target with new.
12954 (solib_target_free_library_list): Free lm_info_target with
12956 (solib_target_current_sos): Adapt to std::string.
12957 (solib_target_free_so): Free lm_info_target with delete.
12959 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12961 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
12963 (frv_current_sos): Allocate lm_info_frv with new.
12964 (frv_relocate_main_executable): Free lm_info_frv with delete,
12966 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
12968 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12970 * solib-frv.c (struct lm_info_frv): Fix indentation.
12972 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12974 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
12976 (dsbt_current_sos): Allocate lm_info_dsbt with new.
12977 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
12978 and allocate with new.
12979 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
12981 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12983 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
12984 <filename, member_name>: Change type to std::string.
12985 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
12986 (library_list_start_library): Allocate lm_info_aix with new.
12987 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
12988 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
12989 with copy constructor.
12991 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12993 * solist.h (struct lm_info): Remove.
12994 (struct lm_info_base): New class.
12995 (struct so_list) <lm_info>: Change type to lm_info_base *.
12996 * nto-tdep.c (struct lm_info): Remove.
12998 * solib-aix.c (struct lm_info): Rename to ...
12999 (struct lm_info_aix): ... this. Extend lm_info_base.
13000 (lm_info_p): Rename to ...
13001 (lm_info_aix_p): ... this, and adjust.
13002 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
13003 solib_aix_parse_libraries, library_list_start_library,
13004 solib_aix_free_library_list, solib_aix_parse_libraries,
13005 solib_aix_get_library_list,
13006 solib_aix_relocate_section_addresses, solib_aix_free_so,
13007 solib_aix_get_section_offsets,
13008 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
13010 (struct solib_aix_inferior_data) <library_list>: Adjust.
13011 * solib-darwin.c (struct lm_info): Rename to ...
13012 (struct lm_info_darwin): ... this. Extend lm_info_base.
13013 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
13014 * solib-dsbt.c (struct lm_info): Rename to ...
13015 (struct lm_info_dsbt): ... this. Extend lm_info_base.
13016 (struct dsbt_info) <main_executable_lm_info): Adjust.
13017 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
13018 dsbt_relocate_section_addresses): Adjust.
13019 * solib-frv.c (struct lm_info): Rename to ...
13020 (struct lm_info_frv): ... this. Extend lm_info_base.
13021 (main_executable_lm_info): Adjust.
13022 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
13023 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
13024 find_canonical_descriptor_in_load_object,
13025 frv_fdpic_find_canonical_descriptor): Adjust.
13026 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
13028 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
13029 svr4_clear_so, svr4_copy_library_list,
13030 library_list_start_library, svr4_default_sos, svr4_read_so_list,
13031 svr4_current_sos, svr4_fetch_objfile_link_map,
13032 solist_update_incremental): Adjust.
13033 * solib-svr4.h (struct lm_info_svr4): Move here from
13035 * solib-target.c (struct lm_info): Rename to ...
13036 (struct lm_info_target): ... this. Extend lm_info_base.
13037 (lm_info_p): Rename to ...
13038 (lm_info_target_p): ... this.
13039 (solib_target_parse_libraries, library_list_start_segment,
13040 library_list_start_section, library_list_start_library,
13041 library_list_end_library, solib_target_free_library_list,
13042 solib_target_current_sos, solib_target_free_so,
13043 solib_target_relocate_section_addresses): Adjust.
13044 * windows-nat.c (struct lm_info): Rename to ...
13045 (struct lm_info_windows): ... this. Extend lm_info_base.
13046 (windows_make_so, handle_load_dll, handle_unload_dll,
13047 windows_xfer_shared_libraries): Adjust.
13049 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13051 * solib-darwin.c (struct darwin_so_list): Remove.
13052 (darwin_current_sos): Allocate an so_list object instead of a
13053 darwin_so_list, separately allocate an lm_info object.
13054 (darwin_free_so): Free lm_info.
13056 2017-04-28 John Baldwin <jhb@FreeBSD.org>
13058 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13059 with fprintf_filtered.
13061 2017-04-28 Yao Qi <yao.qi@linaro.org>
13063 * regcache.c (regcache::regcache): New function.
13064 (regcache::~regcache): New function.
13065 (regcache_xmalloc_1): Remove.
13066 (regcache_xmalloc): Call new regcache.
13067 (regcache_xfree): Call delete regcache.
13068 (get_thread_arch_aspace_regcache): Call new regcache.
13070 2017-04-28 Yao Qi <yao.qi@linaro.org>
13072 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13073 lwp instead of ptid_get_lwp.
13075 2017-04-28 Yao Qi <yao.qi@linaro.org>
13077 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13078 lwp_info instead of getting from inferior_ptid.
13080 2017-04-27 Keith Seitz <keiths@redhat.com>
13082 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13083 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13084 (CV_CONVERSION_BADNESS): Define.
13085 (rank_one_type): Remove overly restrictive rvalue reference
13087 Add cv-qualifier checks and subranks for type equality.
13088 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13089 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13090 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13092 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13094 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13095 count when creating the object.
13097 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13098 Ulrich Weigand <uweigand@de.ibm.com>
13100 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13101 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13103 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13104 (process_xcoff_symbol): Likewise.
13105 (scan_xcoff_symtab): Likewise.
13107 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13109 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13110 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13111 (ia64_access_reg): Use get_frame_register_unsigned.
13112 (ia64_access_rse_reg): Likewise.
13113 (ia64_libunwind_frame_prev_register): Likewise.
13115 2017-04-26 Jiong Wang <jiong.wang@arm.com>
13117 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13118 * gdbarch.c: Regenerated.
13119 * gdbarch.h: Regenerated.
13120 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13121 visibility external.
13122 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13123 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13124 (enum cfa_how_kind): Move to ...
13125 (struct dwarf2_frame_state_reg_info): Likewise.
13126 (struct dwarf2_frame_state): Likewise.
13127 * dwarf2-frame.h: ... here.
13128 (dwarf2_frame_state_alloc_regs): New declaration.
13129 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13130 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13132 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13134 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13135 regcache_raw_read_unsigned.
13136 (xtensa_pseudo_register_write): Likewise.
13138 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13140 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13141 (nds32_pseudo_register_write): Likewise.
13143 2017-04-25 Yao Qi <yao.qi@linaro.org>
13145 * regcache.c (struct regcache) <readonly_p>: Change its type
13147 (regcache_xmalloc_1): Update parameter type and callers update.
13149 2017-04-25 Yao Qi <yao.qi@linaro.org>
13151 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13152 set_gdbarch_wchar_bit.
13153 * arm-tdep.c (arm_gdbarch_init): Likewise.
13155 2017-04-25 Pedro Alves <palves@redhat.com>
13157 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13158 (BothAreRelocatable, memcopy, memmove): Don't define.
13159 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13162 2017-04-25 Pedro Alves <palves@redhat.com>
13164 * common/common-defs.h: Include "common/poison.h".
13165 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13167 * common/poison.h: New file.
13168 * common/traits.h: Include <type_traits>.
13169 (Not, Or, Requires): New, moved from common/function-view.h.
13171 2017-04-25 Pedro Alves <palves@redhat.com>
13173 * breakpoint.h (struct breakpoint): In-class initialize all
13174 fields. Make boolean fields "bool".
13175 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13176 memset call and initializations no longer necessary.
13178 2017-04-25 Pedro Alves <palves@redhat.com>
13180 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13182 (pt_btrace_insn): New function.
13183 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13185 2017-04-25 Pedro Alves <palves@redhat.com>
13187 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13188 "base" field and inherit from "bp_location" instead. Add
13190 (allocate_location_exception): Use new non-default ctor.
13191 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13192 (init_bp_location): Convert to ...
13193 (bp_location::bp_location): ... this new ctor, and remove memset
13195 (base_breakpoint_allocate_location): Use the new non-default ctor.
13196 * breakpoint.h (bp_location): Now a class. Declare default and
13197 non-default ctors. In-class initialize all members.
13198 (init_bp_location): Remove declaration.
13200 2017-04-25 Pedro Alves <palves@redhat.com>
13202 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13203 assignment operator.
13205 2017-04-24 Yao Qi <yao.qi@linaro.org>
13207 * doublest.c (convert_doublest_to_floatformat): Call
13208 floatformat_totalsize_bytes.
13210 2017-04-22 Tom Tromey <tom@tromey.com>
13212 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13214 * stack.c (print_frame): Use ui_out_emit_list.
13215 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13217 * mi/mi-main.c (print_one_inferior)
13218 (mi_cmd_data_list_register_names)
13219 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13220 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13222 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13223 (mi_output_solib_attribs): Use ui_out_emit_list,
13225 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13226 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13227 (mi_cmd_stack_list_args, list_args_or_locals): Use
13229 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13230 * breakpoint.c (print_solib_event, output_thread_groups): Use
13233 2017-04-22 Tom Tromey <tom@tromey.com>
13235 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13236 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13237 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13239 2017-04-22 Tom Tromey <tom@tromey.com>
13241 * tracepoint.c (tvariables_info_1)
13242 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13244 2017-04-22 Tom Tromey <tom@tromey.com>
13246 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13247 annotate_arg_emitter.
13248 * breakpoint.c (print_mention_watchpoint)
13249 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13250 * annotate.h (struct annotate_arg_emitter): New.
13252 2017-04-22 Tom Tromey <tom@tromey.com>
13254 * record-btrace.c (record_btrace_insn_history)
13255 (record_btrace_insn_history_range, record_btrace_call_history)
13256 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13257 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13259 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13260 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13261 * skip.c (skip_info): Use ui_out_emit_tuple.
13262 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13263 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13264 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13265 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13266 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13268 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13269 (output_register, mi_cmd_data_read_memory)
13270 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13271 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13272 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13273 Use ui_out_emit_tuple.
13274 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13276 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13277 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13278 * linux-thread-db.c (info_auto_load_libthread_db): Use
13280 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13281 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13282 * disasm.c (do_mixed_source_and_assembly_deprecated)
13283 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13284 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13285 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13286 * breakpoint.c (print_one_breakpoint_location)
13287 (print_one_breakpoint): Use ui_out_emit_tuple.
13288 * auto-load.c (print_script, info_auto_load_cmd): Use
13290 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13292 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13294 * thread.c (print_thread_info_1): Remove dead code.
13296 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13298 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13300 * arm-tdep.c (selftests::arm_record_test): Likewise.
13302 2017-04-21 Yao Qi <yao.qi@linaro.org>
13304 * regcache.c (regcache_restore): Remove argument 2. Replace
13305 argument 3 with regcache. Get register status from
13306 src->register_status and get register contents from
13307 register_buffer (src, regnum).
13308 (regcache_cpy): Update.
13310 2017-04-19 Pedro Alves <palves@redhat.com>
13312 * gdbthread.h (thread): Add missing closing parenthesis in
13315 2017-04-19 Pedro Alves <palves@redhat.com>
13317 * common/refcounted-object.h: New file.
13318 * gdbthread.h: Include "common/refcounted-object.h".
13319 (thread_info): Inherit from refcounted_object and add comments.
13320 (thread_info::incref, thread_info::decref)
13321 (thread_info::m_refcount): Delete.
13322 (thread_info::deletable): Use the refcounted_object::refcount()
13324 * inferior.c (current_inferior_): Add comment.
13325 (set_current_inferior): Increment/decrement refcounts.
13326 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13327 not-deletable instead of comparing with the current inferior.
13328 (initialize_inferiors): Increment the initial inferior's refcount.
13329 * inferior.h (struct inferior): Forward declare.
13330 Include "common/refcounted-object.h".
13331 (current_inferior, set_current_inferior): Move declaration to
13332 before struct inferior's definition, and fix comment.
13333 (inferior): Inherit from refcounted_object. Add comments.
13334 * thread.c (switch_to_thread_no_regs): Reference the thread's
13335 inferior pointer directly instead of doing a ptid lookup.
13336 (switch_to_no_thread): New function.
13337 (switch_to_thread(thread_info *)): New function, factored out
13339 (switch_to_thread(ptid_t)): ... this.
13340 (restore_current_thread): Delete.
13341 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13342 fields, and add 'inf' field.
13343 (do_restore_current_thread_cleanup): Check whether old->inf is
13344 alive instead of looking up an inferior by ptid. Use
13345 switch_to_thread and switch_to_no_thread.
13346 (restore_current_thread_cleanup_dtor): Use old->inf directly
13347 instead of lookup up an inferior by id. Decref the inferior.
13348 Don't restore 'removable'.
13349 (make_cleanup_restore_current_thread): Same the inferior pointer
13350 in old, instead of the inferior number. Incref the inferior.
13351 Don't save/clear 'removable'.
13353 2017-04-19 Pedro Alves <palves@redhat.com>
13355 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13356 unittests/scoped_restore-selftests.c.
13357 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13358 * common/scoped_restore.h (scoped_restore_base): Make "class".
13359 (scoped_restore_base::release): New public method.
13360 (scoped_restore_base::scoped_restore_base): New protected ctor.
13361 (scoped_restore_base::m_saved_var): New protected field.
13362 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13363 scoped_restore_base base class instead of m_saved_var directly.
13364 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13365 (scoped_restore_tmpl::scoped_restore_tmpl(const
13366 scoped_restore_tmpl<T>&)): Likewise.
13367 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13369 (scoped_restore_tmpl::saved_var): New method.
13370 (scoped_restore_tmpl::m_saved_var): Delete.
13371 * inferior.h (inferior::detaching): Now a bool.
13372 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13374 * unittests/scoped_restore-selftests.c: New file.
13376 2017-04-19 Pedro Alves <palves@redhat.com>
13378 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13379 Re-sort in alphabetic order.
13381 2017-04-18 Pedro Alves <palves@redhat.com>
13383 * xml-support.c (obstack_xml_printf): Delete.
13384 * xml-support.h (obstack_xml_printf): Delete.
13386 2017-04-18 Pedro Alves <palves@redhat.com>
13388 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13389 vdebug, verror, body_text, start_element, end_element, name,
13390 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13391 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13392 is_xinclude>: Make private and add m_ prefix.
13393 (gdb_xml_parser::body_text): New method, based on ...
13394 (gdb_xml_body_text): ... this. Adjust.
13395 (gdb_xml_parser::vdebug): New method, based on ...
13396 (gdb_xml_debug): ... this. Adjust.
13397 (gdb_xml_parser::verror): New method, based on ...
13398 (gdb_xml_error): ... this. Adjust.
13399 (gdb_xml_parser::start_element): New method, based on ...
13400 (gdb_xml_start_element): ... this. Adjust.
13401 (gdb_xml_start_element_wrapper): Defer to
13402 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
13403 (gdb_xml_parser::end_element): New method, based on ...
13404 (gdb_xml_end_element_wrapper): ... this. Adjust.
13405 (gdb_xml_parser::~gdb_xml_parser): Adjust.
13406 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
13407 (gdb_xml_parser::use_dtd): New method, based on ...
13408 (gdb_xml_use_dtd): ... this. Adjust.
13409 (gdb_xml_parser::parse): New method, based on ...
13410 (gdb_xml_parse): ... this. Adjust.
13411 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
13412 (xinclude_start_include): Adjust to call the parser's name method.
13413 (xml_xinclude_default, xml_xinclude_start_doctype)
13414 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
13416 (xml_process_xincludes): Adjust to call parser methods.
13417 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
13420 2017-04-18 Pedro Alves <palves@redhat.com>
13422 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
13423 gdb::optional<std::string>.
13424 * xml-support.c: Include <string>.
13425 (scope_level::scope_level(scope_level &&))
13426 (scope_level::~scope_level): Delete.
13427 (scope_level::body): Now a std::string.
13428 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
13429 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
13431 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
13432 (xinclude_parsing_data::output): Now a std::string reference.
13433 (xinclude_start_include): Adjust.
13434 (xml_xinclude_default): Adjust.
13435 (xml_process_xincludes): Add 'output' parameter, and return bool.
13436 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
13438 * xml-tdesc.c: Include <unordered_map> and <string>.
13439 (tdesc_xml_cache): Delete.
13440 (tdesc_xml_cache_s): Delete.
13441 (xml_cache): Now an std::unordered_map.
13442 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
13443 (target_fetch_description_xml): Change return type to
13444 gdb::optional<std::string>, and adjust.
13445 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
13446 (target_fetch_description_xml): Change return type to
13447 gdb::optional<std::string>.
13449 2017-04-18 Pedro Alves <palves@redhat.com>
13451 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13452 unittests/optional-selftests.c.
13453 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
13454 * unittests/optional-selftests.c: New file.
13455 * unittests/optional/assignment/1.cc: New file.
13456 * unittests/optional/assignment/2.cc: New file.
13457 * unittests/optional/assignment/3.cc: New file.
13458 * unittests/optional/assignment/4.cc: New file.
13459 * unittests/optional/assignment/5.cc: New file.
13460 * unittests/optional/assignment/6.cc: New file.
13461 * unittests/optional/assignment/7.cc: New file.
13462 * unittests/optional/cons/copy.cc: New file.
13463 * unittests/optional/cons/default.cc: New file.
13464 * unittests/optional/cons/move.cc: New file.
13465 * unittests/optional/cons/value.cc: New file.
13466 * unittests/optional/in_place.cc: New file.
13467 * unittests/optional/observers/1.cc: New file.
13468 * unittests/optional/observers/2.cc: New file.
13470 2017-04-18 Pedro Alves <palves@redhat.com>
13472 * common/gdb_optional.h: Include common/traits.h.
13473 (in_place_t): New type.
13474 (in_place): New constexpr variable.
13475 (optional::optional): Remove member initialization of
13477 (optional::optional(in_place_t...)): New constructor.
13478 (optional::~optional): Use reset.
13479 (optional::optional(const optional&)): New.
13480 (optional::optional(const optional&&)): New.
13481 (optional::optional(T &)): New.
13482 (optional::optional(T &&)): New.
13483 (operator::operator=(const optional &)): New.
13484 (operator::operator=(optional &&)): New.
13485 (operator::operator= (const T &))
13486 (operator::operator= (T &&))
13487 (operator::emplace (Args &&... args)): Return a T&. Use reset.
13488 (operator::reset): New.
13489 (operator::m_instantiated):: Add in-class initializer.
13490 * common/traits.h: Include <type_traits>.
13491 (struct And): New types.
13493 2017-04-18 Pedro Alves <palves@redhat.com>
13495 * xml-support.c: Include <vector>.
13496 (scope_level::scope_level(const gdb_xml_element *))
13497 (scope_level::scope_level(scope_level&&)): New.
13498 (scope_level::~scope_level): New.
13499 (scope_level_s): Delete.
13500 (gdb_xml_parser::scopes): Now a std::vector.
13501 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
13503 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
13504 scope cleanup code.
13505 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
13506 of the scopes member. Use std::vector::emplace_back.
13508 2017-04-18 Pedro Alves <palves@redhat.com>
13510 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
13512 (gdb_xml_end_element): Change type of first parameter.
13513 (gdb_xml_cleanup): Rename to ...
13514 (gdb_xml_parser::~gdb_xml_parser): ... this.
13515 (gdb_xml_create_parser_and_cleanup): Delete with ...
13516 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
13518 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
13519 using gdb_xml_create_parser_and_cleanup.
13520 (xinclude_parsing_data): Add ctor/dtor.
13521 (xml_xinclude_cleanup): Delete.
13522 (xml_process_xincludes): Create a local xinclude_parsing_data
13523 instead of heap-allocating one. Create a local gdb_xml_parser
13524 instead of heap-allocating one with
13525 gdb_xml_create_parser_and_cleanup.
13527 2017-04-18 John Baldwin <jhb@FreeBSD.org>
13530 * fbsd-nat.c (resume_one_thread_cb): Remove.
13531 (resume_all_threads_cb): Remove.
13532 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
13533 iterate_over_threads.
13535 2017-04-17 Joel Brobecker <brobecker@adacore.com>
13537 * NEWS: Create a new section for the next release branch.
13538 Rename the section of the current branch, now that it has
13541 2017-04-17 Joel Brobecker <brobecker@adacore.com>
13543 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
13544 * version.in: Bump version to 8.0.50.DATE-git.
13546 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
13549 * windows-nat.c (windows_create_inferior): Declare 'allargs'
13550 independently of the host, and fix build breakage on Cygwin.
13552 2017-04-13 Pedro Alves <palves@redhat.com>
13554 * inferior.c (free_inferior): Convert to ...
13555 (inferior::~inferior): ... this dtor.
13556 (inferior::inferior): New ctor, factored out from ...
13557 (add_inferior_silent): ... here. Allocate the inferior with a new
13559 (delete_inferior): Call delete instead of free_inferior.
13560 * inferior.h (gdb_environ, continuation): Forward declare.
13561 (inferior): Now a class. Add in-class initialization to all
13562 members. Make boolean fields bool, except 'detaching'.
13563 (inferior::inferior): New explicit ctor.
13564 (inferior::~inferior): New.
13566 2017-04-13 Pedro Alves <palves@redhat.com>
13568 * inferior.c (init_inferior_list): Delete.
13569 * inferior.h (init_inferior_list): Delete.
13571 2017-04-13 Pedro Alves <palves@redhat.com>
13574 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
13575 (top level): Call it twice, with different thread sets.
13577 2017-04-13 Pedro Alves <palves@redhat.com>
13579 * thread.c: Include <algorithm>.
13580 (thread_array_cleanup): Delete.
13581 (scoped_inc_dec_ref): New class.
13582 (live_threads_count): New function.
13583 (set_thread_refcount): Delete.
13584 (tp_array_compar_ascending): Now a bool.
13585 (tp_array_compar): Convert to a std::sort comparison function.
13586 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
13587 and live_threads_count.
13589 2017-04-13 Pedro Alves <palves@redhat.com>
13591 * infrun.c (follow_fork_inferior): Also switch the current
13594 2017-04-13 Pedro Alves <palves@redhat.com>
13596 * breakpoint.c (watch_command_1): Save watchpoint-frame info
13597 before calling create_internal_breakpoint.
13599 2017-04-13 Pedro Alves <palves@redhat.com>
13601 * fork-child.c (execv_argv): New class.
13602 (breakup_args): Refactored as ...
13603 (execv_argv::init_for_no_shell): .. this method of execv_argv.
13604 Copy arguments to storage and replace separators with NULL
13605 terminators in place.
13606 (escape_bang_in_quoted_argument): Adjust to return bool.
13607 (execv_argv::execv_argv): New ctor.
13608 (execv_argv::init_for_shell): New method, factored out from
13609 fork_inferior. Don't strdup strings into the vector.
13610 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
13611 Remove free_vector_argv call.
13613 2017-04-13 Yao Qi <yao.qi@linaro.org>
13615 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
13618 2017-04-13 Yao Qi <yao.qi@linaro.org>
13620 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
13621 * rx-tdep.c (rx_gdbarch_init): Likewise.
13623 2017-04-13 Pedro Alves <palves@redhat.com>
13625 * breakpoint.h (struct breakpoint): Reindent.
13627 2017-04-13 Pedro Alves <palves@redhat.com>
13629 * breakpoint.c (bp_location): Rename to ...
13630 (bp_locations): ... this. All references updated.
13631 (bp_location_count): Rename to ...
13632 (bp_locations_count): ... this. All references updated.
13633 (bp_location_placed_address_before_address_max): Rename to ...
13634 (bp_locations_placed_address_before_address_max): ... this. All
13635 references updated.
13636 (bp_location_shadow_len_after_address_max): Rename to ...
13637 (bp_locations_shadow_len_after_address_max): ... this. All
13638 references updated.
13639 (bp_location_compare_addrs): Rename to ...
13640 (bp_locations_compare_addrs): ... this. All references updated.
13641 (bp_location_compare):Rename to ...
13642 (bp_locations_compare): ... this. All references updated.
13643 (bp_location_target_extensions_update): Rename to ...
13644 (bp_locations_target_extensions_update): ... this. All references
13647 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13649 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
13650 * common/common.m4: Check headers 'termios.h', 'termio.h' and
13652 * common/gdb_termios.h: New file, with parts of "terminal.h".
13653 * inflow.c: Include "gdb_termios.h".
13654 * ser-unix.c: Include "gdb_termios.h".
13655 * terminal.h: Move terminal-related defines to
13656 "common/gdb_termios.h".
13658 2017-04-12 Tom Tromey <tom@tromey.com>
13660 * probe.c (parse_probes): Update.
13661 * location.h (delete_event_location): Don't declare.
13662 (event_location_deleter::operator()): Update.
13663 * location.c (event_location_deleter::operator()): Rename from
13664 delete_event_location.
13665 * linespec.h (linespec_result) <location>: Change type to
13667 * linespec.c (canonicalize_linespec, event_location_to_sals)
13668 (decode_objc): Update.
13669 (linespec_result): Don't call delete_event_location.
13670 * breakpoint.c (create_breakpoints_sal)
13671 (bkpt_probe_create_sals_from_location)
13672 (strace_marker_create_sals_from_location): Update.
13674 2017-04-12 Tom Tromey <tom@tromey.com>
13676 * linespec.h (struct linespec_result): Add constructor and
13678 (init_linespec_result, destroy_linespec_result)
13679 (make_cleanup_destroy_linespec_result): Don't declare.
13680 * linespec.c (init_linespec_result): Remove.
13681 (linespec_result::~linespec_result): Rename from
13682 destroy_linespec_result. Update.
13683 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
13685 * breakpoint.c (create_breakpoint, break_range_command)
13686 (decode_location_default): Update.
13687 * ax-gdb.c (agent_command_1): Update.
13689 2017-04-12 Tom Tromey <tom@tromey.com>
13691 * remote.c (remote_download_tracepoint): Update.
13692 * python/py-breakpoint.c (bppy_get_location): Update.
13693 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
13694 (gdbscm_breakpoint_location): Update.
13695 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
13696 * breakpoint.h (struct breakpoint) <location, location_range_end>:
13697 Change type to event_location_up.
13698 * breakpoint.c (create_overlay_event_breakpoint)
13699 (create_longjmp_master_breakpoint)
13700 (create_std_terminate_master_breakpoint)
13701 (create_exception_master_breakpoint)
13702 (breakpoint_event_location_empty_p, print_breakpoint_location)
13703 (print_one_breakpoint_location, create_thread_event_breakpoint)
13704 (init_breakpoint_sal, create_breakpoint)
13705 (print_recreate_ranged_breakpoint, break_range_command)
13706 (init_ada_exception_breakpoint, say_where): Update.
13707 (base_breakpoint_dtor): Don't call delete_event_location.
13708 (bkpt_print_recreate, tracepoint_print_recreate)
13709 (dprintf_print_recreate, update_static_tracepoint)
13710 (breakpoint_re_set_default): Update.
13712 2017-04-12 Tom Tromey <tom@tromey.com>
13714 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
13715 type of "to_do". Update.
13716 (compute_stack_depth): Use std::vector.
13718 2017-04-12 Tom Tromey <tom@tromey.com>
13720 * printcmd.c (find_instruction_backward): Use std::vector.
13722 2017-04-12 Tom Tromey <tom@tromey.com>
13724 * symfile.c (objfilep): Remove typedef.
13725 (reread_symbols): Use a std::vector.
13727 2017-04-12 Tom Tromey <tom@tromey.com>
13729 * mi/mi-main.c (exec_direction_forward): Remove.
13730 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
13731 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
13733 * guile/guile.c (guile_repl_command, guile_command)
13734 (gdbscm_execute_gdb_command): Use scoped_restore.
13735 * go-exp.y (go_parse): Use scoped_restore.
13736 * d-exp.y (d_parse): Use scoped_restore.
13737 * cli/cli-decode.c (cmd_func): Use scoped_restore.
13738 * c-exp.y (c_parse): Use scoped_restore.
13740 2017-04-12 Tom Tromey <tom@tromey.com>
13742 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
13743 (mi_parse): Update return type.
13744 (mi_parse_free): Remove.
13745 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
13746 (mi_parse::~mi_parse): Rename from mi_parse_free.
13747 (mi_parse_cleanup): Remove.
13748 (mi_parse): Return a unique_ptr. Use new.
13749 * mi/mi-main.c (mi_execute_command): Update.
13751 2017-04-12 Tom Tromey <tom@tromey.com>
13753 * location.c (explicit_location_lex_one): Return a
13754 unique_xmalloc_ptr.
13755 (string_to_explicit_location): Update. Remove cleanups.
13757 2017-04-12 Tom Tromey <tom@tromey.com>
13759 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
13760 (compare_value_and_voffset): Change type. Update.
13761 (compute_vtable_size): Change type of "offset_vec".
13762 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
13763 (gnuv3_get_typeid): Remove extraneous declaration.
13765 2017-04-12 Tom Tromey <tom@tromey.com>
13767 * charset.h (wchar_iterator): Fix comment.
13769 2017-04-12 Tom Tromey <tom@tromey.com>
13771 * charset.c (iconv_wrapper): New class.
13772 (cleanup_iconv): Remove.
13773 (convert_between_encodings): Use it.
13775 2017-04-12 Tom Tromey <tom@tromey.com>
13777 * symfile.h (increment_reading_symtab): Update type.
13778 * symfile.c (decrement_reading_symtab): Remove.
13779 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
13780 * psymtab.c (psymtab_to_symtab): Update.
13781 * dwarf2read.c (dw2_instantiate_symtab): Update.
13783 2017-04-12 Tom Tromey <tom@tromey.com>
13785 * jit.c (struct jit_reader): Declare separately. Add constructor
13786 and destructor. Change type of "handle".
13787 (loaded_jit_reader): Define separately.
13788 (jit_reader_load): Update. New "new".
13789 (jit_reader_unload_command): Use "delete".
13790 * gdb-dlfcn.h (struct dlclose_deleter): New.
13791 (gdb_dlhandle_up): New typedef.
13792 (gdb_dlopen, gdb_dlsym): Update types.
13793 (gdb_dlclose): Remove.
13794 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
13795 (gdb_dlsym): Change type of "handle".
13796 (make_cleanup_dlclose): Remove.
13797 (dlclose_deleter::operator()): Rename from gdb_dlclose.
13798 * compile/compile-c-support.c (load_libcc): Update.
13800 2017-04-12 Tom Tromey <tom@tromey.com>
13802 * symtab.h (find_pcs_for_symtab_line): Change return type.
13803 * symtab.c (find_pcs_for_symtab_line): Change return type.
13804 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
13805 type of "vec". Update.
13806 (ltpy_get_pcs_for_line): Update.
13807 * linespec.c (decode_digits_ordinary): Update.
13809 2017-04-12 Tom Tromey <tom@tromey.com>
13811 * tracepoint.c (actions_command): Update.
13812 * python/python.c (python_command, python_interactive_command):
13814 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
13815 * guile/guile.c (guile_command): Update.
13816 * defs.h (read_command_lines, read_command_lines_1): Return
13818 (command_lines_deleter): New struct.
13819 (command_line_up): New typedef.
13820 * compile/compile.c (compile_code_command)
13821 (compile_print_command): Update.
13822 * cli/cli-script.h (get_command_line, copy_command_lines): Return
13824 (make_cleanup_free_command_lines): Remove.
13825 * cli/cli-script.c (get_command_line, read_command_lines_1)
13826 (copy_command_lines): Return command_line_up.
13827 (while_command, if_command, read_command_lines, define_command)
13828 (document_command): Update.
13829 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
13831 * breakpoint.h (breakpoint_set_commands): Change type of
13833 * breakpoint.c (breakpoint_set_commands): Change type of
13834 "commands". Update.
13835 (do_map_commands_command, update_dprintf_command_list)
13836 (create_tracepoint_from_upload): Update.
13838 2017-04-12 Tom Tromey <tom@tromey.com>
13840 * tracepoint.c (scope_info): Update.
13841 * spu-tdep.c (spu_catch_start): Update.
13842 * python/python.c (gdbpy_decode_line): Update.
13843 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
13844 * python/py-breakpoint.c (bppy_init): Update.
13845 * probe.c (parse_probes): Update.
13846 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
13847 * location.h (event_location_deleter): New struct.
13848 (event_location_up): New typedef.
13849 (new_linespec_location, new_address_location, new_probe_location)
13850 (new_explicit_location, copy_event_location)
13851 (string_to_event_location, string_to_event_location_basic)
13852 (string_to_explicit_location): Update return type.
13853 (make_cleanup_delete_event_location): Remove.
13854 * location.c (new_linespec_location, new_address_location)
13855 (new_probe_location, new_explicit_location, copy_event_location):
13856 Return event_location_up.
13857 (delete_event_location_cleanup)
13858 (make_cleanup_delete_event_location): Remove.
13859 (string_to_explicit_location, string_to_event_location_basic)
13860 (string_to_event_location): Return event_location_up.
13861 * linespec.c (canonicalize_linespec, event_location_to_sals)
13862 (decode_line_with_current_source)
13863 (decode_line_with_last_displayed, decode_objc): Update.
13864 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
13865 * completer.c (location_completer): Update.
13866 * cli/cli-cmds.c (edit_command, list_command): Update.
13867 * breakpoint.c (create_overlay_event_breakpoint)
13868 (create_longjmp_master_breakpoint)
13869 (create_std_terminate_master_breakpoint)
13870 (create_exception_master_breakpoint)
13871 (create_thread_event_breakpoint): Update.
13872 (init_breakpoint_sal): Update. Remove some dead code.
13873 (create_breakpoint_sal): Change type of "location". Update.
13874 (create_breakpoints_sal, create_breakpoint, break_command_1)
13875 (dprintf_command, break_range_command, until_break_command)
13876 (init_ada_exception_breakpoint)
13877 (strace_marker_create_sals_from_location)
13878 (update_static_tracepoint, trace_command, ftrace_command)
13879 (strace_command, create_tracepoint_from_upload): Update.
13880 * break-catch-throw.c (re_set_exception_catchpoint): Update.
13881 * ax-gdb.c (agent_command_1): Update.
13883 2017-04-12 Pedro Alves <palves@redhat.com>
13885 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
13886 * configure.tgt: Handle i[34567]86-*-go32* and
13887 i[34567]86-*-msdosdjgpp*.
13888 * i386-tdep.c (i386_svr4_reg_to_regnum):
13890 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
13892 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
13893 * i386-go32-tdep.c: New file.
13894 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
13897 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
13899 * aix-thread.c (pd_status2str): Change return type to const char *.
13901 2017-04-12 Pedro Alves <palves@redhat.com>
13903 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
13904 calls to set_gdbarch_gnu_triplet_regexp.
13906 2017-04-12 Pedro Alves <palves@redhat.com>
13909 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
13911 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
13912 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
13913 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
13914 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
13915 * gdbarch.h, gdbarch.c: Regenerate.
13916 * aarch64-tdep.c (aarch64_gdbarch_init): Override
13917 gdbarch_wchar_bit and gdbarch_wchar_signed.
13918 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
13919 * arm-tdep.c (arm_gdbarch_init): Likewise.
13920 * avr-tdep.c (avr_gdbarch_init): Likewise.
13921 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
13922 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
13923 * i386-tdep.c (i386_go32_init_abi): Likewise.
13924 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
13925 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
13926 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
13927 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
13928 * sh-tdep.c (sh_gdbarch_init): Likewise.
13929 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
13930 * sparc64-tdep.c (sparc64_init_abi): Likewise.
13931 * windows-tdep.c (windows_init_abi): Likewise.
13932 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
13934 2017-04-12 Pedro Alves <palves@redhat.com>
13937 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
13938 cplus_primitive_type_char32_t>: New enum values.
13939 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
13940 and cplus_primitive_type_char32_t.
13941 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
13942 32, use the archtecture's built-in type for char16_t and char32_t,
13943 respectively. Otherwise, fallback to init_integer_type as before,
13944 but make the type unsigned, and issue a complaint.
13945 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
13947 2017-04-12 Alan Hayward <alan.hayward@arm.com>
13949 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
13950 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
13952 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13954 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
13957 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13959 * common/common-utils.c (free_vector_argv): New function.
13960 * common/common-utils.h: Include <vector>.
13961 (free_vector_argv): New prototype.
13962 * darwin-nat.c (darwin_create_inferior): Rewrite function
13963 prototype in order to constify "exec_file" and accept a
13964 "std::string" for "allargs".
13965 * fork-child.c: Include <vector>.
13966 (breakup_args): Rewrite function, using C++.
13967 (fork_inferior): Rewrite function header, constify "exec_file_arg"
13968 and accept "std::string" for "allargs". Update the code to
13969 calculate "argv" based on "allargs". Update calls to "exec_fun"
13971 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
13972 order to constify "exec_file" and accept a "std::string" for
13974 * go32-nat.c (go32_create_inferior): Likewise.
13975 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
13976 * infcmd.c (run_command_1): Constify "exec_file". Use
13977 "std::string" for inferior arguments.
13978 * inferior.h (fork_inferior): Update prototype.
13979 * linux-nat.c (linux_nat_create_inferior): Rewrite function
13980 prototype in order to constify "exec_file" and accept a
13981 "std::string" for "allargs".
13982 * nto-procfs.c (procfs_create_inferior): Likewise.
13983 * procfs.c (procfs_create_inferior): Likewise.
13984 * remote-sim.c (gdbsim_create_inferior): Likewise.
13985 * remote.c (extended_remote_run): Update code to accept
13986 "std::string" as argument.
13987 (extended_remote_create_inferior): Rewrite function prototype in
13988 order to constify "exec_file" and accept a "std::string" for
13990 * rs6000-nat.c (super_create_inferior): Likewise.
13991 (rs6000_create_inferior): Likewise.
13992 * target.h (struct target_ops) <to_create_inferior>: Likewise.
13993 * windows-nat.c (windows_create_inferior): Likewise.
13995 2017-04-11 Pedro Alves <palves@redhat.com>
13997 * thread.c: Fix whitespace throughout.
13999 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
14001 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
14003 2017-04-11 Alan Hayward <alan.hayward@arm.com>
14005 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
14007 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
14010 * osdata.c (info_osdata): Check if 'type' is an empty string
14013 2017-04-10 Pedro Alves <palves@redhat.com>
14015 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
14016 (ptid_to_global_thread_id, in_thread_list)
14017 (do_captured_list_thread_ids, set_resumed, set_running)
14018 (set_executing, set_stop_requested, finish_thread_state)
14019 (validate_registers_access, can_access_registers_ptid)
14020 (print_thread_info_1, switch_to_thread)
14021 (do_restore_current_thread_cleanup)
14022 (make_cleanup_restore_current_thread, thread_command)
14023 (thread_name_command): Use operator== instead of ptid_equal.
14025 2017-04-10 Pedro Alves <palves@redhat.com>
14027 * thread.c (struct current_thread_cleanup) <next>: Delete field.
14028 (current_thread_cleanup_chain): Delete.
14029 (restore_current_thread_cleanup_dtor)
14030 (make_cleanup_restore_current_thread): Remove references to
14031 current_thread_cleanup_chain.
14033 2017-04-10 Alan Hayward <alan.hayward@arm.com>
14035 * msp430-tdep.c (msp430_pseudo_register_read): Never return
14038 2017-04-10 Yao Qi <yao.qi@linaro.org>
14041 * gdbthread.h (thread_info::deletable): New method.
14042 (thread_info::incref): New method.
14043 (thread_info::decref): New method.
14044 (thread_info::refcount): Move it to private.
14045 * infrun.c (save_stop_context): Call inc_refcount.
14046 (release_stop_context_cleanup): Likewise.
14047 * thread.c (set_thread_exited): New function.
14048 (init_thread_list): Delete "tp" only it is deletable, otherwise
14049 call set_thread_exited.
14050 (delete_thread_1): Call set_thread_exited.
14051 (current_thread_cleanup) <inferior_pid>: Remove.
14052 <thread>: New field.
14053 (restore_current_thread_ptid_changed): Removed.
14054 (do_restore_current_thread_cleanup): Adjust.
14055 (restore_current_thread_cleanup_dtor): Don't call
14057 (set_thread_refcount): Use dec_refcount.
14058 (make_cleanup_restore_current_thread): Adjust.
14059 (thread_apply_all_command): Call inc_refcount.
14060 (_initialize_thread): Don't call
14061 observer_attach_thread_ptid_changed.
14063 2017-04-10 Yao Qi <yao.qi@linaro.org>
14065 * thread.c (delete_thread_1): Hoist code on marking thread as
14068 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14070 * windows-nat.c (windows_detach): Initialize ptid with
14073 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14075 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14077 2017-04-07 Alan Hayward <alan.hayward@arm.com>
14079 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14080 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14081 (bfin_pseudo_register_write): Likewise
14083 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14085 * common/ptid.h (struct ptid): Change to...
14086 (class ptid_t): ... this.
14087 <ptid_t>: New constructors.
14088 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14089 matches>: New methods.
14090 <make_null, make_minus_one>: New static methods.
14091 <pid>: Rename to...
14093 <lwp>: Rename to...
14095 <tid>: Rename to...
14097 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14098 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14099 as references, move comment to class ptid_t.
14100 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14101 ptid_t static methods.
14102 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14103 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14104 Take ptid arguments as references, implement using ptid_t methods.
14105 * unittests/ptid-selftests.c: New file.
14106 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14107 unittests/ptid-selftests.c.
14108 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14110 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14112 * python/python.c (python_run_simple_file): Cast mode literal to
14113 non-const char pointer as expected by PyFile_FromString.
14115 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14117 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14118 minus_one_ptid and null_ptid.
14120 2017-04-05 Pedro Alves <palves@redhat.com>
14122 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14123 * configure: Regenerate.
14125 2017-04-05 Pedro Alves <palves@redhat.com>
14127 * ada-exp.y (yyerror): Constify.
14128 * ada-lang.c (bound_name, get_selections)
14129 (ada_variant_discrim_type)
14130 (ada_variant_discrim_name, ada_value_struct_elt)
14131 (ada_lookup_struct_elt_type, is_unchecked_variant)
14132 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14133 (catch_ada_exception_command_split)
14134 (catch_ada_assert_command_split, catch_assert_command)
14135 (ada_op_name): Constify.
14136 * ada-lang.h (ada_yyerror, get_selections)
14137 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14138 * arc-tdep.c (arc_print_frame_cache): Constify.
14139 * arm-tdep.c (arm_skip_stub): Constify.
14140 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14141 (gen_aggregate_elt_ref): Constify.
14142 * bcache.c (print_bcache_statistics): Constify.
14143 * bcache.h (print_bcache_statistics): Constify.
14144 * break-catch-throw.c (catch_exception_command_1):
14145 * breakpoint.c (struct ep_type_description::description):
14147 (add_solib_catchpoint): Constify.
14148 (catch_fork_command_1): Add cast.
14149 (add_catch_command): Constify.
14150 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14152 * bsd-uthread.c (bsd_uthread_state): Constify.
14153 * buildsym.c (patch_subfile_names): Constify.
14154 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14156 * c-exp.y (yyerror): Constify.
14157 (token::oper): Constify.
14158 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14159 * c-varobj.c (cplus_describe_child): Constify.
14160 * charset.c (find_charset_names): Add cast.
14161 (find_charset_names): Constify array and add const_cast.
14162 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14163 (edit_command): Constify.
14164 * cli/cli-decode.c (lookup_cmd): Constify.
14165 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14167 (struct dump_context): Constify.
14168 (add_dump_command, restore_command): Constify.
14169 * cli/cli-script.c (get_command_line): Constify.
14170 * cli/cli-script.h (get_command_line): Constify.
14171 * cli/cli-utils.c (check_for_argument): Constify.
14172 * cli/cli-utils.h (check_for_argument): Constify.
14173 * coff-pe-read.c (struct read_pe_section_data): Constify.
14174 * command.h (lookup_cmd): Constify.
14175 * common/print-utils.c (decimal2str): Constify.
14176 * completer.c (gdb_print_filename): Constify.
14177 * corefile.c (set_gnutarget): Constify.
14178 * cp-name-parser.y (yyerror): Constify.
14179 * cp-valprint.c (cp_print_class_member): Constify.
14180 * cris-tdep.c (cris_register_name, crisv32_register_name):
14182 * d-exp.y (yyerror): Constify.
14183 (struct token::oper): Constify.
14184 * d-lang.h (d_yyerror): Constify.
14185 * dbxread.c (struct header_file_location::name): Constify.
14186 (add_old_header_file, add_new_header_file, last_function_name)
14187 (dbx_next_symbol_text, add_bincl_to_list)
14188 (find_corresponding_bincl_psymtab, set_namestring)
14189 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14190 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14191 * defs.h (command_line_input, print_address_symbolic)
14192 (deprecated_readline_begin_hook): Constify.
14193 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14195 * event-top.c (handle_line_of_input): Constify and add cast.
14196 * exceptions.c (catch_errors): Constify.
14197 * exceptions.h (catch_errors): Constify.
14198 * expprint.c (print_subexp_standard, op_string, op_name)
14199 (op_name_standard, dump_raw_expression, dump_raw_expression):
14200 * expression.h (op_name, op_string, dump_raw_expression):
14202 * f-exp.y (yyerror): Constify.
14203 (struct token::oper): Constify.
14204 (struct f77_boolean_val::name): Constify.
14205 * f-lang.c (f_word_break_characters): Constify.
14206 * f-lang.h (f_yyerror): Constify.
14207 * fork-child.c (fork_inferior): Add cast.
14208 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14209 (new_variant): Constify.
14210 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14211 * gdbarch.c: Regenerate.
14212 * gdbcore.h (set_gnutarget): Constify.
14213 * go-exp.y (yyerror): Constify.
14214 (token::oper): Constify.
14215 * go-lang.h (go_yyerror): Constify.
14216 * go32-nat.c (go32_sysinfo): Constify.
14217 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14218 * guile/scm-cmd.c (cmdscm_function): Constify.
14219 * guile/scm-param.c (pascm_param_value): Constify.
14220 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14221 (h8300sx_register_name): Constify.
14222 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14224 * ia64-tdep.c (ia64_register_names): Constify.
14225 * infcmd.c (construct_inferior_arguments): Constify.
14226 (path_command, attach_post_wait): Constify.
14227 * language.c (show_range_command, show_case_command)
14228 (unk_lang_error): Constify.
14229 * language.h (language_defn::la_error)
14230 (language_defn::la_name_of_this): Constify.
14231 * linespec.c (decode_line_2): Constify.
14232 * linux-thread-db.c (thread_db_err_str): Constify.
14233 * lm32-tdep.c (lm32_register_name): Constify.
14234 * m2-exp.y (yyerror): Constify.
14235 * m2-lang.h (m2_yyerror): Constify.
14236 * m32r-tdep.c (m32r_register_names): Constify and make static.
14237 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14238 * m88k-tdep.c (m88k_register_name): Constify.
14239 * macroexp.c (appendmem): Constify.
14240 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14241 (upgrade_type, parse_external, parse_partial_symbols)
14242 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14243 (new_symbol): Constify.
14244 * memattr.c (mem_info_command): Constify.
14245 * mep-tdep.c (register_name_from_keyword): Constify.
14246 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14248 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14249 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14250 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14252 (mi_execute_async_cli_command): Constify.
14253 * mips-tdep.c (mips_register_name): Constify.
14254 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14255 (am33_register_name, am33_2_register_name)
14256 * moxie-tdep.c (moxie_register_names): Constify.
14257 * nat/linux-osdata.c (osdata_type): Constify fields.
14258 * nto-tdep.c (nto_parse_redirection): Constify.
14259 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14260 (lookup_child_selector): Constify.
14261 (objc_methcall::name): Constify.
14262 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14263 (lookup_struct_typedef): Constify.
14264 * objfiles.c (pc_in_section): Constify.
14265 * objfiles.h (pc_in_section): Constify.
14266 * p-exp.y (struct token::oper): Constify.
14267 (yyerror): Constify.
14268 * p-lang.h (pascal_yyerror): Constify.
14269 * parser-defs.h (op_name_standard): Constify.
14270 (op_print::string): Constify.
14271 (exp_descriptor::op_name): Constify.
14272 * printcmd.c (print_address_symbolic): Constify.
14273 * psymtab.c (print_partial_symbols): Constify.
14274 * python/py-breakpoint.c (stop_func): Constify.
14275 (bppy_get_expression): Constify.
14276 * python/py-cmd.c (cmdpy_completer::name): Constify.
14277 (cmdpy_function): Constify.
14278 * python/py-event.c (evpy_add_attribute)
14279 (gdbpy_initialize_event_generic): Constify.
14280 * python/py-event.h (evpy_add_attribute)
14281 (gdbpy_initialize_event_generic): Constify.
14282 * python/py-evts.c (add_new_registry): Constify.
14283 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14284 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14285 * python/py-inferior.c (get_buffer): Add cast.
14286 * python/py-param.c (parm_constant::name): Constify.
14287 * python/py-unwind.c (fprint_frame_id): Constify.
14288 * python/python.c (gdbpy_parameter_value): Constify.
14289 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14290 * remote.c (memory_packet_config::name): Constify.
14291 (show_packet_config_cmd, remote_write_bytes)
14292 (remote_buffer_add_string):
14293 * reverse.c (exec_reverse_once): Constify.
14294 * rs6000-tdep.c (variant::name, variant::description): Constify.
14295 * rust-exp.y (rustyyerror): Constify.
14296 * rust-lang.c (rust_op_name): Constify.
14297 * rust-lang.h (rustyyerror): Constify.
14298 * serial.h (serial_ops::name): Constify.
14299 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14300 (sh_sh3e_register_name, sh_sh2e_register_name)
14301 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14302 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14303 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14304 (sh_sh4al_dsp_register_name): Constify.
14305 * sh64-tdep.c (sh64_register_name): Constify.
14306 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14307 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14308 * stabsread.c (patch_block_stabs, read_type_number)
14309 (ref_map::stabs, ref_add, process_reference)
14310 (symbol_reference_defined, define_symbol, define_symbol)
14311 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14312 (read_one_struct_field, read_struct_fields, read_baseclasses)
14313 (read_tilde_fields, read_struct_type, read_array_type)
14314 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14315 (read_huge_number, read_range_type, read_args, common_block_start)
14316 (find_name_end): Constify.
14317 * stabsread.h (common_block_start, define_symbol)
14318 (process_one_symbol, symbol_reference_defined, ref_add):
14319 * symfile.c (get_section_index, add_symbol_file_command):
14320 * symfile.h (get_section_index): Constify.
14321 * target-descriptions.c (tdesc_type::name): Constify.
14322 (tdesc_free_type): Add cast.
14323 * target.c (find_default_run_target):
14324 (add_deprecated_target_alias, find_default_run_target)
14325 (target_announce_detach): Constify.
14326 (do_option): Constify.
14327 * target.h (add_deprecated_target_alias): Constify.
14328 * thread.c (print_thread_info_1): Constify.
14329 * top.c (deprecated_readline_begin_hook, command_line_input):
14331 (init_main): Add casts.
14332 * top.h (handle_line_of_input): Constify.
14333 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14334 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14335 (tfind_command): Rename to ...
14336 (tfind_command_1): ... this and constify.
14337 (tfind_command): New function.
14338 (tfind_end_command, tfind_start_command): Adjust.
14339 (encode_source_string): Constify.
14340 * tracepoint.h (encode_source_string): Constify.
14341 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14342 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14343 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14344 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14345 * tui/tui-win.c (parse_scrolling_args): Constify.
14346 * tui/tui-windata.c (tui_erase_data_content): Constify.
14347 * tui/tui-windata.h (tui_erase_data_content): Constify.
14348 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14349 * tui/tui.c (tui_enable): Add cast.
14350 * utils.c (defaulted_query): Constify.
14351 (init_page_info): Add cast.
14352 (puts_debug, subset_compare): Constify.
14353 * utils.h (subset_compare): Constify.
14354 * varobj.c (varobj_format_string): Constify.
14355 * varobj.h (varobj_format_string): Constify.
14356 * vax-tdep.c (vax_register_name): Constify.
14357 * windows-nat.c (windows_detach): Constify.
14358 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14359 * xml-support.c (gdb_xml_end_element): Constify.
14360 * xml-tdesc.c (tdesc_start_reg): Constify.
14361 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14362 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14363 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14365 2017-04-05 Pedro Alves <palves@redhat.com>
14367 * proc-api.c (struct trans): Constify.
14368 (procfs_note): Constify.
14369 * proc-events.c (struct trans, syscall_table):
14370 * proc-flags.c (struct trans): Constify.
14371 * proc-utils.h (procfs_note): Constify.
14372 * proc-why.c (struct trans): Constify.
14373 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14374 (procfs_detach): Constify.
14375 * sol-thread.c (struct string_map): Constify.
14376 (td_err_string, td_state_string): Constify.
14378 2017-04-05 Pedro Alves <palves@redhat.com>
14380 * proc-api.c (procfs_filename): Don't initialize
14382 (prepare_to_trace): Assume procfs_filename is non-NULL.
14383 (_initialize_proc_api): Give procfs_filename a default value here.
14385 2017-04-05 Pedro Alves <palves@redhat.com>
14387 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14388 'cond_string' parameter.
14389 (extract_exception_regexp): Constify 'string' parameter.
14390 (catch_exception_command_1): Constify.
14391 * breakpoint.c (init_catchpoint)
14392 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14394 (ep_parse_optional_if_clause, catch_fork_command_1)
14395 (catch_exec_command_1): Constify.
14396 * breakpoint.h (init_catchpoint): Constify 'cond_string'
14398 (ep_parse_optional_if_clause): Constify.
14399 * cli/cli-utils.c (remove_trailing_whitespace)
14400 (check_for_argument): Constify.
14401 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
14402 non-const overload.
14403 (check_for_argument): Likewise.
14405 2017-04-05 Pedro Alves <palves@redhat.com>
14407 * event-top.c (command_line_handler): Add cast to execute_command
14409 * record-btrace.c (cmd_record_btrace_bts_start)
14410 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
14411 (cmd_record_btrace_start): Add cast to execute_command call.
14412 * record-full.c (record_full_goto_insn):
14413 * record.c (record_start, record_stop): Add cast to
14414 execute_command_to_string calls.
14415 (cmd_record_start): Add cast to execute_command calls.
14417 2017-04-05 Pedro Alves <palves@redhat.com>
14419 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
14420 static inline function.
14421 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
14422 array and use gdb_PyArg_ParseTupleAndKeywords.
14423 * python/py-cmd.c (cmdpy_init): Likewise.
14424 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
14425 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
14426 (infpy_search_memory): Likewise.
14427 * python/py-objfile.c (objfpy_add_separate_debug_file)
14428 (gdbpy_lookup_objfile): Likewise.
14429 * python/py-symbol.c (gdbpy_lookup_symbol)
14430 (gdbpy_lookup_global_symbol): Likewise.
14431 * python/py-type.c (gdbpy_lookup_type): Likewise.
14432 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
14433 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
14436 2017-04-05 Pedro Alves <palves@redhat.com>
14438 * python/python-internal.h (gdb_PyGetSetDef): New type.
14439 * python/py-block.c (block_object_getset)
14440 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
14441 * python/py-event.c (event_object_getset)
14442 (finish_breakpoint_object_getset): Likewise.
14443 * python/py-inferior.c (inferior_object_getset): Likewise.
14444 * python/py-infthread.c (thread_object_getset): Likewise.
14445 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
14446 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
14447 * python/py-objfile.c (objfile_getset): Likewise.
14448 * python/py-progspace.c (pspace_getset): Likewise.
14449 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
14451 * python/py-record.c (recpy_record_getset): Likewise.
14452 * python/py-symbol.c (symbol_object_getset): Likewise.
14453 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
14455 * python/py-type.c (type_object_getset, field_object_getset):
14457 * python/py-value.c (value_object_getset): Likewise.
14459 2017-04-05 Pedro Alves <palves@redhat.com>
14461 * python/python-internal.h (gdb_PyObject_CallMethod)
14462 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
14464 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
14465 (PySys_GetObject, PySys_SetPath): New macros.
14467 2017-04-05 Pedro Alves <palves@redhat.com>
14469 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
14470 info_osdata_command.
14471 * osdata.c (info_osdata_command): Rename to ...
14472 (info_osdata): ... this. Constify 'type' parameter, and remove
14473 the 'from_tty' parameter. Accept NULL TYPE.
14474 (info_osdata_command): New function.
14475 * osdata.h (info_osdata_command): Remove declaration.
14476 (info_osdata): New declaration.
14478 2017-04-05 Pedro Alves <palves@redhat.com>
14480 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
14481 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
14482 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
14484 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
14485 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
14486 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
14488 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
14489 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
14490 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
14491 (mi_cmd_file_list_exec_source_files)
14492 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
14493 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
14494 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
14496 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
14497 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
14498 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
14499 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
14500 (mi_cmd_stack_info_frame): Constify 'command' parameter.
14501 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
14502 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
14503 'command' parameter.
14504 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
14505 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
14506 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
14507 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
14508 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
14509 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
14510 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
14511 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
14512 (mi_cmd_var_set_update_range): Constify 'command' parameter.
14513 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
14514 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
14516 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
14517 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
14518 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
14519 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
14520 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
14521 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
14522 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
14523 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
14524 (mi_cmd_data_list_changed_registers)
14525 (mi_cmd_data_write_register_values)
14526 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
14527 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
14528 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
14529 (mi_cmd_list_features, mi_cmd_list_target_features)
14530 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
14531 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
14532 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
14533 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
14534 (mi_cmd_trace_frame_collected): Constify 'command'
14536 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
14537 'command' parameter.
14539 2017-04-05 Pedro Alves <palves@redhat.com>
14541 * ada-lang.c (ada_completer_word_break_characters): Now a const
14543 (ada_get_gdb_completer_word_break_characters): Constify.
14544 * completer.c (gdb_completer_command_word_break_characters)
14545 (gdb_completer_file_name_break_characters)
14546 (gdb_completer_quote_characters): Now const arrays.
14547 (get_gdb_completer_quote_characters): Constify.
14548 (set_rl_completer_word_break_characters): New function.
14549 (set_gdb_completion_word_break_characters)
14550 (complete_line_internal): Use it.
14551 * completer.h (get_gdb_completer_quote_characters): Constify.
14552 (set_rl_completer_word_break_characters): Declare.
14553 * f-lang.c (f_word_break_characters): Constify.
14554 * language.c (default_word_break_characters): Constify.
14555 * language.h (language_defn::la_word_break_characters): Constify.
14556 (default_word_break_characters): Constify.
14557 * top.c (init_main): Use set_rl_completer_word_break_characters.
14559 2017-04-05 Pedro Alves <palves@redhat.com>
14561 * aix-thread.c (aix_thread_pid_to_str)
14562 (aix_thread_extra_thread_info): Constify.
14563 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
14564 * bsd-uthread.c (bsd_uthread_extra_thread_info)
14565 (bsd_uthread_pid_to_str): Constify.
14566 * corelow.c (core_pid_to_str): Constify.
14567 * darwin-nat.c (darwin_pid_to_str): Constify.
14568 * fbsd-nat.c (fbsd_pid_to_str): Constify.
14569 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
14571 * gnu-nat.c (gnu_pid_to_str): Constify.
14572 * go32-nat.c (go32_pid_to_str): Constify.
14573 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
14574 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
14575 * inferior.c (inferior_pid_to_str): Constify.
14576 * linux-nat.c (linux_nat_pid_to_str): Constify.
14577 * linux-tdep.c (linux_core_pid_to_str): Constify.
14578 * linux-thread-db.c (thread_db_pid_to_str)
14579 (thread_db_extra_thread_info): Constify.
14580 * nto-tdep.c (nto_extra_thread_info): Constify.
14581 * nto-tdep.h (nto_extra_thread_info): Constify.
14582 * obsd-nat.c (obsd_pid_to_str): Constify.
14583 * procfs.c (procfs_pid_to_str): Constify.
14584 * ravenscar-thread.c (ravenscar_extra_thread_info)
14585 (ravenscar_pid_to_str): Constify.
14586 * remote-sim.c (gdbsim_pid_to_str): Constify.
14587 * remote.c (remote_threads_extra_info, remote_pid_to_str):
14589 * sol-thread.c (solaris_pid_to_str): Constify.
14590 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
14591 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
14592 * target.c (default_pid_to_str, target_pid_to_str)
14593 (normal_pid_to_str, default_pid_to_str): Constify.
14594 * target.h (target_ops::to_pid_to_str)
14595 (target_ops::to_extra_thread_info): Constify.
14596 (target_pid_to_str, normal_pid_to_str): Constify.
14597 * windows-nat.c (windows_pid_to_str): Constify.
14598 * gdbarch.sh (core_pid_to_str): Constify.
14599 * target-delegates.c: Regenerate.
14600 * gdbarch.h, gdbarch.c: Regenerate.
14602 2017-04-05 Pedro Alves <palves@redhat.com>
14604 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
14605 the memory of the temporary warning_pre_print override.
14606 * utils.c (warning_pre_print): Constify.
14607 * utils.h (warning_pre_print): Constify.
14609 2017-04-05 Pedro Alves <palves@redhat.com>
14611 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
14612 (shell_command): New function.
14613 (make_command): Use std::string.
14614 (init_cli_cmds): Register shell_command instead of shell_escape.
14616 2017-04-05 Pedro Alves <palves@redhat.com>
14618 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
14619 * tracepoint.c (default_collect): Don't initialize.
14621 2017-04-05 Pedro Alves <palves@redhat.com>
14623 * macroexp.c (macro_buffer::shared): Now a bool.
14624 (init_buffer): Update.
14625 (init_shared_buffer): Constify 'addr' parameter.
14626 (substitute_args, expand, macro_expand, macro_expand_next): Remove
14629 2017-04-05 Pedro Alves <palves@redhat.com>
14631 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
14632 * disasm.c (set_disassembler_options): Constify local.
14633 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
14635 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
14638 * tracefile.c (tsave_command): Fix argument parsing for '-r'
14641 2017-04-05 Yao Qi <yao.qi@linaro.org>
14643 * frame.c (frame_unwind_register_unsigned): Call
14644 frame_unwind_register_value.
14646 2017-04-05 Yao Qi <yao.qi@linaro.org>
14648 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
14649 Use gdb_test_multiple, and don't match anchor.
14651 2017-04-05 Pedro Alves <palves@redhat.com>
14653 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
14654 (Write After Approval): Remove Simon Marchi.
14656 2017-04-05 Pedro Alves <palves@redhat.com>
14658 * common/gdb_optional.h (optional::optional): Make constexpr and
14659 initialize m_dummy.
14661 2017-04-04 John Baldwin <jhb@FreeBSD.org>
14663 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14664 (amd64fbsd_jmp_buf_reg_offset): Remove.
14665 (amd64fbsd_supply_uthread): Remove function.
14666 (amd64fbsd_collect_uthread): Remove function.
14667 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
14668 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
14669 (x86_64-*-freebsd*): Remove bsd-uthread.o.
14670 (fbsd-nat.c): Update comment.
14671 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14672 (i386fbsd_jmp_buf_reg_offset): Remove.
14673 (i386fbsd_supply_uthread): Remove function.
14674 (i386fbsd_collect_uthread): Remove function.
14675 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
14677 2017-04-04 John Baldwin <jhb@FreeBSD.org>
14679 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
14680 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
14681 * NEWS: Mention that support for FreeBSD/alpha was removed.
14682 * alpha-fbsd-tdep.c: Delete file.
14683 * config/alpha/fbsd.mh: Delete file.
14684 * configure.host: Delete alpha*-*-freebsd* and
14685 alpha*-*-kfreebsd*-gnu.
14686 * configure.tgt: Delete alpha*-*-freebsd* and
14687 alpha*-*-kfreebsd*-gnu.
14689 2017-04-04 John Baldwin <jhb@FreeBSD.org>
14691 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
14692 amd64bsd_store_inferior_registers): Use ptid from regcache.
14694 2017-04-04 Pedro Alves <palves@redhat.com>
14696 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
14697 data fields, make them private and add "m_" prefixes.
14698 (lnp_state_machine::lnp_state_machine): New ctor.
14699 (record_line, check_line_address, handle_set_discriminator)
14700 (handle_set_address, handle_advance_pc, handle_special_opcode)
14701 (handle_advance_line, handle_set_file, handle_negate_stmt)
14702 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
14703 (end_sequence, advance_line): New methods.
14704 (m_gdbarch, m_record_lines_p): New fields.
14705 (lnp_reader_state): Delete.
14706 (dwarf_record_line): Rename to ...
14707 (lnp_state_machine::record_line): ... adjust.
14708 (init_lnp_state_machine): Delete.
14709 (lnp_state_machine::lnp_state_machine): New.
14710 (check_line_address): Rename to ...
14711 (lnp_state_machine::check_line_address): This.
14712 (dwarf_decode_lines_1): Remove reference to "reader_state".
14713 Adjust lnp_state_machine having a non-default ctor. Use bool.
14714 State machine internal state manipulation moved to
14715 lnp_state_machine methods.
14717 2017-04-04 Pedro Alves <palves@redhat.com>
14719 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14720 unittests/offset-type-selftests.c.
14721 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
14722 * common/offset-type.h: New file.
14723 * common/preprocessor.h: New file.
14724 * common/traits.h: New file.
14725 * common/valid-expr.h: New file.
14726 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
14727 sect_offset and cu_offset strong typedefs throughout.
14728 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
14729 typedefs throughout.
14730 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
14731 sect_offset and cu_offset strong typedefs throughout.
14732 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
14733 typedefs throughout.
14734 * gdbtypes.h: Include "common/offset-type.h".
14735 (cu_offset): Now an offset type (strong typedef) instead of a
14737 (sect_offset): Likewise.
14738 (union call_site_parameter_u): Rename "param_offset" field to
14740 * unittests/offset-type-selftests.c: New file.
14742 2017-04-04 Pedro Alves <palves@redhat.com>
14744 * common/underlying.h: New file.
14745 * dwarf2read.c: Include "common/gdb_optional.h" and
14746 "common/underlying.h".
14747 (dir_index, file_name_index): New types.
14748 (file_entry): Use them.
14749 (file_entry::include): Use to_underlying.
14750 (line_header::add_file_name): Use dir_index.
14751 (read_formatted_entries): Use gdb::optional. Read form before
14752 writting to file_entry.
14753 (dwarf_decode_line_header): Use dir_index.
14754 (lnp_state_machine::current_file): Use to_underlying.
14755 (lnp_state_machine::file): Change type to file_name_index.
14756 (dwarf_record_line): Use to_underlying.
14757 (init_lnp_state_machine): Use file_name_index.
14758 (dwarf_decode_lines_1): Use dir_index and file_name_index.
14760 2017-04-04 Pedro Alves <palves@redhat.com>
14762 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
14763 operator bool, has_value and get methods.
14765 2017-04-04 Pedro Alves <palves@redhat.com>
14767 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
14769 (line_header): Initialize all data fields. Change type of
14770 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
14771 Change type of include_dirs to std::vector<const char *>. Remove
14772 num_include_dirs, include_dirs_size. Change type of file_names to
14773 std::vector<file_entry>. Remove num_file_names, file_names_size.
14774 (line_header::line_header): New.
14775 (line_header::add_include_dir, line_header::add_file_name): New
14777 (line_header::include_dir_at): Remove NULL check.
14778 (line_header::file_name_at): Add const overload.
14779 (line_header_up): New unique_ptr typedef.
14780 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
14781 std::vector. Remove free_line_header call.
14782 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
14783 free_line_header call.
14784 (free_cu_line_header): Delete.
14785 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
14786 (setup_type_unit_groups): Use line_header_up instead of cleanups.
14787 Adjust to use std::vector.
14788 (free_line_header): Delete.
14789 (free_line_header_voidp): Use delete.
14790 (add_include_dir): Replace with ...
14791 (line_header::add_include_dir): ... this method. Use std::vector.
14792 (add_file_name): Replace with ...
14793 (line_header::add_file_name): ... this method. Use std::vector.
14794 (add_include_dir_stub): Delete.
14795 (read_formatted_entries): Remove memset.
14796 (dwarf_decode_line_header): Return a line_header_up instead of a
14797 raw pointer. Remove cleanup handling. Pass lambdas to
14798 read_formatted_entries. Adjust to use line_header methods.
14799 (dwarf_decode_lines_1): Adjust to use line_header methods.
14800 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
14803 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
14805 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
14806 instead of struct ptid.
14808 2017-05-04 Alan Hayward <alan.hayward@arm.com>
14810 * frame.c (get_frame_register_bytes): Unwind using value.
14811 (put_frame_register_bytes): Likewise.
14813 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
14815 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
14818 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
14820 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
14822 2017-03-29 Yao Qi <yao.qi@linaro.org>
14824 * gdbthread.h (struct thread_info): Declare constructor and
14825 destructor. Add some in-class member initializers.
14826 * thread.c (free_thread): Remove.
14827 (init_thread_list): Call delete instead of free_thread.
14828 (new_thread): Call thread_info constructor.
14829 (thread_info::thread_info): New function.
14830 (thread_info::~thread_info): New function.
14831 (delete_thread_1): Call delete instead of free_thread.
14832 (make_cleanup_restore_current_thread): Move tp and frame to
14835 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14837 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
14838 (arc_skip_prologue): Likewise.
14839 (arc_make_frame_cache): Likewise.
14840 (arc_pv_get_operand): New function.
14841 (arc_is_in_prologue): Likewise.
14842 (arc_analyze_prologue): Likewise.
14843 (arc_print_frame_cache): Likewise.
14844 (MAX_PROLOGUE_LENGTH): New constant.
14846 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14848 * configure.tgt: Add arc-insn.o.
14849 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
14850 (dump_arc_instruction_command): New function.
14851 (arc_fprintf_disasm): Likewise.
14852 (arc_disassemble_info): Likewise.
14853 (arc_insn_get_operand_value): Likewise.
14854 (arc_insn_get_operand_value_signed): Likewise.
14855 (arc_insn_get_memory_base_reg): Likewise.
14856 (arc_insn_get_memory_offset): Likewise.
14857 (arc_insn_get_branch_target): Likewise.
14858 (arc_insn_dump): Likewise.
14859 (arc_insn_get_linear_next_pc): Likewise.
14860 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
14861 (arc_disassemble_info): Likewise.
14862 (arc_insn_get_branch_target): Likewise.
14863 (arc_insn_get_linear_next_pc): Likewise.
14864 * NEWS: Mention new "maint print arc arc-instruction".
14866 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14868 * arc-tdep (maintenance_print_arc_list): New variable.
14869 (maintenance_print_arc_command): New function.
14871 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14873 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
14874 Add "limm" and "reserved".
14875 (arc_cannot_fetch_register, arc_cannot_store_register): Add
14876 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
14877 * arc-tdep.h (arc_regnum): Likewise.
14879 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14881 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14882 for THREADPTR register.
14883 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
14885 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
14886 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
14887 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
14889 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14891 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
14892 registers above gdbarch_num_regs (gdbarch) as privileged in
14895 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14897 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14898 for a single specified register or for all registers in
14899 a0_base..a0_base + C0_NREGS range.
14900 (supply_gregset_reg): Call regcache_raw_supply for a single
14901 specified register or for all registers in a0_base..a0_base +
14904 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14906 * arch/xtensa.h (C0_NREGS): Add definition.
14907 * xtensa-tdep.c (C0_NREGS): Remove definition.
14909 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14911 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
14912 Drop xtensa_default_isa initialization.
14913 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
14915 2017-03-27 Pedro Alves <palves@redhat.com>
14917 * dwarf2read.c (file_entry) <dir_index>: Add comment.
14918 (file_entry::include_dir): New method.
14919 (line_header::include_dir_at, line_header::file_name_at): New
14921 (setup_type_unit_groups, setup_type_unit_groups)
14922 (psymtab_include_file_name): Simplify using the new methods.
14923 (lnp_state_machine) <the_line_header>: New field.
14924 <file>: Add comment.
14925 (lnp_state_machine::current_file): New method.
14926 (dwarf_record_line): Simplify using the new methods.
14927 (init_lnp_state_machine): Initialize the "the_line_header" field.
14928 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
14929 Simplify using the new methods.
14931 2017-03-27 Pedro Alves <palves@redhat.com>
14933 * cp-name-parser.y (make_empty): Delete.
14934 (demangler_special, nested_name, ptr_operator, array_indicator)
14935 (direct_declarator, declarator_1): Use fill_comp instead of
14938 2017-03-27 Pedro Alves <palves@redhat.com>
14940 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
14941 to ATTRIBUTE_PRINTF.
14942 * solib-target.c (library_list_start_list): Print "string" not
14944 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
14945 gdb_xml_error call.
14947 2017-03-27 Pedro Alves <palves@redhat.com>
14949 * dwarf2read.c (struct file_and_directory): New.
14950 (dwarf2_get_dwz_file): Adjust to use std::string.
14951 (dw2_get_file_names_reader): Adjust to use file_and_directory.
14952 (find_file_and_directory): Adjust to return a file_and_directory
14954 (read_file_scope): Adjust to use file_and_directory. Remove
14955 make_cleanup/do_cleanups calls.
14956 (open_and_init_dwp_file): Adjust to use std::string. Remove
14957 make_cleanup/do_cleanups calls.
14958 * python/python.c (do_start_initialization): Adjust to ldirname
14959 returning a std::string.
14960 * utils.c (ldirname): Now returns a std::string.
14961 * utils.h (ldirname): Change return type to std::string.
14962 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
14963 returning a std::string.
14964 * xml-tdesc.c (file_read_description_xml): Likewise.
14966 2017-03-24 Alan Hayward <alan.hayward@arm.com>
14968 * regcache.c (regcache_debug_print_register): New function.
14969 * regcache.h (regcache_debug_print_register): New declaration.
14970 * target.c (debug_print_register): Remove.
14971 (target_fetch_registers): Call regcache_debug_print_register.
14972 (target_store_registers): Likewise.
14974 2017-03-24 Pádraig Brady <pbrady@fb.com>
14976 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
14977 reference beyond the 'lh->include_dirs' array before accessing to
14979 (psymtab_include_file_name): Likewise.
14980 (dwarf_decode_lines_1): Likewise.
14981 (dwarf_decode_lines): Likewise.
14982 (file_file_name): Likewise.
14984 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
14986 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
14988 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14989 ps_lsetfpregs): Likewise.
14990 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
14991 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14992 ps_lsetfpregs): Likewise.
14993 * target.c (target_fetch_registers, target_store_registers):
14996 2017-03-23 Alan Hayward <alan.hayward@arm.com>
14998 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
15000 2017-03-23 Yao Qi <yao.qi@linaro.org>
15002 * aarch64-tdep.c (aarch64_process_record_test): Declare.
15003 (_initialize_aarch64_tdep): Register it.
15004 (aarch64_record_load_store): Handle PRFM instruction.
15005 (aarch64_process_record_test): New function.
15007 2017-03-23 Yao Qi <yao.qi@linaro.org>
15009 * aarch64-tdep.c (aarch64_record_load_store): Fix code
15012 2017-03-23 Yao Qi <yao.qi@linaro.org>
15014 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
15016 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15018 python/python.c (do_start_initialization): Fix memory leak.
15020 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
15022 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
15023 using get_ptrace_pid.
15024 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
15026 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
15027 inferior_ptid instead of pid.
15029 2017-03-22 Yao Qi <yao.qi@linaro.org>
15031 * aarch64-tdep.c: Wrap locally used classes in anonymous
15033 * arm-tdep.c: Likewise.
15034 * linespec.c: Likewise.
15035 * ui-out.c: Likewise.
15037 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
15040 * python/lib/gdb/printer/bound_registers.py: Import sys.
15042 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15044 * windows-nat.c (do_windows_fetch_inferior_registers): Add
15045 windows_thread_info parameter and use it instead of
15047 (windows_fetch_inferior_registers): Don't set current_thread,
15048 pass the thread to do_windows_fetch_inferior_registers. Use
15049 ptid from regcache instead of inferior_ptid.
15050 (do_windows_store_inferior_registers): Add windows_thread_info
15051 parameter and use it instead of current_thread.
15052 (windows_store_inferior_registers): Don't set current_thread,
15053 pass the thread to do_windows_store_inferior_registers. Use
15054 ptid from regcache instead of inferior_ptid.
15056 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15058 * ser-mingw.c (ser_windows_raw): Remove reference to
15059 struct serial::current_timeout.
15061 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15064 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15065 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15066 (sparc64_fsr_type): Fix %fsr decoding.
15068 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15070 * python/py-record-btrace.c (btpy_insn_data): Change return type
15073 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15075 * spu-linux-nat.c (spu_fetch_inferior_registers,
15076 spu_store_inferior_registers): Use ptid from regcache, set and
15077 restore inferior_ptid.
15078 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15081 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15083 * i386-linux-nat.c (fetch_register, store_register,
15084 i386_linux_fetch_inferior_registers,
15085 i386_linux_store_inferior_registers): Use ptid from regcache.
15086 * ia64-linux-nat.c (ia64_linux_fetch_register,
15087 ia64_linux_store_register): Likewise.
15088 * inf-ptrace.c (inf_ptrace_fetch_register,
15089 inf_ptrace_store_register): Likewise.
15090 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15091 m32r_linux_store_inferior_registers): Likewise.
15092 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15093 m68kbsd_store_inferior_registers): Likewise.
15094 * m68k-linux-nat.c (fetch_register, store_register,
15095 m68k_linux_fetch_inferior_registers,
15096 m68k_linux_store_inferior_registers): Likewise.
15097 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15098 m88kbsd_store_inferior_registers): Likewise.
15099 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15100 mips_fbsd_store_inferior_registers): Likewise.
15101 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15102 mips64_linux_regsets_store_registers): Likewise.
15103 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15104 mipsnbsd_store_inferior_registers): Likewise.
15105 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15106 mips64obsd_store_inferior_registers): Likewise.
15107 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15109 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15110 ppcfbsd_store_inferior_registers): Likewise.
15111 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15112 ppc_linux_store_inferior_registers): Likewise.
15113 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15114 ppcnbsd_store_inferior_registers): Likewise.
15115 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15116 ppcobsd_store_registers): Likewise.
15117 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15119 * ravenscar-thread.c (ravenscar_fetch_registers,
15120 ravenscar_store_registers, ravenscar_prepare_to_store):
15122 * record-btrace.c (record_btrace_fetch_registers,
15123 record_btrace_store_registers, record_btrace_prepare_to_store):
15125 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15126 Lookup inferior using ptid from regcache, instead of
15128 * remote.c (remote_fetch_registers, remote_store_registers): Use
15129 ptid from regcache.
15130 * rs6000-nat.c (fetch_register, store_register): Likewise.
15131 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15132 s390_linux_store_inferior_registers): Likewise.
15133 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15134 shnbsd_store_inferior_registers): Likewise.
15135 * sol-thread.c (sol_thread_fetch_registers,
15136 sol_thread_store_registers): Likewise.
15137 * sparc-nat.c (sparc_fetch_inferior_registers,
15138 sparc_store_inferior_registers): Likewise.
15139 * tilegx-linux-nat.c (fetch_inferior_registers,
15140 store_inferior_registers): Likewise.
15141 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15142 vaxbsd_store_inferior_registers): Likewise.
15143 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15144 store_xtregs): Likewise.
15146 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15149 * NEWS: Mention support for rvalue references in GDB and python.
15150 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15151 supports both lvalue and rvalue references.
15153 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15156 * gdbtypes.c (rank_one_type): Implement overloading
15157 resolution rules regarding rvalue references.
15159 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15162 * aarch64-tdep.c (aarch64_type_align)
15163 (aarch64_extract_return_value, aarch64_store_return_value): Change
15164 lvalue reference type checks to general reference type checks.
15165 * amd64-tdep.c (amd64_classify): Likewise.
15166 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15168 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15169 (arm_store_return_value): Likewise.
15170 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15171 * c-typeprint.c (c_print_type): Likewise.
15172 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15173 (cplus_number_of_children, cplus_describe_child): Likewise.
15174 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15175 * completer.c (expression_completer): Likewise.
15176 * cp-support.c (make_symbol_overload_list_adl_namespace):
15178 * darwin-nat-info.c (info_mach_region_command): Likewise.
15179 * dwarf2loc.c (entry_data_value_coerce_ref)
15180 (value_of_dwarf_reg_entry): Likewise.
15181 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15182 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15184 * findvar.c (extract_typed_address, store_typed_address):
15186 * gdbtypes.c (rank_one_type): Likewise.
15187 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15188 * infcall.c (value_arg_coerce): Likewise.
15189 * language.c (pointer_type): Likewise.
15190 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15192 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15193 * mn10300-tdep.c (mn10300_type_align): Likewise.
15194 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15195 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15196 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15198 * printcmd.c (print_formatted, x_command): Likewise.
15199 * python/py-type.c (typy_get_composite, typy_template_argument):
15201 * python/py-value.c (valpy_referenced_value)
15202 (valpy_get_dynamic_type, value_has_field): Likewise.
15203 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15204 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15205 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15206 * spu-tdep.c (spu_scalar_value_p): Likewise.
15207 * symtab.c (lookup_symbol_aux): Likewise.
15208 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15209 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15211 * valops.c (value_cast_pointers, value_cast)
15212 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15213 (value_struct_elt, value_struct_elt_bitpos)
15214 (value_find_oload_method_list, find_overload_match)
15215 (value_rtti_indirect_type): Likewise.
15216 * valprint.c (val_print_scalar_type_p, generic_val_print):
15218 * value.c (value_actual_type, value_as_address, unpack_long)
15219 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15220 (coerce_ref): Likewise.
15221 * varobj.c (varobj_get_value_type): Likewise.
15223 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15226 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15227 table of constants.
15228 * python/lib/gdb/command/explore.py: Support exploring values
15229 of rvalue reference types.
15230 * python/lib/gdb/types.py: Implement get_basic_type() for
15231 rvalue reference types.
15232 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15234 * python/py-value.c (valpy_getitem): Add an rvalue reference
15236 (valpy_reference_value): Add new parameter "refcode".
15237 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15238 New wrappers for valpy_reference_value().
15239 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15240 (gdbpy_invoke_xmethod): Likewise.
15242 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15245 * dwarf2read.c (process_die, read_type_die_1): Handle the
15246 DW_TAG_rvalue_reference_type DIE.
15247 (read_tag_reference_type): Add new parameter "refcode".
15249 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15252 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15253 (c_type_print_modifier, c_type_print_varspec_suffix)
15254 (c_type_print_base): Support printing rvalue reference types.
15255 * c-valprint.c (c_val_print, c_value_print): Support printing
15256 rvalue reference values.
15258 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15261 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15263 * cp-support.c (replace_typedefs): Handle
15264 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15265 * python/py-type.c (typy_lookup_type): Likewise.
15267 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15270 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15271 * parse.c (insert_type): Change assert statement.
15272 (follow_types): Handle rvalue reference types.
15273 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15276 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15279 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15280 value_ref() interface.
15281 * c-valprint.c (c_value_print): Likewise.
15282 * infcall.c (value_arg_coerce): Likewise.
15283 * python/py-value.c (valpy_reference_value): Likewise.
15284 * valops.c (value_cast, value_reinterpret_cast)
15285 (value_dynamic_cast, typecmp): Likewise.
15286 (value_ref): Parameterize by kind of return value reference type.
15287 * value.h (value_ref): Add new parameter "refcode".
15289 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15292 * dwarf2read.c (read_tag_reference_type): Use
15293 lookup_lvalue_reference_type() instead of lookup_reference_type().
15294 * eval.c (evaluate_subexp_standard): Likewise.
15295 * f-exp.y: Likewise.
15296 * gdbtypes.c (make_reference_type, lookup_reference_type):
15297 Generalize with rvalue reference types.
15298 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15299 convenience wrappers for lookup_reference_type().
15300 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15301 reference kind parameter.
15302 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15303 wrappers for lookup_reference_type().
15304 * guile/scm-type.c (gdbscm_type_reference): Use
15305 lookup_lvalue_reference_type() instead of lookup_reference_type().
15306 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15307 * parse.c (follow_types): Likewise.
15308 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15309 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15311 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15312 (gdbpy_invoke_xmethod): Likewise.
15313 * stabsread.c: Provide extra argument to make_reference_type()
15315 * valops.c (value_ref, value_rtti_indirect_type): Use
15316 lookup_lvalue_reference_type() instead of lookup_reference_type().
15318 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15321 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15322 (TYPE_IS_REFERENCE): New macro.
15323 (struct type): Add rvalue_reference_type field.
15324 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15326 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15328 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15329 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15330 New function definition.
15331 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15332 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15333 New function declaration.
15334 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15335 * mi/mi-interp.h: New file.
15336 * solib.c (info_sharedlibrary_command): Replace for loop with
15338 * solib.h (update_solib_list): New function declaration.
15339 (so_list_head): Move macro.
15340 * solist.h (ALL_SO_LIBS): New macro.
15342 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15344 * infcmd.c (post_create_inferior): Remove unused argument in
15346 * remote.c (remote_start_remote): Likewise.
15347 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15348 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15349 (enable_break): Likewise.
15350 * solib.c (update_solib_list): Remove unused target argument
15351 and its documentation.
15352 (solib_add): Remove unused target argument. Remove unused
15353 argument in call to update_solib_list.
15354 (info_sharedlibrary_command): Remove unused argument in call
15355 to update_solib_list.
15356 (sharedlibrary_command): Remove unused argument in call to
15358 (handle_solib_event): Likewise.
15359 (reload_shared_libraries): Likewise.
15360 * solib.h (solib_add): Remove unused target argument.
15362 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15364 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15365 (s390_displaced_step_fixup): Cover relative branches with the
15366 default fixup handling. This fixes lack of support for some
15367 relative branch instructions.
15369 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15371 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15372 ptid from regcache.
15374 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15376 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15377 i386_darwin_store_inferior_registers): Use ptid from regcache.
15379 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15381 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15382 i386bsd_store_inferior_registers): Use ptid from regcache.
15384 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15386 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15387 hppaobsd_store_registers): Use ptid from regcache.
15389 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15391 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15392 hppanbsd_store_registers): Use ptid from regcache.
15394 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15396 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
15397 from regcache. Use get_ptrace_pid.
15399 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15401 * corelow.c (get_core_register_section): Use ptid from regcache,
15404 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15406 * bsd-uthread.c (bsd_uthread_fetch_registers,
15407 bsd_uthread_store_registers): Use ptid from regcache, set and
15408 restore inferior_ptid.
15410 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15412 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
15413 fetch_fp_regs, store_register, store_regs, store_fp_register,
15414 store_fp_regs): Use ptid from regcache.
15416 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15418 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
15419 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
15420 store_vfp_regs): Use ptid from regcache.
15422 2017-03-17 Pedro Alves <palves@redhat.com>
15425 * ser-base.c (ser_base_wait_for): Add comment.
15426 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
15428 * ser-unix.c (hardwire_raw): Remove reference to
15429 scb->current_timeout.
15430 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
15431 (hardwire_ops): Install ser_base_readchar instead of
15433 * serial.h (struct serial) <current_timeout, timeout_remaining>:
15436 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
15439 * python/lib/gdb/printer/bound_registers.py: Add support for
15442 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
15444 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
15445 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
15446 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
15447 byte_offset to subobj_byte_offset. Fix the handling of
15448 DWARF_VALUE_STACK on big-endian targets when coming via an
15450 (dwarf2_evaluate_loc_desc): Adjust call to
15451 dwarf2_evaluate_loc_desc_full.
15452 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
15453 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
15455 2017-03-16 Yao Qi <yao.qi@linaro.org>
15457 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
15458 and REVSH instructions.
15460 2017-03-16 Yao Qi <yao.qi@linaro.org>
15462 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
15463 (arm_record_test): Declare.
15464 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
15465 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
15466 align with the manual.
15467 (thumb_record_misc): Adjust the code order to align with the
15469 (thumb2_record_decode_insn_handler): Fix instruction matching.
15470 (instruction_reader_thumb): New class.
15471 (arm_record_test): New function.
15473 2017-03-16 Yao Qi <yao.qi@linaro.org>
15475 * arm-tdep.c (abstract_memory_reader): New class.
15476 (instruction_reader): New class.
15477 (extract_arm_insn): Add argument 'reader'. Callers updated.
15478 (decode_insn): Likewise.
15480 2017-03-16 Doug Evans <dje@google.com>
15482 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
15483 member. Change type of TYPE member to SCM. All uses updated.
15484 (lsscm_make_lazy_string_smob): Add assert.
15485 (lsscm_make_lazy_string): Flag bad length values.
15486 (lsscm_elt_type): New function.
15487 (gdbscm_lazy_string_to_value): Rewrite to use
15488 lsscm_safe_lazy_string_to_value.
15489 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
15490 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
15491 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
15493 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15494 * guile/scm-type.c (tyscm_scm_to_type): New function.
15496 2017-03-15 Doug Evans <dje@google.com>
15498 PR python/17728, python/18439, python/18779
15499 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
15500 member. Change type of TYPE member to PyObject *. All uses updated.
15501 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
15502 (gdbpy_create_lazy_string_object): Flag bad length values.
15503 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
15504 Handle typedefs in incoming type.
15505 (stpy_lazy_string_elt_type): New function.
15506 (gdbpy_extract_lazy_string): Call it.
15507 * python/py-value.c (valpy_lazy_string): Flag bad length values.
15508 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
15509 typedefs in incoming type.
15511 2017-03-16 Doug Evans <dje@google.com>
15513 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15514 * guile/scm-type.c (tyscm_scm_to_type): New function.
15516 2017-03-16 Jiong Wang <jiong.wang@arm.com>
15518 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
15519 "ULONGEST" for "skip".
15521 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15524 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
15525 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
15526 (inf_ptrace_peek_poke): ...here. New function. Now also loop
15527 over ptrace peek/poke until end of buffer or error.
15529 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
15531 * parse.c (length_of_subexp): Make static.
15532 * parser-defs.h (length_of_subexp): Remove.
15534 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15536 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
15539 2017-03-14 Pedro Alves <palves@redhat.com>
15541 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
15542 (main): Use std::unique_ptr. Remove calls to
15543 cp_demangled_name_parse_free.
15545 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15547 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
15548 alphabsd_store_inferior_registers): Use regcache->ptid instead
15551 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15553 * aix-thread.c (aix_thread_fetch_registers,
15554 aix_thread_store_registers): Use regcache->ptid instead of
15557 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15559 * aarch64-linux-nat.c (fetch_gregs_from_thread,
15560 store_gregs_to_thread, fetch_fpregs_from_thread,
15561 store_fpregs_to_thread): Use regcache->ptid instead of
15564 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15566 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
15567 amd64_linux_fetch_inferior_registers): Use regcache->ptid
15568 instead of inferior_ptid.
15570 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15572 * target.c (target_fetch_registers, target_store_registers): Add
15575 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15577 * regcache.h (regcache_get_ptid): New function.
15578 * regcache.c (regcache_get_ptid): New function.
15580 2017-03-13 Mark Wielaard <mark@klomp.org>
15582 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
15584 2017-03-10 Keith Seitz <keiths@redhat.com>
15587 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
15589 2017-03-08 Pedro Alves <palves@redhat.com>
15592 * infrun.c (start_step_over, do_target_resume, resume)
15593 (restart_threads): Assert we're not resuming a thread that is
15594 meant to be stopped.
15595 (infrun_thread_stop_requested_callback): Delete.
15596 (infrun_thread_stop_requested): If the thread is internally
15597 stopped, queue a pending stop event and clear the thread's
15598 inline-frame state.
15599 (handle_stop_requested): New function.
15600 (handle_syscall_event, handle_inferior_event_1): Use
15601 handle_stop_requested.
15602 (handle_stop_requested): New function.
15603 (handle_signal_stop): Set the thread's stop_signal here instead of
15605 (finish_step_over): Clear step over info unconditionally.
15606 (handle_signal_stop): If the user had interrupted the event
15607 thread, consider the stop a random signal.
15608 (handle_signal_stop) <signal arrived while stepping over
15609 breakpoint>: Don't restart threads here.
15610 (stop_waiting): Don't clear step-over info here.
15612 2017-03-08 Pedro Alves <palves@redhat.com>
15615 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
15616 goes to argument 2, not 1.
15618 2017-03-08 Pedro Alves <palves@redhat.com>
15621 * top.c (gdb_readline_wrapper): Avoid passing NULL to
15622 display_gdb_prompt.
15623 (command_line_input): Add comment.
15625 2017-03-08 Pedro Alves <palves@redhat.com>
15628 * tui/tui-file.c (tui_file::write): New.
15629 * tui/tui-file.h (tui_file): Override "write".
15630 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
15631 factored out from ...
15632 (tui_puts): ... here.
15633 (tui_putc): Use them.
15634 (tui_write): New function.
15635 * tui/tui-io.h (tui_write): Declare.
15637 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
15639 * Makefile.in (SFILES): Replace "environ.c" with
15640 "common/environ.c".
15641 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
15642 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
15644 * common/environ.c: ... here.
15645 * environ.h: Moved to...
15646 * common/environ.h: ... here.
15648 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15650 * gdbarch.sh (pstring_ptr): New static function.
15651 (gdbarch_disassembler_options): Use it.
15652 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
15653 not valid_disassembler_option->name.
15654 * gdbarch.c: Regenerate.
15656 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15658 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
15660 2017-03-07 Pedro Alves <palves@redhat.com>
15662 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
15664 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
15666 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
15667 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
15668 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
15669 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
15671 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
15673 * xtensa-linux-nat.c (fetch_gregs): Remove const.
15675 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
15677 * remote.c (remote_add_target_side_commands): Use range-based
15680 2017-03-03 Yao Qi <yao.qi@linaro.org>
15683 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
15685 * valprint.c (common_val_print): Likewise.
15687 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
15689 * NEWS: Mention new set/show disassembler-options commands.
15690 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
15691 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
15692 (prospective_options): New static variable.
15693 (gdb_disassembler::gdb_disassembler): Initialize
15694 m_di.disassembler_options.
15695 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
15696 (get_disassembler_options): New function.
15697 (set_disassembler_options): Likewise.
15698 (set_disassembler_options_sfunc): Likewise.
15699 (show_disassembler_options_sfunc): Likewise.
15700 (disassembler_options_completer): Likewise.
15701 (_initialize_disasm): Likewise.
15702 * disasm.h (get_disassembler_options): New prototype.
15703 (set_disassembler_options): Likewise.
15704 * gdbarch.sh (gdbarch_disassembler_options): New variable.
15705 (gdbarch_verify_disassembler_options): Likewise.
15706 * gdbarch.c: Regenerate.
15707 * gdbarch.h: Likewise.
15708 * arm-tdep.c (num_disassembly_options): Delete.
15709 (set_disassembly_style): Likewise.
15710 (arm_disassembler_options): New static variable.
15711 (set_disassembly_style_sfunc): Convert short style name into long
15712 option name. Call set_disassembler_options.
15713 (show_disassembly_style_sfunc): New function.
15714 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
15715 set_gdbarch_verify_disassembler_options.
15716 (_initialize_arm_tdep): Delete regnames variable and update callers.
15717 (arm_disassembler_options): Initialize.
15718 (disasm_options): New variable.
15719 (num_disassembly_options): Rename from this...
15720 (num_disassembly_styles): ...to this. Compute by scanning through
15722 (valid_disassembly_styles): Initialize using disasm_options.
15723 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
15724 set_arm_regname_option.
15725 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
15726 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
15727 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
15728 set_gdbarch_verify_disassembler_options.
15729 * s390-tdep.c (s390_disassembler_options): New static variable.
15730 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
15731 set_gdbarch_verify_disassembler_options.
15733 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15735 * remote.c (remote_add_target_side_condition): Remove "struct"
15736 keyword from range-based for loop.
15738 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15740 * remote.c (remote_add_target_side_condition): Use range-based
15741 for loop. Update comment.
15743 2017-02-27 Yao Qi <yao.qi@linaro.org>
15745 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
15747 2017-02-26 Alan Hayward <alan.hayward@arm.com>
15749 * regcache.c (regcache_raw_update): New function.
15750 (regcache_raw_read): Move code to regcache_raw_update.
15751 * regcache.h (regcache_raw_update): New declaration.
15752 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
15754 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
15756 * dwarf2read.c (create_debug_type_hash_table): Initialize
15757 header.signature and header.type_offset_in_tu.
15759 2017-02-24 Pedro Alves <palves@redhat.com>
15761 * symtab.c (make_file_symbol_completion_list_1): Use
15762 add_symtab_completions.
15764 2017-02-24 Alan Hayward <alan.hayward@arm.com>
15766 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
15768 2017-02-24 Alan Hayward <alan.hayward@arm.com>
15770 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
15771 I386_MAX_REGISTER_SIZE.
15772 (i386_pseudo_register_write): Likewise.
15773 (i386_process_record): Likewise.
15774 * i387-tdep.c (i387_supply_xsave): Likewise.
15775 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
15776 (store_register): Likewise.
15778 2017-02-23 Pedro Alves <palves@redhat.com>
15780 * ada-lang.c: Include "common/function-view.h".
15781 (ada_iterate_over_symbols): Adjust to use function_view as
15783 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
15784 (ada_make_symbol_completion_list): Use a lambda.
15785 (ada_exc_search_name_matches): Delete.
15786 (name_matches_regex): New.
15787 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
15788 * compile/compile-c-support.c: Include "common/function-view.h".
15789 (print_one_macro): Change prototype to accept a ui_file pointer.
15790 (write_macro_definitions): Use a lambda.
15791 * dwarf2read.c: Include "common/function-view.h".
15792 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
15793 (dw2_expand_symtabs_matching): Adjust to use function_view as
15795 * language.h: Include "common/function-view.h".
15796 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
15797 function_view as callback type.
15798 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
15799 * linespec.c: Include "common/function-view.h".
15800 (collect_info::add_symbol): New method.
15801 (struct symbol_and_data_callback, iterate_inline_only, struct
15802 symbol_matcher_data, iterate_name_matcher): Delete.
15803 (iterate_over_all_matching_symtabs): Adjust to use function_view
15804 as callback type and lambdas.
15805 (iterate_over_file_blocks): Adjust to use function_view as
15807 (decode_compound_collector): Now a class with private fields.
15808 (decode_compound_collector::release_symbols): New method.
15809 (collect_one_symbol): Rename to...
15810 (decode_compound_collector::operator()): ... this and adjust.
15811 (lookup_prefix_sym): decode_compound_collector construction bits
15812 move to decode_compound_collector ctor. Pass the
15813 decode_compound_collector object directly as callback. Remove
15814 cleanups and use decode_compound_collector::release_symbols
15816 (symtab_collector): Now a class with private fields.
15817 (symtab_collector::release_symtabs): New method.
15818 (add_symtabs_to_list): Rename to...
15819 (symtab_collector::operator()): ... this and adjust.
15820 (collect_symtabs_from_filename): symtab_collector construction
15821 bits move to symtab_collector ctor. Pass the symtab_collector
15822 object directly as callback. Remove cleanups and use
15823 symtab_collector::release_symtabs instead.
15824 (collect_symbols): Delete.
15825 (add_matching_symbols_to_info): Use lambdas.
15826 * macrocmd.c (print_macro_callback): Delete.
15827 (info_macro_command): Use a lambda.
15828 (info_macros_command): Pass print_macro_definition as callable
15830 (print_one_macro): Remove 'ignore' parameter.
15831 (macro_list_command): Adjust.
15832 * macrotab.c (macro_for_each_data::fn): Now a function_view.
15833 (macro_for_each_data::user_data): Delete field.
15834 (foreach_macro): Adjust to call the function_view.
15835 (macro_for_each): Adjust to use function_view as callback type.
15836 (foreach_macro_in_scope): Adjust to call the function_view.
15837 (macro_for_each_in_scope): Adjust to use function_view as callback
15839 * macrotab.h: Include "common/function-view.h".
15840 (macro_callback_fn): Declare a prototype instead of a pointer.
15841 Remove "user_data" parameter.
15842 (macro_for_each, macro_for_each_in_scope): Adjust to use
15843 function_view as callback type.
15844 * psymtab.c (partial_map_expand_apply)
15845 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
15846 Adjust to use function_view as callback type and to return bool.
15847 (psym_expand_symtabs_matching): Adjust to use function_view as
15849 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
15850 to use function_view as callback type and to return bool.
15851 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
15853 * symfile.c (expand_symtabs_matching): Adjust to use function_view
15855 * symfile.h: Include "common/function-view.h".
15856 (expand_symtabs_file_matcher_ftype)
15857 (expand_symtabs_symbol_matcher_ftype)
15858 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
15860 (quick_symbol_functions::map_symtabs_matching_filename)
15861 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
15862 function_view as callback type and return bool.
15863 (expand_symtabs_matching): Adjust to use function_view as callback
15865 (maintenance_expand_name_matcher)
15866 (maintenance_expand_file_matcher): Delete.
15867 (maintenance_expand_symtabs): Use lambdas.
15868 * symtab.c (iterate_over_some_symtabs): Adjust to use
15869 function_view as callback types and return bool.
15870 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
15872 (lookup_symtab_callback): Delete.
15873 (lookup_symtab): Use a lambda.
15874 (iterate_over_symbols): Adjust to use function_view as callback
15876 (struct search_symbols_data, search_symbols_file_matches)
15877 (search_symbols_name_matches): Delete.
15878 (search_symbols): Use a pair of lambdas.
15879 (struct add_name_data, add_macro_name, symbol_completion_matcher)
15880 (symtab_expansion_callback): Delete.
15881 (default_make_symbol_completion_list_break_on_1): Use lambdas.
15882 * symtab.h: Include "common/function-view.h".
15883 (iterate_over_some_symtabs): Adjust to use function_view as
15884 callback type and return bool.
15885 (iterate_over_symtabs): Adjust to use function_view as callback
15887 (symbol_found_callback_ftype): Remove 'data' parameter and return
15889 (iterate_over_symbols): Adjust to use function_view as callback
15892 2017-02-23 Pedro Alves <palves@redhat.com>
15894 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
15895 (%.o) <unittests/%.c>: New pattern.
15896 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
15897 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
15898 * common/function-view.h: New file.
15899 * unittests/function-view-selftests.c: New file.
15900 * configure: Regenerate.
15902 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
15904 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
15906 * go32-nat.c (go32_thread_alive): Likewise.
15908 2017-02-23 Yao Qi <yao.qi@linaro.org>
15910 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
15913 2017-02-23 Yao Qi <yao.qi@linaro.org>
15915 * varobj.c (varobj_clear_saved_item): Use delete instead of
15917 (update_dynamic_varobj_children): Likewise.
15919 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15921 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
15923 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
15925 * common/enum-flags.h (enum_flags::enum_flags): Initialize
15926 m_enum_value to 0 in default constructor.
15928 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
15930 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
15931 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
15932 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
15933 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
15934 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
15935 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
15936 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
15937 IS_STORE_CONDITIONAL_INSN.
15939 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15941 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
15943 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15945 * NEWS (Changes since GDB 7.12): Add DWARF-5.
15947 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15949 * dwarf2read.c (skip_one_die, read_attribute_value)
15950 (dwarf2_const_value_attr, dump_die_shallow)
15951 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
15952 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
15954 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15956 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
15957 (dwarf_parse_macro_header): Accept DWARF version 5.
15958 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
15960 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15962 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
15964 * common/common-exceptions.h (enum errors): Likewise.
15965 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
15966 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
15967 (dwarf_expr_context::execute_stack_op): Likewise.
15968 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
15970 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
15971 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
15972 (show_entry_values_debug, call_site_to_target_addr)
15973 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
15974 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
15975 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
15976 (value_of_dwarf_block_entry, indirect_pieced_value)
15977 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
15978 (disassemble_dwarf_expression): Likewise.
15979 * dwarf2read.c (process_die, inherit_abstract_dies)
15980 (read_call_site_scope): Likewise.
15981 * gdbtypes.h (struct func_type, struct call_site_parameter)
15982 (struct call_site): Likewise.
15983 * stack.c (read_frame_arg): Likewise.
15984 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
15986 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15988 * defs.h (read_unsigned_leb128): New declaration.
15989 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
15990 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
15991 (dwarf2_find_location_expression): Call also
15992 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
15993 * dwarf2loc.h (dwarf2_version): New declaration.
15994 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
15996 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
15998 (struct dwop_section_names): Add loclists_dwo.
15999 (dwop_section_names): Add .debug_loclists.dwo.
16000 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
16001 (struct dwarf2_per_cu_data): Add dwarf_version.
16002 (struct dwo_sections): Add loclists.
16003 (struct attr_abbrev): Add implicit_const.
16004 (read_indirect_line_string): New declaration.
16005 (read_unsigned_leb128): Delete declaration.
16006 (rcuh_kind): New definition.
16007 (read_and_check_comp_unit_head): Change parameter
16008 is_debug_types_section to section_kind.
16009 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
16010 (read_comp_unit_head): Change parameter abfd to section, add parameter
16011 section_kind. Handle DWARF-5.
16012 (error_check_comp_unit_head): Accept also DWARF version 5.
16013 (read_and_check_comp_unit_head): Change parameter
16014 is_debug_types_section to section_kind.
16015 (read_and_check_type_unit_head): Delete function.
16016 (read_abbrev_offset): Handle DWARF-5.
16017 (create_debug_type_hash_table): Add parameter section_kind. Process
16018 only DW_UT_type. Use signature and type_offset_in_tu from struct
16020 (create_debug_types_hash_table): Update create_debug_type_hash_table
16022 (create_all_type_units): Call create_debug_type_hash_table.
16023 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
16024 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
16026 (skip_one_die): Handle DW_FORM_implicit_const.
16027 (dwarf2_rnglists_process): New function.
16028 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
16029 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
16030 (read_attribute_value): Handle DW_FORM_implicit_const,
16032 (read_attribute): Handle DW_FORM_implicit_const.
16033 (read_indirect_string_at_offset_from): New function from
16034 read_indirect_string_at_offset.
16035 (read_indirect_string_at_offset): Call
16036 read_indirect_string_at_offset_from.
16037 (read_indirect_line_string_at_offset): New function.
16038 (read_indirect_string): New function comment.
16039 (read_indirect_line_string): New function.
16040 (read_unsigned_leb128): Make it global.
16041 (dwarf2_string_attr): Handle DWARF-5.
16042 (add_include_dir_stub, read_formatted_entries): New functions.
16043 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
16045 (per_cu_header_read_in): Update read_comp_unit_head caller.
16046 (dwarf2_version): New function.
16047 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
16049 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16052 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16054 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16056 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16058 * dwarf2read.c (dwarf2_ranges_process): New function from
16059 dwarf2_ranges_read.
16060 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16061 dwarf2_ranges_process.
16063 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16065 * dwarf2read.c (create_debug_type_hash_table): New function from
16066 create_debug_types_hash_table.
16067 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16068 (create_all_type_units, open_and_init_dwo_file): Update
16069 create_debug_types_hash_table callers.
16071 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16074 * fork-child.c (trace_start_error): Fix thinko. va_end should
16075 refer to 'ap', not 'args'.
16077 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16078 Pedro Alves <palves@redhat.com>
16081 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16083 * fork-child.c (trace_start_error): New function.
16084 (trace_start_error_with_name): Likewise.
16085 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16086 * inf-ptrace.c (inf_ptrace_me): Likewise.
16087 * inferior.h (trace_start_error): New prototype.
16088 (trace_start_error_with_name): Likewise.
16090 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16093 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16094 NULL before using it.
16095 * symmisc.c (maintenance_print_symbols): Likewise.
16096 (maintenance_print_msymbols): Likewise.
16098 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16100 * NEWS: Add record Python bindings entry.
16102 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16104 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16106 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16107 * python/py-record-btrace.c, python/py-record-btrace.h,
16108 python/py-record-full.c, python/py-record-full.h: New file.
16109 * python/py-record.c: Add include for py-record-btrace.h and
16111 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16112 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16113 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16114 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16116 (gdbpy_initialize_btrace): New export.
16117 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16119 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16121 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16122 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16123 * python/py-record.c: New file.
16124 * python/python-internal.h (gdbpy_start_recording,
16125 gdbpy_current_recording, gdpy_stop_recording,
16126 gdbpy_initialize_record): New export.
16127 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16128 (python_GdbMethods): Add gdbpy_start_recording,
16129 gdbpy_current_recording and gdbpy_stop_recording.
16131 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16133 * record-btrace.c (record_btrace_record_method): New function.
16134 (init_record_btrace_ops): Initialize to_record_method.
16135 * record-full.c (record_full_record_method): New function.
16136 (init_record_full_ops, init_record_full_core_ops): Add
16137 record_full_record_method.
16138 * record.h (enum record_method): New enum.
16139 * target-debug.h (target_debug_print_enum_record_method: New define.
16140 * target-delegates.c: Regenerate.
16141 * target.c (target_record_method): New function.
16142 * target.h: Include record.h.
16143 (struct target_ops) <to_record_method>: New field.
16144 (target_record_method): New export.
16146 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16148 * record.h (record_start, record_stop): New export.
16149 * record.c (record_start, record_stop): New function.
16151 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16153 * btrace.c (btrace_fetch): Copy function call segments pointer
16155 (btrace_clear): Clear the vector.
16156 (btrace_find_insn_by_number): Use binary search to find the correct
16157 function call segment.
16158 * btrace.h (brace_fun_p): New typedef.
16159 (struct btrace_thread_info) <functions>: New field.
16161 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16163 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16164 * btrace.c (btrace_decode_error): ... here. New function.
16165 * btrace.h (btrace_decode_error): New export.
16167 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16169 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16170 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16171 btrace_find_insn_by_number): Remove special case for gaps.
16172 * btrace.h (btrace_insn_get_error): New export.
16173 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16174 * record-btrace.c (btrace_insn_history): Print number for gaps.
16175 (record_btrace_info, record_btrace_goto): Handle gaps.
16177 2017-02-14 Tom Tromey <tom@tromey.com>
16180 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16182 * python/py-evts.c (gdbpy_initialize_py_events): Add
16183 before_prompt registry.
16184 * python/py-events.h (events_object) <before_prompt>: New field.
16186 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16188 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16190 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
16192 * symfile (_initialize_symfile): Add usage text to the load command's
16195 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16197 * utils.c (defaulted_query): Don't query on secondary UIs.
16199 2017-02-10 Tom Tromey <tom@tromey.com>
16201 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16203 2017-02-10 Tom Tromey <tom@tromey.com>
16205 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16207 * python/py-type.c (typy_legacy_template_argument): Remove
16208 unnecessary "cleanup" local.
16210 2017-02-10 Tom Tromey <tom@tromey.com>
16212 * python/python.c (do_start_initialization): New function, from
16213 _initialize_python.
16214 (_initialize_python): Call do_start_initialization.
16215 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16218 2017-02-10 Tom Tromey <tom@tromey.com>
16220 * python/py-prettyprint.c (pretty_print_one_value): Use
16223 2017-02-10 Tom Tromey <tom@tromey.com>
16225 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16226 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16228 * python/py-type.c (field_new): Use gdbpy_ref.
16229 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16231 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16232 (py_free_pspace): Likewise.
16233 (pspace_to_pspace_object): Likewise.
16234 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16235 (py_free_objfile): Likewise.
16236 (objfile_to_objfile_object): Likewise.
16237 * python/py-inferior.c (delete_thread_object): Use
16239 (infpy_read_memory): Likewise.
16240 (py_free_inferior): Likewise.
16241 * python/py-evtregistry.c (create_eventregistry_object): Use
16243 * python/py-event.c (create_event_object): Use gdbpy_ref.
16245 2017-02-10 Tom Tromey <tom@tromey.com>
16247 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16248 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16250 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16251 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16252 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16253 python/py-framefilter.c, python/py-function.c,
16254 python/py-inferior.c, python/py-infevents.c,
16255 python/py-linetable.c, python/py-newobjfileevent.c,
16256 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16257 python/py-signalevent.c, python/py-stopevent.c,
16258 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16259 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16260 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16261 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16263 2017-02-10 Tom Tromey <tom@tromey.com>
16265 * ui-out.h (ui_out_emit_type): New class.
16266 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16267 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16268 and ui_out_emit_tuple.
16269 (enumerate_locals): Likewise.
16270 (py_mi_print_variables, py_print_locals, py_print_args): Use
16272 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16274 * common/gdb_optional.h: New file.
16276 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
16278 * MAINTAINERS (Write After Approval): Update my e-mail address.
16280 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
16283 * breakpoint.c (_initialize_breakpoint): Update the help description
16284 of the 'commands' command to indicate that it takes a list argument.
16286 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16288 * interps.c (current_interp_set_logging): Remove "return".
16290 2017-02-09 Gary Benson <gbenson@redhat.com>
16292 * symtab.c (add_symtab_completions): Prevent NULL pointer
16295 2017-02-08 Pedro Alves <palves@redhat.com>
16297 * interps.c (interp::interp): Remove reference to quiet_p.
16298 (interp_set): Make static. Remove dead "Switching to" output
16300 (interp_quiet_p, interp_set_quiet): Delete.
16301 (interpreter_exec_cmd): Don't set the interpreter quiet.
16302 * interps.h (interp_quiet_p): Make static.
16303 (class interp) <quiet_p>: Remove field
16305 2017-02-08 Jerome Guitton <guitton@adacore.com>
16307 * cli/cli-decode.c (find_command_name_length): Make it extern.
16308 * cli/cli-decode.h (find_command_name_length): Declare.
16309 * cli/cli-script.c (command_name_equals, line_first_arg):
16311 (process_next_line): Use cli-decode to parse command names.
16312 (build_command_line): Make args a constant pointer.
16314 2017-02-08 Jerome Guitton <guitton@adacore.com>
16316 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16317 Remove case-insensitive search.
16319 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16321 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16322 at the end of the line. Avoids an ARI warning.
16324 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
16326 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16327 rdseed instructions.
16328 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16330 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16333 Provide and use sparc32 and sparc64 target description XML files.
16334 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16335 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16336 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16337 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16338 * features/sparc/sparc32-solaris.xml: New file.
16339 * features/sparc/sparc64-solaris.xml: New file.
16340 * features/sparc/sparc32-solaris.c: Generated.
16341 * features/sparc/sparc64-solaris.c: Generated.
16342 * sparc-tdep.h: Account for differences in target descriptions.
16343 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16344 (sparc32_register_type): Use target provided registers.
16345 (validate_tdesc_registers): New function.
16346 (sparc32_gdbarch_init): Use tdesc_has_registers.
16347 Set pseudoregister functions.
16348 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16349 (sparc64_register_type): Use target provided registers.
16350 (sparc64_init_abi): Set pseudoregister functions.
16352 2017-02-03 Tom Tromey <tom@tromey.com>
16355 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16356 with a single member.
16358 2017-02-03 Pedro Alves <palves@redhat.com>
16360 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16361 (cli_interp_base::~cli_interp_base): New.
16362 (cli_interp): New struct.
16363 (as_cli_interp): Cast the interp itself to cli_interp.
16364 (cli_interpreter_pre_command_loop): Rename to ...
16365 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16367 (cli_interpreter_init): Rename to ...
16368 (cli_interp::init): ... this. Remove 'self' parameter. Use
16369 boolean. Make extern.
16370 (cli_interpreter_resume): Rename to ...
16371 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16373 (cli_interpreter_suspend): Rename to ...
16374 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16376 (cli_interpreter_exec): Rename to ...
16377 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16379 (cli_interpreter_supports_command_editing): Rename to ...
16380 (cli_interp_base::supports_command_editing): ... this. Remove
16381 'interp' parameter. Make extern.
16382 (cli_ui_out): Rename to ...
16383 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16385 (cli_set_logging): Rename to ...
16386 (cli_interp_base::set_logging): ... this. Remove 'interp'
16387 parameter. Make extern.
16388 (cli_interp_procs): Delete.
16389 (cli_interp_factory): Adjust to use "new".
16390 * cli/cli-interp.h: Include "interps.h".
16391 (struct cli_interp_base): New struct.
16392 * interps.c (struct interp): Delete. Fields moved to interps.h.
16393 (interp_new): Delete.
16394 (interp::interp, interp::~interp): New.
16395 (interp_set): Use bool, and return void. Assume the interpreter
16396 has suspend, init and resume methods, and that the all return
16398 (set_top_level_interpreter): interp_set returns void.
16399 (interp_ui_out): Adapt.
16400 (current_interp_set_logging): Adapt.
16401 (interp_data): Delete.
16402 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
16403 (interp_exec): Adapt.
16404 (top_level_interpreter_data): Delete.
16405 * interps.h (interp_init_ftype, interp_resume_ftype)
16406 (interp_suspend_ftype, interp_exec_ftype)
16407 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
16408 (class interp): New.
16409 (interp_new): Delete.
16410 (interp_set): Now returns void. Use bool.
16411 (interp_data, top_level_interpreter_data): Delete.
16412 * mi/mi-common.h: Include interps.h.
16413 (class mi_interp): Inherit from interp. Define a ctor. Declare
16414 init, resume, suspect, exec, interp_ui_out, set_logging and
16415 pre_command_loop methods.
16416 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
16417 (mi_interpreter_init): Rename to ...
16418 (mi_interp::init): ... this. Remove the 'interp' parameter, use
16419 bool, return void and make extern. Adjust.
16420 (mi_interpreter_resume): ... Rename to ...
16421 (mi_interp::resume): ... this. Remove the 'data' parameter,
16422 return void and make extern. Adjust.
16423 (mi_interpreter_suspend): ... Rename to ...
16424 (mi_interp::suspend): ... this. Remove the 'data' parameter,
16425 return void and make extern. Adjust.
16426 (mi_interpreter_exec): ... Rename to ...
16427 (mi_interp::exec): ... this. Remove the 'data' parameter and make
16429 (mi_interpreter_pre_command_loop): ... Rename to ...
16430 (mi_interp::pre_command_loop): ... this. Remove the 'self'
16431 parameter and make extern.
16432 (mi_on_normal_stop_1): Adjust.
16433 (mi_ui_out): Rename to ...
16434 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
16435 parameter and make extern. Adjust.
16436 (mi_set_logging): Rename to ...
16437 (mi_interp::set_logging): ... this. Remove the 'interp'
16438 parameter and make extern. Adjust.
16439 (mi_interp_procs): Delete.
16440 (mi_interp_factory): Adjust to use 'new'.
16441 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
16442 (mi_print_exception, mi_execute_command, mi_load_progress):
16444 * tui/tui-interp.c (tui_interp): New class.
16445 (as_tui_interp): Return a tui_interp pointer.
16446 (tui_on_normal_stop, tui_on_signal_received)
16447 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
16448 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
16449 to use interp::interp_ui_out.
16450 (tui_init): Rename to ...
16451 (tui_interp::init): ... this. Remove the 'self' parameter, use
16452 bool, return void and make extern. Adjust.
16453 (tui_resume): Rename to ...
16454 (tui_interp::resume): ... this. Remove the 'data' parameter,
16455 return void and make extern. Adjust.
16456 (tui_suspend): Rename to ...
16457 (tui_interp::suspend): ... this. Remove the 'data' parameter,
16458 return void and make extern. Adjust.
16459 (tui_ui_out): Rename to ...
16460 (tui_interp::interp_ui_out): ... this. Remove the 'self'
16461 parameter, and make extern. Adjust.
16462 (tui_exec): Rename to ...
16463 (tui_interp::exec): ... this. Remove the 'data' parameter and
16465 (tui_interp_procs): Delete.
16466 (tui_interp_factory): Use "new".
16468 2017-02-02 Tom Tromey <tom@tromey.com>
16470 * rust-exp.y (ends_raw_string, space_then_number)
16471 (rust_identifier_start_p): Return bool.
16472 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
16473 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
16474 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
16475 (rust_chartype_p): Return bool.
16476 (val_print_struct, rust_print_struct_def, rust_print_type):
16478 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
16481 2017-02-02 Tom Tromey <tom@tromey.com>
16483 * rust-lang.c: Reindent.
16485 2017-02-02 Tom Tromey <tom@tromey.com>
16487 * rust-lang.h (rust_crate_for_block): Update.
16488 * rust-lang.c (rust_crate_for_block): Return std::string.
16489 (rust_get_disr_info): Use std:;string, not
16490 gdb::unique_xmalloc_ptr.
16491 * rust-exp.y (crate_name): Update.
16493 2017-02-02 Pedro Alves <palves@redhat.com>
16495 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
16496 field out of gdb_disassembler_test and make it static.
16498 2017-02-02 Pedro Alves <palves@redhat.com>
16500 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
16501 mi1_interp and mi_interp fields.
16503 2017-02-02 Pedro Alves <palves@redhat.com>
16505 * cli/cli-interp.c (struct saved_output_files, saved_output):
16506 Moved from cli/cli-logging.c.
16507 (cli_set_logging): New function.
16508 (cli_interp_procs): Install cli_set_logging.
16509 * cli/cli-interp.h (make_logging_output, cli_set_logging):
16511 * cli/cli-logging.c (struct saved_output_files, saved_output):
16512 Moved to cli/cli-interp.c.
16513 (pop_output_files): Don't save outputs here.
16514 (make_logging_output): New function.
16515 (handle_redirections): Don't build tee nor save previous outputs
16517 * interps.c (current_interp_set_logging): Change prototype.
16518 Assume there's always a set_logging_proc method installed.
16519 * interps.h (interp_set_logging_ftype): Change prototype.
16520 (current_interp_set_logging): Change prototype and adjust comment.
16521 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
16522 use make_logging_output.
16523 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
16524 2017-02-02 Pedro Alves <palves@redhat.com>
16526 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
16528 (set_logging_overwrite): ... here.
16529 (logging_no_redirect_file): Delete.
16530 (set_logging_redirect): Don't handle redirection on the fly.
16531 Instead warn that "logging off" / "logging on" is necessary.
16532 (pop_output_files): Delete references to logging_no_redirect_file.
16533 (show_logging_command): Always speak in terms of what will happen
16534 once logging is reenabled.
16536 2017-02-02 Pedro Alves <palves@redhat.com>
16538 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
16540 2017-02-02 Pedro Alves <palves@redhat.com>
16542 * disasm.c (gdb_pretty_print_insn): Rename to ...
16543 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
16544 Remove gdbarch parameter. Adapt to clear the object's buffers
16545 instead of allocating new buffers, and to print using the object's
16546 gdb_disassembler instead of calling gdb_print_insn.
16547 (dump_insns): Use gdb_pretty_print_disassembler.
16548 * disasm.h (gdb_pretty_print_insn): Delete declaration.
16549 (gdb_pretty_print_disassembler): New class.
16550 * record-btrace.c (btrace_insn_history): Use
16551 gdb_pretty_print_disassembler.
16553 2017-02-02 Pedro Alves <palves@redhat.com>
16555 * ada-lang.c (type_as_string): Use string_file.
16556 * ada-valprint.c (ada_print_floating): Use string_file.
16557 * ada-varobj.c (ada_varobj_scalar_image)
16558 (ada_varobj_get_value_image): Use string_file.
16559 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
16560 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
16561 * breakpoint.c (update_inserted_breakpoint_locations)
16562 (insert_breakpoint_locations, reattach_breakpoints)
16563 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
16564 (print_it_watchpoint): Use string_file.
16565 (save_breakpoints): Use stdio_file.
16566 * c-exp.y (oper): Use string_file.
16567 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
16569 (pop_output_files): Use delete.
16570 (handle_redirections): Use stdio_file and tee_file.
16571 * cli/cli-setshow.c (do_show_command): Use string_file.
16572 * compile/compile-c-support.c (c_compute_program): Use
16574 * compile/compile-c-symbols.c (generate_vla_size): Take a
16575 'string_file &' instead of a 'ui_file *'.
16576 (generate_c_for_for_one_variable): Take a 'string_file &' instead
16577 of a 'ui_file *'. Use string_file.
16578 (generate_c_for_variable_locations): Take a 'string_file &'
16579 instead of a 'ui_file *'.
16580 * compile/compile-internal.h (generate_c_for_for_one_variable):
16581 Take a 'string_file &' instead of a 'ui_file *'.
16582 * compile/compile-loc2c.c (push, pushf, unary, binary)
16583 (print_label, pushf_register_address, pushf_register)
16584 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
16585 'ui_file *'. Adjust.
16586 * compile/compile.c (compile_to_object): Use string_file.
16587 * compile/compile.h (compile_dwarf_expr_to_c)
16588 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
16590 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
16591 (replace_typedefs_qualified_name): Use string_file and
16593 * disasm.c (gdb_pretty_print_insn): Use string_file.
16594 (gdb_disassembly): Adjust reference the null_stream global.
16595 (do_ui_file_delete): Delete.
16596 (gdb_insn_length): Use null_stream.
16597 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
16598 * dwarf2loc.c (dwarf2_compile_property_to_c)
16599 (locexpr_generate_c_location, loclist_generate_c_location): Take a
16600 'string_file &' instead of a 'ui_file *'.
16601 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
16602 * dwarf2read.c (do_ui_file_peek_last): Delete.
16603 (dwarf2_compute_name): Use string_file.
16604 * event-top.c (gdb_setup_readline): Use stdio_file.
16605 * gdbarch.sh (verify_gdbarch): Use string_file.
16606 * gdbtypes.c (safe_parse_type): Use null_stream.
16607 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
16609 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
16610 'string_file *' instead of a 'ui_file *'.
16611 (gdbscm_arch_disassemble): Use string_file.
16612 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
16613 * guile/scm-ports.c (class ioscm_file_port): Now a class that
16614 inherits from ui_file.
16615 (ioscm_file_port_delete, ioscm_file_port_rewind)
16616 (ioscm_file_port_put): Delete.
16617 (ioscm_file_port_write): Rename to ...
16618 (ioscm_file_port::write): ... this. Remove file_port_magic
16620 (ioscm_file_port_new): Delete.
16621 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
16623 * guile/scm-type.c (tyscm_type_name): Use string_file.
16624 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
16626 * infcmd.c (print_return_value_1): Use string_file.
16627 * infrun.c (print_target_wait_results): Use string_file.
16628 * language.c (add_language): Use string_file.
16629 * location.c (explicit_to_string_internal): Use string_file.
16630 * main.c (captured_main_1): Use null_file.
16631 * maint.c (maintenance_print_architecture): Use stdio_file.
16632 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
16633 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
16634 event_channel>: Change type to mi_console_file pointer.
16635 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
16636 (mi_console_file_delete): Delete.
16637 (struct mi_console_file): Delete.
16638 (mi_console_file_magic): Delete.
16639 (mi_console_file_new): Delete.
16640 (mi_console_file::mi_console_file): New.
16641 (mi_console_file_delete): Delete.
16642 (mi_console_file_fputs): Delete.
16643 (mi_console_file::write): New.
16644 (mi_console_raw_packet): Delete.
16645 (mi_console_file::flush): New.
16646 (mi_console_file_flush): Delete.
16647 (mi_console_set_raw): Rename to ...
16648 (mi_console_file::set_raw): ... this.
16649 * mi/mi-console.h (class mi_console_file): New class.
16650 (mi_console_file_new, mi_console_set_raw): Delete.
16651 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
16652 (mi_set_logging): Use delete and tee_file. Adjust.
16653 * mi/mi-main.c (output_register): Use string_file.
16654 (mi_cmd_data_evaluate_expression): Use string_file.
16655 (mi_cmd_data_read_memory): Use string_file.
16656 (mi_cmd_execute, print_variable_or_computed): Use string_file.
16657 * mi/mi-out.c (mi_ui_out::main_stream): New.
16658 (mi_ui_out::rewind): Use main_stream and
16660 (mi_ui_out::put): Use main_stream and string_file.
16661 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16662 Allocate a 'string_file' instead.
16663 (mi_out_new): Don't allocate a mem_fileopen stream here.
16664 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16665 (mi_ui_out::main_stream): Declare method.
16666 * printcmd.c (eval_command): Use string_file.
16667 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
16668 * python/py-arch.c (archpy_disassemble): Use string_file.
16669 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
16670 * python/py-frame.c (frapy_str): Use string_file.
16671 * python/py-framefilter.c (py_print_type, py_print_single_arg):
16673 * python/py-type.c (typy_str): Use string_file.
16674 * python/py-unwind.c (unwind_infopy_str): Use string_file.
16675 * python/py-value.c (valpy_str): Use string_file.
16676 * record-btrace.c (btrace_insn_history): Use string_file.
16677 * regcache.c (regcache_print): Use stdio_file.
16678 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
16679 * remote.c (escape_buffer): Use string_file.
16680 * rust-lang.c (rust_get_disr_info): Use string_file.
16681 * serial.c (serial_open_ops_1): Use stdio_file.
16682 (do_serial_close): Use delete.
16683 * stack.c (print_frame_arg): Use string_file.
16684 (print_frame_args): Remove local mem_fileopen stream, not used.
16685 (print_frame): Use string_file.
16686 * symmisc.c (maintenance_print_symbols): Use stdio_file.
16687 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
16688 Take a 'string_file *' instead of a 'ui_file *'.
16689 * top.c (new_ui): Use stdio_file and stderr_file.
16690 (free_ui): Use delete.
16691 (execute_command_to_string): Use string_file.
16692 (quit_confirm): Use string_file.
16693 * tracepoint.c (collection_list::append_exp): Use string_file.
16694 * tui/tui-disasm.c (tui_disassemble): Use string_file.
16695 * tui/tui-file.c: Don't include "ui-file.h".
16696 (enum streamtype, struct tui_stream): Delete.
16697 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
16698 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
16699 (tui_file::tui_file): New method.
16700 (tui_file_fputs): Delete.
16701 (tui_file_get_strbuf): Delete.
16702 (tui_file::puts): New method.
16703 (tui_file_adjust_strbuf): Delete.
16704 (tui_file_flush): Delete.
16705 (tui_file::flush): New method.
16706 * tui/tui-file.h: Tweak intro comment.
16708 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
16709 (tui_file_adjust_strbuf): Delete declarations.
16710 (class tui_file): New class.
16711 * tui/tui-io.c (tui_initialize_io): Use tui_file.
16712 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
16713 (tui_register_format): Use string_stream.
16714 * tui/tui-stack.c (tui_make_status_line): Use string_file.
16715 (tui_get_function_from_frame): Use string_file.
16716 * typeprint.c (type_to_string): Use string_file.
16717 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
16718 (null_stream): New global.
16719 (ui_file_delete): Delete.
16720 (ui_file::ui_file): New.
16721 (null_file_isatty): Delete.
16722 (ui_file::~ui_file): New.
16723 (null_file_rewind): Delete.
16724 (ui_file::printf): New.
16725 (null_file_put): Delete.
16726 (null_file_flush): Delete.
16727 (ui_file::putstr): New.
16728 (null_file_write): Delete.
16729 (ui_file::putstrn): New.
16730 (null_file_read): Delete.
16731 (ui_file::putc): New.
16732 (null_file_fputs): Delete.
16733 (null_file_write_async_safe): Delete.
16734 (ui_file::vprintf): New.
16735 (null_file_delete): Delete.
16736 (null_file::write): New.
16737 (null_file_fseek): Delete.
16738 (null_file::puts): New.
16739 (ui_file_data): Delete.
16740 (null_file::write_async_safe): New.
16741 (gdb_flush, ui_file_isatty): Adjust.
16742 (ui_file_put, ui_file_rewind): Delete.
16743 (ui_file_write): Adjust.
16744 (ui_file_write_for_put): Delete.
16745 (ui_file_write_async_safe, ui_file_read): Adjust.
16746 (ui_file_fseek): Delete.
16747 (fputs_unfiltered): Adjust.
16748 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
16749 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
16750 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
16751 (set_ui_file_data): Delete.
16752 (string_file::~string_file, string_file::write)
16753 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
16754 (do_ui_file_as_string, ui_file_as_string): Delete.
16755 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
16756 (struct mem_file): Delete.
16757 (mem_file_new): Delete.
16758 (stdio_file::stdio_file): New.
16759 (mem_file_delete): Delete.
16760 (stdio_file::stdio_file): New.
16761 (mem_fileopen): Delete.
16762 (stdio_file::~stdio_file): New.
16763 (mem_file_rewind): Delete.
16764 (stdio_file::set_stream): New.
16765 (mem_file_put): Delete.
16766 (stdio_file::open): New.
16767 (mem_file_write): Delete.
16768 (stdio_file_magic, struct stdio_file): Delete.
16769 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
16770 (stdio_file::flush): New.
16771 (stdio_file_read): Rename to ...
16772 (stdio_file::read): ... this. Adjust.
16773 (stdio_file_write): Rename to ...
16774 (stdio_file::write): ... this. Adjust.
16775 (stdio_file_write_async_safe): Rename to ...
16776 (stdio_file::write_async_safe) ... this. Adjust.
16777 (stdio_file_fputs): Rename to ...
16778 (stdio_file::puts) ... this. Adjust.
16779 (stdio_file_isatty): Delete.
16780 (stdio_file_fseek): Delete.
16781 (stdio_file::isatty): New.
16782 (stderr_file_write): Rename to ...
16783 (stderr_file::write) ... this. Adjust.
16784 (stderr_file_fputs): Rename to ...
16785 (stderr_file::puts) ... this. Adjust.
16786 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
16787 (stderr_file::stderr_file): New.
16788 (tee_file_magic): Delete.
16789 (struct tee_file): Delete.
16790 (tee_file::tee_file): New.
16791 (tee_file_new): Delete.
16792 (tee_file::~tee_file): New.
16793 (tee_file_delete): Delete.
16794 (tee_file_flush): Rename to ...
16795 (tee_file::flush): ... this. Adjust.
16796 (tee_file_write): Rename to ...
16797 (tee_file::write): ... this. Adjust.
16798 (tee_file::write_async_safe): New.
16799 (tee_file_fputs): Rename to ...
16800 (tee_file::puts): ... this. Adjust.
16801 (tee_file_isatty): Rename to ...
16802 (tee_file::isatty): ... this. Adjust.
16803 * ui-file.h (struct obstack, struct ui_file): Don't
16805 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
16806 (ui_file_write_ftype)
16807 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
16808 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
16809 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
16810 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
16811 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
16812 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
16813 (set_ui_file_fseek): Delete.
16814 (ui_file_data, ui_file_delete, ui_file_rewind)
16815 (struct ui_file): New.
16817 (class null_file): New.
16818 (null_stream): Declare.
16819 (ui_file_write_for_put, ui_file_put): Delete.
16820 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
16822 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
16823 (gdb_fopen, tee_file_new): Delete.
16824 (struct string_file): New.
16825 (struct stdio_file): New.
16826 (stdio_file_up): New.
16827 (struct stderr_file): New.
16828 (class tee_file): New.
16829 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
16830 of a 'ui_file *'. Adjust.
16831 * ui-out.h (class ui_out) <field_stream>: Likewise.
16832 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
16833 (null_stream): Delete.
16834 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
16836 * utils.h (struct ui_file): Delete forward declaration..
16837 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
16838 (error_stream): Take a 'string_file &' instead of a
16840 * varobj.c (varobj_value_get_print_value): Use string_file.
16841 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
16842 * gdbarch.c: Regenerate.
16844 2017-02-02 Pedro Alves <palves@redhat.com>
16846 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
16847 (gdb_pretty_print_insn): ... this. Now a free function. Add back
16848 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
16849 Adjust to call gdb_print_insn instead of
16850 gdb_disassembler::print_insn.
16851 (dump_insns, do_mixed_source_and_assembly_deprecated)
16852 (do_mixed_source_and_assembly, do_assembly_only): Add back a
16853 'gdbarch' parameter. Remove gdb_disassembler parameter.
16854 (gdb_disassembly): Don't allocate a gdb_disassembler here.
16855 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
16857 (gdb_pretty_print_insn): Re-add declaration.
16858 * record-btrace.c (btrace_insn_history): Don't allocate a
16859 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
16861 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
16863 * disasm.h (gdb_disassembly): Remove file_string parameter.
16864 * disasm.c (gdb_disassembly): Likewise.
16865 * cli/cli-cmds.c (print_disassembly): Adapt.
16866 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
16867 * stack.c (do_gdb_disassembly): Likewise.
16869 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
16871 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
16872 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
16873 targets. And if the implicit value is longer than needed, extract
16874 the first bytes instead of the "least significant" ones.
16876 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16878 * btrace.c (btrace_enable): Do not call btrace_add_pc for
16879 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
16880 (btrace_fetch): Assert can_access_registers_ptid.
16881 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
16882 validate_registers_access.
16884 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16886 * gdbthread.h (can_access_registers_ptid): New.
16887 * thread.c (can_access_registers_ptid): New.
16889 2017-02-01 Pedro Alves <palves@redhat.com>
16891 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
16893 2017-01-31 Pedro Alves <palves@redhat.com>
16895 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
16898 2017-01-31 Pedro Alves <palves@redhat.com>
16900 * stack.c (print_frame_args): Remove local mem_fileopen stream,
16903 2017-01-31 Pedro Alves <palves@redhat.com>
16905 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
16907 2017-01-31 Pedro Alves <palves@redhat.com>
16909 * common/scoped_restore.h
16910 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
16911 change the value's parameter type to T2.
16912 (make_scoped_restore): Likewise.
16914 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16915 Richard Henderson <rth@redhat.com>
16917 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
16918 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
16919 GS_BASE for older kernels.
16920 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
16921 GS_BASE for older kernels.
16922 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
16923 and GS_BASE to the offset table.
16924 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
16925 system register group.
16926 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
16928 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
16930 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
16931 AMD64_GSBASE_REGNUM.
16932 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
16933 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
16934 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
16935 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
16936 i386/64bit-segments.xml in those rules.
16937 * features/i386/64bit-segments.xml: New file.
16938 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
16939 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
16940 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
16941 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
16942 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
16943 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
16944 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
16945 * features/i386/amd64-avx-linux.c: Regenerated.
16946 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
16947 * features/i386/amd64-avx-mpx.c: Regenerated.
16948 * features/i386/amd64-avx512-linux.c: Regenerated.
16949 * features/i386/amd64-linux.c: Regenerated.
16950 * features/i386/amd64-mpx-linux.c: Regenerated.
16951 * features/i386/i386-avx-mpx-linux.c: Regenerated.
16952 * features/i386/i386-avx-mpx.c: Regenerated.
16953 * features/i386/x32-avx-linux.c: Regenerated.
16954 * features/i386/x32-avx512-linux.c: Regenerated.
16955 * regformats/i386/amd64-avx-linux.dat: Regenerated.
16956 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
16957 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
16958 * regformats/i386/amd64-linux.dat: Regenerated.
16959 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
16960 * regformats/i386/x32-avx-linux.dat: Regenerated.
16961 * regformats/i386/x32-avx512-linux.dat: Regenerated.
16962 * regformats/i386/x32-linux.dat: Regenerated.
16964 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16966 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
16967 Set to AMD64_NUM_REGS.
16969 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16971 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
16972 that checks validity of a register number.
16974 2017-01-27 Kees Cook <keescook@google.com>
16976 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
16977 fetch_fpregs if target has fpa registers.
16978 (arm_linux_store_inferior_registers): Call store_fpregs if target
16981 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
16983 * cris-tdep.c (cris_gdbarch_init): Remove check for
16984 info.byte_order and force it to BFD_ENDIAN_LITTLE.
16986 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
16988 * corelow.c (get_core_register_section): Check for regset
16989 existence before checking for REGSET_VARIABLE_SIZE.
16991 2017-01-26 Yao Qi <yao.qi@linaro.org>
16992 Pedro Alves <palves@redhat.com>
16995 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
16996 call memory_error, save memaddr instead.
16997 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
16998 negative, cal memory_error.
16999 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
17001 2017-01-26 Yao Qi <yao.qi@linaro.org>
17003 * disasm-selftests.c (memory_error_test): New function.
17004 (_initialize_disasm_selftests): Register memory_error_test.
17006 2017-01-26 Yao Qi <yao.qi@linaro.org>
17008 * Makefile.in (SFILES): Add disasm-selftests.c and
17010 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
17011 * disasm-selftests.c: New file.
17012 * selftest-arch.c: New file.
17013 * selftest-arch.h: New file.
17015 2017-01-26 Yao Qi <yao.qi@linaro.org>
17017 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
17018 to bfd_arch_mep. Don't return 0 if section is not
17019 found. Call print_insn_mep.
17021 2017-01-26 Pedro Alves <palves@redhat.com>
17022 Yao Qi <yao.qi@linaro.org>
17024 * arm-tdep.c: Include "disasm.h".
17025 (gdb_print_insn_arm): Update code to get gdbarch.
17026 * disasm.c (dis_asm_read_memory): Change it to
17027 gdb_disassembler::dis_asm_read_memory.
17028 (dis_asm_memory_error): Likewise.
17029 (dis_asm_print_address): Likewise.
17030 (gdb_pretty_print_insn): Change it to
17031 gdb_disassembler::pretty_print_insn.
17032 (dump_insns): Add one argument gdb_disassemlber. All
17034 (do_mixed_source_and_assembly_deprecated): Likewise.
17035 (do_mixed_source_and_assembly): Likewise.
17036 (do_assembly_only): Likewise.
17037 (gdb_disassembler::gdb_disassembler): New.
17038 (gdb_disassembler::print_insn): New.
17039 * disasm.h (class gdb_disassembler): New.
17040 (gdb_pretty_print_insn): Remove declaration.
17041 (gdb_disassemble_info): Likewise.
17042 * guile/scm-disasm.c (class gdbscm_disassembler): New.
17043 (gdbscm_disasm_read_memory_worker): Update.
17044 (gdbscm_disasm_read_memory): Update.
17045 (gdbscm_disasm_memory_error): Remove.
17046 (gdbscm_disasm_print_address): Remove.
17047 (gdbscm_disassembler::gdbscm_disassembler): New.
17048 (gdbscm_print_insn_from_port): Update.
17049 * mips-tdep.c: Include disasm.h.
17050 (gdb_print_insn_mips): Update code to get gdbarch.
17051 * record-btrace.c (btrace_insn_history): Update.
17052 * spu-tdep.c: Include disasm.h.
17053 (struct spu_dis_asm_data): Remove.
17054 (struct spu_dis_asm_info): New.
17055 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17057 (gdb_print_insn_spu): Cast disassemble_info to
17060 2017-01-26 Yao Qi <yao.qi@linaro.org>
17062 * disasm.c (do_ui_file_delete): Delete.
17063 (gdb_insn_length): Move code creating stream to ...
17064 * utils.c (null_stream): ... here. New function.
17065 * utils.h (null_stream): Declare.
17067 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17069 * python/py-inferior.c (find_thread_object): Return directly
17070 from the loop. Remove "found" variable.
17072 2017-01-21 Joel Brobecker <brobecker@adacore.com>
17074 GDB 7.12.1 released.
17076 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17078 * python/py-function.c (fnpy_call): Reorder declarations to have
17079 the gdbpy_enter object declared first.
17080 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17082 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17085 * python/python-internal.h (PyMem_RawMalloc): Define for
17087 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17088 PyMem_RawMalloc instead of PyMem_Malloc.
17090 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17091 Luis Machado <lgustavo@codesourcery.com>
17093 * NEWS (New commands): Mention flash-erase.
17094 (New MI commands): Mention target-flash-erase.
17095 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17097 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17098 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17099 * target.c (flash_erase_command): New function.
17100 (initialize_targets): Add new flash-erase command.
17101 * target.h (flash_erase_command): New declaration.
17103 2017-01-20 Joel Brobecker <brobecker@adacore.com>
17105 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17106 HAVE_SYS_PROCFS_H is defined.
17108 2017-01-18 Alan Hayward <alan.hayward@arm.com>
17110 * remote.c (struct cached_reg): Change data into a pointer.
17111 * (stop_reply_dtr): Free data pointers before deleting vector.
17112 (process_stop_reply): Likewise.
17113 (remote_parse_stop_reply): Allocate space for data
17115 2017-01-18 Alan Hayward <alan.hayward@arm.com>
17117 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17119 (amd64_pseudo_register_read_value): Likewise.
17120 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17121 (store_register_using_P): Likewise.
17122 * regcache.c (regcache_xfer_part): Likewise.
17124 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17126 Split real and pseudo registers.
17127 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17128 (sparc32_pseudo_regnum): New enum.
17129 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17130 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17131 (SPARC32_CP0_REGISTERS): New macro.
17132 (sparc32_pseudo_register_name): New function.
17133 (sparc32_register_name): Use sparc32_pseudo_register_name.
17134 (sparc32_pseudo_register_type): New function.
17135 (sparc32_register_type): Use sparc32_pseudo_register_type.
17136 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17137 pseudo register numbers.
17138 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17139 (SPARC64_CP0_REGISTERS): New macro.
17140 (sparc64_pseudo_register_name): New function.
17141 (sparc64_register_name): Use sparc64_pseudo_register_name.
17142 (sparc64_pseudo_register_type): New function.
17143 (sparc64_register_type): Use sparc64_pseudo_register_type.
17144 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17145 pseudo register numbers.
17146 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17147 sparc64_store_arguments): Handle pseudo register numbers.
17149 2017-01-13 Yao Qi <yao.qi@linaro.org>
17151 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17152 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17154 (getpkt_or_notif_sane_1): Likewise.
17156 2017-01-13 Yao Qi <yao.qi@linaro.org>
17158 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17159 of CC. Pass "-x c++-header" instead of "-x c".
17161 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17163 * remote.c (remote_can_async_p): Update comment.
17165 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17167 * linux-nat.c (linux_nat_can_async_p): Update comment.
17169 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17171 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17173 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17175 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17177 2017-01-10 Tom Tromey <tom@tromey.com>
17179 * python/py-type.c (typy_legacy_template_argument): Update.
17180 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17181 ~demangle_parse_info): Declare new members.
17182 (cp_demangled_name_to_comp): Return unique_ptr.
17183 (cp_demangled_name_parse_free)
17184 (make_cleanup_cp_demangled_name_parse_free)
17185 (cp_new_demangle_parse_info): Remove.
17186 * cp-support.c (do_demangled_name_parse_free_cleanup)
17187 (make_cleanup_cp_demangled_name_parse_free): Remove.
17188 (inspect_type, cp_canonicalize_string_full)
17189 (cp_canonicalize_string): Update.
17190 (mangled_name_to_comp): Change return type.
17191 (cp_class_name_from_physname, method_name_from_physname)
17192 (cp_func_name, cp_remove_params): Update.
17193 * cp-name-parser.y (demangle_parse_info): New constructor, from
17194 cp_new_demangle_parse_info.
17195 (~demangle_parse_info): New destructor, from
17196 cp_demangled_name_parse_free.
17197 (cp_merge_demangle_parse_infos): Update.
17198 (cp_demangled_name_to_comp): Change return type.
17200 2017-01-10 Tom Tromey <tom@tromey.com>
17202 * top.c (prevent_dont_repeat): Change return type.
17203 * python/python.c (execute_gdb_command): Use std::string.
17205 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17206 * command.h (prevent_dont_repeat): Change return type.
17207 * breakpoint.c (bpstat_do_actions_1): Update.
17209 2017-01-10 Tom Tromey <tom@tromey.com>
17211 * value.h (scoped_value_mark::~scoped_value_mark): Call
17213 (scoped_value_mark::free_to_mark): New method.
17214 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17217 2017-01-10 Tom Tromey <tom@tromey.com>
17219 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17220 (valpy_reference_value, valpy_const_value, valpy_get_address)
17221 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17222 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17223 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17224 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17226 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17227 * value.h (scoped_value_mark): New class.
17229 2017-01-10 Tom Tromey <tom@tromey.com>
17231 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17232 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17233 * psymtab.c (discard_psymtabs_upto): Remove.
17234 (make_cleanup_discard_psymtabs): Remove.
17235 (struct psymtab_state): Remove.
17237 2017-01-10 Tom Tromey <tom@tromey.com>
17239 * record-full.c (record_full_save_cleanups): Remove.
17240 (record_full_save): Use gdb::unlinker.
17241 * gcore.c (do_bfd_delete_cleanup): Remove.
17242 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17244 * dwarf2read.c (unlink_if_set): Remove.
17245 (write_psymtabs_to_index): Use gdb::unlinker.
17246 * common/gdb_unlinker.h: New file.
17248 2017-01-10 Tom Tromey <tom@tromey.com>
17250 * windows-tdep.c (windows_xfer_shared_library): Update.
17251 * windows-nat.c (windows_make_so): Update.
17252 * utils.h (make_cleanup_bfd_unref): Remove.
17253 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17254 * symfile.h (symfile_bfd_open)
17255 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17256 * symfile.c (read_symbols, symbol_file_add)
17257 (separate_debug_file_exists): Update.
17258 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17259 (generic_load, reread_symbols): Update.
17260 * symfile-mem.c (symbol_file_add_from_memory): Update.
17261 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17262 (spu_symbol_file_add_from_memory): Update.
17263 * solist.h (struct target_so_ops) <bfd_open>: Return
17265 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17266 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17268 (solib_map_sections, reload_shared_libraries_1): Update.
17269 * solib-svr4.c (enable_break): Update.
17270 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17271 * solib-frv.c (enable_break2): Update.
17272 * solib-dsbt.c (enable_break): Update.
17273 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17275 (darwin_solib_get_all_image_info_addr_at_init): Update.
17276 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17277 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17278 * record-full.c (record_full_save): Update.
17279 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17280 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17281 * minidebug.c (find_separate_debug_file_in_section): Return
17283 * machoread.c (macho_add_oso_symfile): Change abfd to
17285 (macho_symfile_read_all_oso): Update.
17286 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17287 (macho_symfile_read): Update.
17288 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17289 (jit_bfd_try_read_symtab): Update.
17290 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17291 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17292 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17294 (gdb_bfd_ref_policy): New struct.
17295 (gdb_bfd_ref_ptr): New typedef.
17296 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17297 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17298 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17300 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17301 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17302 (gcore_command): Update.
17303 * exec.c (exec_file_attach): Update.
17304 * elfread.c (elf_symfile_read): Update.
17305 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17306 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17307 (open_and_init_dwo_file): Update.
17308 (open_dwp_file): Return gdb_bfd_ref_ptr.
17309 (open_and_init_dwp_file): Update.
17310 * corelow.c (core_open): Update.
17311 * compile/compile-object-load.c (compile_object_load): Update.
17312 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17313 * coffread.c (coff_symfile_read): Update.
17314 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17315 gdb_bfd_ref_ptr. Rename.
17316 (dump_bfd_file, restore_command): Update.
17317 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17318 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17319 (find_separate_debug_file_by_buildid): Update.
17321 2017-01-10 Tom Tromey <tom@tromey.com>
17323 * common/gdb_ref_ptr.h: New file.
17324 * python/py-ref.h (struct gdbpy_ref_policy): New.
17325 (gdbpy_ref): Now a typedef.
17327 2017-01-10 Tom Tromey <tom@tromey.com>
17329 * utils.h (make_cleanup_htab_delete): Don't declare.
17330 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17332 * linespec.c (decode_compound_collector): Add constructor,
17334 (lookup_prefix_sym): Remove cleanup.
17335 (symtab_collector): Add constructor, destructor.
17336 (collect_symtabs_from_filename): Remove cleanup.
17337 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17338 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17340 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17341 * dwarf2read.c (dw2_expand_symtabs_matching)
17342 (dw2_map_symbol_filenames, dwarf_decode_macros)
17343 (write_psymtabs_to_index): Use htab_up.
17344 * dwarf2loc.c (func_verify_no_selftailcall)
17345 (call_site_find_chain_1, func_verify_no_selftailcall)
17346 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17347 std::vector, gdb::unique_xmalloc_ptr.
17348 (call_sitep): Remove typedef.
17349 (dwarf2_locexpr_baton_eval): Remove unused variable.
17351 2017-01-10 Tom Tromey <tom@tromey.com>
17353 * python/python-internal.h (make_cleanup_py_decref)
17354 (make_cleanup_py_xdecref): Don't declare.
17355 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17356 (py_xdecref, make_cleanup_py_xdecref): Remove.
17358 2017-01-10 Tom Tromey <tom@tromey.com>
17360 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17361 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17363 2017-01-10 Tom Tromey <tom@tromey.com>
17365 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17367 2017-01-10 Tom Tromey <tom@tromey.com>
17369 * python/py-utils.c (unicode_to_encoded_string)
17370 (python_string_to_target_string)
17371 (python_string_to_target_python_string)
17372 (python_string_to_host_string, gdbpy_obj_to_string)
17373 (get_addr_from_python): Use gdbpy_ref.
17375 2017-01-10 Tom Tromey <tom@tromey.com>
17377 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17380 2017-01-10 Tom Tromey <tom@tromey.com>
17382 * python/python.c (eval_python_command, gdbpy_decode_line)
17383 (gdbpy_run_events, gdbpy_start_type_printers)
17384 (gdbpy_apply_type_printers): Use gdbpy_ref.
17386 2017-01-10 Tom Tromey <tom@tromey.com>
17388 * python/py-param.c (get_doc_string, compute_enum_values): Use
17391 2017-01-10 Tom Tromey <tom@tromey.com>
17393 * python/py-inferior.c (find_thread_object, build_inferior_list):
17396 2017-01-10 Tom Tromey <tom@tromey.com>
17398 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17400 2017-01-10 Tom Tromey <tom@tromey.com>
17402 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
17405 2017-01-10 Tom Tromey <tom@tromey.com>
17407 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
17409 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
17412 2017-01-10 Tom Tromey <tom@tromey.com>
17414 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17417 2017-01-10 Tom Tromey <tom@tromey.com>
17419 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
17420 decref results of PyArg_ParseTupleAndKeywords.
17422 2017-01-10 Tom Tromey <tom@tromey.com>
17424 * python/python.c (python_run_simple_file): Use
17425 unique_xmalloc_ptr, gdbpy_ref.
17427 2017-01-10 Tom Tromey <tom@tromey.com>
17429 * python/py-prettyprint.c (print_stack_unless_memory_error)
17430 (print_string_repr, print_children): Use gdbpy_ref.
17431 (dummy_python_frame): New class.
17432 (dummy_python_frame::dummy_python_frame): Rename from
17433 push_dummy_python_frame.
17434 (py_restore_tstate): Remove.
17436 2017-01-10 Tom Tromey <tom@tromey.com>
17438 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17440 2017-01-10 Tom Tromey <tom@tromey.com>
17442 * python/python.c (ensure_python_env, restore_python_env):
17444 * python/python-internal.h (ensure_python_env): Don't declare.
17445 * varobj.h (varobj_ensure_python_env): Don't declare.
17446 * varobj.c (varobj_ensure_python_env): Remove.
17448 2017-01-10 Tom Tromey <tom@tromey.com>
17450 * varobj.c (varobj_value_get_print_value): Use
17451 gdbpy_enter_varobj.
17453 2017-01-10 Tom Tromey <tom@tromey.com>
17455 * python/py-prettyprint.c (print_string_repr, print_children):
17457 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
17459 * varobj.c (varobj_value_get_print_value): Update.
17460 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
17462 2017-01-10 Tom Tromey <tom@tromey.com>
17464 * varobj.c (varobj_get_display_hint)
17465 (dynamic_varobj_has_child_method, install_new_value_visualizer)
17466 (varobj_set_visualizer, free_variable): Use
17467 gdbpy_enter_varobj.
17469 2017-01-10 Tom Tromey <tom@tromey.com>
17471 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
17472 (do_finish_initialization): New function. Use gdbpy_ref.
17473 (gdbpy_finish_initialization): Use gdbpy_enter. Call
17474 do_finish_initialization.
17476 2017-01-10 Tom Tromey <tom@tromey.com>
17478 * python/py-param.c (get_set_value, get_show_value): Use
17479 gdbpy_enter, gdbpy_ref.
17481 2017-01-10 Tom Tromey <tom@tromey.com>
17483 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
17485 2017-01-10 Tom Tromey <tom@tromey.com>
17487 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
17489 2017-01-10 Tom Tromey <tom@tromey.com>
17491 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
17492 Use gdbpy_enter_varobj.
17494 2017-01-10 Tom Tromey <tom@tromey.com>
17496 * varobj.c (gdbpy_enter_varobj): New constructor.
17497 * python/python-internal.h (gdbpy_enter_varobj): New class.
17498 * python/py-varobj.c (py_varobj_get_iterator): Use
17499 gdbpy_enter_varobj.
17501 2017-01-10 Tom Tromey <tom@tromey.com>
17503 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
17504 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17505 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
17506 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
17507 unique_xmalloc_ptr.
17508 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
17510 2017-01-10 Tom Tromey <tom@tromey.com>
17512 * python/py-xmethods.c (invoke_match_method): Use
17515 2017-01-10 Tom Tromey <tom@tromey.com>
17517 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
17518 gdbpy_enter, gdbpy_ref.
17520 2017-01-10 Tom Tromey <tom@tromey.com>
17522 * python/python.c (python_interactive_command): Use gdbpy_enter.
17524 2017-01-10 Tom Tromey <tom@tromey.com>
17526 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
17529 2017-01-10 Tom Tromey <tom@tromey.com>
17531 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
17532 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17534 2017-01-10 Tom Tromey <tom@tromey.com>
17536 * utils.h (htab_deleter): New struct.
17537 (htab_up): New typedef.
17538 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
17539 gdbpy_enter, gdbpy_ref, htab_up.
17541 2017-01-10 Tom Tromey <tom@tromey.com>
17543 * python/py-unwind.c (pending_frame_invalidate): Remove.
17544 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
17546 2017-01-10 Tom Tromey <tom@tromey.com>
17548 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
17549 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
17551 2017-01-10 Tom Tromey <tom@tromey.com>
17553 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
17555 2017-01-10 Tom Tromey <tom@tromey.com>
17557 * python/python.c (gdbpy_eval_from_control_command)
17558 (gdbpy_source_script, gdbpy_run_events)
17559 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
17560 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
17563 2017-01-10 Tom Tromey <tom@tromey.com>
17565 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
17567 2017-01-10 Tom Tromey <tom@tromey.com>
17569 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
17571 2017-01-10 Tom Tromey <tom@tromey.com>
17573 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
17574 (python_on_inferior_call_pre, python_on_inferior_call_post)
17575 (python_on_memory_change, python_on_register_change)
17576 (python_inferior_exit, python_new_objfile, add_thread_object)
17577 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
17579 2017-01-10 Tom Tromey <tom@tromey.com>
17581 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
17582 (bpfinishpy_handle_exit): Use gdbpy_enter.
17584 2017-01-10 Tom Tromey <tom@tromey.com>
17586 * python/py-cmd.c (cmdpy_destroyer)
17587 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
17590 2017-01-10 Tom Tromey <tom@tromey.com>
17592 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17594 (gdbpy_breakpoint_has_cond): Likewise.
17596 2017-01-10 Tom Tromey <tom@tromey.com>
17598 * python/python.c (gdbpy_enter): New constructor.
17599 (~gdbpy_enter): New destructor.
17600 (restore_python_env, ensure_python_env): Rewrite.
17601 * python/python-internal.h (gdbpy_enter): New class.
17603 2017-01-10 Tom Tromey <tom@tromey.com>
17605 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
17607 2017-01-10 Tom Tromey <tom@tromey.com>
17609 * python/py-value.c (value_has_field, get_field_flag)
17610 (get_field_type, valpy_getitem, convert_value_from_python): Use
17613 2017-01-10 Tom Tromey <tom@tromey.com>
17615 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
17618 2017-01-10 Tom Tromey <tom@tromey.com>
17620 * python/py-prettyprint.c (search_pp_list)
17621 (find_pretty_printer_from_objfiles)
17622 (find_pretty_printer_from_progspace)
17623 (find_pretty_printer_from_gdb, find_pretty_printer)
17624 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
17627 2017-01-10 Tom Tromey <tom@tromey.com>
17629 * python/py-param.c (call_doc_function): Use gdbpy_ref.
17631 2017-01-10 Tom Tromey <tom@tromey.com>
17633 * python/py-linetable.c (build_line_table_tuple_from_pcs)
17634 (ltpy_get_all_source_lines): Use gdbpy_ref.
17636 2017-01-10 Tom Tromey <tom@tromey.com>
17638 * python/py-framefilter.c (extract_sym, extract_value)
17639 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
17642 2017-01-10 Tom Tromey <tom@tromey.com>
17644 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
17646 2017-01-10 Tom Tromey <tom@tromey.com>
17648 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
17650 2017-01-10 Tom Tromey <tom@tromey.com>
17652 * python/py-function.c (convert_values_to_python, fnpy_init): Use
17655 2017-01-10 Tom Tromey <tom@tromey.com>
17657 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
17659 2017-01-10 Tom Tromey <tom@tromey.com>
17661 * python/py-type.c (convert_field, make_fielditem, typy_fields)
17662 (typy_range): Use gdbpy_ref.
17664 2017-01-10 Tom Tromey <tom@tromey.com>
17666 * python/py-threadevent.c (create_thread_event_object): Use
17668 * python/py-stopevent.c (create_stop_event_object): Simplify.
17669 (emit_stop_event): Use gdbpy_ref.
17670 * python/py-signalevent.c (create_signal_event_object): Use
17672 * python/py-newobjfileevent.c (create_new_objfile_event_object)
17673 (emit_new_objfile_event, create_clear_objfiles_event_object)
17674 (emit_clear_objfiles_event): Use gdbpy_ref.
17675 * python/py-infevents.c (create_inferior_call_event_object)
17676 (create_register_changed_event_object)
17677 (create_memory_changed_event_object, emit_inferior_call_event)
17678 (emit_memory_changed_event, emit_register_changed_event): Use
17680 * python/py-exitedevent.c (create_exited_event_object)
17681 (emit_exited_event): Use gdbpy_ref.
17682 * python/py-event.h (evpy_emit_event): Remove
17683 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
17684 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
17685 * python/py-continueevent.c (emit_continue_event): Use
17687 * python/py-breakpoint.c (gdbpy_breakpoint_created)
17688 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
17690 * python/py-bpevent.c (create_breakpoint_event_object): Use
17693 2017-01-10 Tom Tromey <tom@tromey.com>
17695 * python/py-ref.h: New file.
17697 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17699 * cli-out.c (cli_ui_out::do_redirect): Change return type to
17701 * cli-out.h (cli_ui_out::do_redirect): Likewise.
17702 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
17703 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
17704 * ui-out.c (ui_out::redirect): Likewise.
17705 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
17706 * cli/cli-logging.c (set_logging_redirect): Update call site of
17708 (handle_redirections): Likewise.
17709 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
17710 * top.c (execute_command_to_string): Likewise.
17711 * utils.c (do_ui_out_redirect_pop): Likewise.
17713 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17715 * stack.c (_initialize_stack): Update "frame" command help message.
17717 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
17719 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
17721 2017-01-06 Yao Qi <yao.qi@linaro.org>
17723 * x86-linux-nat.h: Include gdb_proc_service.h.
17725 2017-01-06 Yao Qi <yao.qi@linaro.org>
17727 * ser-base.h: Include serial.h.
17729 2017-01-06 Yao Qi <yao.qi@linaro.org>
17731 * ppc-linux-tdep.h: Include ppc-tdep.h.
17733 2017-01-06 Yao Qi <yao.qi@linaro.org>
17735 * nat/amd64-linux-siginfo.h: Include signal.h.
17737 2017-01-06 Yao Qi <yao.qi@linaro.org>
17739 * nat/aarch64-linux-hw-point.h: Include break-common.h.
17741 2017-01-06 Yao Qi <yao.qi@linaro.org>
17743 * mi/mi-parse.h: Include mi-cmds.h.
17745 2017-01-06 Yao Qi <yao.qi@linaro.org>
17747 * inf-loop.c: Don't include "target.h".
17748 * inf-loop.h: Include it here.
17750 2017-01-06 Yao Qi <yao.qi@linaro.org>
17752 * dfp.h: Include "dboulest.h" and "expression.h".
17754 2017-01-06 Yao Qi <yao.qi@linaro.org>
17756 * ax-gdb.h: Include "ax.h".
17758 2017-01-06 Yao Qi <yao.qi@linaro.org>
17760 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
17761 with nat/gdb_ptrace.h.
17763 2017-01-05 Yao Qi <yao.qi@linaro.org>
17765 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
17767 (mips64_fbsd_sigframe_init): Likewise.
17769 2017-01-04 John Baldwin <jhb@FreeBSD.org>
17771 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
17772 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
17774 2017-01-04 John Baldwin <jhb@FreeBSD.org>
17776 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
17777 * NEWS: Mention new FreeBSD/mips native configuration.
17778 * config/mips/fbsd.mh: New file.
17779 * configure.host: Add mips*-*-freebsd*.
17780 * mips-fbsd-nat.c: New file.
17782 2017-01-04 John Baldwin <jhb@FreeBSD.org>
17784 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
17785 (ALLDEPFILES): Add mips-fbsd-tdep.c.
17786 * NEWS: Mention new FreeBSD/mips target.
17787 * configure.tgt: Add mips*-*-freebsd*.
17788 * mips-fbsd-tdep.c: New file.
17789 * mips-fbsd-tdep.h: New file.
17791 2017-01-04 Yao Qi <yao.qi@linaro.org>
17793 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
17794 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
17796 2017-01-01 Joel Brobecker <brobecker@adacore.com>
17798 Update copyright year range in all GDB files.
17800 2017-01-01 Joel Brobecker <brobecker@adacore.com>
17802 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
17804 For older changes see ChangeLog-2016.
17810 version-control: never