X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2FChangeLog;h=e90fbc0adfd76ce6ec6fbdce529f2c759f7da2f3;hb=a379284af268ed768674e7f452ca78dad2aaaf55;hp=710b181578e8b2a660fdfd7a66091207dddf1221;hpb=be85ce7dcbe99a8e7cd847a0c5b449a0b18a8ce7;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 710b181578..e90fbc0adf 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,1358 @@ +2017-03-14 Andreas Arnez + + * linux-nat.c (linux_proc_xfer_partial): Handle write operations + as well. + +2017-03-14 Pedro Alves + + * cp-name-parser.y (cp_demangled_name_to_comp): Update comment. + (main): Use std::unique_ptr. Remove calls to + cp_demangled_name_parse_free. + +2017-03-13 Simon Marchi + + * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers, + alphabsd_store_inferior_registers): Use regcache->ptid instead + of inferior_ptid. + +2017-03-13 Simon Marchi + + * aix-thread.c (aix_thread_fetch_registers, + aix_thread_store_registers): Use regcache->ptid instead of + inferior_ptid. + +2017-03-13 Simon Marchi + + * aarch64-linux-nat.c (fetch_gregs_from_thread, + store_gregs_to_thread, fetch_fpregs_from_thread, + store_fpregs_to_thread): Use regcache->ptid instead of + inferior_ptid. + +2017-03-13 Simon Marchi + + * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers, + amd64_linux_fetch_inferior_registers): Use regcache->ptid + instead of inferior_ptid. + +2017-03-13 Simon Marchi + + * target.c (target_fetch_registers, target_store_registers): Add + assert. + +2017-03-13 Simon Marchi + + * regcache.h (regcache_get_ptid): New function. + * regcache.c (regcache_get_ptid): New function. + +2017-03-13 Mark Wielaard + + * cp-name-parser.y (make_empty): Initialize d_printing to zero. + +2017-03-10 Keith Seitz + + PR c++/8218 + * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments. + +2017-03-08 Pedro Alves + + PR gdb/18360 + * infrun.c (start_step_over, do_target_resume, resume) + (restart_threads): Assert we're not resuming a thread that is + meant to be stopped. + (infrun_thread_stop_requested_callback): Delete. + (infrun_thread_stop_requested): If the thread is internally + stopped, queue a pending stop event and clear the thread's + inline-frame state. + (handle_stop_requested): New function. + (handle_syscall_event, handle_inferior_event_1): Use + handle_stop_requested. + (handle_stop_requested): New function. + (handle_signal_stop): Set the thread's stop_signal here instead of + at caller. + (finish_step_over): Clear step over info unconditionally. + (handle_signal_stop): If the user had interrupted the event + thread, consider the stop a random signal. + (handle_signal_stop) : Don't restart threads here. + (stop_waiting): Don't clear step-over info here. + +2017-03-08 Pedro Alves + + PR 21206 + * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull + goes to argument 2, not 1. + +2017-03-08 Pedro Alves + + PR cli/21218 + * top.c (gdb_readline_wrapper): Avoid passing NULL to + display_gdb_prompt. + (command_line_input): Add comment. + +2017-03-08 Pedro Alves + + PR tui/21216 + * tui/tui-file.c (tui_file::write): New. + * tui/tui-file.h (tui_file): Override "write". + * tui/tui-io.c (do_tui_putc, update_start_line): New functions, + factored out from ... + (tui_puts): ... here. + (tui_putc): Use them. + (tui_write): New function. + * tui/tui-io.h (tui_write): Declare. + +2017-03-07 Sergio Durigan Junior + + * Makefile.in (SFILES): Replace "environ.c" with + "common/environ.c". + (HFILES_NO_SRCDIR): Likewise, for "environ.h". + * environ.c: Include "common-defs.h" instead of "defs.h. Moved + to... + * common/environ.c: ... here. + * environ.h: Moved to... + * common/environ.h: ... here. + +2017-03-07 Peter Bergner + + * gdbarch.sh (pstring_ptr): New static function. + (gdbarch_disassembler_options): Use it. + (gdbarch_verify_disassembler_options): Print valid_disassembler_options, + not valid_disassembler_option->name. + * gdbarch.c: Regenerate. + +2017-03-07 Peter Bergner + + * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete. + +2017-03-07 Pedro Alves + + * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout. + +2017-03-07 Walfred Tedeschi + + * i387-tdep.h (i387_reset_bnd_regs): Add function definition. + * i387-tdep.c (i387_reset_bnd_regs): Add function implementation. + * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs. + * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs. + +2017-03-06 Simon Marchi + + * xtensa-linux-nat.c (fetch_gregs): Remove const. + +2017-03-03 Simon Marchi + + * remote.c (remote_add_target_side_commands): Use range-based + for loop. + +2017-03-03 Yao Qi + + PR gdb/21165 + * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if + value is lazy. + * valprint.c (common_val_print): Likewise. + +2017-02-28 Peter Bergner + + * NEWS: Mention new set/show disassembler-options commands. + * doc/gdb.texinfo: Document new set/show disassembler-options commands. + * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h". + (prospective_options): New static variable. + (gdb_disassembler::gdb_disassembler): Initialize + m_di.disassembler_options. + (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options. + (get_disassembler_options): New function. + (set_disassembler_options): Likewise. + (set_disassembler_options_sfunc): Likewise. + (show_disassembler_options_sfunc): Likewise. + (disassembler_options_completer): Likewise. + (_initialize_disasm): Likewise. + * disasm.h (get_disassembler_options): New prototype. + (set_disassembler_options): Likewise. + * gdbarch.sh (gdbarch_disassembler_options): New variable. + (gdbarch_verify_disassembler_options): Likewise. + * gdbarch.c: Regenerate. + * gdbarch.h: Likewise. + * arm-tdep.c (num_disassembly_options): Delete. + (set_disassembly_style): Likewise. + (arm_disassembler_options): New static variable. + (set_disassembly_style_sfunc): Convert short style name into long + option name. Call set_disassembler_options. + (show_disassembly_style_sfunc): New function. + (arm_gdbarch_init): Call set_gdbarch_disassembler_options and + set_gdbarch_verify_disassembler_options. + (_initialize_arm_tdep): Delete regnames variable and update callers. + (arm_disassembler_options): Initialize. + (disasm_options): New variable. + (num_disassembly_options): Rename from this... + (num_disassembly_styles): ...to this. Compute by scanning through + disasm_options. + (valid_disassembly_styles): Initialize using disasm_options. + Remove calls to parse_arm_disassembler_option, get_arm_regnames and + set_arm_regname_option. + Pass show_disassembly_style_sfunc to the "disassembler" setshow command. + * rs6000-tdep.c (powerpc_disassembler_options): New static variable. + (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and + set_gdbarch_verify_disassembler_options. + * s390-tdep.c (s390_disassembler_options): New static variable. + (s390_gdbarch_init):all set_gdbarch_disassembler_options and + set_gdbarch_verify_disassembler_options. + +2017-02-27 Simon Marchi + + * remote.c (remote_add_target_side_condition): Remove "struct" + keyword from range-based for loop. + +2017-02-27 Simon Marchi + + * remote.c (remote_add_target_side_condition): Use range-based + for loop. Update comment. + +2017-02-27 Yao Qi + + * f-typeprint.c (f_print_type): Check "varstring" is empty first. + +2017-02-26 Alan Hayward + + * regcache.c (regcache_raw_update): New function. + (regcache_raw_read): Move code to regcache_raw_update. + * regcache.h (regcache_raw_update): New declaration. + * remote.c (remote_prepare_to_store): Call regcache_raw_update. + +2017-02-26 Jan Kratochvil + + * dwarf2read.c (create_debug_type_hash_table): Initialize + header.signature and header.type_offset_in_tu. + +2017-02-24 Pedro Alves + + * symtab.c (make_file_symbol_completion_list_1): Use + add_symtab_completions. + +2017-02-24 Alan Hayward + + * stack.c (frame_info): Use frame_unwind_register_value to avoid buf. + +2017-02-24 Alan Hayward + + * i386-tdep.c (i386_pseudo_register_read_into_value): Use + I386_MAX_REGISTER_SIZE. + (i386_pseudo_register_write): Likewise. + (i386_process_record): Likewise. + * i387-tdep.c (i387_supply_xsave): Likewise. + * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE. + (store_register): Likewise. + +2017-02-23 Pedro Alves + + * ada-lang.c: Include "common/function-view.h". + (ada_iterate_over_symbols): Adjust to use function_view as + callback type. + (struct add_partial_datum, ada_complete_symbol_matcher): Delete. + (ada_make_symbol_completion_list): Use a lambda. + (ada_exc_search_name_matches): Delete. + (name_matches_regex): New. + (ada_add_global_exceptions): Use a lambda and name_matches_regex. + * compile/compile-c-support.c: Include "common/function-view.h". + (print_one_macro): Change prototype to accept a ui_file pointer. + (write_macro_definitions): Use a lambda. + * dwarf2read.c: Include "common/function-view.h". + (dw2_map_expand_apply, dw2_map_symtabs_matching_filename) + (dw2_expand_symtabs_matching): Adjust to use function_view as + callback type. + * language.h: Include "common/function-view.h". + (struct language_defn) : Adjust to use + function_view as callback type. + (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter. + * linespec.c: Include "common/function-view.h". + (collect_info::add_symbol): New method. + (struct symbol_and_data_callback, iterate_inline_only, struct + symbol_matcher_data, iterate_name_matcher): Delete. + (iterate_over_all_matching_symtabs): Adjust to use function_view + as callback type and lambdas. + (iterate_over_file_blocks): Adjust to use function_view as + callback type. + (decode_compound_collector): Now a class with private fields. + (decode_compound_collector::release_symbols): New method. + (collect_one_symbol): Rename to... + (decode_compound_collector::operator()): ... this and adjust. + (lookup_prefix_sym): decode_compound_collector construction bits + move to decode_compound_collector ctor. Pass the + decode_compound_collector object directly as callback. Remove + cleanups and use decode_compound_collector::release_symbols + instead. + (symtab_collector): Now a class with private fields. + (symtab_collector::release_symtabs): New method. + (add_symtabs_to_list): Rename to... + (symtab_collector::operator()): ... this and adjust. + (collect_symtabs_from_filename): symtab_collector construction + bits move to symtab_collector ctor. Pass the symtab_collector + object directly as callback. Remove cleanups and use + symtab_collector::release_symtabs instead. + (collect_symbols): Delete. + (add_matching_symbols_to_info): Use lambdas. + * macrocmd.c (print_macro_callback): Delete. + (info_macro_command): Use a lambda. + (info_macros_command): Pass print_macro_definition as callable + directly. + (print_one_macro): Remove 'ignore' parameter. + (macro_list_command): Adjust. + * macrotab.c (macro_for_each_data::fn): Now a function_view. + (macro_for_each_data::user_data): Delete field. + (foreach_macro): Adjust to call the function_view. + (macro_for_each): Adjust to use function_view as callback type. + (foreach_macro_in_scope): Adjust to call the function_view. + (macro_for_each_in_scope): Adjust to use function_view as callback + type. + * macrotab.h: Include "common/function-view.h". + (macro_callback_fn): Declare a prototype instead of a pointer. + Remove "user_data" parameter. + (macro_for_each, macro_for_each_in_scope): Adjust to use + function_view as callback type. + * psymtab.c (partial_map_expand_apply) + (psym_map_symtabs_matching_filename, recursively_search_psymtabs): + Adjust to use function_view as callback type and to return bool. + (psym_expand_symtabs_matching): Adjust to use function_view as + callback types. + * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust + to use function_view as callback type and to return bool. + (debug_qf_expand_symtabs_matching): Adjust to use function_view as + callback types. + * symfile.c (expand_symtabs_matching): Adjust to use function_view + as callback types. + * symfile.h: Include "common/function-view.h". + (expand_symtabs_file_matcher_ftype) + (expand_symtabs_symbol_matcher_ftype) + (expand_symtabs_exp_notify_ftype): Remove "data" parameter and + return bool. + (quick_symbol_functions::map_symtabs_matching_filename) + (quick_symbol_functions::expand_symtabs_matching): Adjust to use + function_view as callback type and return bool. + (expand_symtabs_matching): Adjust to use function_view as callback + type. + (maintenance_expand_name_matcher) + (maintenance_expand_file_matcher): Delete. + (maintenance_expand_symtabs): Use lambdas. + * symtab.c (iterate_over_some_symtabs): Adjust to use + function_view as callback types and return bool. + (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead + of a cleanup. + (lookup_symtab_callback): Delete. + (lookup_symtab): Use a lambda. + (iterate_over_symbols): Adjust to use function_view as callback + type. + (struct search_symbols_data, search_symbols_file_matches) + (search_symbols_name_matches): Delete. + (search_symbols): Use a pair of lambdas. + (struct add_name_data, add_macro_name, symbol_completion_matcher) + (symtab_expansion_callback): Delete. + (default_make_symbol_completion_list_break_on_1): Use lambdas. + * symtab.h: Include "common/function-view.h". + (iterate_over_some_symtabs): Adjust to use function_view as + callback type and return bool. + (iterate_over_symtabs): Adjust to use function_view as callback + type. + (symbol_found_callback_ftype): Remove 'data' parameter and return + bool. + (iterate_over_symbols): Adjust to use function_view as callback + type. + +2017-02-23 Pedro Alves + + * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New. + (%.o) : New pattern. + * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to + CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS. + * common/function-view.h: New file. + * unittests/function-view-selftests.c: New file. + * configure: Regenerate. + +2017-02-23 Simon Marchi + + * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of + inferior_ptid. + * go32-nat.c (go32_thread_alive): Likewise. + +2017-02-23 Yao Qi + + * varobj-iter.h (varobj_iter_delete): Call xfree instead of + delete. + +2017-02-23 Yao Qi + + * varobj.c (varobj_clear_saved_item): Use delete instead of + xfree. + (update_dynamic_varobj_children): Likewise. + +2017-02-21 Jan Kratochvil + + * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR. + +2017-02-21 Simon Marchi + + * common/enum-flags.h (enum_flags::enum_flags): Initialize + m_enum_value to 0 in default constructor. + +2017-02-21 Edjunior Barbosa Machado + + * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK. + (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK. + (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION, + STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines. + (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros. + (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN. + (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and + IS_STORE_CONDITIONAL_INSN. + +2017-02-21 Jan Kratochvil + + * dwarf2_rnglists_process: Initialize range_beginning and range_end. + +2017-02-20 Jan Kratochvil + + * NEWS (Changes since GDB 7.12): Add DWARF-5. + +2017-02-20 Jan Kratochvil + + * dwarf2read.c (skip_one_die, read_attribute_value) + (dwarf2_const_value_attr, dump_die_shallow) + (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes) + (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16. + +2017-02-20 Jan Kratochvil + + * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*. + (dwarf_parse_macro_header): Accept DWARF version 5. + (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*. + +2017-02-20 Jan Kratochvil + + * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and + DW_AT_GNU_*. + * common/common-exceptions.h (enum errors): Likewise. + * dwarf2-frame.c (class dwarf_expr_executor): Likewise. + * dwarf2expr.c (dwarf_block_to_dwarf_reg) + (dwarf_expr_context::execute_stack_op): Likewise. + * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece): + Likewise. + * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type) + (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value) + (show_entry_values_debug, call_site_to_target_addr) + (func_addr_to_tail_call_list, func_verify_no_selftailcall) + (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value) + (entry_data_value_free_closure, value_of_dwarf_reg_entry) + (value_of_dwarf_block_entry, indirect_pieced_value) + (symbol_needs_eval_context::push_dwarf_reg_entry_value): + (disassemble_dwarf_expression): Likewise. + * dwarf2read.c (process_die, inherit_abstract_dies) + (read_call_site_scope): Likewise. + * gdbtypes.h (struct func_type, struct call_site_parameter) + (struct call_site): Likewise. + * stack.c (read_frame_arg): Likewise. + * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise. + +2017-02-20 Jan Kratochvil + + * defs.h (read_unsigned_leb128): New declaration. + * dwarf2loc.c (decode_debug_loclists_addresses): New function. + (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*. + (dwarf2_find_location_expression): Call also + decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length. + * dwarf2loc.h (dwarf2_version): New declaration. + * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str, + rnglists. + (dwarf2_elf_names): Add .debug_loclists, .debug_line_str, + .debug_rnglists. + (struct dwop_section_names): Add loclists_dwo. + (dwop_section_names): Add .debug_loclists.dwo. + (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu. + (struct dwarf2_per_cu_data): Add dwarf_version. + (struct dwo_sections): Add loclists. + (struct attr_abbrev): Add implicit_const. + (read_indirect_line_string): New declaration. + (read_unsigned_leb128): Delete declaration. + (rcuh_kind): New definition. + (read_and_check_comp_unit_head): Change parameter + is_debug_types_section to section_kind. + (dwarf2_locate_sections): Handle loclists, line_str and rnglists. + (read_comp_unit_head): Change parameter abfd to section, add parameter + section_kind. Handle DWARF-5. + (error_check_comp_unit_head): Accept also DWARF version 5. + (read_and_check_comp_unit_head): Change parameter + is_debug_types_section to section_kind. + (read_and_check_type_unit_head): Delete function. + (read_abbrev_offset): Handle DWARF-5. + (create_debug_type_hash_table): Add parameter section_kind. Process + only DW_UT_type. Use signature and type_offset_in_tu from struct + comp_unit_head. + (create_debug_types_hash_table): Update create_debug_type_hash_table + caller. + (create_all_type_units): Call create_debug_type_hash_table. + (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change + read_and_check_type_unit_head caller to read_and_check_comp_unit_head + caller. + (skip_one_die): Handle DW_FORM_implicit_const. + (dwarf2_rnglists_process): New function. + (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5. + (abbrev_table_read_table): Handle DW_FORM_implicit_const. + (read_attribute_value): Handle DW_FORM_implicit_const, + DW_FORM_line_strp. + (read_attribute): Handle DW_FORM_implicit_const. + (read_indirect_string_at_offset_from): New function from + read_indirect_string_at_offset. + (read_indirect_string_at_offset): Call + read_indirect_string_at_offset_from. + (read_indirect_line_string_at_offset): New function. + (read_indirect_string): New function comment. + (read_indirect_line_string): New function. + (read_unsigned_leb128): Make it global. + (dwarf2_string_attr): Handle DWARF-5. + (add_include_dir_stub, read_formatted_entries): New functions. + (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section): + Handle DWARF-5. + (per_cu_header_read_in): Update read_comp_unit_head caller. + (dwarf2_version): New function. + * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and + rnglists. + * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections + fields. + +2017-02-20 Jan Kratochvil + + * dwarf2read.c (abbrev_table_read_table): Read the data only once. + +2017-02-20 Jan Kratochvil + + * dwarf2read.c (dwarf2_ranges_process): New function from + dwarf2_ranges_read. + (dwarf2_ranges_read, dwarf2_record_block_ranges): Use + dwarf2_ranges_process. + +2017-02-20 Jan Kratochvil + + * dwarf2read.c (create_debug_type_hash_table): New function from + create_debug_types_hash_table. + (create_debug_types_hash_table): Call create_debug_type_hash_table. + (create_all_type_units, open_and_init_dwo_file): Update + create_debug_types_hash_table callers. + +2017-02-20 Sergio Durigan Junior + + PR gdb/16188 + * fork-child.c (trace_start_error): Fix thinko. va_end should + refer to 'ap', not 'args'. + +2017-02-20 Sergio Durigan Junior + Pedro Alves + + PR gdb/16188 + * darwin-nat.c (darwin_ptrace_me): Check if calls to system + calls succeeded. + * fork-child.c (trace_start_error): New function. + (trace_start_error_with_name): Likewise. + * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded. + * inf-ptrace.c (inf_ptrace_me): Likewise. + * inferior.h (trace_start_error): New prototype. + (trace_start_error_with_name): Likewise. + +2017-02-15 Sergio Durigan Junior + + PR gdb/21164 + * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not + NULL before using it. + * symmisc.c (maintenance_print_symbols): Likewise. + (maintenance_print_msymbols): Likewise. + +2017-02-14 Tim Wiederhake + + * NEWS: Add record Python bindings entry. + +2017-02-14 Tim Wiederhake + + * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o, + py-record-full.o. + (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c. + * python/py-record-btrace.c, python/py-record-btrace.h, + python/py-record-full.c, python/py-record-full.h: New file. + * python/py-record.c: Add include for py-record-btrace.h and + py-record-full.h. + (recpy_method, recpy_format, recpy_goto, recpy_replay_position, + recpy_instruction_history, recpy_function_call_history, recpy_begin, + recpy_end): Use functions from py-record-btrace.c and py-record-full.c. + * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t): + New definition. + (gdbpy_initialize_btrace): New export. + * python/python.c (_initialize_python): Add gdbpy_initialize_btrace. + +2017-02-14 Tim Wiederhake + + * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o. + (SUBDIR_PYTHON_SRCS): Add python/py-record.c. + * python/py-record.c: New file. + * python/python-internal.h (gdbpy_start_recording, + gdbpy_current_recording, gdpy_stop_recording, + gdbpy_initialize_record): New export. + * python/python.c (_initialize_python): Add gdbpy_initialize_record. + (python_GdbMethods): Add gdbpy_start_recording, + gdbpy_current_recording and gdbpy_stop_recording. + +2017-02-14 Tim Wiederhake + + * record-btrace.c (record_btrace_record_method): New function. + (init_record_btrace_ops): Initialize to_record_method. + * record-full.c (record_full_record_method): New function. + (init_record_full_ops, init_record_full_core_ops): Add + record_full_record_method. + * record.h (enum record_method): New enum. + * target-debug.h (target_debug_print_enum_record_method: New define. + * target-delegates.c: Regenerate. + * target.c (target_record_method): New function. + * target.h: Include record.h. + (struct target_ops) : New field. + (target_record_method): New export. + +2017-02-14 Tim Wiederhake + + * record.h (record_start, record_stop): New export. + * record.c (record_start, record_stop): New function. + +2017-02-14 Tim Wiederhake + + * btrace.c (btrace_fetch): Copy function call segments pointer + into a vector. + (btrace_clear): Clear the vector. + (btrace_find_insn_by_number): Use binary search to find the correct + function call segment. + * btrace.h (brace_fun_p): New typedef. + (struct btrace_thread_info) : New field. + +2017-02-14 Tim Wiederhake + + * record-btrace.c (btrace_ui_out_decode_error): Move most of it ... + * btrace.c (btrace_decode_error): ... here. New function. + * btrace.h (btrace_decode_error): New export. + +2017-02-14 Tim Wiederhake + + * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function. + (ftrace_new_function, btrace_insn_number, btrace_insn_cmp, + btrace_find_insn_by_number): Remove special case for gaps. + * btrace.h (btrace_insn_get_error): New export. + (btrace_insn_number, btrace_find_insn_by_number): Adjust comment. + * record-btrace.c (btrace_insn_history): Print number for gaps. + (record_btrace_info, record_btrace_goto): Handle gaps. + +2017-02-14 Tom Tromey + + PR python/13598: + * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt + event. + * python/py-evts.c (gdbpy_initialize_py_events): Add + before_prompt registry. + * python/py-events.h (events_object) : New field. + +2017-02-14 Markus Metzger + + * btrace.c (ftrace_new_switch): Preserve up link and flags. + +2017-02-13 Luis Machado + + * symfile (_initialize_symfile): Add usage text to the load command's + help text. + +2017-02-10 Simon Marchi + + * utils.c (defaulted_query): Don't query on secondary UIs. + +2017-02-10 Tom Tromey + + * rust-lang.c (rust_get_disr_info): Remove unused variable. + +2017-02-10 Tom Tromey + + * python/py-value.c (valpy_richcompare_throw): Remove unnecessary + "cleanup" local. + * python/py-type.c (typy_legacy_template_argument): Remove + unnecessary "cleanup" local. + +2017-02-10 Tom Tromey + + * python/python.c (do_start_initialization): New function, from + _initialize_python. + (_initialize_python): Call do_start_initialization. + * python/py-linetable.c (ltpy_iternext): Use explicit returns, not + goto. + +2017-02-10 Tom Tromey + + * python/py-prettyprint.c (pretty_print_one_value): Use + gdbpy_ref. + +2017-02-10 Tom Tromey + + * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref. + * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use + gdbpy_ref. + * python/py-type.c (field_new): Use gdbpy_ref. + * python/py-symtab.c (symtab_and_line_to_sal_object): Use + gdbpy_ref. + * python/py-progspace.c (pspy_new): Use gdbpy_ref. + (py_free_pspace): Likewise. + (pspace_to_pspace_object): Likewise. + * python/py-objfile.c (objfpy_new): Use gdbpy_ref. + (py_free_objfile): Likewise. + (objfile_to_objfile_object): Likewise. + * python/py-inferior.c (delete_thread_object): Use + gdbpy_ref. + (infpy_read_memory): Likewise. + (py_free_inferior): Likewise. + * python/py-evtregistry.c (create_eventregistry_object): Use + gdbpy_ref. + * python/py-event.c (create_event_object): Use gdbpy_ref. + +2017-02-10 Tom Tromey + + * python/py-ref.h (gdbpy_ref_policy): Now a template. + (gdbpy_ref): Now a template; allow subclasses of PyObject to be + used. + * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c, + python/py-cmd.c, python/py-continueevent.c, python/py-event.c, + python/py-exitedevent.c, python/py-finishbreakpoint.c, + python/py-framefilter.c, python/py-function.c, + python/py-inferior.c, python/py-infevents.c, + python/py-linetable.c, python/py-newobjfileevent.c, + python/py-param.c, python/py-prettyprint.c, python/py-ref.h, + python/py-signalevent.c, python/py-stopevent.c, + python/py-symbol.c, python/py-threadevent.c, python/py-type.c, + python/py-unwind.c, python/py-utils.c, python/py-value.c, + python/py-varobj.c, python/py-xmethods.c, python/python.c, + varobj.c: Change gdbpy_ref to gdbpy_ref<>. + +2017-02-10 Tom Tromey + + * ui-out.h (ui_out_emit_type): New class. + (ui_out_emit_tuple, ui_out_emit_list): New typedefs. + * python/py-framefilter.c (py_print_single_arg): Use gdb::optional + and ui_out_emit_tuple. + (enumerate_locals): Likewise. + (py_mi_print_variables, py_print_locals, py_print_args): Use + ui_out_emit_list. + (py_print_frame): Use gdb::optional, ui_out_emit_tuple, + ui_out_emit_list. + * common/gdb_optional.h: New file. + +2017-02-10 Martin Galvan + + * MAINTAINERS (Write After Approval): Update my e-mail address. + +2017-02-10 Martin Galvan + + PR gdb/21122 + * breakpoint.c (_initialize_breakpoint): Update the help description + of the 'commands' command to indicate that it takes a list argument. + +2017-02-09 Simon Marchi + + * interps.c (current_interp_set_logging): Remove "return". + +2017-02-09 Gary Benson + + * symtab.c (add_symtab_completions): Prevent NULL pointer + dereference. + +2017-02-08 Pedro Alves + + * interps.c (interp::interp): Remove reference to quiet_p. + (interp_set): Make static. Remove dead "Switching to" output + code. + (interp_quiet_p, interp_set_quiet): Delete. + (interpreter_exec_cmd): Don't set the interpreter quiet. + * interps.h (interp_quiet_p): Make static. + (class interp) : Remove field + +2017-02-08 Jerome Guitton + + * cli/cli-decode.c (find_command_name_length): Make it extern. + * cli/cli-decode.h (find_command_name_length): Declare. + * cli/cli-script.c (command_name_equals, line_first_arg): + New functions. + (process_next_line): Use cli-decode to parse command names. + (build_command_line): Make args a constant pointer. + +2017-02-08 Jerome Guitton + + * cli-decode.c (lookup_cmd_1, lookup_cmd_composition): + Remove case-insensitive search. + +2017-02-07 Jose E. Marchesi + + * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator + at the end of the line. Avoids an ARI warning. + +2017-02-06 Luis Machado + + * NEWS: Mention support for record/replay of Intel 64 rdrand and + rdseed instructions. + i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed. + +2017-02-06 Ivo Raisr + + PR tdep/20936 + Provide and use sparc32 and sparc64 target description XML files. + * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml, + features/sparc/sparc32-fpu.xml: New files for sparc 32-bit. + * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml, + features/sparc/sparc64-fpu.xml: New files for sparc 64-bit. + * features/sparc/sparc32-solaris.xml: New file. + * features/sparc/sparc64-solaris.xml: New file. + * features/sparc/sparc32-solaris.c: Generated. + * features/sparc/sparc64-solaris.c: Generated. + * sparc-tdep.h: Account for differences in target descriptions. + * sparc-tdep.c (sparc32_register_name): Use target provided registers. + (sparc32_register_type): Use target provided registers. + (validate_tdesc_registers): New function. + (sparc32_gdbarch_init): Use tdesc_has_registers. + Set pseudoregister functions. + * sparc64-tdep.c (sparc64_register_name): Use target provided registers. + (sparc64_register_type): Use target provided registers. + (sparc64_init_abi): Set pseudoregister functions. + +2017-02-03 Tom Tromey + + PR rust/21097: + * rust-lang.c (rust_print_type) : Handle enums + with a single member. + +2017-02-03 Pedro Alves + + * cli/cli-interp.c (cli_interp_base::cli_interp_base) + (cli_interp_base::~cli_interp_base): New. + (cli_interp): New struct. + (as_cli_interp): Cast the interp itself to cli_interp. + (cli_interpreter_pre_command_loop): Rename to ... + (cli_interp_base::pre_command_loop): ... this. Remove 'self' + parameter. + (cli_interpreter_init): Rename to ... + (cli_interp::init): ... this. Remove 'self' parameter. Use + boolean. Make extern. + (cli_interpreter_resume): Rename to ... + (cli_interp::resume): ... this. Remove 'data' parameter. Make + extern. + (cli_interpreter_suspend): Rename to ... + (cli_interp::suspend): ... this. Remove 'data' parameter. Make + extern. + (cli_interpreter_exec): Rename to ... + (cli_interp::exec): ... this. Remove 'data' parameter. Make + extern. + (cli_interpreter_supports_command_editing): Rename to ... + (cli_interp_base::supports_command_editing): ... this. Remove + 'interp' parameter. Make extern. + (cli_ui_out): Rename to ... + (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter. + Make extern. + (cli_set_logging): Rename to ... + (cli_interp_base::set_logging): ... this. Remove 'interp' + parameter. Make extern. + (cli_interp_procs): Delete. + (cli_interp_factory): Adjust to use "new". + * cli/cli-interp.h: Include "interps.h". + (struct cli_interp_base): New struct. + * interps.c (struct interp): Delete. Fields moved to interps.h. + (interp_new): Delete. + (interp::interp, interp::~interp): New. + (interp_set): Use bool, and return void. Assume the interpreter + has suspend, init and resume methods, and that the all return + void. + (set_top_level_interpreter): interp_set returns void. + (interp_ui_out): Adapt. + (current_interp_set_logging): Adapt. + (interp_data): Delete. + (interp_pre_command_loop, interp_supports_command_editing): Adapt. + (interp_exec): Adapt. + (top_level_interpreter_data): Delete. + * interps.h (interp_init_ftype, interp_resume_ftype) + (interp_suspend_ftype, interp_exec_ftype) + (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete. + (class interp): New. + (interp_new): Delete. + (interp_set): Now returns void. Use bool. + (interp_data, top_level_interpreter_data): Delete. + * mi/mi-common.h: Include interps.h. + (class mi_interp): Inherit from interp. Define a ctor. Declare + init, resume, suspect, exec, interp_ui_out, set_logging and + pre_command_loop methods. + * mi/mi-interp.c (as_mi_interp): Cast the interp itself. + (mi_interpreter_init): Rename to ... + (mi_interp::init): ... this. Remove the 'interp' parameter, use + bool, return void and make extern. Adjust. + (mi_interpreter_resume): ... Rename to ... + (mi_interp::resume): ... this. Remove the 'data' parameter, + return void and make extern. Adjust. + (mi_interpreter_suspend): ... Rename to ... + (mi_interp::suspend): ... this. Remove the 'data' parameter, + return void and make extern. Adjust. + (mi_interpreter_exec): ... Rename to ... + (mi_interp::exec): ... this. Remove the 'data' parameter and make + extern. Adjust. + (mi_interpreter_pre_command_loop): ... Rename to ... + (mi_interp::pre_command_loop): ... this. Remove the 'self' + parameter and make extern. + (mi_on_normal_stop_1): Adjust. + (mi_ui_out): Rename to ... + (mi_interp::interp_ui_out): ... this. Remove the 'interp' + parameter and make extern. Adjust. + (mi_set_logging): Rename to ... + (mi_interp::set_logging): ... this. Remove the 'interp' + parameter and make extern. Adjust. + (mi_interp_procs): Delete. + (mi_interp_factory): Adjust to use 'new'. + * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command) + (mi_print_exception, mi_execute_command, mi_load_progress): + Adjust. + * tui/tui-interp.c (tui_interp): New class. + (as_tui_interp): Return a tui_interp pointer. + (tui_on_normal_stop, tui_on_signal_received) + (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited) + (tui_on_no_history, tui_on_user_selected_context_changed): Adjust + to use interp::interp_ui_out. + (tui_init): Rename to ... + (tui_interp::init): ... this. Remove the 'self' parameter, use + bool, return void and make extern. Adjust. + (tui_resume): Rename to ... + (tui_interp::resume): ... this. Remove the 'data' parameter, + return void and make extern. Adjust. + (tui_suspend): Rename to ... + (tui_interp::suspend): ... this. Remove the 'data' parameter, + return void and make extern. Adjust. + (tui_ui_out): Rename to ... + (tui_interp::interp_ui_out): ... this. Remove the 'self' + parameter, and make extern. Adjust. + (tui_exec): Rename to ... + (tui_interp::exec): ... this. Remove the 'data' parameter and + make extern. + (tui_interp_procs): Delete. + (tui_interp_factory): Use "new". + +2017-02-02 Tom Tromey + + * rust-exp.y (ends_raw_string, space_then_number) + (rust_identifier_start_p): Return bool. + * rust-lang.c (rust_tuple_type_p, rust_underscore_fields) + (rust_tuple_struct_type_p, rust_tuple_variant_type_p) + (rust_slice_type_p, rust_range_type_p, rust_u8_type_p) + (rust_chartype_p): Return bool. + (val_print_struct, rust_print_struct_def, rust_print_type): + Update. + * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p): + Return bool. + +2017-02-02 Tom Tromey + + * rust-lang.c: Reindent. + +2017-02-02 Tom Tromey + + * rust-lang.h (rust_crate_for_block): Update. + * rust-lang.c (rust_crate_for_block): Return std::string. + (rust_get_disr_info): Use std:;string, not + gdb::unique_xmalloc_ptr. + * rust-exp.y (crate_name): Update. + +2017-02-02 Pedro Alves + + * disasm-selftests.c (print_one_insn_test): Move the "verbose" + field out of gdb_disassembler_test and make it static. + +2017-02-02 Pedro Alves + + * mi/mi-common.h (struct mi_interp): Delete the mi2_interp, + mi1_interp and mi_interp fields. + +2017-02-02 Pedro Alves + + * cli/cli-interp.c (struct saved_output_files, saved_output): + Moved from cli/cli-logging.c. + (cli_set_logging): New function. + (cli_interp_procs): Install cli_set_logging. + * cli/cli-interp.h (make_logging_output, cli_set_logging): + Declare. + * cli/cli-logging.c (struct saved_output_files, saved_output): + Moved to cli/cli-interp.c. + (pop_output_files): Don't save outputs here. + (make_logging_output): New function. + (handle_redirections): Don't build tee nor save previous outputs + here. + * interps.c (current_interp_set_logging): Change prototype. + Assume there's always a set_logging_proc method installed. + * interps.h (interp_set_logging_ftype): Change prototype. + (current_interp_set_logging): Change prototype and adjust comment. + * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to + use make_logging_output. + * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging. +2017-02-02 Pedro Alves + + * cli/cli-logging.c (maybe_warn_already_logging): New factored out + from ... + (set_logging_overwrite): ... here. + (logging_no_redirect_file): Delete. + (set_logging_redirect): Don't handle redirection on the fly. + Instead warn that "logging off" / "logging on" is necessary. + (pop_output_files): Delete references to logging_no_redirect_file. + (show_logging_command): Always speak in terms of what will happen + once logging is reenabled. + +2017-02-02 Pedro Alves + + * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment. + +2017-02-02 Pedro Alves + + * disasm.c (gdb_pretty_print_insn): Rename to ... + (gdb_pretty_print_disassembler::pretty_print_insn): ... this. + Remove gdbarch parameter. Adapt to clear the object's buffers + instead of allocating new buffers, and to print using the object's + gdb_disassembler instead of calling gdb_print_insn. + (dump_insns): Use gdb_pretty_print_disassembler. + * disasm.h (gdb_pretty_print_insn): Delete declaration. + (gdb_pretty_print_disassembler): New class. + * record-btrace.c (btrace_insn_history): Use + gdb_pretty_print_disassembler. + +2017-02-02 Pedro Alves + + * ada-lang.c (type_as_string): Use string_file. + * ada-valprint.c (ada_print_floating): Use string_file. + * ada-varobj.c (ada_varobj_scalar_image) + (ada_varobj_get_value_image): Use string_file. + * aix-thread.c (aix_thread_extra_thread_info): Use string_file. + * arm-tdep.c (_initialize_arm_tdep): Use string_printf. + * breakpoint.c (update_inserted_breakpoint_locations) + (insert_breakpoint_locations, reattach_breakpoints) + (print_breakpoint_location, print_one_detail_ranged_breakpoint) + (print_it_watchpoint): Use string_file. + (save_breakpoints): Use stdio_file. + * c-exp.y (oper): Use string_file. + * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and + tee_file. + (pop_output_files): Use delete. + (handle_redirections): Use stdio_file and tee_file. + * cli/cli-setshow.c (do_show_command): Use string_file. + * compile/compile-c-support.c (c_compute_program): Use + string_file. + * compile/compile-c-symbols.c (generate_vla_size): Take a + 'string_file &' instead of a 'ui_file *'. + (generate_c_for_for_one_variable): Take a 'string_file &' instead + of a 'ui_file *'. Use string_file. + (generate_c_for_variable_locations): Take a 'string_file &' + instead of a 'ui_file *'. + * compile/compile-internal.h (generate_c_for_for_one_variable): + Take a 'string_file &' instead of a 'ui_file *'. + * compile/compile-loc2c.c (push, pushf, unary, binary) + (print_label, pushf_register_address, pushf_register) + (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a + 'ui_file *'. Adjust. + * compile/compile.c (compile_to_object): Use string_file. + * compile/compile.h (compile_dwarf_expr_to_c) + (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a + 'ui_file *'. + * cp-support.c (inspect_type): Use string_file and obstack_copy0. + (replace_typedefs_qualified_name): Use string_file and + obstack_copy0. + * disasm.c (gdb_pretty_print_insn): Use string_file. + (gdb_disassembly): Adjust reference the null_stream global. + (do_ui_file_delete): Delete. + (gdb_insn_length): Use null_stream. + * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file. + * dwarf2loc.c (dwarf2_compile_property_to_c) + (locexpr_generate_c_location, loclist_generate_c_location): Take a + 'string_file &' instead of a 'ui_file *'. + * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise. + * dwarf2read.c (do_ui_file_peek_last): Delete. + (dwarf2_compute_name): Use string_file. + * event-top.c (gdb_setup_readline): Use stdio_file. + * gdbarch.sh (verify_gdbarch): Use string_file. + * gdbtypes.c (safe_parse_type): Use null_stream. + * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use + string_file. + * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a + 'string_file *' instead of a 'ui_file *'. + (gdbscm_arch_disassemble): Use string_file. + * guile/scm-frame.c (frscm_print_frame_smob): Use string_file. + * guile/scm-ports.c (class ioscm_file_port): Now a class that + inherits from ui_file. + (ioscm_file_port_delete, ioscm_file_port_rewind) + (ioscm_file_port_put): Delete. + (ioscm_file_port_write): Rename to ... + (ioscm_file_port::write): ... this. Remove file_port_magic + checks. + (ioscm_file_port_new): Delete. + (ioscm_with_output_to_port_worker): Use ioscm_file_port and + ui_file_up. + * guile/scm-type.c (tyscm_type_name): Use string_file. + * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print): + Use string_file. + * infcmd.c (print_return_value_1): Use string_file. + * infrun.c (print_target_wait_results): Use string_file. + * language.c (add_language): Use string_file. + * location.c (explicit_to_string_internal): Use string_file. + * main.c (captured_main_1): Use null_file. + * maint.c (maintenance_print_architecture): Use stdio_file. + * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file. + * mi/mi-common.h (struct mi_interp) : Change type to mi_console_file pointer. + * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush) + (mi_console_file_delete): Delete. + (struct mi_console_file): Delete. + (mi_console_file_magic): Delete. + (mi_console_file_new): Delete. + (mi_console_file::mi_console_file): New. + (mi_console_file_delete): Delete. + (mi_console_file_fputs): Delete. + (mi_console_file::write): New. + (mi_console_raw_packet): Delete. + (mi_console_file::flush): New. + (mi_console_file_flush): Delete. + (mi_console_set_raw): Rename to ... + (mi_console_file::set_raw): ... this. + * mi/mi-console.h (class mi_console_file): New class. + (mi_console_file_new, mi_console_set_raw): Delete. + * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file. + (mi_set_logging): Use delete and tee_file. Adjust. + * mi/mi-main.c (output_register): Use string_file. + (mi_cmd_data_evaluate_expression): Use string_file. + (mi_cmd_data_read_memory): Use string_file. + (mi_cmd_execute, print_variable_or_computed): Use string_file. + * mi/mi-out.c (mi_ui_out::main_stream): New. + (mi_ui_out::rewind): Use main_stream and + string_file. + (mi_ui_out::put): Use main_stream and string_file. + (mi_ui_out::mi_ui_out): Remove 'stream' parameter. + Allocate a 'string_file' instead. + (mi_out_new): Don't allocate a mem_fileopen stream here. + * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter. + (mi_ui_out::main_stream): Declare method. + * printcmd.c (eval_command): Use string_file. + * psymtab.c (maintenance_print_psymbols): Use stdio_file. + * python/py-arch.c (archpy_disassemble): Use string_file. + * python/py-breakpoint.c (bppy_get_commands): Use string_file. + * python/py-frame.c (frapy_str): Use string_file. + * python/py-framefilter.c (py_print_type, py_print_single_arg): + Use string_file. + * python/py-type.c (typy_str): Use string_file. + * python/py-unwind.c (unwind_infopy_str): Use string_file. + * python/py-value.c (valpy_str): Use string_file. + * record-btrace.c (btrace_insn_history): Use string_file. + * regcache.c (regcache_print): Use stdio_file. + * reggroups.c (maintenance_print_reggroups): Use stdio_file. + * remote.c (escape_buffer): Use string_file. + * rust-lang.c (rust_get_disr_info): Use string_file. + * serial.c (serial_open_ops_1): Use stdio_file. + (do_serial_close): Use delete. + * stack.c (print_frame_arg): Use string_file. + (print_frame_args): Remove local mem_fileopen stream, not used. + (print_frame): Use string_file. + * symmisc.c (maintenance_print_symbols): Use stdio_file. + * symtab.h (struct symbol_computed_ops) : + Take a 'string_file *' instead of a 'ui_file *'. + * top.c (new_ui): Use stdio_file and stderr_file. + (free_ui): Use delete. + (execute_command_to_string): Use string_file. + (quit_confirm): Use string_file. + * tracepoint.c (collection_list::append_exp): Use string_file. + * tui/tui-disasm.c (tui_disassemble): Use string_file. + * tui/tui-file.c: Don't include "ui-file.h". + (enum streamtype, struct tui_stream): Delete. + (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen) + (tui_file_isatty, tui_file_rewind, tui_file_put): Delete. + (tui_file::tui_file): New method. + (tui_file_fputs): Delete. + (tui_file_get_strbuf): Delete. + (tui_file::puts): New method. + (tui_file_adjust_strbuf): Delete. + (tui_file_flush): Delete. + (tui_file::flush): New method. + * tui/tui-file.h: Tweak intro comment. + Include ui-file.h. + (tui_fileopen, tui_sfileopen, tui_file_get_strbuf) + (tui_file_adjust_strbuf): Delete declarations. + (class tui_file): New class. + * tui/tui-io.c (tui_initialize_io): Use tui_file. + * tui/tui-regs.c (tui_restore_gdbout): Use delete. + (tui_register_format): Use string_stream. + * tui/tui-stack.c (tui_make_status_line): Use string_file. + (tui_get_function_from_frame): Use string_file. + * typeprint.c (type_to_string): Use string_file. + * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete. + (null_stream): New global. + (ui_file_delete): Delete. + (ui_file::ui_file): New. + (null_file_isatty): Delete. + (ui_file::~ui_file): New. + (null_file_rewind): Delete. + (ui_file::printf): New. + (null_file_put): Delete. + (null_file_flush): Delete. + (ui_file::putstr): New. + (null_file_write): Delete. + (ui_file::putstrn): New. + (null_file_read): Delete. + (ui_file::putc): New. + (null_file_fputs): Delete. + (null_file_write_async_safe): Delete. + (ui_file::vprintf): New. + (null_file_delete): Delete. + (null_file::write): New. + (null_file_fseek): Delete. + (null_file::puts): New. + (ui_file_data): Delete. + (null_file::write_async_safe): New. + (gdb_flush, ui_file_isatty): Adjust. + (ui_file_put, ui_file_rewind): Delete. + (ui_file_write): Adjust. + (ui_file_write_for_put): Delete. + (ui_file_write_async_safe, ui_file_read): Adjust. + (ui_file_fseek): Delete. + (fputs_unfiltered): Adjust. + (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind) + (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe) + (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek) + (set_ui_file_data): Delete. + (string_file::~string_file, string_file::write) + (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup) + (do_ui_file_as_string, ui_file_as_string): Delete. + (do_ui_file_obsavestring, ui_file_obsavestring): Delete. + (struct mem_file): Delete. + (mem_file_new): Delete. + (stdio_file::stdio_file): New. + (mem_file_delete): Delete. + (stdio_file::stdio_file): New. + (mem_fileopen): Delete. + (stdio_file::~stdio_file): New. + (mem_file_rewind): Delete. + (stdio_file::set_stream): New. + (mem_file_put): Delete. + (stdio_file::open): New. + (mem_file_write): Delete. + (stdio_file_magic, struct stdio_file): Delete. + (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete. + (stdio_file::flush): New. + (stdio_file_read): Rename to ... + (stdio_file::read): ... this. Adjust. + (stdio_file_write): Rename to ... + (stdio_file::write): ... this. Adjust. + (stdio_file_write_async_safe): Rename to ... + (stdio_file::write_async_safe) ... this. Adjust. + (stdio_file_fputs): Rename to ... + (stdio_file::puts) ... this. Adjust. + (stdio_file_isatty): Delete. + (stdio_file_fseek): Delete. + (stdio_file::isatty): New. + (stderr_file_write): Rename to ... + (stderr_file::write) ... this. Adjust. + (stderr_file_fputs): Rename to ... + (stderr_file::puts) ... this. Adjust. + (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete. + (stderr_file::stderr_file): New. + (tee_file_magic): Delete. + (struct tee_file): Delete. + (tee_file::tee_file): New. + (tee_file_new): Delete. + (tee_file::~tee_file): New. + (tee_file_delete): Delete. + (tee_file_flush): Rename to ... + (tee_file::flush): ... this. Adjust. + (tee_file_write): Rename to ... + (tee_file::write): ... this. Adjust. + (tee_file::write_async_safe): New. + (tee_file_fputs): Rename to ... + (tee_file::puts): ... this. Adjust. + (tee_file_isatty): Rename to ... + (tee_file::isatty): ... this. Adjust. + * ui-file.h (struct obstack, struct ui_file): Don't + forward-declare. + (ui_file_new, ui_file_flush_ftype, set_ui_file_flush) + (ui_file_write_ftype) + (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs) + (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe) + (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype) + (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind) + (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put) + (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype) + (set_ui_file_fseek): Delete. + (ui_file_data, ui_file_delete, ui_file_rewind) + (struct ui_file): New. + (ui_file_up): New. + (class null_file): New. + (null_stream): Declare. + (ui_file_write_for_put, ui_file_put): Delete. + (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring): + Delete. + (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen) + (gdb_fopen, tee_file_new): Delete. + (struct string_file): New. + (struct stdio_file): New. + (stdio_file_up): New. + (struct stderr_file): New. + (class tee_file): New. + * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead + of a 'ui_file *'. Adjust. + * ui-out.h (class ui_out) : Likewise. + * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete) + (null_stream): Delete. + (error_stream): Take a 'string_file &' instead of a 'ui_file *'. + Adjust. + * utils.h (struct ui_file): Delete forward declaration.. + (make_cleanup_ui_file_delete, null_stream): Delete declarations. + (error_stream): Take a 'string_file &' instead of a + 'ui_file *'. + * varobj.c (varobj_value_get_print_value): Use string_file. + * xtensa-tdep.c (xtensa_verify_config): Use string_file. + * gdbarch.c: Regenerate. + +2017-02-02 Pedro Alves + + * disasm.c (gdb_disassembler::pretty_print_insn): Rename to... + (gdb_pretty_print_insn): ... this. Now a free function. Add back + a 'gdbarch' parameter. Allocate a mem_fileopen stream here. + Adjust to call gdb_print_insn instead of + gdb_disassembler::print_insn. + (dump_insns, do_mixed_source_and_assembly_deprecated) + (do_mixed_source_and_assembly, do_assembly_only): Add back a + 'gdbarch' parameter. Remove gdb_disassembler parameter. + (gdb_disassembly): Don't allocate a gdb_disassembler here. + * disasm.h (gdb_disassembler::pretty_print_insn): Delete + declaration. + (gdb_pretty_print_insn): Re-add declaration. + * record-btrace.c (btrace_insn_history): Don't allocate a + gdb_disassembler here. Adjust to call gdb_pretty_print_insn. + +2017-02-01 Simon Marchi + + * disasm.h (gdb_disassembly): Remove file_string parameter. + * disasm.c (gdb_disassembly): Likewise. + * cli/cli-cmds.c (print_disassembly): Adapt. + * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise. + * stack.c (do_gdb_disassembly): Likewise. + +2017-02-01 Andreas Arnez + + * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For + DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian + targets. And if the implicit value is longer than needed, extract + the first bytes instead of the "least significant" ones. + +2017-02-01 Markus Metzger + + * btrace.c (btrace_enable): Do not call btrace_add_pc for + BTRACE_FORMAT_PT or if can_access_registers_ptid returns false. + (btrace_fetch): Assert can_access_registers_ptid. + * record-btrace.c (require_btrace_thread, record_btrace_info): Call + validate_registers_access. + +2017-02-01 Markus Metzger + + * gdbthread.h (can_access_registers_ptid): New. + * thread.c (can_access_registers_ptid): New. + 2017-02-01 Pedro Alves * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length. @@ -907,7 +2262,7 @@ 2017-01-01 Joel Brobecker - Update copyright year range in all GDB files. + Update copyright year range in all GDB files. 2017-01-01 Joel Brobecker