aix-thread: Use ptid from regcache instead of inferior_ptid
[binutils-gdb.git] / gdb / ChangeLog
1 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2
3 * aix-thread.c (aix_thread_fetch_registers,
4 aix_thread_store_registers): Use regcache->ptid instead of
5 inferior_ptid.
6
7 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8
9 * aarch64-linux-nat.c (fetch_gregs_from_thread,
10 store_gregs_to_thread, fetch_fpregs_from_thread,
11 store_fpregs_to_thread): Use regcache->ptid instead of
12 inferior_ptid.
13
14 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15
16 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
17 amd64_linux_fetch_inferior_registers): Use regcache->ptid
18 instead of inferior_ptid.
19
20 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
21
22 * target.c (target_fetch_registers, target_store_registers): Add
23 assert.
24
25 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
26
27 * regcache.h (regcache_get_ptid): New function.
28 * regcache.c (regcache_get_ptid): New function.
29
30 2017-03-13 Mark Wielaard <mark@klomp.org>
31
32 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
33
34 2017-03-10 Keith Seitz <keiths@redhat.com>
35
36 PR c++/8218
37 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
38
39 2017-03-08 Pedro Alves <palves@redhat.com>
40
41 PR gdb/18360
42 * infrun.c (start_step_over, do_target_resume, resume)
43 (restart_threads): Assert we're not resuming a thread that is
44 meant to be stopped.
45 (infrun_thread_stop_requested_callback): Delete.
46 (infrun_thread_stop_requested): If the thread is internally
47 stopped, queue a pending stop event and clear the thread's
48 inline-frame state.
49 (handle_stop_requested): New function.
50 (handle_syscall_event, handle_inferior_event_1): Use
51 handle_stop_requested.
52 (handle_stop_requested): New function.
53 (handle_signal_stop): Set the thread's stop_signal here instead of
54 at caller.
55 (finish_step_over): Clear step over info unconditionally.
56 (handle_signal_stop): If the user had interrupted the event
57 thread, consider the stop a random signal.
58 (handle_signal_stop) <signal arrived while stepping over
59 breakpoint>: Don't restart threads here.
60 (stop_waiting): Don't clear step-over info here.
61
62 2017-03-08 Pedro Alves <palves@redhat.com>
63
64 PR 21206
65 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
66 goes to argument 2, not 1.
67
68 2017-03-08 Pedro Alves <palves@redhat.com>
69
70 PR cli/21218
71 * top.c (gdb_readline_wrapper): Avoid passing NULL to
72 display_gdb_prompt.
73 (command_line_input): Add comment.
74
75 2017-03-08 Pedro Alves <palves@redhat.com>
76
77 PR tui/21216
78 * tui/tui-file.c (tui_file::write): New.
79 * tui/tui-file.h (tui_file): Override "write".
80 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
81 factored out from ...
82 (tui_puts): ... here.
83 (tui_putc): Use them.
84 (tui_write): New function.
85 * tui/tui-io.h (tui_write): Declare.
86
87 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
88
89 * Makefile.in (SFILES): Replace "environ.c" with
90 "common/environ.c".
91 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
92 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
93 to...
94 * common/environ.c: ... here.
95 * environ.h: Moved to...
96 * common/environ.h: ... here.
97
98 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
99
100 * gdbarch.sh (pstring_ptr): New static function.
101 (gdbarch_disassembler_options): Use it.
102 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
103 not valid_disassembler_option->name.
104 * gdbarch.c: Regenerate.
105
106 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
107
108 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
109
110 2017-03-07 Pedro Alves <palves@redhat.com>
111
112 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
113
114 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
115
116 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
117 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
118 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
119 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
120
121 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
122
123 * xtensa-linux-nat.c (fetch_gregs): Remove const.
124
125 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
126
127 * remote.c (remote_add_target_side_commands): Use range-based
128 for loop.
129
130 2017-03-03 Yao Qi <yao.qi@linaro.org>
131
132 PR gdb/21165
133 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
134 value is lazy.
135 * valprint.c (common_val_print): Likewise.
136
137 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
138
139 * NEWS: Mention new set/show disassembler-options commands.
140 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
141 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
142 (prospective_options): New static variable.
143 (gdb_disassembler::gdb_disassembler): Initialize
144 m_di.disassembler_options.
145 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
146 (get_disassembler_options): New function.
147 (set_disassembler_options): Likewise.
148 (set_disassembler_options_sfunc): Likewise.
149 (show_disassembler_options_sfunc): Likewise.
150 (disassembler_options_completer): Likewise.
151 (_initialize_disasm): Likewise.
152 * disasm.h (get_disassembler_options): New prototype.
153 (set_disassembler_options): Likewise.
154 * gdbarch.sh (gdbarch_disassembler_options): New variable.
155 (gdbarch_verify_disassembler_options): Likewise.
156 * gdbarch.c: Regenerate.
157 * gdbarch.h: Likewise.
158 * arm-tdep.c (num_disassembly_options): Delete.
159 (set_disassembly_style): Likewise.
160 (arm_disassembler_options): New static variable.
161 (set_disassembly_style_sfunc): Convert short style name into long
162 option name. Call set_disassembler_options.
163 (show_disassembly_style_sfunc): New function.
164 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
165 set_gdbarch_verify_disassembler_options.
166 (_initialize_arm_tdep): Delete regnames variable and update callers.
167 (arm_disassembler_options): Initialize.
168 (disasm_options): New variable.
169 (num_disassembly_options): Rename from this...
170 (num_disassembly_styles): ...to this. Compute by scanning through
171 disasm_options.
172 (valid_disassembly_styles): Initialize using disasm_options.
173 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
174 set_arm_regname_option.
175 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
176 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
177 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
178 set_gdbarch_verify_disassembler_options.
179 * s390-tdep.c (s390_disassembler_options): New static variable.
180 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
181 set_gdbarch_verify_disassembler_options.
182
183 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
184
185 * remote.c (remote_add_target_side_condition): Remove "struct"
186 keyword from range-based for loop.
187
188 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
189
190 * remote.c (remote_add_target_side_condition): Use range-based
191 for loop. Update comment.
192
193 2017-02-27 Yao Qi <yao.qi@linaro.org>
194
195 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
196
197 2017-02-26 Alan Hayward <alan.hayward@arm.com>
198
199 * regcache.c (regcache_raw_update): New function.
200 (regcache_raw_read): Move code to regcache_raw_update.
201 * regcache.h (regcache_raw_update): New declaration.
202 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
203
204 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
205
206 * dwarf2read.c (create_debug_type_hash_table): Initialize
207 header.signature and header.type_offset_in_tu.
208
209 2017-02-24 Pedro Alves <palves@redhat.com>
210
211 * symtab.c (make_file_symbol_completion_list_1): Use
212 add_symtab_completions.
213
214 2017-02-24 Alan Hayward <alan.hayward@arm.com>
215
216 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
217
218 2017-02-24 Alan Hayward <alan.hayward@arm.com>
219
220 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
221 I386_MAX_REGISTER_SIZE.
222 (i386_pseudo_register_write): Likewise.
223 (i386_process_record): Likewise.
224 * i387-tdep.c (i387_supply_xsave): Likewise.
225 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
226 (store_register): Likewise.
227
228 2017-02-23 Pedro Alves <palves@redhat.com>
229
230 * ada-lang.c: Include "common/function-view.h".
231 (ada_iterate_over_symbols): Adjust to use function_view as
232 callback type.
233 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
234 (ada_make_symbol_completion_list): Use a lambda.
235 (ada_exc_search_name_matches): Delete.
236 (name_matches_regex): New.
237 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
238 * compile/compile-c-support.c: Include "common/function-view.h".
239 (print_one_macro): Change prototype to accept a ui_file pointer.
240 (write_macro_definitions): Use a lambda.
241 * dwarf2read.c: Include "common/function-view.h".
242 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
243 (dw2_expand_symtabs_matching): Adjust to use function_view as
244 callback type.
245 * language.h: Include "common/function-view.h".
246 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
247 function_view as callback type.
248 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
249 * linespec.c: Include "common/function-view.h".
250 (collect_info::add_symbol): New method.
251 (struct symbol_and_data_callback, iterate_inline_only, struct
252 symbol_matcher_data, iterate_name_matcher): Delete.
253 (iterate_over_all_matching_symtabs): Adjust to use function_view
254 as callback type and lambdas.
255 (iterate_over_file_blocks): Adjust to use function_view as
256 callback type.
257 (decode_compound_collector): Now a class with private fields.
258 (decode_compound_collector::release_symbols): New method.
259 (collect_one_symbol): Rename to...
260 (decode_compound_collector::operator()): ... this and adjust.
261 (lookup_prefix_sym): decode_compound_collector construction bits
262 move to decode_compound_collector ctor. Pass the
263 decode_compound_collector object directly as callback. Remove
264 cleanups and use decode_compound_collector::release_symbols
265 instead.
266 (symtab_collector): Now a class with private fields.
267 (symtab_collector::release_symtabs): New method.
268 (add_symtabs_to_list): Rename to...
269 (symtab_collector::operator()): ... this and adjust.
270 (collect_symtabs_from_filename): symtab_collector construction
271 bits move to symtab_collector ctor. Pass the symtab_collector
272 object directly as callback. Remove cleanups and use
273 symtab_collector::release_symtabs instead.
274 (collect_symbols): Delete.
275 (add_matching_symbols_to_info): Use lambdas.
276 * macrocmd.c (print_macro_callback): Delete.
277 (info_macro_command): Use a lambda.
278 (info_macros_command): Pass print_macro_definition as callable
279 directly.
280 (print_one_macro): Remove 'ignore' parameter.
281 (macro_list_command): Adjust.
282 * macrotab.c (macro_for_each_data::fn): Now a function_view.
283 (macro_for_each_data::user_data): Delete field.
284 (foreach_macro): Adjust to call the function_view.
285 (macro_for_each): Adjust to use function_view as callback type.
286 (foreach_macro_in_scope): Adjust to call the function_view.
287 (macro_for_each_in_scope): Adjust to use function_view as callback
288 type.
289 * macrotab.h: Include "common/function-view.h".
290 (macro_callback_fn): Declare a prototype instead of a pointer.
291 Remove "user_data" parameter.
292 (macro_for_each, macro_for_each_in_scope): Adjust to use
293 function_view as callback type.
294 * psymtab.c (partial_map_expand_apply)
295 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
296 Adjust to use function_view as callback type and to return bool.
297 (psym_expand_symtabs_matching): Adjust to use function_view as
298 callback types.
299 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
300 to use function_view as callback type and to return bool.
301 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
302 callback types.
303 * symfile.c (expand_symtabs_matching): Adjust to use function_view
304 as callback types.
305 * symfile.h: Include "common/function-view.h".
306 (expand_symtabs_file_matcher_ftype)
307 (expand_symtabs_symbol_matcher_ftype)
308 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
309 return bool.
310 (quick_symbol_functions::map_symtabs_matching_filename)
311 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
312 function_view as callback type and return bool.
313 (expand_symtabs_matching): Adjust to use function_view as callback
314 type.
315 (maintenance_expand_name_matcher)
316 (maintenance_expand_file_matcher): Delete.
317 (maintenance_expand_symtabs): Use lambdas.
318 * symtab.c (iterate_over_some_symtabs): Adjust to use
319 function_view as callback types and return bool.
320 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
321 of a cleanup.
322 (lookup_symtab_callback): Delete.
323 (lookup_symtab): Use a lambda.
324 (iterate_over_symbols): Adjust to use function_view as callback
325 type.
326 (struct search_symbols_data, search_symbols_file_matches)
327 (search_symbols_name_matches): Delete.
328 (search_symbols): Use a pair of lambdas.
329 (struct add_name_data, add_macro_name, symbol_completion_matcher)
330 (symtab_expansion_callback): Delete.
331 (default_make_symbol_completion_list_break_on_1): Use lambdas.
332 * symtab.h: Include "common/function-view.h".
333 (iterate_over_some_symtabs): Adjust to use function_view as
334 callback type and return bool.
335 (iterate_over_symtabs): Adjust to use function_view as callback
336 type.
337 (symbol_found_callback_ftype): Remove 'data' parameter and return
338 bool.
339 (iterate_over_symbols): Adjust to use function_view as callback
340 type.
341
342 2017-02-23 Pedro Alves <palves@redhat.com>
343
344 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
345 (%.o) <unittests/%.c>: New pattern.
346 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
347 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
348 * common/function-view.h: New file.
349 * unittests/function-view-selftests.c: New file.
350 * configure: Regenerate.
351
352 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
353
354 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
355 inferior_ptid.
356 * go32-nat.c (go32_thread_alive): Likewise.
357
358 2017-02-23 Yao Qi <yao.qi@linaro.org>
359
360 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
361 delete.
362
363 2017-02-23 Yao Qi <yao.qi@linaro.org>
364
365 * varobj.c (varobj_clear_saved_item): Use delete instead of
366 xfree.
367 (update_dynamic_varobj_children): Likewise.
368
369 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
370
371 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
372
373 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
374
375 * common/enum-flags.h (enum_flags::enum_flags): Initialize
376 m_enum_value to 0 in default constructor.
377
378 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
379
380 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
381 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
382 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
383 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
384 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
385 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
386 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
387 IS_STORE_CONDITIONAL_INSN.
388
389 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
390
391 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
392
393 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
394
395 * NEWS (Changes since GDB 7.12): Add DWARF-5.
396
397 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
398
399 * dwarf2read.c (skip_one_die, read_attribute_value)
400 (dwarf2_const_value_attr, dump_die_shallow)
401 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
402 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
403
404 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
405
406 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
407 (dwarf_parse_macro_header): Accept DWARF version 5.
408 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
409
410 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
411
412 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
413 DW_AT_GNU_*.
414 * common/common-exceptions.h (enum errors): Likewise.
415 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
416 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
417 (dwarf_expr_context::execute_stack_op): Likewise.
418 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
419 Likewise.
420 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
421 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
422 (show_entry_values_debug, call_site_to_target_addr)
423 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
424 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
425 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
426 (value_of_dwarf_block_entry, indirect_pieced_value)
427 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
428 (disassemble_dwarf_expression): Likewise.
429 * dwarf2read.c (process_die, inherit_abstract_dies)
430 (read_call_site_scope): Likewise.
431 * gdbtypes.h (struct func_type, struct call_site_parameter)
432 (struct call_site): Likewise.
433 * stack.c (read_frame_arg): Likewise.
434 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
435
436 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
437
438 * defs.h (read_unsigned_leb128): New declaration.
439 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
440 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
441 (dwarf2_find_location_expression): Call also
442 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
443 * dwarf2loc.h (dwarf2_version): New declaration.
444 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
445 rnglists.
446 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
447 .debug_rnglists.
448 (struct dwop_section_names): Add loclists_dwo.
449 (dwop_section_names): Add .debug_loclists.dwo.
450 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
451 (struct dwarf2_per_cu_data): Add dwarf_version.
452 (struct dwo_sections): Add loclists.
453 (struct attr_abbrev): Add implicit_const.
454 (read_indirect_line_string): New declaration.
455 (read_unsigned_leb128): Delete declaration.
456 (rcuh_kind): New definition.
457 (read_and_check_comp_unit_head): Change parameter
458 is_debug_types_section to section_kind.
459 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
460 (read_comp_unit_head): Change parameter abfd to section, add parameter
461 section_kind. Handle DWARF-5.
462 (error_check_comp_unit_head): Accept also DWARF version 5.
463 (read_and_check_comp_unit_head): Change parameter
464 is_debug_types_section to section_kind.
465 (read_and_check_type_unit_head): Delete function.
466 (read_abbrev_offset): Handle DWARF-5.
467 (create_debug_type_hash_table): Add parameter section_kind. Process
468 only DW_UT_type. Use signature and type_offset_in_tu from struct
469 comp_unit_head.
470 (create_debug_types_hash_table): Update create_debug_type_hash_table
471 caller.
472 (create_all_type_units): Call create_debug_type_hash_table.
473 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
474 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
475 caller.
476 (skip_one_die): Handle DW_FORM_implicit_const.
477 (dwarf2_rnglists_process): New function.
478 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
479 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
480 (read_attribute_value): Handle DW_FORM_implicit_const,
481 DW_FORM_line_strp.
482 (read_attribute): Handle DW_FORM_implicit_const.
483 (read_indirect_string_at_offset_from): New function from
484 read_indirect_string_at_offset.
485 (read_indirect_string_at_offset): Call
486 read_indirect_string_at_offset_from.
487 (read_indirect_line_string_at_offset): New function.
488 (read_indirect_string): New function comment.
489 (read_indirect_line_string): New function.
490 (read_unsigned_leb128): Make it global.
491 (dwarf2_string_attr): Handle DWARF-5.
492 (add_include_dir_stub, read_formatted_entries): New functions.
493 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
494 Handle DWARF-5.
495 (per_cu_header_read_in): Update read_comp_unit_head caller.
496 (dwarf2_version): New function.
497 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
498 rnglists.
499 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
500 fields.
501
502 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
503
504 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
505
506 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
507
508 * dwarf2read.c (dwarf2_ranges_process): New function from
509 dwarf2_ranges_read.
510 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
511 dwarf2_ranges_process.
512
513 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
514
515 * dwarf2read.c (create_debug_type_hash_table): New function from
516 create_debug_types_hash_table.
517 (create_debug_types_hash_table): Call create_debug_type_hash_table.
518 (create_all_type_units, open_and_init_dwo_file): Update
519 create_debug_types_hash_table callers.
520
521 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
522
523 PR gdb/16188
524 * fork-child.c (trace_start_error): Fix thinko. va_end should
525 refer to 'ap', not 'args'.
526
527 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
528 Pedro Alves <palves@redhat.com>
529
530 PR gdb/16188
531 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
532 calls succeeded.
533 * fork-child.c (trace_start_error): New function.
534 (trace_start_error_with_name): Likewise.
535 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
536 * inf-ptrace.c (inf_ptrace_me): Likewise.
537 * inferior.h (trace_start_error): New prototype.
538 (trace_start_error_with_name): Likewise.
539
540 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
541
542 PR gdb/21164
543 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
544 NULL before using it.
545 * symmisc.c (maintenance_print_symbols): Likewise.
546 (maintenance_print_msymbols): Likewise.
547
548 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
549
550 * NEWS: Add record Python bindings entry.
551
552 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
553
554 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
555 py-record-full.o.
556 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
557 * python/py-record-btrace.c, python/py-record-btrace.h,
558 python/py-record-full.c, python/py-record-full.h: New file.
559 * python/py-record.c: Add include for py-record-btrace.h and
560 py-record-full.h.
561 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
562 recpy_instruction_history, recpy_function_call_history, recpy_begin,
563 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
564 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
565 New definition.
566 (gdbpy_initialize_btrace): New export.
567 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
568
569 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
570
571 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
572 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
573 * python/py-record.c: New file.
574 * python/python-internal.h (gdbpy_start_recording,
575 gdbpy_current_recording, gdpy_stop_recording,
576 gdbpy_initialize_record): New export.
577 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
578 (python_GdbMethods): Add gdbpy_start_recording,
579 gdbpy_current_recording and gdbpy_stop_recording.
580
581 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
582
583 * record-btrace.c (record_btrace_record_method): New function.
584 (init_record_btrace_ops): Initialize to_record_method.
585 * record-full.c (record_full_record_method): New function.
586 (init_record_full_ops, init_record_full_core_ops): Add
587 record_full_record_method.
588 * record.h (enum record_method): New enum.
589 * target-debug.h (target_debug_print_enum_record_method: New define.
590 * target-delegates.c: Regenerate.
591 * target.c (target_record_method): New function.
592 * target.h: Include record.h.
593 (struct target_ops) <to_record_method>: New field.
594 (target_record_method): New export.
595
596 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
597
598 * record.h (record_start, record_stop): New export.
599 * record.c (record_start, record_stop): New function.
600
601 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
602
603 * btrace.c (btrace_fetch): Copy function call segments pointer
604 into a vector.
605 (btrace_clear): Clear the vector.
606 (btrace_find_insn_by_number): Use binary search to find the correct
607 function call segment.
608 * btrace.h (brace_fun_p): New typedef.
609 (struct btrace_thread_info) <functions>: New field.
610
611 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
612
613 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
614 * btrace.c (btrace_decode_error): ... here. New function.
615 * btrace.h (btrace_decode_error): New export.
616
617 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
618
619 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
620 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
621 btrace_find_insn_by_number): Remove special case for gaps.
622 * btrace.h (btrace_insn_get_error): New export.
623 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
624 * record-btrace.c (btrace_insn_history): Print number for gaps.
625 (record_btrace_info, record_btrace_goto): Handle gaps.
626
627 2017-02-14 Tom Tromey <tom@tromey.com>
628
629 PR python/13598:
630 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
631 event.
632 * python/py-evts.c (gdbpy_initialize_py_events): Add
633 before_prompt registry.
634 * python/py-events.h (events_object) <before_prompt>: New field.
635
636 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
637
638 * btrace.c (ftrace_new_switch): Preserve up link and flags.
639
640 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
641
642 * symfile (_initialize_symfile): Add usage text to the load command's
643 help text.
644
645 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
646
647 * utils.c (defaulted_query): Don't query on secondary UIs.
648
649 2017-02-10 Tom Tromey <tom@tromey.com>
650
651 * rust-lang.c (rust_get_disr_info): Remove unused variable.
652
653 2017-02-10 Tom Tromey <tom@tromey.com>
654
655 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
656 "cleanup" local.
657 * python/py-type.c (typy_legacy_template_argument): Remove
658 unnecessary "cleanup" local.
659
660 2017-02-10 Tom Tromey <tom@tromey.com>
661
662 * python/python.c (do_start_initialization): New function, from
663 _initialize_python.
664 (_initialize_python): Call do_start_initialization.
665 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
666 goto.
667
668 2017-02-10 Tom Tromey <tom@tromey.com>
669
670 * python/py-prettyprint.c (pretty_print_one_value): Use
671 gdbpy_ref.
672
673 2017-02-10 Tom Tromey <tom@tromey.com>
674
675 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
676 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
677 gdbpy_ref.
678 * python/py-type.c (field_new): Use gdbpy_ref.
679 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
680 gdbpy_ref.
681 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
682 (py_free_pspace): Likewise.
683 (pspace_to_pspace_object): Likewise.
684 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
685 (py_free_objfile): Likewise.
686 (objfile_to_objfile_object): Likewise.
687 * python/py-inferior.c (delete_thread_object): Use
688 gdbpy_ref.
689 (infpy_read_memory): Likewise.
690 (py_free_inferior): Likewise.
691 * python/py-evtregistry.c (create_eventregistry_object): Use
692 gdbpy_ref.
693 * python/py-event.c (create_event_object): Use gdbpy_ref.
694
695 2017-02-10 Tom Tromey <tom@tromey.com>
696
697 * python/py-ref.h (gdbpy_ref_policy): Now a template.
698 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
699 used.
700 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
701 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
702 python/py-exitedevent.c, python/py-finishbreakpoint.c,
703 python/py-framefilter.c, python/py-function.c,
704 python/py-inferior.c, python/py-infevents.c,
705 python/py-linetable.c, python/py-newobjfileevent.c,
706 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
707 python/py-signalevent.c, python/py-stopevent.c,
708 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
709 python/py-unwind.c, python/py-utils.c, python/py-value.c,
710 python/py-varobj.c, python/py-xmethods.c, python/python.c,
711 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
712
713 2017-02-10 Tom Tromey <tom@tromey.com>
714
715 * ui-out.h (ui_out_emit_type): New class.
716 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
717 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
718 and ui_out_emit_tuple.
719 (enumerate_locals): Likewise.
720 (py_mi_print_variables, py_print_locals, py_print_args): Use
721 ui_out_emit_list.
722 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
723 ui_out_emit_list.
724 * common/gdb_optional.h: New file.
725
726 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
727
728 * MAINTAINERS (Write After Approval): Update my e-mail address.
729
730 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
731
732 PR gdb/21122
733 * breakpoint.c (_initialize_breakpoint): Update the help description
734 of the 'commands' command to indicate that it takes a list argument.
735
736 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
737
738 * interps.c (current_interp_set_logging): Remove "return".
739
740 2017-02-09 Gary Benson <gbenson@redhat.com>
741
742 * symtab.c (add_symtab_completions): Prevent NULL pointer
743 dereference.
744
745 2017-02-08 Pedro Alves <palves@redhat.com>
746
747 * interps.c (interp::interp): Remove reference to quiet_p.
748 (interp_set): Make static. Remove dead "Switching to" output
749 code.
750 (interp_quiet_p, interp_set_quiet): Delete.
751 (interpreter_exec_cmd): Don't set the interpreter quiet.
752 * interps.h (interp_quiet_p): Make static.
753 (class interp) <quiet_p>: Remove field
754
755 2017-02-08 Jerome Guitton <guitton@adacore.com>
756
757 * cli/cli-decode.c (find_command_name_length): Make it extern.
758 * cli/cli-decode.h (find_command_name_length): Declare.
759 * cli/cli-script.c (command_name_equals, line_first_arg):
760 New functions.
761 (process_next_line): Use cli-decode to parse command names.
762 (build_command_line): Make args a constant pointer.
763
764 2017-02-08 Jerome Guitton <guitton@adacore.com>
765
766 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
767 Remove case-insensitive search.
768
769 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
770
771 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
772 at the end of the line. Avoids an ARI warning.
773
774 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
775
776 * NEWS: Mention support for record/replay of Intel 64 rdrand and
777 rdseed instructions.
778 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
779
780 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
781
782 PR tdep/20936
783 Provide and use sparc32 and sparc64 target description XML files.
784 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
785 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
786 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
787 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
788 * features/sparc/sparc32-solaris.xml: New file.
789 * features/sparc/sparc64-solaris.xml: New file.
790 * features/sparc/sparc32-solaris.c: Generated.
791 * features/sparc/sparc64-solaris.c: Generated.
792 * sparc-tdep.h: Account for differences in target descriptions.
793 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
794 (sparc32_register_type): Use target provided registers.
795 (validate_tdesc_registers): New function.
796 (sparc32_gdbarch_init): Use tdesc_has_registers.
797 Set pseudoregister functions.
798 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
799 (sparc64_register_type): Use target provided registers.
800 (sparc64_init_abi): Set pseudoregister functions.
801
802 2017-02-03 Tom Tromey <tom@tromey.com>
803
804 PR rust/21097:
805 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
806 with a single member.
807
808 2017-02-03 Pedro Alves <palves@redhat.com>
809
810 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
811 (cli_interp_base::~cli_interp_base): New.
812 (cli_interp): New struct.
813 (as_cli_interp): Cast the interp itself to cli_interp.
814 (cli_interpreter_pre_command_loop): Rename to ...
815 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
816 parameter.
817 (cli_interpreter_init): Rename to ...
818 (cli_interp::init): ... this. Remove 'self' parameter. Use
819 boolean. Make extern.
820 (cli_interpreter_resume): Rename to ...
821 (cli_interp::resume): ... this. Remove 'data' parameter. Make
822 extern.
823 (cli_interpreter_suspend): Rename to ...
824 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
825 extern.
826 (cli_interpreter_exec): Rename to ...
827 (cli_interp::exec): ... this. Remove 'data' parameter. Make
828 extern.
829 (cli_interpreter_supports_command_editing): Rename to ...
830 (cli_interp_base::supports_command_editing): ... this. Remove
831 'interp' parameter. Make extern.
832 (cli_ui_out): Rename to ...
833 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
834 Make extern.
835 (cli_set_logging): Rename to ...
836 (cli_interp_base::set_logging): ... this. Remove 'interp'
837 parameter. Make extern.
838 (cli_interp_procs): Delete.
839 (cli_interp_factory): Adjust to use "new".
840 * cli/cli-interp.h: Include "interps.h".
841 (struct cli_interp_base): New struct.
842 * interps.c (struct interp): Delete. Fields moved to interps.h.
843 (interp_new): Delete.
844 (interp::interp, interp::~interp): New.
845 (interp_set): Use bool, and return void. Assume the interpreter
846 has suspend, init and resume methods, and that the all return
847 void.
848 (set_top_level_interpreter): interp_set returns void.
849 (interp_ui_out): Adapt.
850 (current_interp_set_logging): Adapt.
851 (interp_data): Delete.
852 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
853 (interp_exec): Adapt.
854 (top_level_interpreter_data): Delete.
855 * interps.h (interp_init_ftype, interp_resume_ftype)
856 (interp_suspend_ftype, interp_exec_ftype)
857 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
858 (class interp): New.
859 (interp_new): Delete.
860 (interp_set): Now returns void. Use bool.
861 (interp_data, top_level_interpreter_data): Delete.
862 * mi/mi-common.h: Include interps.h.
863 (class mi_interp): Inherit from interp. Define a ctor. Declare
864 init, resume, suspect, exec, interp_ui_out, set_logging and
865 pre_command_loop methods.
866 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
867 (mi_interpreter_init): Rename to ...
868 (mi_interp::init): ... this. Remove the 'interp' parameter, use
869 bool, return void and make extern. Adjust.
870 (mi_interpreter_resume): ... Rename to ...
871 (mi_interp::resume): ... this. Remove the 'data' parameter,
872 return void and make extern. Adjust.
873 (mi_interpreter_suspend): ... Rename to ...
874 (mi_interp::suspend): ... this. Remove the 'data' parameter,
875 return void and make extern. Adjust.
876 (mi_interpreter_exec): ... Rename to ...
877 (mi_interp::exec): ... this. Remove the 'data' parameter and make
878 extern. Adjust.
879 (mi_interpreter_pre_command_loop): ... Rename to ...
880 (mi_interp::pre_command_loop): ... this. Remove the 'self'
881 parameter and make extern.
882 (mi_on_normal_stop_1): Adjust.
883 (mi_ui_out): Rename to ...
884 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
885 parameter and make extern. Adjust.
886 (mi_set_logging): Rename to ...
887 (mi_interp::set_logging): ... this. Remove the 'interp'
888 parameter and make extern. Adjust.
889 (mi_interp_procs): Delete.
890 (mi_interp_factory): Adjust to use 'new'.
891 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
892 (mi_print_exception, mi_execute_command, mi_load_progress):
893 Adjust.
894 * tui/tui-interp.c (tui_interp): New class.
895 (as_tui_interp): Return a tui_interp pointer.
896 (tui_on_normal_stop, tui_on_signal_received)
897 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
898 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
899 to use interp::interp_ui_out.
900 (tui_init): Rename to ...
901 (tui_interp::init): ... this. Remove the 'self' parameter, use
902 bool, return void and make extern. Adjust.
903 (tui_resume): Rename to ...
904 (tui_interp::resume): ... this. Remove the 'data' parameter,
905 return void and make extern. Adjust.
906 (tui_suspend): Rename to ...
907 (tui_interp::suspend): ... this. Remove the 'data' parameter,
908 return void and make extern. Adjust.
909 (tui_ui_out): Rename to ...
910 (tui_interp::interp_ui_out): ... this. Remove the 'self'
911 parameter, and make extern. Adjust.
912 (tui_exec): Rename to ...
913 (tui_interp::exec): ... this. Remove the 'data' parameter and
914 make extern.
915 (tui_interp_procs): Delete.
916 (tui_interp_factory): Use "new".
917
918 2017-02-02 Tom Tromey <tom@tromey.com>
919
920 * rust-exp.y (ends_raw_string, space_then_number)
921 (rust_identifier_start_p): Return bool.
922 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
923 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
924 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
925 (rust_chartype_p): Return bool.
926 (val_print_struct, rust_print_struct_def, rust_print_type):
927 Update.
928 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
929 Return bool.
930
931 2017-02-02 Tom Tromey <tom@tromey.com>
932
933 * rust-lang.c: Reindent.
934
935 2017-02-02 Tom Tromey <tom@tromey.com>
936
937 * rust-lang.h (rust_crate_for_block): Update.
938 * rust-lang.c (rust_crate_for_block): Return std::string.
939 (rust_get_disr_info): Use std:;string, not
940 gdb::unique_xmalloc_ptr.
941 * rust-exp.y (crate_name): Update.
942
943 2017-02-02 Pedro Alves <palves@redhat.com>
944
945 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
946 field out of gdb_disassembler_test and make it static.
947
948 2017-02-02 Pedro Alves <palves@redhat.com>
949
950 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
951 mi1_interp and mi_interp fields.
952
953 2017-02-02 Pedro Alves <palves@redhat.com>
954
955 * cli/cli-interp.c (struct saved_output_files, saved_output):
956 Moved from cli/cli-logging.c.
957 (cli_set_logging): New function.
958 (cli_interp_procs): Install cli_set_logging.
959 * cli/cli-interp.h (make_logging_output, cli_set_logging):
960 Declare.
961 * cli/cli-logging.c (struct saved_output_files, saved_output):
962 Moved to cli/cli-interp.c.
963 (pop_output_files): Don't save outputs here.
964 (make_logging_output): New function.
965 (handle_redirections): Don't build tee nor save previous outputs
966 here.
967 * interps.c (current_interp_set_logging): Change prototype.
968 Assume there's always a set_logging_proc method installed.
969 * interps.h (interp_set_logging_ftype): Change prototype.
970 (current_interp_set_logging): Change prototype and adjust comment.
971 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
972 use make_logging_output.
973 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
974 2017-02-02 Pedro Alves <palves@redhat.com>
975
976 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
977 from ...
978 (set_logging_overwrite): ... here.
979 (logging_no_redirect_file): Delete.
980 (set_logging_redirect): Don't handle redirection on the fly.
981 Instead warn that "logging off" / "logging on" is necessary.
982 (pop_output_files): Delete references to logging_no_redirect_file.
983 (show_logging_command): Always speak in terms of what will happen
984 once logging is reenabled.
985
986 2017-02-02 Pedro Alves <palves@redhat.com>
987
988 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
989
990 2017-02-02 Pedro Alves <palves@redhat.com>
991
992 * disasm.c (gdb_pretty_print_insn): Rename to ...
993 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
994 Remove gdbarch parameter. Adapt to clear the object's buffers
995 instead of allocating new buffers, and to print using the object's
996 gdb_disassembler instead of calling gdb_print_insn.
997 (dump_insns): Use gdb_pretty_print_disassembler.
998 * disasm.h (gdb_pretty_print_insn): Delete declaration.
999 (gdb_pretty_print_disassembler): New class.
1000 * record-btrace.c (btrace_insn_history): Use
1001 gdb_pretty_print_disassembler.
1002
1003 2017-02-02 Pedro Alves <palves@redhat.com>
1004
1005 * ada-lang.c (type_as_string): Use string_file.
1006 * ada-valprint.c (ada_print_floating): Use string_file.
1007 * ada-varobj.c (ada_varobj_scalar_image)
1008 (ada_varobj_get_value_image): Use string_file.
1009 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
1010 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
1011 * breakpoint.c (update_inserted_breakpoint_locations)
1012 (insert_breakpoint_locations, reattach_breakpoints)
1013 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
1014 (print_it_watchpoint): Use string_file.
1015 (save_breakpoints): Use stdio_file.
1016 * c-exp.y (oper): Use string_file.
1017 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
1018 tee_file.
1019 (pop_output_files): Use delete.
1020 (handle_redirections): Use stdio_file and tee_file.
1021 * cli/cli-setshow.c (do_show_command): Use string_file.
1022 * compile/compile-c-support.c (c_compute_program): Use
1023 string_file.
1024 * compile/compile-c-symbols.c (generate_vla_size): Take a
1025 'string_file &' instead of a 'ui_file *'.
1026 (generate_c_for_for_one_variable): Take a 'string_file &' instead
1027 of a 'ui_file *'. Use string_file.
1028 (generate_c_for_variable_locations): Take a 'string_file &'
1029 instead of a 'ui_file *'.
1030 * compile/compile-internal.h (generate_c_for_for_one_variable):
1031 Take a 'string_file &' instead of a 'ui_file *'.
1032 * compile/compile-loc2c.c (push, pushf, unary, binary)
1033 (print_label, pushf_register_address, pushf_register)
1034 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
1035 'ui_file *'. Adjust.
1036 * compile/compile.c (compile_to_object): Use string_file.
1037 * compile/compile.h (compile_dwarf_expr_to_c)
1038 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
1039 'ui_file *'.
1040 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
1041 (replace_typedefs_qualified_name): Use string_file and
1042 obstack_copy0.
1043 * disasm.c (gdb_pretty_print_insn): Use string_file.
1044 (gdb_disassembly): Adjust reference the null_stream global.
1045 (do_ui_file_delete): Delete.
1046 (gdb_insn_length): Use null_stream.
1047 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
1048 * dwarf2loc.c (dwarf2_compile_property_to_c)
1049 (locexpr_generate_c_location, loclist_generate_c_location): Take a
1050 'string_file &' instead of a 'ui_file *'.
1051 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
1052 * dwarf2read.c (do_ui_file_peek_last): Delete.
1053 (dwarf2_compute_name): Use string_file.
1054 * event-top.c (gdb_setup_readline): Use stdio_file.
1055 * gdbarch.sh (verify_gdbarch): Use string_file.
1056 * gdbtypes.c (safe_parse_type): Use null_stream.
1057 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
1058 string_file.
1059 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
1060 'string_file *' instead of a 'ui_file *'.
1061 (gdbscm_arch_disassemble): Use string_file.
1062 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
1063 * guile/scm-ports.c (class ioscm_file_port): Now a class that
1064 inherits from ui_file.
1065 (ioscm_file_port_delete, ioscm_file_port_rewind)
1066 (ioscm_file_port_put): Delete.
1067 (ioscm_file_port_write): Rename to ...
1068 (ioscm_file_port::write): ... this. Remove file_port_magic
1069 checks.
1070 (ioscm_file_port_new): Delete.
1071 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
1072 ui_file_up.
1073 * guile/scm-type.c (tyscm_type_name): Use string_file.
1074 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
1075 Use string_file.
1076 * infcmd.c (print_return_value_1): Use string_file.
1077 * infrun.c (print_target_wait_results): Use string_file.
1078 * language.c (add_language): Use string_file.
1079 * location.c (explicit_to_string_internal): Use string_file.
1080 * main.c (captured_main_1): Use null_file.
1081 * maint.c (maintenance_print_architecture): Use stdio_file.
1082 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
1083 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
1084 event_channel>: Change type to mi_console_file pointer.
1085 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
1086 (mi_console_file_delete): Delete.
1087 (struct mi_console_file): Delete.
1088 (mi_console_file_magic): Delete.
1089 (mi_console_file_new): Delete.
1090 (mi_console_file::mi_console_file): New.
1091 (mi_console_file_delete): Delete.
1092 (mi_console_file_fputs): Delete.
1093 (mi_console_file::write): New.
1094 (mi_console_raw_packet): Delete.
1095 (mi_console_file::flush): New.
1096 (mi_console_file_flush): Delete.
1097 (mi_console_set_raw): Rename to ...
1098 (mi_console_file::set_raw): ... this.
1099 * mi/mi-console.h (class mi_console_file): New class.
1100 (mi_console_file_new, mi_console_set_raw): Delete.
1101 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
1102 (mi_set_logging): Use delete and tee_file. Adjust.
1103 * mi/mi-main.c (output_register): Use string_file.
1104 (mi_cmd_data_evaluate_expression): Use string_file.
1105 (mi_cmd_data_read_memory): Use string_file.
1106 (mi_cmd_execute, print_variable_or_computed): Use string_file.
1107 * mi/mi-out.c (mi_ui_out::main_stream): New.
1108 (mi_ui_out::rewind): Use main_stream and
1109 string_file.
1110 (mi_ui_out::put): Use main_stream and string_file.
1111 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
1112 Allocate a 'string_file' instead.
1113 (mi_out_new): Don't allocate a mem_fileopen stream here.
1114 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
1115 (mi_ui_out::main_stream): Declare method.
1116 * printcmd.c (eval_command): Use string_file.
1117 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
1118 * python/py-arch.c (archpy_disassemble): Use string_file.
1119 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
1120 * python/py-frame.c (frapy_str): Use string_file.
1121 * python/py-framefilter.c (py_print_type, py_print_single_arg):
1122 Use string_file.
1123 * python/py-type.c (typy_str): Use string_file.
1124 * python/py-unwind.c (unwind_infopy_str): Use string_file.
1125 * python/py-value.c (valpy_str): Use string_file.
1126 * record-btrace.c (btrace_insn_history): Use string_file.
1127 * regcache.c (regcache_print): Use stdio_file.
1128 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
1129 * remote.c (escape_buffer): Use string_file.
1130 * rust-lang.c (rust_get_disr_info): Use string_file.
1131 * serial.c (serial_open_ops_1): Use stdio_file.
1132 (do_serial_close): Use delete.
1133 * stack.c (print_frame_arg): Use string_file.
1134 (print_frame_args): Remove local mem_fileopen stream, not used.
1135 (print_frame): Use string_file.
1136 * symmisc.c (maintenance_print_symbols): Use stdio_file.
1137 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1138 Take a 'string_file *' instead of a 'ui_file *'.
1139 * top.c (new_ui): Use stdio_file and stderr_file.
1140 (free_ui): Use delete.
1141 (execute_command_to_string): Use string_file.
1142 (quit_confirm): Use string_file.
1143 * tracepoint.c (collection_list::append_exp): Use string_file.
1144 * tui/tui-disasm.c (tui_disassemble): Use string_file.
1145 * tui/tui-file.c: Don't include "ui-file.h".
1146 (enum streamtype, struct tui_stream): Delete.
1147 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
1148 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
1149 (tui_file::tui_file): New method.
1150 (tui_file_fputs): Delete.
1151 (tui_file_get_strbuf): Delete.
1152 (tui_file::puts): New method.
1153 (tui_file_adjust_strbuf): Delete.
1154 (tui_file_flush): Delete.
1155 (tui_file::flush): New method.
1156 * tui/tui-file.h: Tweak intro comment.
1157 Include ui-file.h.
1158 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
1159 (tui_file_adjust_strbuf): Delete declarations.
1160 (class tui_file): New class.
1161 * tui/tui-io.c (tui_initialize_io): Use tui_file.
1162 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
1163 (tui_register_format): Use string_stream.
1164 * tui/tui-stack.c (tui_make_status_line): Use string_file.
1165 (tui_get_function_from_frame): Use string_file.
1166 * typeprint.c (type_to_string): Use string_file.
1167 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
1168 (null_stream): New global.
1169 (ui_file_delete): Delete.
1170 (ui_file::ui_file): New.
1171 (null_file_isatty): Delete.
1172 (ui_file::~ui_file): New.
1173 (null_file_rewind): Delete.
1174 (ui_file::printf): New.
1175 (null_file_put): Delete.
1176 (null_file_flush): Delete.
1177 (ui_file::putstr): New.
1178 (null_file_write): Delete.
1179 (ui_file::putstrn): New.
1180 (null_file_read): Delete.
1181 (ui_file::putc): New.
1182 (null_file_fputs): Delete.
1183 (null_file_write_async_safe): Delete.
1184 (ui_file::vprintf): New.
1185 (null_file_delete): Delete.
1186 (null_file::write): New.
1187 (null_file_fseek): Delete.
1188 (null_file::puts): New.
1189 (ui_file_data): Delete.
1190 (null_file::write_async_safe): New.
1191 (gdb_flush, ui_file_isatty): Adjust.
1192 (ui_file_put, ui_file_rewind): Delete.
1193 (ui_file_write): Adjust.
1194 (ui_file_write_for_put): Delete.
1195 (ui_file_write_async_safe, ui_file_read): Adjust.
1196 (ui_file_fseek): Delete.
1197 (fputs_unfiltered): Adjust.
1198 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
1199 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
1200 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
1201 (set_ui_file_data): Delete.
1202 (string_file::~string_file, string_file::write)
1203 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
1204 (do_ui_file_as_string, ui_file_as_string): Delete.
1205 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
1206 (struct mem_file): Delete.
1207 (mem_file_new): Delete.
1208 (stdio_file::stdio_file): New.
1209 (mem_file_delete): Delete.
1210 (stdio_file::stdio_file): New.
1211 (mem_fileopen): Delete.
1212 (stdio_file::~stdio_file): New.
1213 (mem_file_rewind): Delete.
1214 (stdio_file::set_stream): New.
1215 (mem_file_put): Delete.
1216 (stdio_file::open): New.
1217 (mem_file_write): Delete.
1218 (stdio_file_magic, struct stdio_file): Delete.
1219 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
1220 (stdio_file::flush): New.
1221 (stdio_file_read): Rename to ...
1222 (stdio_file::read): ... this. Adjust.
1223 (stdio_file_write): Rename to ...
1224 (stdio_file::write): ... this. Adjust.
1225 (stdio_file_write_async_safe): Rename to ...
1226 (stdio_file::write_async_safe) ... this. Adjust.
1227 (stdio_file_fputs): Rename to ...
1228 (stdio_file::puts) ... this. Adjust.
1229 (stdio_file_isatty): Delete.
1230 (stdio_file_fseek): Delete.
1231 (stdio_file::isatty): New.
1232 (stderr_file_write): Rename to ...
1233 (stderr_file::write) ... this. Adjust.
1234 (stderr_file_fputs): Rename to ...
1235 (stderr_file::puts) ... this. Adjust.
1236 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
1237 (stderr_file::stderr_file): New.
1238 (tee_file_magic): Delete.
1239 (struct tee_file): Delete.
1240 (tee_file::tee_file): New.
1241 (tee_file_new): Delete.
1242 (tee_file::~tee_file): New.
1243 (tee_file_delete): Delete.
1244 (tee_file_flush): Rename to ...
1245 (tee_file::flush): ... this. Adjust.
1246 (tee_file_write): Rename to ...
1247 (tee_file::write): ... this. Adjust.
1248 (tee_file::write_async_safe): New.
1249 (tee_file_fputs): Rename to ...
1250 (tee_file::puts): ... this. Adjust.
1251 (tee_file_isatty): Rename to ...
1252 (tee_file::isatty): ... this. Adjust.
1253 * ui-file.h (struct obstack, struct ui_file): Don't
1254 forward-declare.
1255 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
1256 (ui_file_write_ftype)
1257 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
1258 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
1259 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
1260 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
1261 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
1262 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
1263 (set_ui_file_fseek): Delete.
1264 (ui_file_data, ui_file_delete, ui_file_rewind)
1265 (struct ui_file): New.
1266 (ui_file_up): New.
1267 (class null_file): New.
1268 (null_stream): Declare.
1269 (ui_file_write_for_put, ui_file_put): Delete.
1270 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
1271 Delete.
1272 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
1273 (gdb_fopen, tee_file_new): Delete.
1274 (struct string_file): New.
1275 (struct stdio_file): New.
1276 (stdio_file_up): New.
1277 (struct stderr_file): New.
1278 (class tee_file): New.
1279 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
1280 of a 'ui_file *'. Adjust.
1281 * ui-out.h (class ui_out) <field_stream>: Likewise.
1282 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
1283 (null_stream): Delete.
1284 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
1285 Adjust.
1286 * utils.h (struct ui_file): Delete forward declaration..
1287 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
1288 (error_stream): Take a 'string_file &' instead of a
1289 'ui_file *'.
1290 * varobj.c (varobj_value_get_print_value): Use string_file.
1291 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
1292 * gdbarch.c: Regenerate.
1293
1294 2017-02-02 Pedro Alves <palves@redhat.com>
1295
1296 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
1297 (gdb_pretty_print_insn): ... this. Now a free function. Add back
1298 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
1299 Adjust to call gdb_print_insn instead of
1300 gdb_disassembler::print_insn.
1301 (dump_insns, do_mixed_source_and_assembly_deprecated)
1302 (do_mixed_source_and_assembly, do_assembly_only): Add back a
1303 'gdbarch' parameter. Remove gdb_disassembler parameter.
1304 (gdb_disassembly): Don't allocate a gdb_disassembler here.
1305 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
1306 declaration.
1307 (gdb_pretty_print_insn): Re-add declaration.
1308 * record-btrace.c (btrace_insn_history): Don't allocate a
1309 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
1310
1311 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
1312
1313 * disasm.h (gdb_disassembly): Remove file_string parameter.
1314 * disasm.c (gdb_disassembly): Likewise.
1315 * cli/cli-cmds.c (print_disassembly): Adapt.
1316 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
1317 * stack.c (do_gdb_disassembly): Likewise.
1318
1319 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
1320
1321 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
1322 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
1323 targets. And if the implicit value is longer than needed, extract
1324 the first bytes instead of the "least significant" ones.
1325
1326 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
1327
1328 * btrace.c (btrace_enable): Do not call btrace_add_pc for
1329 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
1330 (btrace_fetch): Assert can_access_registers_ptid.
1331 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
1332 validate_registers_access.
1333
1334 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
1335
1336 * gdbthread.h (can_access_registers_ptid): New.
1337 * thread.c (can_access_registers_ptid): New.
1338
1339 2017-02-01 Pedro Alves <palves@redhat.com>
1340
1341 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
1342
1343 2017-01-31 Pedro Alves <palves@redhat.com>
1344
1345 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
1346 Fix typos.
1347
1348 2017-01-31 Pedro Alves <palves@redhat.com>
1349
1350 * stack.c (print_frame_args): Remove local mem_fileopen stream,
1351 not used.
1352
1353 2017-01-31 Pedro Alves <palves@redhat.com>
1354
1355 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
1356
1357 2017-01-31 Pedro Alves <palves@redhat.com>
1358
1359 * common/scoped_restore.h
1360 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
1361 change the value's parameter type to T2.
1362 (make_scoped_restore): Likewise.
1363
1364 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
1365 Richard Henderson <rth@redhat.com>
1366
1367 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
1368 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
1369 GS_BASE for older kernels.
1370 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
1371 GS_BASE for older kernels.
1372 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
1373 and GS_BASE to the offset table.
1374 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
1375 system register group.
1376 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
1377 for older kernels.
1378 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
1379 amd64 ABI.
1380 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
1381 AMD64_GSBASE_REGNUM.
1382 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
1383 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
1384 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
1385 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
1386 i386/64bit-segments.xml in those rules.
1387 * features/i386/64bit-segments.xml: New file.
1388 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
1389 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
1390 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
1391 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
1392 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
1393 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
1394 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
1395 * features/i386/amd64-avx-linux.c: Regenerated.
1396 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
1397 * features/i386/amd64-avx-mpx.c: Regenerated.
1398 * features/i386/amd64-avx512-linux.c: Regenerated.
1399 * features/i386/amd64-linux.c: Regenerated.
1400 * features/i386/amd64-mpx-linux.c: Regenerated.
1401 * features/i386/i386-avx-mpx-linux.c: Regenerated.
1402 * features/i386/i386-avx-mpx.c: Regenerated.
1403 * features/i386/x32-avx-linux.c: Regenerated.
1404 * features/i386/x32-avx512-linux.c: Regenerated.
1405 * regformats/i386/amd64-avx-linux.dat: Regenerated.
1406 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
1407 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
1408 * regformats/i386/amd64-linux.dat: Regenerated.
1409 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
1410 * regformats/i386/x32-avx-linux.dat: Regenerated.
1411 * regformats/i386/x32-avx512-linux.dat: Regenerated.
1412 * regformats/i386/x32-linux.dat: Regenerated.
1413
1414 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
1415
1416 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
1417 Set to AMD64_NUM_REGS.
1418
1419 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
1420
1421 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
1422 that checks validity of a register number.
1423
1424 2017-01-27 Kees Cook <keescook@google.com>
1425
1426 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
1427 fetch_fpregs if target has fpa registers.
1428 (arm_linux_store_inferior_registers): Call store_fpregs if target
1429 has fpa registers.
1430
1431 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
1432
1433 * cris-tdep.c (cris_gdbarch_init): Remove check for
1434 info.byte_order and force it to BFD_ENDIAN_LITTLE.
1435
1436 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
1437
1438 * corelow.c (get_core_register_section): Check for regset
1439 existence before checking for REGSET_VARIABLE_SIZE.
1440
1441 2017-01-26 Yao Qi <yao.qi@linaro.org>
1442 Pedro Alves <palves@redhat.com>
1443
1444 PR gdb/20939
1445 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
1446 call memory_error, save memaddr instead.
1447 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
1448 negative, cal memory_error.
1449 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
1450
1451 2017-01-26 Yao Qi <yao.qi@linaro.org>
1452
1453 * disasm-selftests.c (memory_error_test): New function.
1454 (_initialize_disasm_selftests): Register memory_error_test.
1455
1456 2017-01-26 Yao Qi <yao.qi@linaro.org>
1457
1458 * Makefile.in (SFILES): Add disasm-selftests.c and
1459 selftest-arch.c.
1460 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
1461 * disasm-selftests.c: New file.
1462 * selftest-arch.c: New file.
1463 * selftest-arch.h: New file.
1464
1465 2017-01-26 Yao Qi <yao.qi@linaro.org>
1466
1467 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
1468 to bfd_arch_mep. Don't return 0 if section is not
1469 found. Call print_insn_mep.
1470
1471 2017-01-26 Pedro Alves <palves@redhat.com>
1472 Yao Qi <yao.qi@linaro.org>
1473
1474 * arm-tdep.c: Include "disasm.h".
1475 (gdb_print_insn_arm): Update code to get gdbarch.
1476 * disasm.c (dis_asm_read_memory): Change it to
1477 gdb_disassembler::dis_asm_read_memory.
1478 (dis_asm_memory_error): Likewise.
1479 (dis_asm_print_address): Likewise.
1480 (gdb_pretty_print_insn): Change it to
1481 gdb_disassembler::pretty_print_insn.
1482 (dump_insns): Add one argument gdb_disassemlber. All
1483 callers updated.
1484 (do_mixed_source_and_assembly_deprecated): Likewise.
1485 (do_mixed_source_and_assembly): Likewise.
1486 (do_assembly_only): Likewise.
1487 (gdb_disassembler::gdb_disassembler): New.
1488 (gdb_disassembler::print_insn): New.
1489 * disasm.h (class gdb_disassembler): New.
1490 (gdb_pretty_print_insn): Remove declaration.
1491 (gdb_disassemble_info): Likewise.
1492 * guile/scm-disasm.c (class gdbscm_disassembler): New.
1493 (gdbscm_disasm_read_memory_worker): Update.
1494 (gdbscm_disasm_read_memory): Update.
1495 (gdbscm_disasm_memory_error): Remove.
1496 (gdbscm_disasm_print_address): Remove.
1497 (gdbscm_disassembler::gdbscm_disassembler): New.
1498 (gdbscm_print_insn_from_port): Update.
1499 * mips-tdep.c: Include disasm.h.
1500 (gdb_print_insn_mips): Update code to get gdbarch.
1501 * record-btrace.c (btrace_insn_history): Update.
1502 * spu-tdep.c: Include disasm.h.
1503 (struct spu_dis_asm_data): Remove.
1504 (struct spu_dis_asm_info): New.
1505 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
1506 SPU id.
1507 (gdb_print_insn_spu): Cast disassemble_info to
1508 spu_dis_asm_info.
1509
1510 2017-01-26 Yao Qi <yao.qi@linaro.org>
1511
1512 * disasm.c (do_ui_file_delete): Delete.
1513 (gdb_insn_length): Move code creating stream to ...
1514 * utils.c (null_stream): ... here. New function.
1515 * utils.h (null_stream): Declare.
1516
1517 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
1518
1519 * python/py-inferior.c (find_thread_object): Return directly
1520 from the loop. Remove "found" variable.
1521
1522 2017-01-21 Joel Brobecker <brobecker@adacore.com>
1523
1524 GDB 7.12.1 released.
1525
1526 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
1527
1528 * python/py-function.c (fnpy_call): Reorder declarations to have
1529 the gdbpy_enter object declared first.
1530 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
1531
1532 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
1533
1534 PR python/21068
1535 * python/python-internal.h (PyMem_RawMalloc): Define for
1536 Python < 3.4.
1537 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
1538 PyMem_RawMalloc instead of PyMem_Malloc.
1539
1540 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
1541 Luis Machado <lgustavo@codesourcery.com>
1542
1543 * NEWS (New commands): Mention flash-erase.
1544 (New MI commands): Mention target-flash-erase.
1545 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
1546 command.
1547 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
1548 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
1549 * target.c (flash_erase_command): New function.
1550 (initialize_targets): Add new flash-erase command.
1551 * target.h (flash_erase_command): New declaration.
1552
1553 2017-01-20 Joel Brobecker <brobecker@adacore.com>
1554
1555 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
1556 HAVE_SYS_PROCFS_H is defined.
1557
1558 2017-01-18 Alan Hayward <alan.hayward@arm.com>
1559
1560 * remote.c (struct cached_reg): Change data into a pointer.
1561 * (stop_reply_dtr): Free data pointers before deleting vector.
1562 (process_stop_reply): Likewise.
1563 (remote_parse_stop_reply): Allocate space for data
1564
1565 2017-01-18 Alan Hayward <alan.hayward@arm.com>
1566
1567 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
1568 MAX_REGISTER_SIZE.
1569 (amd64_pseudo_register_read_value): Likewise.
1570 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
1571 (store_register_using_P): Likewise.
1572 * regcache.c (regcache_xfer_part): Likewise.
1573
1574 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
1575
1576 Split real and pseudo registers.
1577 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
1578 (sparc32_pseudo_regnum): New enum.
1579 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
1580 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
1581 (SPARC32_CP0_REGISTERS): New macro.
1582 (sparc32_pseudo_register_name): New function.
1583 (sparc32_register_name): Use sparc32_pseudo_register_name.
1584 (sparc32_pseudo_register_type): New function.
1585 (sparc32_register_type): Use sparc32_pseudo_register_type.
1586 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
1587 pseudo register numbers.
1588 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
1589 (SPARC64_CP0_REGISTERS): New macro.
1590 (sparc64_pseudo_register_name): New function.
1591 (sparc64_register_name): Use sparc64_pseudo_register_name.
1592 (sparc64_pseudo_register_type): New function.
1593 (sparc64_register_type): Use sparc64_pseudo_register_type.
1594 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
1595 pseudo register numbers.
1596 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
1597 sparc64_store_arguments): Handle pseudo register numbers.
1598
1599 2017-01-13 Yao Qi <yao.qi@linaro.org>
1600
1601 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
1602 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
1603 output.
1604 (getpkt_or_notif_sane_1): Likewise.
1605
1606 2017-01-13 Yao Qi <yao.qi@linaro.org>
1607
1608 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
1609 of CC. Pass "-x c++-header" instead of "-x c".
1610
1611 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
1612
1613 * remote.c (remote_can_async_p): Update comment.
1614
1615 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
1616
1617 * linux-nat.c (linux_nat_can_async_p): Update comment.
1618
1619 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
1620
1621 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
1622
1623 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
1624
1625 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
1626
1627 2017-01-10 Tom Tromey <tom@tromey.com>
1628
1629 * python/py-type.c (typy_legacy_template_argument): Update.
1630 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
1631 ~demangle_parse_info): Declare new members.
1632 (cp_demangled_name_to_comp): Return unique_ptr.
1633 (cp_demangled_name_parse_free)
1634 (make_cleanup_cp_demangled_name_parse_free)
1635 (cp_new_demangle_parse_info): Remove.
1636 * cp-support.c (do_demangled_name_parse_free_cleanup)
1637 (make_cleanup_cp_demangled_name_parse_free): Remove.
1638 (inspect_type, cp_canonicalize_string_full)
1639 (cp_canonicalize_string): Update.
1640 (mangled_name_to_comp): Change return type.
1641 (cp_class_name_from_physname, method_name_from_physname)
1642 (cp_func_name, cp_remove_params): Update.
1643 * cp-name-parser.y (demangle_parse_info): New constructor, from
1644 cp_new_demangle_parse_info.
1645 (~demangle_parse_info): New destructor, from
1646 cp_demangled_name_parse_free.
1647 (cp_merge_demangle_parse_infos): Update.
1648 (cp_demangled_name_to_comp): Change return type.
1649
1650 2017-01-10 Tom Tromey <tom@tromey.com>
1651
1652 * top.c (prevent_dont_repeat): Change return type.
1653 * python/python.c (execute_gdb_command): Use std::string.
1654 Update.
1655 * guile/guile.c (gdbscm_execute_gdb_command): Update.
1656 * command.h (prevent_dont_repeat): Change return type.
1657 * breakpoint.c (bpstat_do_actions_1): Update.
1658
1659 2017-01-10 Tom Tromey <tom@tromey.com>
1660
1661 * value.h (scoped_value_mark::~scoped_value_mark): Call
1662 free_to_mark.
1663 (scoped_value_mark::free_to_mark): New method.
1664 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
1665 scoped_value_mark.
1666
1667 2017-01-10 Tom Tromey <tom@tromey.com>
1668
1669 * python/py-value.c (valpy_dereference, valpy_referenced_value)
1670 (valpy_reference_value, valpy_const_value, valpy_get_address)
1671 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
1672 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
1673 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
1674 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
1675 scoped_value_mark.
1676 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
1677 * value.h (scoped_value_mark): New class.
1678
1679 2017-01-10 Tom Tromey <tom@tromey.com>
1680
1681 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
1682 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
1683 * psymtab.c (discard_psymtabs_upto): Remove.
1684 (make_cleanup_discard_psymtabs): Remove.
1685 (struct psymtab_state): Remove.
1686
1687 2017-01-10 Tom Tromey <tom@tromey.com>
1688
1689 * record-full.c (record_full_save_cleanups): Remove.
1690 (record_full_save): Use gdb::unlinker.
1691 * gcore.c (do_bfd_delete_cleanup): Remove.
1692 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
1693 cleanups.
1694 * dwarf2read.c (unlink_if_set): Remove.
1695 (write_psymtabs_to_index): Use gdb::unlinker.
1696 * common/gdb_unlinker.h: New file.
1697
1698 2017-01-10 Tom Tromey <tom@tromey.com>
1699
1700 * windows-tdep.c (windows_xfer_shared_library): Update.
1701 * windows-nat.c (windows_make_so): Update.
1702 * utils.h (make_cleanup_bfd_unref): Remove.
1703 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
1704 * symfile.h (symfile_bfd_open)
1705 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
1706 * symfile.c (read_symbols, symbol_file_add)
1707 (separate_debug_file_exists): Update.
1708 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
1709 (generic_load, reread_symbols): Update.
1710 * symfile-mem.c (symbol_file_add_from_memory): Update.
1711 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
1712 (spu_symbol_file_add_from_memory): Update.
1713 * solist.h (struct target_so_ops) <bfd_open>: Return
1714 gdb_bfd_ref_ptr.
1715 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
1716 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
1717 gdb_bfd_ref_ptr.
1718 (solib_map_sections, reload_shared_libraries_1): Update.
1719 * solib-svr4.c (enable_break): Update.
1720 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
1721 * solib-frv.c (enable_break2): Update.
1722 * solib-dsbt.c (enable_break): Update.
1723 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
1724 gdb_bfd_ref_ptr.
1725 (darwin_solib_get_all_image_info_addr_at_init): Update.
1726 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
1727 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
1728 * record-full.c (record_full_save): Update.
1729 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
1730 * procfs.c (insert_dbx_link_bpt_in_file): Update.
1731 * minidebug.c (find_separate_debug_file_in_section): Return
1732 gdb_bfd_ref_ptr.
1733 * machoread.c (macho_add_oso_symfile): Change abfd to
1734 gdb_bfd_ref_ptr.
1735 (macho_symfile_read_all_oso): Update.
1736 (macho_check_dsym): Return gdb_bfd_ref_ptr.
1737 (macho_symfile_read): Update.
1738 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
1739 (jit_bfd_try_read_symtab): Update.
1740 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
1741 (gdb_bfd_openw, gdb_bfd_openr_iovec)
1742 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
1743 gdb_bfd_ref_ptr.
1744 (gdb_bfd_ref_policy): New struct.
1745 (gdb_bfd_ref_ptr): New typedef.
1746 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
1747 (gdb_bfd_openw, gdb_bfd_openr_iovec)
1748 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
1749 gdb_bfd_ref_ptr.
1750 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
1751 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
1752 (gcore_command): Update.
1753 * exec.c (exec_file_attach): Update.
1754 * elfread.c (elf_symfile_read): Update.
1755 * dwarf2read.c (dwarf2_get_dwz_file): Update.
1756 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
1757 (open_and_init_dwo_file): Update.
1758 (open_dwp_file): Return gdb_bfd_ref_ptr.
1759 (open_and_init_dwp_file): Update.
1760 * corelow.c (core_open): Update.
1761 * compile/compile-object-load.c (compile_object_load): Update.
1762 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
1763 * coffread.c (coff_symfile_read): Update.
1764 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
1765 gdb_bfd_ref_ptr. Rename.
1766 (dump_bfd_file, restore_command): Update.
1767 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
1768 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
1769 (find_separate_debug_file_by_buildid): Update.
1770
1771 2017-01-10 Tom Tromey <tom@tromey.com>
1772
1773 * common/gdb_ref_ptr.h: New file.
1774 * python/py-ref.h (struct gdbpy_ref_policy): New.
1775 (gdbpy_ref): Now a typedef.
1776
1777 2017-01-10 Tom Tromey <tom@tromey.com>
1778
1779 * utils.h (make_cleanup_htab_delete): Don't declare.
1780 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
1781 Remove.
1782 * linespec.c (decode_compound_collector): Add constructor,
1783 destructor.
1784 (lookup_prefix_sym): Remove cleanup.
1785 (symtab_collector): Add constructor, destructor.
1786 (collect_symtabs_from_filename): Remove cleanup.
1787 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
1788 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
1789 Use htab_up.
1790 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
1791 * dwarf2read.c (dw2_expand_symtabs_matching)
1792 (dw2_map_symbol_filenames, dwarf_decode_macros)
1793 (write_psymtabs_to_index): Use htab_up.
1794 * dwarf2loc.c (func_verify_no_selftailcall)
1795 (call_site_find_chain_1, func_verify_no_selftailcall)
1796 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
1797 std::vector, gdb::unique_xmalloc_ptr.
1798 (call_sitep): Remove typedef.
1799 (dwarf2_locexpr_baton_eval): Remove unused variable.
1800
1801 2017-01-10 Tom Tromey <tom@tromey.com>
1802
1803 * python/python-internal.h (make_cleanup_py_decref)
1804 (make_cleanup_py_xdecref): Don't declare.
1805 * python/py-utils.c (py_decref, make_cleanup_py_decref)
1806 (py_xdecref, make_cleanup_py_xdecref): Remove.
1807
1808 2017-01-10 Tom Tromey <tom@tromey.com>
1809
1810 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
1811 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
1812
1813 2017-01-10 Tom Tromey <tom@tromey.com>
1814
1815 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
1816
1817 2017-01-10 Tom Tromey <tom@tromey.com>
1818
1819 * python/py-utils.c (unicode_to_encoded_string)
1820 (python_string_to_target_string)
1821 (python_string_to_target_python_string)
1822 (python_string_to_host_string, gdbpy_obj_to_string)
1823 (get_addr_from_python): Use gdbpy_ref.
1824
1825 2017-01-10 Tom Tromey <tom@tromey.com>
1826
1827 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
1828 gdbpy_ref.
1829
1830 2017-01-10 Tom Tromey <tom@tromey.com>
1831
1832 * python/python.c (eval_python_command, gdbpy_decode_line)
1833 (gdbpy_run_events, gdbpy_start_type_printers)
1834 (gdbpy_apply_type_printers): Use gdbpy_ref.
1835
1836 2017-01-10 Tom Tromey <tom@tromey.com>
1837
1838 * python/py-param.c (get_doc_string, compute_enum_values): Use
1839 gdbpy_ref.
1840
1841 2017-01-10 Tom Tromey <tom@tromey.com>
1842
1843 * python/py-inferior.c (find_thread_object, build_inferior_list):
1844 Use gdbpy_ref.
1845
1846 2017-01-10 Tom Tromey <tom@tromey.com>
1847
1848 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
1849
1850 2017-01-10 Tom Tromey <tom@tromey.com>
1851
1852 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
1853 gdbpy_ref.
1854
1855 2017-01-10 Tom Tromey <tom@tromey.com>
1856
1857 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
1858 extra incref.
1859 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
1860 Use gdbpy_ref.
1861
1862 2017-01-10 Tom Tromey <tom@tromey.com>
1863
1864 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
1865 gdbpy_ref.
1866
1867 2017-01-10 Tom Tromey <tom@tromey.com>
1868
1869 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
1870 decref results of PyArg_ParseTupleAndKeywords.
1871
1872 2017-01-10 Tom Tromey <tom@tromey.com>
1873
1874 * python/python.c (python_run_simple_file): Use
1875 unique_xmalloc_ptr, gdbpy_ref.
1876
1877 2017-01-10 Tom Tromey <tom@tromey.com>
1878
1879 * python/py-prettyprint.c (print_stack_unless_memory_error)
1880 (print_string_repr, print_children): Use gdbpy_ref.
1881 (dummy_python_frame): New class.
1882 (dummy_python_frame::dummy_python_frame): Rename from
1883 push_dummy_python_frame.
1884 (py_restore_tstate): Remove.
1885
1886 2017-01-10 Tom Tromey <tom@tromey.com>
1887
1888 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
1889
1890 2017-01-10 Tom Tromey <tom@tromey.com>
1891
1892 * python/python.c (ensure_python_env, restore_python_env):
1893 Remove.
1894 * python/python-internal.h (ensure_python_env): Don't declare.
1895 * varobj.h (varobj_ensure_python_env): Don't declare.
1896 * varobj.c (varobj_ensure_python_env): Remove.
1897
1898 2017-01-10 Tom Tromey <tom@tromey.com>
1899
1900 * varobj.c (varobj_value_get_print_value): Use
1901 gdbpy_enter_varobj.
1902
1903 2017-01-10 Tom Tromey <tom@tromey.com>
1904
1905 * python/py-prettyprint.c (print_string_repr, print_children):
1906 Update.
1907 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
1908 of "encoding".
1909 * varobj.c (varobj_value_get_print_value): Update.
1910 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
1911
1912 2017-01-10 Tom Tromey <tom@tromey.com>
1913
1914 * varobj.c (varobj_get_display_hint)
1915 (dynamic_varobj_has_child_method, install_new_value_visualizer)
1916 (varobj_set_visualizer, free_variable): Use
1917 gdbpy_enter_varobj.
1918
1919 2017-01-10 Tom Tromey <tom@tromey.com>
1920
1921 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
1922 (do_finish_initialization): New function. Use gdbpy_ref.
1923 (gdbpy_finish_initialization): Use gdbpy_enter. Call
1924 do_finish_initialization.
1925
1926 2017-01-10 Tom Tromey <tom@tromey.com>
1927
1928 * python/py-param.c (get_set_value, get_show_value): Use
1929 gdbpy_enter, gdbpy_ref.
1930
1931 2017-01-10 Tom Tromey <tom@tromey.com>
1932
1933 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
1934
1935 2017-01-10 Tom Tromey <tom@tromey.com>
1936
1937 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
1938
1939 2017-01-10 Tom Tromey <tom@tromey.com>
1940
1941 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
1942 Use gdbpy_enter_varobj.
1943
1944 2017-01-10 Tom Tromey <tom@tromey.com>
1945
1946 * varobj.c (gdbpy_enter_varobj): New constructor.
1947 * python/python-internal.h (gdbpy_enter_varobj): New class.
1948 * python/py-varobj.c (py_varobj_get_iterator): Use
1949 gdbpy_enter_varobj.
1950
1951 2017-01-10 Tom Tromey <tom@tromey.com>
1952
1953 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
1954 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
1955 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
1956 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
1957 unique_xmalloc_ptr.
1958 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
1959
1960 2017-01-10 Tom Tromey <tom@tromey.com>
1961
1962 * python/py-xmethods.c (invoke_match_method): Use
1963 gdbpy_ref.
1964
1965 2017-01-10 Tom Tromey <tom@tromey.com>
1966
1967 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
1968 gdbpy_enter, gdbpy_ref.
1969
1970 2017-01-10 Tom Tromey <tom@tromey.com>
1971
1972 * python/python.c (python_interactive_command): Use gdbpy_enter.
1973
1974 2017-01-10 Tom Tromey <tom@tromey.com>
1975
1976 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
1977 gdbpy_ref.
1978
1979 2017-01-10 Tom Tromey <tom@tromey.com>
1980
1981 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
1982 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
1983
1984 2017-01-10 Tom Tromey <tom@tromey.com>
1985
1986 * utils.h (htab_deleter): New struct.
1987 (htab_up): New typedef.
1988 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
1989 gdbpy_enter, gdbpy_ref, htab_up.
1990
1991 2017-01-10 Tom Tromey <tom@tromey.com>
1992
1993 * python/py-unwind.c (pending_frame_invalidate): Remove.
1994 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
1995
1996 2017-01-10 Tom Tromey <tom@tromey.com>
1997
1998 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
1999 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
2000
2001 2017-01-10 Tom Tromey <tom@tromey.com>
2002
2003 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
2004
2005 2017-01-10 Tom Tromey <tom@tromey.com>
2006
2007 * python/python.c (gdbpy_eval_from_control_command)
2008 (gdbpy_source_script, gdbpy_run_events)
2009 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
2010 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
2011 gdbpy_enter.
2012
2013 2017-01-10 Tom Tromey <tom@tromey.com>
2014
2015 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
2016
2017 2017-01-10 Tom Tromey <tom@tromey.com>
2018
2019 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
2020
2021 2017-01-10 Tom Tromey <tom@tromey.com>
2022
2023 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
2024 (python_on_inferior_call_pre, python_on_inferior_call_post)
2025 (python_on_memory_change, python_on_register_change)
2026 (python_inferior_exit, python_new_objfile, add_thread_object)
2027 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
2028
2029 2017-01-10 Tom Tromey <tom@tromey.com>
2030
2031 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
2032 (bpfinishpy_handle_exit): Use gdbpy_enter.
2033
2034 2017-01-10 Tom Tromey <tom@tromey.com>
2035
2036 * python/py-cmd.c (cmdpy_destroyer)
2037 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
2038 gdbpy_enter.
2039
2040 2017-01-10 Tom Tromey <tom@tromey.com>
2041
2042 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
2043 gdbpy_enter.
2044 (gdbpy_breakpoint_has_cond): Likewise.
2045
2046 2017-01-10 Tom Tromey <tom@tromey.com>
2047
2048 * python/python.c (gdbpy_enter): New constructor.
2049 (~gdbpy_enter): New destructor.
2050 (restore_python_env, ensure_python_env): Rewrite.
2051 * python/python-internal.h (gdbpy_enter): New class.
2052
2053 2017-01-10 Tom Tromey <tom@tromey.com>
2054
2055 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
2056
2057 2017-01-10 Tom Tromey <tom@tromey.com>
2058
2059 * python/py-value.c (value_has_field, get_field_flag)
2060 (get_field_type, valpy_getitem, convert_value_from_python): Use
2061 gdbpy_ref.
2062
2063 2017-01-10 Tom Tromey <tom@tromey.com>
2064
2065 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
2066 gdbpy_ref.
2067
2068 2017-01-10 Tom Tromey <tom@tromey.com>
2069
2070 * python/py-prettyprint.c (search_pp_list)
2071 (find_pretty_printer_from_objfiles)
2072 (find_pretty_printer_from_progspace)
2073 (find_pretty_printer_from_gdb, find_pretty_printer)
2074 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
2075 gdbpy_ref.
2076
2077 2017-01-10 Tom Tromey <tom@tromey.com>
2078
2079 * python/py-param.c (call_doc_function): Use gdbpy_ref.
2080
2081 2017-01-10 Tom Tromey <tom@tromey.com>
2082
2083 * python/py-linetable.c (build_line_table_tuple_from_pcs)
2084 (ltpy_get_all_source_lines): Use gdbpy_ref.
2085
2086 2017-01-10 Tom Tromey <tom@tromey.com>
2087
2088 * python/py-framefilter.c (extract_sym, extract_value)
2089 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
2090 gdbpy_ref.
2091
2092 2017-01-10 Tom Tromey <tom@tromey.com>
2093
2094 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
2095
2096 2017-01-10 Tom Tromey <tom@tromey.com>
2097
2098 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
2099
2100 2017-01-10 Tom Tromey <tom@tromey.com>
2101
2102 * python/py-function.c (convert_values_to_python, fnpy_init): Use
2103 gdbpy_ref.
2104
2105 2017-01-10 Tom Tromey <tom@tromey.com>
2106
2107 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
2108
2109 2017-01-10 Tom Tromey <tom@tromey.com>
2110
2111 * python/py-type.c (convert_field, make_fielditem, typy_fields)
2112 (typy_range): Use gdbpy_ref.
2113
2114 2017-01-10 Tom Tromey <tom@tromey.com>
2115
2116 * python/py-threadevent.c (create_thread_event_object): Use
2117 gdbpy_ref.
2118 * python/py-stopevent.c (create_stop_event_object): Simplify.
2119 (emit_stop_event): Use gdbpy_ref.
2120 * python/py-signalevent.c (create_signal_event_object): Use
2121 gdbpy_ref.
2122 * python/py-newobjfileevent.c (create_new_objfile_event_object)
2123 (emit_new_objfile_event, create_clear_objfiles_event_object)
2124 (emit_clear_objfiles_event): Use gdbpy_ref.
2125 * python/py-infevents.c (create_inferior_call_event_object)
2126 (create_register_changed_event_object)
2127 (create_memory_changed_event_object, emit_inferior_call_event)
2128 (emit_memory_changed_event, emit_register_changed_event): Use
2129 gdbpy_ref.
2130 * python/py-exitedevent.c (create_exited_event_object)
2131 (emit_exited_event): Use gdbpy_ref.
2132 * python/py-event.h (evpy_emit_event): Remove
2133 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
2134 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
2135 * python/py-continueevent.c (emit_continue_event): Use
2136 gdbpy_ref.
2137 * python/py-breakpoint.c (gdbpy_breakpoint_created)
2138 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
2139 gdbpy_ref.
2140 * python/py-bpevent.c (create_breakpoint_event_object): Use
2141 gdbpy_ref.
2142
2143 2017-01-10 Tom Tromey <tom@tromey.com>
2144
2145 * python/py-ref.h: New file.
2146
2147 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
2148
2149 * cli-out.c (cli_ui_out::do_redirect): Change return type to
2150 void.
2151 * cli-out.h (cli_ui_out::do_redirect): Likewise.
2152 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
2153 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
2154 * ui-out.c (ui_out::redirect): Likewise.
2155 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
2156 * cli/cli-logging.c (set_logging_redirect): Update call site of
2157 ui_out::redirect.
2158 (handle_redirections): Likewise.
2159 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
2160 * top.c (execute_command_to_string): Likewise.
2161 * utils.c (do_ui_out_redirect_pop): Likewise.
2162
2163 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
2164
2165 * stack.c (_initialize_stack): Update "frame" command help message.
2166
2167 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
2168
2169 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
2170
2171 2017-01-06 Yao Qi <yao.qi@linaro.org>
2172
2173 * x86-linux-nat.h: Include gdb_proc_service.h.
2174
2175 2017-01-06 Yao Qi <yao.qi@linaro.org>
2176
2177 * ser-base.h: Include serial.h.
2178
2179 2017-01-06 Yao Qi <yao.qi@linaro.org>
2180
2181 * ppc-linux-tdep.h: Include ppc-tdep.h.
2182
2183 2017-01-06 Yao Qi <yao.qi@linaro.org>
2184
2185 * nat/amd64-linux-siginfo.h: Include signal.h.
2186
2187 2017-01-06 Yao Qi <yao.qi@linaro.org>
2188
2189 * nat/aarch64-linux-hw-point.h: Include break-common.h.
2190
2191 2017-01-06 Yao Qi <yao.qi@linaro.org>
2192
2193 * mi/mi-parse.h: Include mi-cmds.h.
2194
2195 2017-01-06 Yao Qi <yao.qi@linaro.org>
2196
2197 * inf-loop.c: Don't include "target.h".
2198 * inf-loop.h: Include it here.
2199
2200 2017-01-06 Yao Qi <yao.qi@linaro.org>
2201
2202 * dfp.h: Include "dboulest.h" and "expression.h".
2203
2204 2017-01-06 Yao Qi <yao.qi@linaro.org>
2205
2206 * ax-gdb.h: Include "ax.h".
2207
2208 2017-01-06 Yao Qi <yao.qi@linaro.org>
2209
2210 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
2211 with nat/gdb_ptrace.h.
2212
2213 2017-01-05 Yao Qi <yao.qi@linaro.org>
2214
2215 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
2216 new line.
2217 (mips64_fbsd_sigframe_init): Likewise.
2218
2219 2017-01-04 John Baldwin <jhb@FreeBSD.org>
2220
2221 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
2222 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
2223
2224 2017-01-04 John Baldwin <jhb@FreeBSD.org>
2225
2226 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
2227 * NEWS: Mention new FreeBSD/mips native configuration.
2228 * config/mips/fbsd.mh: New file.
2229 * configure.host: Add mips*-*-freebsd*.
2230 * mips-fbsd-nat.c: New file.
2231
2232 2017-01-04 John Baldwin <jhb@FreeBSD.org>
2233
2234 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
2235 (ALLDEPFILES): Add mips-fbsd-tdep.c.
2236 * NEWS: Mention new FreeBSD/mips target.
2237 * configure.tgt: Add mips*-*-freebsd*.
2238 * mips-fbsd-tdep.c: New file.
2239 * mips-fbsd-tdep.h: New file.
2240
2241 2017-01-04 Yao Qi <yao.qi@linaro.org>
2242
2243 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
2244 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
2245
2246 2017-01-01 Joel Brobecker <brobecker@adacore.com>
2247
2248 Update copyright year range in all GDB files.
2249
2250 2017-01-01 Joel Brobecker <brobecker@adacore.com>
2251
2252 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
2253
2254 For older changes see ChangeLog-2016.
2255 \f
2256 Local Variables:
2257 mode: change-log
2258 left-margin: 8
2259 fill-column: 74
2260 version-control: never
2261 coding: utf-8
2262 End: