1 2017-12-20 Uros Bizjak <ubizjak@gmail.com>
3 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Remove
4 write-only assignment to "insn" variable.
6 2017-12-20 Ulrich Weigand <uweigand@de.ibm.com>
8 * spu-tdep.c (spu_gdbarch_init): Set set_gdbarch_significant_addr_bit
10 (ppc_linux_init_abi): Likewise, if Cell/B.E. is supported.
12 2017-12-18 Joel Brobecker <brobecker@adacore.com>
14 * ada-lang.c (ada_to_fixed_type_1): Rethrow errors with
15 a more detailed exception message when getting an exception
16 while trying to read the value of an XVZ variable.
17 * ada-valprint.c (ada_val_print): Only catch RETURN_MASK_ERROR
18 exceptions. Print an error message when an exception is caught.
20 2017-12-18 Joel Brobecker <brobecker@adacore.com>
22 * ada-lang.c (assign_component): Strip any TYPE_CODE_TYPEDEF
24 (assign_aggregate): Likewise.
26 2017-12-18 Xavier Roirand <roirand@adacore.com>
28 * ada-lang.c (ada_convert_actual): Change the way actual value
29 are passed to the inferior when the inferior expects a pointer type.
31 2017-12-17 Stafford Horne <shorne@gmail.com>
33 * gdb/or1k-tdep.c (show_or1k_debug): Fix function parameter alignment.
34 (or1k_analyse_inst): Likewise.
35 (or1k_single_step_through_delay): Likewise.
36 (or1k_frame_cache): Fix parameter alignment and use paddress()
39 2017-12-17 Stafford Horne <shorne@gmail.com>
41 * NEWS (Changes since GDB 8.0): Mention new or1k target and new
42 commands to set/show or1k debug.
44 2017-12-15 Sergio Durigan Junior <sergiodj@redhat.com>
46 * typeprint.c (whatis_exp): Fix ARI warning and reindent "if"
49 2017-12-15 Sergio Durigan Junior <sergiodj@redhat.com>
50 Pedro Alves <palves@redhat.com>
53 * NEWS (Changes since GDB 8.0): Mention new '/o' flag.
54 * c-typeprint.c (OFFSET_SPC_LEN): New define.
55 (c_type_print_varspec_prefix): New argument 'struct
57 (c_type_print_base_1): New function and prototype.
58 (c_print_type_1): New function, with code from 'c_print_type'.
59 (c_print_type): Use 'c_print_type_1'.
60 (c_type_print_varspec_prefix): New argument 'struct
61 print_offset_data *'. Use it. Call 'c_type_print_base_1'
62 instead of 'c_print_type_base'.
63 (print_spaces_filtered_with_print_options): New function.
64 (output_access_specifier): Take new argument FLAGS. Modify
65 function to call 'print_spaces_filtered_with_print_options'.
66 (c_print_type_vtable_offset_marker): New function.
67 (c_print_type_union_field_offset): New function.
68 (c_print_type_struct_field_offset): New function.
69 (c_print_type_no_offsets): New function.
70 (c_type_print_base_struct_union): New argument 'struct
71 print_offset_data *'. Print offsets and sizes for
72 struct/union/class fields.
73 * typeprint.c (const struct type_print_options
74 type_print_raw_options): Initialize 'print_offsets'.
75 (static struct type_print_options default_ptype_flags):
77 (struct print_offset_data print_offset_default_data): New
79 (whatis_exp): Handle '/o' option.
80 (_initialize_typeprint): Add '/o' flag to ptype's help.
81 * typeprint.h (struct print_offset_data): New struct.
82 (struct type_print_options) <print_offsets>: New field.
84 2017-12-15 Sergio Durigan Junior <sergiodj@redhat.com>
86 * c-typeprint.c (need_access_label_p): New function.
87 (c_type_print_base_struct_union): New function.
88 (c_type_print_base): Move code to handle
89 TYPE_CODE_{STRUCT,UNION} to the functions mentioned above.
91 2017-12-15 Richard Henderson <rth@redhat.com>
92 Uros Bizjak <ubizjak@gmail.com>
95 * alpha-tdep.c (alpha_software_single_step): Call
96 alpha_deal_with_atomic_sequence here.
97 (set_gdbarch_software_single_step): Set to
98 alpha_software_single_step.
99 * nat/linux-ptrace.h [__alpha__]: Define GDB_ARCH_IS_TRAP_BRKPT
100 and GDB_ARCH_IS_TRAP_HWBKPT.
102 2017-12-15 Yao Qi <yao.qi@linaro.org>
104 * unittests/memory-map-selftests.c: Wrap test with HAVE_LIBEXPAT.
106 2017-12-15 Xavier Roirand <roirand@adacore.com>
108 * ada-lang.c (ada_value_primitive_field): Handle field search
110 (find_struct_field): Ditto.
111 (ada_search_struct_field): Ditto.
112 (ada_value_struct_elt): Ditto.
113 (ada_lookup_struct_elt_type): Ditto.
115 2017-12-14 Simon Marchi <simon.marchi@ericsson.com>
117 * python/py-breakpoint.c (bppy_init): Use 'O' format specifier
118 for "qualified" and use PyObject_IsTrue.
120 2017-12-14 Jan Kratochvil <jan.kratochvil@redhat.com>
122 * dwarf2read.c (dw2_debug_names_iterator::next): Support
124 (debug_names::dwarf5_offset_size, unit_kind): New.
125 (debug_names::insert): Add parameter kind.
126 (debug_names::build): Support DW_IDX_type_unit.
127 (debug_names::recursively_write_psymbols): Update
128 (debug_names::write_psymbols caller.
129 (debug_names::write_one_signatured_type_data)
130 (debug_names::write_one_signatured_type): New.
131 (debug_names::index_key, debug_names::symbol_value)
132 (debug_names::write_psymbols): Add kind.
133 (debug_names::write_one_signatured_type): New.
134 (write_debug_names): Move dwarf5_offset_size to debug_names.
135 Use debug_names::write_one_signatured_type for type units.
137 2017-12-14 Joel Brobecker <brobecker@adacore.com>
139 * ada-lang.c (ada_value_equal): Add handling of typedef types
140 when comparing array objects.
142 2017-12-14 Joel Brobecker <brobecker@adacore.com>
144 * ada-tasks.c (read_atcb): Properly set task_info->ptid
145 when !target_has_execution as well.
146 (task_command): Remove error when !target_has_execution.
148 2017-12-13 Simon Marchi <simon.marchi@ericsson.com>
150 * location.h (string_to_event_location): Add match_type
152 * location.c (string_to_event_location): Likewise.
153 * python/py-breakpoint.c (bppy_init): Handle qualified
156 2017-12-13 Pedro Alves <palves@redhat.com>
158 * completer.c (completion_tracker::maybe_add_completion): New
159 'text' and 'word' parameters. Use make_completion_match_str.
160 (completion_tracker::add_completion): New 'text' and 'word'
161 parameters. Pass down.
162 (completion_tracker::recompute_lowest_common_denominator): Change
163 parameter type to gdb::unique_xmalloc_ptr rval ref. Adjust.
164 * completer.h (completion_tracker::add_completion): New 'text' and
166 (completion_tracker::recompute_lowest_common_denominator): Change
167 parameter type to gdb::unique_xmalloc_ptr rval ref.
168 (completion_tracker::recompute_lowest_common_denominator): Change
169 parameter type to gdb::unique_xmalloc_ptr rval ref.
170 * symtab.c (completion_list_add_name): Pass down 'text' and 'word'
173 2017-12-13 Pedro Alves <palves@redhat.com>
175 * cli/cli-decode.c (complete_on_cmdlist, complete_on_enum): Use
176 make_completion_match_str.
177 * completer.c: Use gdb::unique_xmalloc_ptr and
178 make_completion_match_str.
179 (make_completion_match_str_1): New.
180 (make_completion_match_str(const char *, const char *,
182 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
183 const char *, const char *)): New.
184 * completer.h (make_completion_match_str(const char *,
185 const char *, const char *)): New.
186 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
187 const char *, const char *)): New.
188 * interps.c (interpreter_completer): Use make_completion_match_str.
189 * symtab.c (completion_list_add_name, add_filename_to_list): Use
190 make_completion_match_str.
192 2017-12-13 Stafford Horne <shorne@gmail.com>
194 * or1k-tdep.c (or1k_analyse_inst): Use _() wrapper for message
196 (or1k_unwind_pc): Use paddress() instead of %p.
197 (or1k_unwind_sp): Likewise.
198 (or1k_frame_cache): Use host_address_to_string()/paddress()
199 instead of %p and use _() wrapper for message strings.
201 2017-12-13 Simon Marchi <simon.marchi@ericsson.com>
203 * contrib/ari/gdb_ari.sh: Fix typo in help.
205 2017-12-13 Joel Brobecker <brobecker@adacore.com>
207 * event-top.c (handle_line_of_input): Set server_command.
209 2017-12-12 Stafford Horne <shorne@gmail.com>
210 Stefan Wallentowitz <stefan@wallentowitz.de>
211 Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
212 Franck Jullien <franck.jullien@gmail.com>
213 Jeremy Bennett <jeremy.bennett@embecosm.com>
215 * configure.tgt: Add targets for or1k and or1knd.
216 * or1k-tdep.c: New file.
217 * or1k-tdep.h: New file.
218 * features/Makefile: Add or1k.xml to build.
219 * features/or1k.xml: New file.
220 * features/or1k-core.xml: New file.
221 * features/or1k.c: Generated.
223 2017-12-12 Alan Modra <amodra@gmail.com>
226 * ppc64-tdep.c (ppc64_plt_entry_point): Rewrite to take TOC-relative
227 PLT offset, and retrieve r2 from stack when executing in reverse.
228 (ppc64_standard_linkage1_target): Drop pc param. Calculate offset
229 rather than PLT address.
230 (ppc64_standard_linkage2_target): Likewise.
231 (ppc64_standard_linkage3_target): Likewise.
232 (ppc64_standard_linkage4_target): Likewise.
233 (ppc64_skip_trampoline_code_1): Adjust to suit.
235 2017-12-11 Simon Marchi <simon.marchi@ericsson.com>
238 * remote.c (remote_thread_name): Return NULL if name is empty.
239 (remote_threads_extra_info): Return NULL if extra info is empty.
241 2017-12-11 Pedro Alves <palves@redhat.com>
243 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index)
244 (elf_sym_fns_debug_names): Move to elfread.c.
245 * dwarf2read.c (dwarf2_initialize_objfile): Return a boolean
246 instead of a sym_fns and add 'index_kind' output parameter. Fill
247 the latter in with the index variant kind if using an index.
248 (enum dw_index_kind): Moved to symfile.h.
249 * elfread.c (elf_sym_fns_gdb_index, elf_sym_fns_debug_names)
250 (elf_sym_fns_lazy_psyms): Move from defs.h.
251 (elf_symfile_read): Adjust to new dwarf2_initialize_objfile
253 * symfile.h (enum class dw_index_kind): New, moved from
255 (dwarf2_initialize_objfile): Change prototype.
257 2017-12-11 Ulrich Weigand <uweigand@de.ibm.com>
259 * target-float.c (mpfr_float_ops::from_target): Use mpfr_set_ui
260 instead of mpfr_set_si to convert mantissa bits.
262 2017-12-11 Xavier Roirand <roirand@adacore.com>
263 Joel Brobecker <brobecker@adacore.com>
265 * ada-lang.c (ada_tag_value_at_base_address): Change the way
266 tagged type base address is computed.
267 (enum ada_primitive_types) <ada_primitive_type_storage_offset>:
269 (ada_language_arch_info): Set the ada_primitive_type_storage_offset
270 element of lai->primitive_type_vector.
272 2017-12-08 Pedro Alves <palves@redhat.com>
274 * dwarf2read.c (mock_mapped_index): Reimplement as an extension of
276 (check_match): Adjust to use mock_index directly.
277 (check_find_bounds_finds)
278 (test_mapped_index_find_name_component_bounds): Adjust to work
279 with a mapped_index_base.
281 2017-12-08 Pedro Alves <palves@redhat.com>
283 * dwarf2read.c (struct mapped_index_base): New, partially factored
285 (struct mapped_index): ... this. Inherit mapped_index_base.
286 (mapped_index::symbol_name_slot_invalid):
287 (mapped_index::symbol_name_at): Add override marker.
288 (mapped_index::symbol_name_count): New.
289 (struct mapped_debug_names): Inherit mapped_index_base.
290 (mapped_debug_names::symbol_name_at): New.
291 (mapped_debug_names::symbol_name_count): New.
292 (mapped_index::find_name_components_bounds): Rename to ...
293 (mapped_index_base::find_name_components_bounds): ... this.
294 (mapped_index::build_name_components): Rename to ...
295 (mapped_index_base::build_name_components): ... this. Adjust to
296 use mapped_index_base::symbol_name_count and
297 mapped_index_base::symbol_name_slot_invalid.
298 (dw2_expand_symtabs_matching_symbol): Take a mapped_index_base
299 instead of a mapped_index. Use
300 dw2_expand_symtabs_matching_symbol.
302 2017-12-08 Pedro Alves <palves@redhat.com>
304 * dwarf2read.c (mapped_index::symbol_table_slot): New.
305 (mapped_index::address_table): Now a gdb::array_view of const
307 (mapped_index::symbol_table): Now a gdb::array_view of
309 (mapped_index::address_table_size)
310 (mapped_index::symbol_table_slots): Delete.
311 (create_addrmap_from_index): Adjust.
312 (find_slot_in_mapped_hash): Adjust.
313 (read_index_from_section): Adjust.
314 (dwarf2_read_index): Adjust.
316 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
317 Pedro Alves <palves@redhat.com>
319 * defs.h (elf_sym_fns_debug_names): New declaration.
320 * dwarf2read.c: Include "hash_enum.h".
321 (mapped_debug_names): New.
322 (struct dwarf2_per_objfile): Add debug_names, debug_aranges and
324 (dwarf2_elf_names): Add ".debug_names" and ".debug_aranges".
325 (struct dwz_file): Add debug_names.
326 (dwarf2_per_objfile::locate_sections): Handle debug_names and
328 (locate_dwz_sections): Handle debug_names.
329 (create_signatured_type_table_from_debug_names)
330 (create_addrmap_from_aranges): New.
331 (dwarf2_read_index): Update function comment.
332 (dwarf5_augmentation): Moved up.
333 (read_debug_names_from_section, create_cus_from_debug_names_list)
334 (create_cus_from_debug_names, dwarf2_read_debug_names): New.
335 (dwarf5_djb_hash): Moved up.
336 (dw2_debug_names_iterator): New.
337 (read_indirect_string_at_offset): New declaration.
338 (mapped_debug_names::namei_to_name)
339 (dw2_debug_names_iterator::find_vec_in_debug_names)
340 (dw2_debug_names_iterator::next, dw2_debug_names_lookup_symbol)
341 (dw2_debug_names_dump, dw2_debug_names_expand_symtabs_for_function)
342 (dw2_debug_names_expand_symtabs_matching, dwarf2_debug_names_functions):
344 (dwarf2_initialize_objfile): Return also elf_sym_fns_debug_names.
345 (debug_names::djb_hash): Rename it to dwarf5_djb_hash.
346 (debug_names::build): Update djb_hash caller.
347 (write_debug_names): Move out and rename augmentation to
349 * elfread.c (elf_sym_fns_debug_names): New.
350 * psymtab.h (dwarf2_debug_names_functions): New declaration.
351 * symfile.h (struct dwarf2_debug_sections): Add debug_names and
353 * xcoffread.c (dwarf2_xcoff_names): Add debug_names and debug_aranges.
355 2017-12-08 Pedro Alves <palves@redhat.com>
357 * common/hash_enum.h: New file.
359 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
361 * dwarf2read.c (create_cu_from_index_list): New from ...
362 (create_cus_from_index_list): ... this function, use it.
363 (dw_expand_symtabs_matching_file_matcher)
364 (dw2_expand_symtabs_matching_one): New from ...
365 (dw2_expand_symtabs_matching): ... this function, use them.
367 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
369 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move here
370 declarations from elfread.c.
371 (dwarf2_initialize_objfile): Change return value.
372 * elfread.c (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move these
373 declarations to defs.h.
374 (elf_symfile_read): Adjust dwarf2_initialize_objfile caller.
375 * symfile.h (dwarf2_initialize_objfile): Change return type.
377 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
378 Pedro Alves <palves@redhat.com>
380 * contrib/gdb-add-index.sh (index): Rename to ...
382 (index5, debugstr, debugstrmerge, debugstrerr): New variables.
383 Support also .debug_names and .debug_str.
384 * dwarf2read.c: Include cmath, set, list.
385 (INDEX_SUFFIX): Rename to ...
386 (INDEX4_SUFFIX): ... here.
387 (INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
388 (file_write(FILE *, const void *, size_t)): New.
389 (file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
390 (data_buf::append_unsigned_leb128, data_buf::empty): New.
391 (data_buf::file_write): Use ::file_write.
392 (data_buf::c_str, dwarf5_djb_hash, debug_names)
393 (check_dwarf64_offsets): New.
394 (psyms_seen_size, write_gdbindex): New from
395 write_psymtabs_to_index code.
396 (dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
397 (enum dw_index_kind): New.
398 (write_psymtabs_to_index): New parameter index_kind. Support
399 filename_str and out_file_str. Move code to write_gdbindex,
400 possibly call write_debug_names.
401 (save_gdb_index_command): New parameter -dwarf-5.
402 (_initialize_dwarf2_read): Document the new parameter -dwarf-5.
404 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
405 Pedro Alves <palves@redhat.com>
407 * contrib/cc-with-tweaks.sh: Change interpreter to bash, incl. initial
409 (GDB_ADD_INDEX): New variable.
410 <$want_index>: Call $GDB_ADD_INDEX.
412 2017-12-08 Sergio Durigan Junior <sergiodj@redhat.com>
414 * dtrace-probe.c (dtrace_process_dof_probe): Do not declare a new
415 "expression_up" inside the TRY block.
417 2017-12-08 Yao Qi <yao.qi@linaro.org>
419 * breakpoint.c (update_watchpoint): Call
422 2017-12-08 Yao Qi <yao.qi@linaro.org>
424 * breakpoint.c (adjust_breakpoint_address): Call
427 2017-12-08 Yao Qi <yao.qi@linaro.org>
429 * aarch64-tdep.c (aarch64_gdbarch_init): Install gdbarch
430 significant_addr_bit.
431 * gdbarch.sh (significant_addr_bit): New.
432 * gdbarch.c, gdbarch.h: Re-generated.
433 * target.c (memory_xfer_partial): Call address_significant.
434 * utils.c (address_significant): New function.
435 * utils.h (address_significant): Declare.
437 2017-12-08 Tom Tromey <tom@tromey.com>
439 * printcmd.c (ui_printf): Update. Use std::vector.
440 * common/format.h (struct format_piece): Add constructor.
442 (class format_pieces): New class.
443 (parse_format_string, free_format_pieces)
444 (free_format_pieces_cleanup): Remove.
445 * common/format.c (format_pieces::format_pieces): Rename from
446 parse_format_string. Update.
447 (free_format_pieces, free_format_pieces_cleanup): Remove.
448 * breakpoint.c (parse_cmd_to_aexpr): Update. Use std::vector.
449 * ax-gdb.h (gen_printf): Remove argument.
450 * ax-gdb.c (gen_printf): Remove "frags" argument.
451 (maint_agent_printf_command): Update. Use std::vector.
453 2017-12-08 Yao Qi <yao.qi@linaro.org>
456 * linespec.c (minsym_found): Set sal.section.
458 2017-12-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
460 * configure.tgt (s390*-*-linux*): Add symfile-mem.o.
462 2017-12-07 Keith Seitz <keiths@redhat.com>
465 * location.c (string_to_explicit_location): When terminating
466 parsing early, break out of enclosing loop instead of returning.
468 2017-12-07 Keith Seitz <keiths@redhat.com>
470 * NEWS (New commands): Mention set/show print type nested-type-limit.
471 * c-typeprint.c (c_type_print_base): Print out nested types.
472 * dwarf2read.c (struct typedef_field_list): Rename to ...
473 (struct decl_field_list): ... this. Change all uses.
474 (struct field_info) <nested_types_list, nested_types_list_count>:
476 (add_partial_symbol): Look for nested type definitions in C++, too.
477 (dwarf2_add_typedef): Rename to ...
478 (dwarf2_add_type_defn): ... this.
479 (type_can_define_types): New function.
480 Update assertion to use type_can_define_types.
481 Permit NULL for a field's name.
482 (process_structure_scope): Handle child DIEs of types that can
484 Copy the list of nested types into the type struct.
485 * gdbtypes.h (struct typedef_field): Rename to ...
486 (struct decl_field): ... this. Change all uses.
487 [is_protected, is_private]: New fields.
488 (struct cplus_struct_type) <nested_types, nested_types_count>: New
490 (TYPE_NESTED_TYPES_ARRAY, TYPE_NESTED_TYPES_FIELD)
491 (TYPE_NESTED_TYPES_FIELD_NAME, TYPE_NESTED_TYPES_FIELD_TYPE)
492 (TYPE_NESTED_TYPES_COUNT, TYPE_NESTED_TYPES_FIELD_PROTECTED)
493 (TYPE_NESTED_TYPES_FIELD_PRIVATE): New macros.
494 * typeprint.c (type_print_raw_options, default_ptype_flags): Add
495 default value for print_nested_type_limit.
496 (print_nested_type_limit): New static variable.
497 (set_print_type_nested_types, show_print_type_nested_types): New
499 (_initialize_typeprint): Register new commands for set/show
500 `print-nested-type-limit'.
501 * typeprint.h (struct type_print_options) [print_nested_type_limit]:
504 2017-12-07 Tom Tromey <tom@tromey.com>
506 PR breakpoints/22511:
507 * breakpoint.c (commands_command_1): Don't throw an exception when
508 no commands have been read.
510 2017-12-07 Adam Stylinski <adam.stylinski@etegent.com>
513 * target-descriptions.c (print_c_tdesc::visit_pre): Change type of
516 2017-12-07 Simon Marchi <simon.marchi@ericsson.com>
518 * common/selftest.h (struct selftest): Add virtual destructor.
520 2017-12-07 Phil Muldoon <pmuldoon@redhat.com>
522 * python/py-breakpoint.c (bppy_init): Use string_to_event_location
523 over basic location code. Implement explicit location keywords.
524 (bppy_init_validate_args): New function.
525 * NEWS: Document Python explicit breakpoint locations.
527 2017-12-07 Joel Brobecker <brobecker@adacore.com>
529 * MAINTAINERS: Restore target entries for m68hc11-elf,
530 score-elf and xstormy16-elf, incorrectly removed in a previous
531 patch meant to only update the list of active maintainers.
533 2017-12-06 Pedro Alves <palves@redhat.com>
535 * break-catch-syscall.c (insert_catch_syscall)
536 (remove_catch_syscall): Adjust to pass reference to
537 inf_data->syscalls_counts directly via gdb::array_view.
538 * fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
540 * linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
541 * remote.c (remote_set_syscall_catchpoint): Likewise.
542 * target-debug.h (target_debug_print_bool): New.
543 (define target_debug_print_gdb_array_view_const_int): New.
544 * target-delegates.c: Regenerate.
545 * target.h (target_ops) <to_set_syscall_catchpoint>: Use
546 gdb::array_view and bool.
547 (target_set_syscall_catchpoint): Likewise.
549 2017-12-06 Simon Marchi <simon.marchi@ericsson.com>
551 * break-catch-syscall.c (catch_syscall_completer): Get pointers
552 to syscall group strings after building the string vector.
554 2017-12-06 Pedro Alves <palves@redhat.com>
556 * remote.c (remote_query_supported): Don't send "xmlRegisters=" if
557 "qXfer:features:read"" is disabled.
558 (remote_write_qxfer, remote_read_qxfer, remote_search_memory):
559 Check packet_config_support instead of packet->support directly.
561 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
563 * target-descriptions.c (struct tdesc_feature) <registers>: Use
564 tdesc_reg_up typedef.
565 (struct target_desc) <features>: Use tdesc_feature_up typedef.
567 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
569 * target-descriptions.c (struct tdesc_type): Use default
573 (struct tdesc_type_builtin): New.
574 (struct tdesc_type_vector): New.
575 (struct tdesc_type_with_fields): New.
576 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
577 (tdesc_gdb_type): Remove.
578 (tdesc_register_type): Adjust.
579 (tdesc_create_vector): Create tdesc_type_vector.
580 (tdesc_create_struct): Create tdesc_type_with_fields.
581 (tdesc_set_struct_size): Change parameter type.
582 (tdesc_create_union): Create tdesc_type_with_fields.
583 (tdesc_create_flags): Likewise.
584 (tdesc_create_enum): Likewise.
585 (tdesc_add_field): Change parameter type.
586 (tdesc_add_typed_bitfield): Likewise.
587 (tdesc_add_bitfield): Likewise.
588 (tdesc_add_flag): Likewise.
589 (tdesc_add_enum_value): Likewise.
590 (print_c_tdesc) <visit>: Remove overload with tdesc_type
591 parameter, add overloads for tdesc_type_builtin,
592 tdesc_type_with_fields and tdesc_type_vector.
593 <m_printed_type>: Remove.
594 <m_printed_element_type, m_printed_type_with_fields>: Add.
595 * target-descriptions.h (tdesc_create_enum): Change return type.
596 (tdesc_add_typed_bitfield): Change parameter type.
597 (tdesc_add_enum_value): Change parameter type.
598 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
599 type to tdesc_type_with_fields.
600 (tdesc_start_struct): Adjust.
601 (tdesc_start_flags): Adjust.
602 (tdesc_start_enum): Adjust.
603 (tdesc_start_field): Adjust.
604 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
605 (struct tdesc_type_vector): Forward-declare.
606 (struct tdesc_type_with_fields): Forward-declare.
607 (tdesc_create_struct): Change return type.
608 (tdesc_create_union): Likewise.
609 (tdesc_create_flags): Likewise.
610 (tdesc_add_field): Change parameter type.
611 (tdesc_set_struct_size): Likewise.
612 (tdesc_add_bitfield): Likewise.
613 (tdesc_add_flag): Likewise.
614 * features: Re-generate C files.
616 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
618 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
619 (struct tdesc_arch_reg): Add constructor.
620 (DEF_VEC_O (tdesc_arch_reg)): Remove.
621 (struct tdesc_arch_data): Initialize fields.
622 <arch_regs>: Change type to std::vector.
623 (target_find_description): Adjust.
624 (tdesc_find_type): Adjust.
625 (tdesc_data_init): Call tdesc_arch_data constructor.
626 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
627 (tdesc_data_cleanup): Free data with delete.
628 (tdesc_numbered_register): Adjust.
629 (tdesc_find_arch_register): Adjust.
630 (tdesc_use_registers): Adjust.
632 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
634 * target-descriptions.c (tdesc_type_field): Remove typedef.
635 (DEF_VEC_O (tdesc_type_field)): Remove.
636 (struct tdesc_type_field): Add constructor.
637 <name>: Change type to std::string.
638 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
640 <~tdesc_type>: Destroy vector if the type kind uses it.
641 <u::u::fields>: Change type to std::vector.
642 (tdesc_gdb_type): Adjust.
643 (tdesc_add_field): Adjust.
644 (tdesc_add_typed_bitfield): Adjust.
645 (tdesc_add_field): Adjust.
646 (tdesc_add_enum_value): Adjust.
647 (class print_c_tdesc) <visit>: Adjust.
649 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
651 * target-descriptions.c (struct tdesc_type) <name>: Change type
653 <~tdesc_type>: Don't manually free name.
654 <operator==>: Adjust.
655 (tdesc_named_type): Adjust.
656 (tdesc_find_type): Adjust.
657 (tdesc_gdb_type): Adjust.
658 (class print_c_tdesc) <visit>: Adjust.
660 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
662 * target-descriptions.c (tdesc_type_p): Remove typedef.
663 (DEF_VEC_P (tdesc_type_p)): Remove.
664 (struct tdesc_feature) <types>: Change type to std::vector.
665 <~tdesc_feature>: Replace with default implementation.
667 (tdesc_named_type): Adjust.
668 (tdesc_create_vector): Adjust.
669 (tdesc_create_struct): Adjust.
670 (tdesc_create_union): Adjust.
671 (tdesc_create_flags): Adjust.
672 (tdesc_create_enum): Adjust.
674 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
676 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
677 type of name_ parameter, adjust to std::string change.
678 <name, group, type>: Change type to std::string.
679 <~tdesc_reg>: Replace with default implementation.
680 <operator==>: Adjust.
681 (tdesc_find_register_early): Adjust.
682 (tdesc_register_name): Adjust.
683 (tdesc_register_type): Adjust.
684 (tdesc_register_in_reggroup_p): Adjust.
685 (class print_c_tdesc) <visit>: Adjust.
686 (class print_c_feature) <visit>: Adjust.
687 * features/arc-arcompact.c: Re-generate.
688 * features/arc-v2.c: Re-generate.
690 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
692 * target-descriptions.c (tdesc_reg_p): Remove typedef.
693 (DEF_VEC_P (tdesc_reg_p)): Remove.
694 (struct tdesc_feature) <registers>: Change type to std::vector.
695 <~tdesc_feature>: Don't manually free registers.
697 <operator==>: Adjust.
698 (tdesc_has_registers): Adjust.
699 (tdesc_find_register_early): Adjust.
700 (tdesc_use_registers): Adjust.
701 (tdesc_create_reg): Adjust.
703 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
705 * target-descriptions.c (tdesc_feature) <name>: Change type to
707 <~tdesc_feature>: Don't manually free name.
708 <operator==>: Adjust.
709 (tdesc_find_feature): Adjust.
710 (tdesc_feature_name): Adjust.
711 (class print_c_tdesc) <visit_pre>: Adjust.
712 (class print_c_feature) <visit_pre>: Adjust.
714 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
716 * target-descriptions.c (tdesc_feature_p): Remove typedef.
717 (DEF_VEC_P (tdesc_feature_p)): Remove.
718 (struct target_desc) <features>: Change type to std::vector.
719 <~target_desc>: Replace with default implementation.
721 <operator==>: Adjust.
722 (tdesc_has_registers): Adjust.
723 (tdesc_find_feature): Adjust.
724 (tdesc_use_registers): Adjust.
725 (tdesc_create_feature): Adjust.
727 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
729 * target-descriptions.c (arch_p): Remove typedef.
730 (DEF_VEC_P (arch_p)): Remove.
731 (struct target_desc) <compatible>: Change type to std::vector.
732 <~target_desc>: Don't manually free compatible.
733 (tdesc_compatible_p): Adjust.
734 (tdesc_add_compatible): Adjust.
735 (class print_c_tdesc) <visit_pre>: Adjust.
737 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
739 * target-descriptions.c (property_s): Remove typedef.
740 (DEF_VEC_O (property_s)): Remove.
741 (struct target_desc) <properties>: Make an std::vector.
742 <~target_desc>: Don't manually free properties.
743 (tdesc_property): Adjust.
744 (set_tdesc_property): Adjust.
745 (class print_c_tdesc) <visit_pre>: Adjust.
747 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
749 * common/gdb_assert.h (gdb_static_assert): Redefine using
752 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
754 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
756 (ada_is_redundant_range_encoding): Likewise.
757 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
759 * alpha-tdep.c (alpha_software_single_step): Likewise.
760 * arm-tdep.c (_initialize_arm_tdep): Likewise.
761 * auto-load.c (info_auto_load_cmd): Likewise.
762 * break-catch-syscall.c (insert_catch_syscall): Likewise.
763 (remove_catch_syscall): Likewise.
764 * breakpoint.c (condition_completer): Likewise.
765 (clear_command): Likewise.
766 (update_breakpoint_locations): Likewise.
767 * btrace.c (btrace_disable): Likewise.
768 (btrace_teardown): Likewise.
769 (btrace_maint_update_pt_packets): Likewise.
770 (maint_btrace_clear_cmd): Likewise.
771 * cli/cli-decode.c (lookup_cmd_1): Likewise.
772 (lookup_cmd_composition): Likewise.
773 * cli/cli-dump.c (scan_filename): Likewise.
774 (restore_command): Likewise.
775 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
776 * compile/compile-object-load.c (compile_object_load): Likewise.
777 * compile/compile-object-run.c (compile_object_run): Likewise.
778 * compile/compile.c (compile_to_object): Likewise.
779 * completer.c (filename_completer): Likewise.
780 (complete_files_symbols): Likewise.
781 (complete_expression): Likewise.
782 * corelow.c (core_open): Likewise.
783 * ctf.c (ctf_start): Likewise.
784 (ctf_write_status): Likewise.
785 (ctf_write_uploaded_tsv): Likewise.
786 (ctf_write_definition_end): Likewise.
787 (ctf_open_dir): Likewise.
788 (ctf_xfer_partial): Likewise.
789 (ctf_trace_find): Likewise.
790 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
792 * dwarf2loc.c (allocate_piece_closure): Likewise.
793 (indirect_pieced_value): Likewise.
794 (dwarf2_evaluate_loc_desc_full): Likewise.
795 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
796 (dw2_expand_symtabs_matching): Likewise.
797 (dw2_map_symbol_filenames): Likewise.
798 (read_and_check_comp_unit_head): Likewise.
799 (read_cutu_die_from_dwo): Likewise.
800 (lookup_dwo_unit): Likewise.
801 (read_comp_units_from_section): Likewise.
802 (dwarf2_compute_name): Likewise.
803 (handle_DW_AT_stmt_list): Likewise.
804 (create_cus_hash_table): Likewise.
805 (create_dwp_v2_section): Likewise.
806 (dwarf2_rnglists_process): Likewise.
807 (dwarf2_ranges_process): Likewise.
808 (dwarf2_record_block_ranges): Likewise.
809 (is_vtable_name): Likewise.
810 (read_formatted_entries): Likewise.
811 (skip_form_bytes): Likewise.
812 * elfread.c (elf_symtab_read): Likewise.
813 * exec.c (exec_file_command): Likewise.
814 * f-valprint.c (f_val_print): Likewise.
815 (info_common_command_for_block): Likewise.
816 * guile/guile.c (initialize_scheme_side): Likewise.
817 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
818 * guile/scm-cmd.c (cmdscm_completer): Likewise.
819 (gdbscm_register_command_x): Likewise.
820 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
821 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
822 * guile/scm-ports.c (file_port_magic): Likewise.
823 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
824 (ppscm_pretty_print_one_value): Likewise.
825 (ppscm_print_children): Likewise.
826 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
827 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
828 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
829 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
830 * i386-tdep.c (i386_register_reggroup_p): Likewise.
831 * infcmd.c (run_command_1): Likewise.
832 (until_next_fsm_clean_up): Likewise.
833 * linespec.c (linespec_complete): Likewise.
834 (find_label_symbols): Likewise.
835 * m2-valprint.c (m2_val_print): Likewise.
836 * memattr.c (require_user_regions): Likewise.
837 (lookup_mem_region): Likewise.
838 (disable_mem_command): Likewise.
839 (mem_delete): Likewise.
840 * mep-tdep.c (mep_register_name): Likewise.
841 (mep_analyze_prologue): Likewise.
842 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
843 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
844 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
845 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
846 * minidebug.c (lzma_open): Likewise.
847 * minsyms.c (lookup_minimal_symbol): Likewise.
848 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
849 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
850 (mips_o64_return_value): Likewise.
851 (mips_single_step_through_delay): Likewise.
852 (_initialize_mips_tdep): Likewise.
853 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
854 (nios2_software_single_step): Likewise.
855 * parse.c (find_minsym_type_and_address): Likewise.
856 * psymtab.c (psym_relocate): Likewise.
857 * python/py-breakpoint.c (bppy_get_commands): Likewise.
858 (gdbpy_breakpoint_modified): Likewise.
859 * python/py-infevents.c (create_inferior_call_event_object):
861 * python/py-record-btrace.c (btpy_list_item): Likewise.
862 * python/py-type.c (typy_str): Likewise.
863 * python/py-value.c (valpy_call): Likewise.
864 * python/python.c (do_start_initialization): Likewise.
865 * record-btrace.c (record_btrace_insn_history_range): Likewise.
866 (record_btrace_call_history_range): Likewise.
867 (record_btrace_record_method): Likewise.
868 (record_btrace_xfer_partial): Likewise.
869 (btrace_get_frame_function): Likewise.
870 * record-full.c (record_full_open): Likewise.
871 * record.c (get_context_size): Likewise.
872 * registry.h (DEFINE_REGISTRY): Likewise.
873 * remote-fileio.c (remote_fileio_request): Likewise.
874 * remote.c (remote_update_thread_list): Likewise.
875 (remote_check_symbols): Likewise.
876 (remote_commit_resume): Likewise.
877 (remote_interrupt): Likewise.
878 (remote_insert_breakpoint): Likewise.
879 (compare_sections_command): Likewise.
880 * rust-exp.y (super_name): Likewise.
881 (lex_string): Likewise.
882 (convert_ast_to_type): Likewise.
883 (convert_ast_to_expression): Likewise.
884 * rust-lang.c (rust_print_struct_def): Likewise.
885 (rust_print_type): Likewise.
886 (rust_evaluate_subexp): Likewise.
887 * rx-tdep.c (rx_register_type): Likewise.
888 * ser-event.c (serial_event_clear): Likewise.
889 * serial.c (serial_open): Likewise.
890 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
891 * symfile.c (section_is_overlay): Likewise.
892 (overlay_unmapped_address): Likewise.
893 (overlay_mapped_address): Likewise.
894 (simple_overlay_update_1): Likewise.
895 (simple_overlay_update): Likewise.
896 * symtab.c (symbol_find_demangled_name): Likewise.
897 (search_symbols): Likewise.
898 * target-descriptions.c (tdesc_predefined_type): Likewise.
899 * target.c (target_commit_resume): Likewise.
900 * thread.c (print_selected_thread_frame): Likewise.
901 * top.c (new_ui_command): Likewise.
902 (gdb_readline_no_editing): Likewise.
903 * tracefile-tfile.c (tfile_open): Likewise.
904 * tracepoint.c (create_tsv_from_upload): Likewise.
905 * utils.c (quit): Likewise.
906 (defaulted_query): Likewise.
907 * valarith.c (value_concat): Likewise.
908 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
909 * xml-tdesc.c (target_fetch_description_xml): Likewise.
910 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
911 (xtensa_pseudo_register_write): Likewise.
913 2017-12-04 Tom Tromey <tom@tromey.com>
915 * NEWS: Mention Rust trait object inspection.
917 2017-12-04 Pedro Alves <palves@redhat.com>
920 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
921 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
922 (vex2_prefix_p, vex3_prefix_p): New functions.
923 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
925 (fixup_riprel): Set VEX3.!B.
927 2017-12-03 Simon Marchi <simon.marchi@ericsson.com>
929 * target.h (mem_region_vector): Remove.
930 (struct target_ops) <to_memory_map>: Change return type to
931 std::vector<mem_region>.
932 * target-debug.h (target_debug_print_mem_region_vector): Rename
934 (target_debug_print_std_vector_mem_region): ... this.
935 * target-delegates.c: Re-generate.
937 2017-12-03 Pedro Alves <palves@redhat.com>
939 * make-target-delegates (munge_type): Also munge '<', '>', and
940 ':'. Avoid double underscores in identifiers, and trailing
943 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
945 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
946 * target-delegates.c: Regenerate.
948 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
950 * common/poison.h (XDELETE): Fix typo.
952 2017-12-01 Andrew Cagney <cagney@redhat.com>
953 Joel Brobecker <brobecker@adacore.com>
954 Sergio Durigan Junior <sergiodj@redhat.com>
956 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
958 * coffread.c (coff_symfile_read): Do not map over sections with
959 'coff_locate_sections' if readnever is on.
960 * dwarf2read.c (dwarf2_has_info): Return 0 if
962 * elfread.c (elf_symfile_read): Do not map over sections with
963 'elf_locate_sections' if readnever is on.
964 * main.c (validate_readnow_readnever): New function.
965 (captured_main_1): Add support for --readnever.
966 (print_gdb_help): Document --readnever.
967 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
969 * symfile.c (readnever_symbol_files): New global.
970 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
971 'READNEVER_SYMBOL_FILES' is set.
972 (validate_readnow_readnever): New function.
973 (symbol_file_command): Handle '-readnever' option.
974 Call 'validate_readnow_readnever'.
975 (add_symbol_file_command): Handle '-readnever' option.
976 Call 'validate_readnow_readnever'.
977 (_initialize_symfile): Document new '-readnever' option for
978 both 'symbol-file' and 'add-symbol-file' commands.
979 * top.h (readnever_symbol_files): New extern global.
980 * xcoffread.c (xcoff_initial_scan): Do not read debug
981 information if readnever is on.
983 2017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
985 * symfile.c (symbol_file_command): Call
986 'symbol_file_add_main_1' only after processing all command
988 (add_symbol_file_command): Modify logic to make arguments
989 position-independent.
991 2017-12-01 Joel Brobecker <brobecker@adacore.com>
993 * ada-lang.c (symbol_list_obstack): Delete.
994 (resolve_subexp): Make sure "candidates" gets xfree'ed.
995 (ada_lookup_symbol_list_worker): Remove the limitation that
996 the result is only good until the next call, now making it
997 the responsibility of the caller to free the result when no
998 longer needed. Adjust the function's intro comment accordingly.
999 (ada_lookup_symbol_list): Adjust the function's intro comment.
1000 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
1001 (ada_lookup_encoded_symbol, get_var_value): Likewise.
1002 (_initialize_ada_language): Remove symbol_list_obstack
1004 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
1005 (write_var_or_type, write_name_assoc): Likewise.
1007 2017-12-01 Tom Tromey <tom@tromey.com>
1009 * Makefile.in (all_deps_files): New variable.
1010 Include .Po files using all_deps_files.
1012 2017-12-01 Joel Brobecker <brobecker@adacore.com>
1014 * MAINTAINERS: Update list of maintainers, moving those who
1015 stepped down or became inactive to the "Past Maintainers"
1018 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1020 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
1022 (NEW_PROC_API): Remove.
1023 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
1025 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
1026 * configure: Regenerate.
1027 * config.in: Regenerate.
1028 * gdbserver/configure: Regenerate.
1029 * gdbserver/config.in: Regenerate.
1031 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
1033 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
1035 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
1037 * proc-api.c: Remove !NEW_PROC_API support.
1038 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
1039 Remove tests for macros always defined on Solaris.
1040 * proc-events.c: Remove !NEW_PROC_API support.
1041 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
1042 HAVE_SYS_USER_H tests.
1043 (init_syscall_table): Remove non-Solaris syscalls.
1044 Remove tests for syscalls present on all Solaris versions.
1045 Add missing Solaris 10+ syscalls.
1046 (signal_table): Remove non-Solaris signals.
1047 Remove tests for signals present on all Solaris versions.
1048 (fault_table): Remove non-Solaris faults.
1049 Remove tests for faults present on all Solaris versions.
1050 * proc-flags.c: Remove !NEW_PROC_API support.
1051 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
1052 Remove non-Solaris flags.
1053 * proc-why.c: Remove !NEW_PROC_API support.
1054 (pr_why_table): Remove meaningless comments.
1055 Remove tests for reasons present on all Solaris versions.
1057 (proc_prettyfprint_why): Likewise.
1059 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
1060 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
1061 Remove WA_READ test, IRIX watchpoint support.
1062 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
1063 types. Change users.
1064 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
1065 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
1067 Remove CTL_PROC_NAME_FMT tests.
1068 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
1070 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
1071 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
1072 (proc_modify_flag): Replace GDBRESET by PCUNSET.
1073 Remove PR_ASYNC, PR_KLC tests.
1074 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
1075 (proc_parent_pid): Remove PCWATCH etc. tests.
1076 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
1077 Remove PCAGENT test.
1078 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
1079 Remove SYS_lwpcreate || SYS_lwp_create test.
1080 (proc_get_current_thread): Likewise.
1081 [PIOCNTHR && PIOCTLIST]: Remove.
1082 [PIOCLSTATUS]: Remove.
1083 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
1084 [PRFS_STOPEXEC]: Remove.
1085 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
1086 (syscall_is_exit): Likewise.
1087 (syscall_is_exec): Likewise.
1088 (syscall_is_lwp_create): Likewise.
1089 Remove SYS_syssgi support.
1090 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
1091 [SYS_syssgi]: Remove.
1092 Remove non-Solaris cases, conditionals.
1093 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
1095 (procfs_init_inferior) [SYS_syssgi]: Remove.
1096 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
1097 (procfs_inferior_created) [SYS_syssgi]: Remove.
1098 (procfs_set_watchpoint): Remove !AIX5 test.
1099 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
1101 (mappingflags) [MA_PHYS]: Remove.
1102 (info_mappings_callback): Remove PCAGENT test.
1103 Remove PIOCOPENLWP || PCAGENT test.
1105 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1107 * sol-thread.c (info_solthreads): Constify args.
1108 Cast args to void *.
1110 2017-11-29 John Baldwin <jhb@FreeBSD.org>
1112 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
1114 2017-11-29 Joel Brobecker <brobecker@adacore.com>
1116 * ada-lang.c (to_fixed_range_type): Make sure that the size
1117 of the range type being returned is the same as the size
1118 of the range type being fixed.
1120 2017-11-29 Pedro Alves <palves@redhat.com>
1123 * NEWS: Mention setting breakpoints on functions with C++ ABI
1125 * completer.h (completion_match_for_lcd) <match,
1126 mark_ignored_range>: New methods.
1127 <finish>: Consider ignored ranges.
1128 <clear>: Clear ignored ranges.
1129 <m_ignored_ranges, m_finished_storage>: New fields.
1130 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1131 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1132 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1133 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1134 * language.c (default_symbol_name_matcher): Pass the
1135 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1136 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1137 * utils.c (skip_abi_tag): New function.
1138 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1140 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1143 2017-11-29 Pedro Alves <palves@redhat.com>
1146 * NEWS: Mention setting breakpoints on functions with C++ ABI
1148 * completer.h (completion_match_for_lcd) <match,
1149 mark_ignored_range>: New methods.
1150 <finish>: Consider ignored ranges.
1151 <clear>: Clear ignored ranges.
1152 <m_ignored_ranges, m_finished_storage>: New fields.
1153 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1154 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1155 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1156 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1157 * language.c (default_symbol_name_matcher): Pass the
1158 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1159 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1160 * utils.c (skip_abi_tag): New function.
1161 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1163 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1166 2017-11-29 Pedro Alves <palves@redhat.com>
1168 * NEWS: Mention that breakpoints on C++ functions are now set on
1169 on all namespaces/classes by default, and mention "break
1171 * ax-gdb.c (agent_command_1): Adjust to pass a
1172 symbol_name_match_type to new_linespec_location.
1173 * breakpoint.c (parse_breakpoint_sals): Adjust to
1174 get_linespec_location's return type change.
1175 (strace_marker_create_sals_from_location): Adjust to pass a
1176 symbol_name_match_type to new_linespec_location.
1177 (strace_marker_decode_location): Adjust to get_linespec_location's
1179 (strace_command): Adjust to pass a symbol_name_match_type to
1180 new_linespec_location.
1181 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
1182 mention "-qualified".
1183 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
1184 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
1186 (complete_address_and_linespec_locations): New parameter
1187 'match_type'. Pass it down.
1188 (explicit_options): Add "-qualified".
1189 (collect_explicit_location_matches): Pass the requested match type
1190 to the linespec completers. Handle MATCH_QUALIFIED.
1191 (location_completer): Handle "-qualified" combined with linespecs.
1192 * cp-support.c (cp_search_name_hash): New.
1193 (cp_symbol_name_matches_1): Implement wild matching for C++.
1194 (cp_fq_symbol_name_matches): Reimplement.
1195 (cp_get_symbol_name_matcher): Return different matchers depending
1196 on the lookup name's match type.
1197 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
1198 * cp-support.h (cp_search_name_hash): New declaration.
1200 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
1202 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
1204 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
1205 pass a symbol_name_match_type to new_linespec_location.
1206 * linespec.c (linespec_parse_basic): Lookup function symbols using
1207 the parser's symbol name match type.
1208 (convert_explicit_location_to_linespec): New
1209 symbol_name_match_type parameter. Pass it down to
1210 find_linespec_symbols.
1211 (convert_explicit_location_to_sals): Pass the location's name
1212 match type to convert_explicit_location_to_linespec.
1213 (parse_linespec): New match_type parameter. Save it in the
1215 (linespec_parser_new): Default to symbol_name_match_type::WILD.
1216 (linespec_complete_function): New symbol_name_match_type
1218 (complete_linespec_component): Pass down the parser's recorded
1220 (linespec_complete_label): New symbol_name_match_type parameter.
1222 (linespec_complete): New symbol_name_match_type parameter. Save
1223 it in the parser and pass it down. Adjust to
1224 get_linespec_location's prototype change.
1225 (find_function_symbols, find_linespec_symbols): New
1226 symbol_name_match_type parameter. Pass it down instead of
1227 assuming symbol_name_match_type::WILD.
1228 * linespec.h (linespec_complete, linespec_complete_function)
1229 (linespec_complete_label): New symbol_name_match_type parameter.
1230 * location.c (event_location::linespec_location): Now a struct
1232 (EL_LINESPEC): Adjust.
1233 (initialize_explicit_location): Default to
1234 symbol_name_match_type::WILD.
1235 (new_linespec_location): New symbol_name_match_type parameter.
1236 Record it in the location.
1237 (get_linespec_location): Now returns a struct linespec_location.
1238 (new_explicit_location): Also copy func_name_match_type.
1239 (explicit_to_string_internal)
1240 (string_to_explicit_location): Handle "-qualified".
1241 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
1242 Copy symbol_name_match_type fields.
1243 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
1245 (event_location_to_string): Adjust to LINESPEC_LOCATION type
1246 change. Handle "-qualfied".
1247 (string_to_explicit_location): Handle "-qualified".
1248 (string_to_event_location_basic): New symbol_name_match_type
1249 parameter. Pass it down.
1250 (string_to_event_location): Handle "-qualified".
1251 * location.h (struct linespec_location): New.
1252 (explicit_location::func_name_match_type): New field.
1253 (new_linespec_location): Now returns a const linespec_location *.
1254 (string_to_event_location_basic): New symbol_name_match_type
1256 (explicit_completion_info::saw_explicit_location_option): New
1258 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
1259 symbol_name_match_type to new_linespec_location.
1260 * python/py-breakpoint.c (bppy_init): Likewise.
1261 * python/python.c (gdbpy_decode_line): Likewise.
1263 2017-11-29 Pedro Alves <palves@redhat.com>
1265 * ada-lang.c (ada_lookup_name_info::matches): Change type of
1266 parameter from completion_match to completion_match_result.
1268 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
1269 * completer.c (completion_tracker::maybe_add_completion): Add
1270 match_for_lcd parameter and use it.
1271 (completion_tracker::add_completion): Likewise.
1272 * completer.h (class completion_match_for_lcd): New class.
1273 (completion_match_result::match_for_lcd): New field.
1274 (completion_match_result::set_match): New method.
1275 (completion_tracker): Add comments.
1276 (completion_tracker::add_completion): Add match_for_lcd parameter.
1277 (completion_tracker::reset_completion_match_result): Reset
1279 (completion_tracker::maybe_add_completion): Add match_for_lcd
1281 (completion_tracker::m_lowest_common_denominator_unique): Extend
1283 * cp-support.c (cp_symbol_name_matches_1)
1284 (cp_fq_symbol_name_matches): Change type of parameter from
1285 completion_match to completion_match_result. Adjust.
1286 * language.c (default_symbol_name_matcher): Change type of
1287 parameter from completion_match to completion_match_result.
1289 * language.h (completion_match_for_lcd): Forward declare.
1290 (default_symbol_name_matcher): Change type of parameter from
1291 completion_match to completion_match_result.
1292 * symtab.c (compare_symbol_name): Adjust.
1293 (completion_list_add_name): Pass the match_for_lcd to the tracker.
1294 * symtab.h (ada_lookup_name_info::matches): Change type of
1295 parameter from completion_match to completion_match_result.
1296 (symbol_name_matcher_ftype): Likewise, and update comments.
1298 2017-11-29 Pedro Alves <palves@redhat.com>
1300 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
1301 * minsyms.c (msymbol_is_text): Delete.
1302 (msymbol_is_function): New function.
1303 * minsyms.h (msymbol_is_text): Delete.
1304 (msymbol_is_function): New declaration.
1305 * symtab.c (find_function_alias_target): Use msymbol_is_function.
1307 2017-11-29 Tom Tromey <tom@tromey.com>
1309 * Makefile.in (distclean): Handle the case where rmdir fails.
1311 2017-11-29 Tom Tromey <tom@tromey.com>
1313 * symfile.c (_initialize_symfile): Update usage text for
1314 add-symbol-file, symbol-file, load.
1316 2017-11-29 Tom Tromey <tom@tromey.com>
1318 * symfile.c (add_symbol_file_command): Error if some arguments to
1319 -s are missing. Change unrecognized-argument error message.
1320 (_initialize_symfile): Fix usage text for add-symbol-file.
1322 2017-11-27 Tom Tromey <tom@tromey.com>
1324 * Makefile.in (REMOTE_OBS): Remove.
1325 (SFILES): Remove remote sources.
1326 (COMMON_SFILES): Add remote sources.
1327 (ALLDEPFILES): Remove dcache.c.
1329 2017-11-27 Tom Tromey <tom@tromey.com>
1331 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
1333 (SFILES): Use SUBDIR_TARGET_SRCS.
1334 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
1335 (CONFIG_SRC_SUBDIR): Add target.
1336 (%.o): Remove target rule.
1338 2017-11-27 Tom Tromey <tom@tromey.com>
1340 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
1341 registry.o, thread-fsm.o, debug.o.
1342 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
1343 thread-fsm.c, debug.c.
1345 2017-11-27 Tom Tromey <tom@tromey.com>
1347 * Makefile.in (COMMON_SFILES): New.
1348 (SFILES): Move some entries to COMMON_SFILES.
1349 (COMMON_OBS): Use COMMON_SFILES.
1351 2017-11-27 Tom Tromey <tom@tromey.com>
1353 * Makefile.in (YYFILES): Update comment.
1356 2017-11-27 Tom Tromey <tom@tromey.com>
1358 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
1359 (CONFIG_SRC_SUBDIR): Add python.
1360 (%.o): Remove python rule.
1361 (python/%.o): New rule.
1362 * configure: Rebuild.
1363 * configure.ac (CONFIG_OBS): Refer to python/python.o
1365 2017-11-27 Tom Tromey <tom@tromey.com>
1367 * configure: Rebuild.
1368 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
1369 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
1370 (CONFIG_SRC_SUBDIR): Add guile.
1371 (%.o): Remove guile rule.
1373 2017-11-27 Tom Tromey <tom@tromey.com>
1375 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
1376 (%.o): Remove unittests rule.
1377 (CONFIG_SRC_SUBDIR): Add unittests.
1379 2017-11-27 Tom Tromey <tom@tromey.com>
1381 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
1382 (CONFIG_SRC_SUBDIR): Add tui.
1383 (%.o): Remove tui rule.
1385 2017-11-27 Tom Tromey <tom@tromey.com>
1387 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
1388 (%.o): Remove compile rule.
1389 (CONFIG_SRC_SUBDIR): Add compile.
1391 2017-11-27 Tom Tromey <tom@tromey.com>
1393 * Makefile.in (SUBDIR_MI_OBS): Redefine.
1394 (%.o): Remove mi rule.
1395 (CONFIG_SRC_SUBDIR): Add mi.
1396 (COMMON_OBS): Use mi/mi-common.o
1398 2017-11-27 Tom Tromey <tom@tromey.com>
1400 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
1401 (%.o): Remove cli rule.
1402 (CONFIG_SRC_SUBDIR): Add cli.
1404 2017-11-27 Tom Tromey <tom@tromey.com>
1406 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
1407 * configure: Rebuild.
1408 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
1409 (CONFIG_DEP_SUBDIR): New variable.
1410 (%.o): Add order-only dependency.
1411 ($(CONFIG_DEP_SUBDIR)): New target.
1413 2017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
1416 * findcmd.c (_initialize_mem_search): Update find command help
1419 2017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
1421 * python/python.c (do_start_initialization): Change progname
1422 type to gdb::unique_xmalloc_ptr. Release the pointer when using
1425 2017-11-26 Tom Tromey <tom@tromey.com>
1427 * common/format.h: Add include guards.
1429 2017-11-26 Tom Tromey <tom@tromey.com>
1431 * nat/linux-personality.h (class
1432 maybe_disable_address_space_randomization): New class.
1433 (maybe_disable_address_space_randomization): Don't declare
1435 * nat/linux-personality.c (restore_personality)
1436 (make_disable_asr_cleanup): Remove.
1437 (maybe_disable_address_space_randomization): Now a constructor.
1438 (~maybe_disable_address_space_randomization): New destructor.
1439 * linux-nat.c (linux_nat_create_inferior): Update.
1441 2017-11-26 Tom Tromey <tom@tromey.com>
1443 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
1445 2017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
1447 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
1448 "cooked" register. Access only first four bytes of branch target
1451 2017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
1454 * stap-probe.c (relocate_address): New function.
1455 (stap_probe::get_relocated_address): Use 'relocate_address'.
1456 (stap_probe::set_semaphore): Use 'relocate_address' and pass
1458 (stap_probe::clear_semaphore): Likewise.
1460 2017-11-25 Pedro Alves <palves@redhat.com>
1462 * dictionary.c: Include "safe-ctype.h".
1463 * minsyms.c: Include "safe-ctype.h".
1464 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
1466 2017-11-25 Pedro Alves <palves@redhat.com>
1468 * completer.c (complete_line_internal_1): Skip spaces until the
1469 start of the command.
1471 2017-11-24 Pedro Alves <palves@redhat.com>
1473 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
1474 cp_fq_symbol_name_matches. Pass language_cplus to
1476 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
1477 (selftests::test_cp_symbol_name_cmp): New.
1478 (_initialize_cp_support): Register "cp_symbol_name_matches"
1480 * language.c (default_symbol_name_matcher): Pass language_minimal
1481 to strncmp_iw_with_mode.
1482 * utils.c: Include "cp-support.h" and <algorithm>.
1483 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
1484 (cp_is_operator): New functions.
1485 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
1486 skip whitespace in the symbol name when the lookup name doesn't
1487 have spaces, and vice versa.
1488 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
1489 * utils.h (strncmp_iw_with_mode): Add language parameter.
1491 2017-11-24 Joel Brobecker <brobecker@adacore.com>
1493 * ada-lang.c (ada_exception_message_1, ada_exception_message):
1495 (print_it_exception): If available, display the exception
1497 * NEWS: Document new feature.
1499 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1501 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
1503 2017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
1505 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
1506 (dtrace_probe::is_enabled, dtrace_probe::enable)
1507 (dtrace_probe::disable): Remove keyword 'struct' at for-range
1509 * probe.c (gen_ui_out_table_header_info)
1510 (print_ui_out_not_applicables): Remove keyword 'struct' at
1513 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1515 * configure.tgt: Add arch/aarch64.o
1517 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1519 * common/common-utils.h: Include poison.h.
1520 (xfree): Remove declaration, add definition with static_assert.
1521 * common/common-utils.c (xfree): Remove.
1522 * common/poison.h (IsMallocatable): Define.
1523 (IsFreeable): Define.
1524 (free): Delete for non-freeable types.
1526 (XNEW): Undef and redefine.
1528 (XCNEW): Undef and redefine.
1530 (XDELETE): Undef and redefine.
1532 (XNEWVEC): Undef and redefine.
1534 (XCNEWVEC): Undef and redefine.
1536 (XRESIZEVEC): Undef and redefine.
1538 (XDELETEVEC): Undef and redefine.
1540 (XNEWVAR): Undef and redefine.
1542 (XCNEWVAR): Undef and redefine.
1544 (XRESIZEVAR): Undef and redefine.
1546 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1548 * gdbthread.h (private_thread_info): Define structure type, add
1549 virtual pure destructor.
1550 (thread_info) <priv>: Change type to unique_ptr.
1551 <private_dtor>: Remove.
1552 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
1553 (private_thread_info::~private_thread_info): Provide default
1555 (thread_info::~thread_info): Don't call private_dtor nor
1557 * aix-thread.c (private_thread_info): Rename to ...
1558 (aix_thread_info): ... this.
1559 (get_aix_thread_info): New.
1560 (sync_threadlists): Adjust.
1562 (aix_thread_resume): Adjust.
1563 (aix_thread_fetch_registers): Adjust.
1564 (aix_thread_store_registers): Adjust.
1565 (aix_thread_extra_thread_info): Adjust.
1566 * darwin-nat.h (private_thread_info): Rename to ...
1567 (darwin_thread_info): ... this.
1568 (get_darwin_thread_info): New.
1569 * darwin-nat.c (darwin_init_thread_list): Adjust.
1570 (darwin_check_new_threads): Adjust.
1571 (thread_info_from_private_thread_info): Adjust.
1572 * linux-thread-db.c (private_thread_info): Rename to ...
1573 (thread_db_thread_info): ... this, initialize fields.
1574 (get_thread_db_thread_info): New.
1575 <dying>: Change type to bool.
1576 (update_thread_state): Adjust to type rename.
1577 (record_thread): Adjust to type rename an use of unique_ptr.
1578 (thread_db_pid_to_str): Likewise.
1579 (thread_db_extra_thread_info): Likewise.
1580 (thread_db_thread_handle_to_thread_info): Likewise.
1581 (thread_db_get_thread_local_address): Likewise.
1582 * nto-tdep.h (private_thread_info): Rename to ...
1583 (nto_thread_info): ... this, initialize fields.
1584 (get_nto_thread_info): New.
1585 <name>: Change type to std::string.
1586 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1588 * nto-procfs.c (update_thread_private_data_name): Adjust to
1589 std::string change, allocate nto_private_thread_info with new.
1590 (update_thread_private_data): Adjust to unique_ptr.
1591 * remote.c (private_thread_info): Rename to ...
1592 (remote_thread_info): ... this, initialize data members with
1594 <extra, name>: Change type to std::string.
1595 <thread_handle>: Change type to non-pointer.
1596 (free_private_thread_info): Remove.
1597 (get_private_info_thread): Rename to...
1598 (get_remote_thread_info): ... this, change return type, adjust to
1599 use of unique_ptr, use remote_thread_info constructor.
1600 (remote_add_thread): Adjust.
1601 (get_private_info_ptid): Rename to...
1602 (get_remote_thread_info): ...this, change return type.
1603 (remote_thread_name): Use get_remote_thread_info, adjust to
1604 change to std::string.
1605 (struct thread_item) <~thread_item>: Remove.
1606 <thread_handle>: Make non pointer.
1607 (start_thread): Adjust to thread_item::thread_handle type
1609 (remote_update_thread_list): Adjust to type name change, move
1610 strings from temporary to long-lived object instead of
1612 (remote_threads_extra_info): Use get_remote_thread_info.
1613 (process_initial_stop_replies): Likewise.
1614 (resume_clear_thread_private_info): Likewise.
1615 (remote_resume): Adjust to type name change.
1616 (remote_commit_resume): Use get_remote_thread_info.
1617 (process_stop_reply): Adjust to type name change.
1618 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1619 (remote_stopped_by_hw_breakpoint): Likewise.
1620 (remote_stopped_by_watchpoint): Likewise.
1621 (remote_stopped_data_address): Likewise.
1622 (remote_core_of_thread): Likewise.
1623 (remote_thread_handle_to_thread_info): Use
1624 get_private_info_thread, adjust to thread_handle field type
1627 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1629 * remote.c (struct thread_item): Add constructor, disable copy
1630 construction and copy assignment, define default move
1631 construction and move assignment.
1632 <extra, name>: Change type to std::string.
1634 <thread_handle>: Make non-pointer.
1635 (thread_item_t): Remove typedef.
1636 (DEF_VEC_O(thread_item_t)): Remove.
1637 (threads_listing_context) <contains_thread>: New method.
1638 <remove_thread>: New method.
1639 <items>: Change type to std::vector.
1640 (clear_threads_listing_context): Remove.
1641 (threads_listing_context_remove): Remove.
1642 (remote_newthread_step): Use thread_item constructor, adjust to
1643 change to std::vector.
1644 (start_thread): Use thread_item constructor, adjust to change to
1646 (end_thread): Adjust to change to std::vector and std::string.
1647 (remote_get_threads_with_qthreadinfo): Use thread_item
1648 constructor, adjust to std::vector.
1649 (remote_update_thread_list): Adjust to change to std::vector and
1650 std::string, use threads_listing_context methods.
1651 (remove_child_of_pending_fork): Adjust.
1652 (remove_new_fork_children): Adjust.
1653 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1654 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1655 * unittests/rsp-low-selftests.c: New file.
1656 * common/rsp-low.h: Include common/byte-vector.h.
1657 (hex2bin): New overload.
1658 * common/rsp-low.c (hex2bin): New overload.
1660 2017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1662 * inferior.h (private_inferior): Define structure type, add
1663 virtual pure destructor.
1664 (inferior) <priv>: Change type to unique_ptr.
1665 * inferior.c (private_inferior::~private_inferior): Provide
1666 default implementation.
1667 (inferior::~inferior): Don't free priv field.
1668 (exit_inferior_1): Likewise.
1669 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1670 (darwin_exception_info): Remove typedef.
1671 (DEF_VEC_O (darwin_thread_t)); Remove.
1672 (private_inferior): Rename to ...
1673 (darwin_private_inferior): ... this, extend private_inferior.
1674 (get_darwin_inferior): New.
1675 <threads>: Change type to std::vector of darwin_thread_t pointers.
1676 * darwin-nat.c (darwin_check_new_threads): Adjust.
1677 (find_inferior_task_it): Adjust.
1678 (darwin_find_thread); Adjust.
1679 (darwin_suspend_inferior): Adjust.
1680 (darwin_resume_inferior): Adjust.
1681 (darwin_find_new_inferior): Adjust.
1682 (darwin_decode_notify_message): Adjust.
1683 (darwin_send_reply): Adjust.
1684 (darwin_resume_inferior_threads): Adjust.
1685 (darwin_suspend_inferior_threads): Adjust.
1686 (darwin_decode_message): Adjust.
1687 (darwin_wait): Adjust.
1688 (darwin_interrupt): Adjust.
1689 (darwin_deallocate_threads): Adjust.
1690 (darwin_mourn_inferior): Adjust, don't free private data.
1691 (darwin_reply_to_all_pending_messages): Adjust.
1692 (darwin_stop_inferior): Adjust.
1693 (darwin_setup_exceptions): Adjust.
1694 (darwin_kill_inferior): Adjust.
1695 (darwin_setup_request_notification): Adjust.
1696 (darwin_attach_pid): Adjust.
1697 (darwin_init_thread_list): Adjust.
1698 (darwin_setup_fake_stop_event): Adjust.
1699 (darwin_attach): Adjust.
1700 (darwin_detach): Adjust.
1701 (darwin_xfer_partial): Adjust.
1702 (set_enable_mach_exceptions): Adjust.
1703 (darwin_pid_to_exec_file): Adjust.
1704 (darwin_get_ada_task_ptid): Adjust.
1705 * darwin-nat-info.c (get_task_from_args): Adjust.
1706 (info_mach_ports_command): Adjust.
1707 (info_mach_region_command): Adjust.
1708 (info_mach_exceptions_command): Adjust.
1709 * remote.c (private_inferior): Rename to ...
1710 (remote_private_inferior): ... this, initialize fields.
1711 (get_remote_inferior); New.
1712 (remote_commit_resume): Use get_remote_inferior.
1713 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1715 2017-11-24 Pedro Alves <palves@redhat.com>
1717 * NEWS: Mention linespecs and explicit locations, and completion
1720 2017-11-24 Yao Qi <yao.qi@linaro.org>
1722 * regcache.c (regcache::dump): Remove footnote_register_size.
1724 2017-11-24 Yao Qi <yao.qi@linaro.org>
1726 * regcache.c (cooked_read_test): Add more test for readonly
1729 2017-11-24 Yao Qi <yao.qi@linaro.org>
1731 * gdbarch-selftests.c (test_target_has_registers): Move it to
1733 (test_target_has_stack): Likewise.
1734 (test_target_has_memory): Likewise.
1735 (test_target_prepare_to_store): Likewise.
1736 (test_target_store_registers): Likewise.
1737 (test_target_ops): Likewise.
1738 * regcache.c: Include selftest-arch.h and gdbthread.h.
1739 (target_ops_no_register): New class.
1740 (test_target_fetch_registers): New.
1741 (test_target_store_registers): New.
1742 (test_target_xfer_partial): New.
1743 (readwrite_regcache): New.
1744 (cooked_read_test): New.
1745 (_initialize_regcache): Register the test.
1746 * target.c: (test_target_has_registers): Moved from
1747 gdbarch-selftests.c.
1748 (test_target_has_stack): Likewise.
1749 (test_target_has_memory): Likewise.
1750 (test_target_prepare_to_store): Likewise.
1751 (test_target_store_registers): Likewise.
1752 * target.h (test_target_ops): New class.
1754 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1756 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1759 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1761 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1762 * arch/aarch64.c (aarch64_create_target_description): Create
1763 new target description.
1764 * features/Makefile: Add new files.
1765 * features/aarch64.c: Remove file.
1766 * features/aarch64-core.c: New autogenerated file.
1767 * features/aarch64-fpu.c: New autogenerated file.
1768 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
1770 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1772 * Makefile.in: Add new files.
1773 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1774 aarch64_read_description.
1775 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1776 Call aarch64_read_description.
1777 * aarch64-tdep.c (aarch64_read_description): New function.
1778 (aarch64_gdbarch_init): Call aarch64_read_description.
1779 * aarch64-tdep.h (aarch64_read_description): New function.
1780 * arch/aarch64.c: New file.
1781 * configure.tgt: Add new files.
1783 2017-11-24 Yao Qi <yao.qi@linaro.org>
1785 * mi/mi-main.c (register_changed_p): Update.
1786 * value.c (value_contents_bits_eq): Change return type.
1787 (value_contents_eq): Likewise.
1788 * value.h: Update comments.
1790 2017-11-24 Yao Qi <yao.qi@linaro.org>
1792 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1793 local 'changed'. Remove error.
1794 (register_changed_p): Change return type to bool.
1796 2017-11-24 Yao Qi <yao.qi@linaro.org>
1798 * arch/tic6x.c: New file.
1799 * arch/tic6x.h: New file.
1800 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1801 tic6x-core.xml and tic6x-gp.xml.
1802 * features/tic6x-c6xp.c: Generated.
1803 * features/tic6x-core.c: Generated.
1804 * features/tic6x-gp.c: Generated.
1805 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1808 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1810 * mi/mi-main.c (list_available_thread_groups): Change map value
1811 type to std::vector.
1813 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1815 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1817 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1819 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1821 <children_requested>: ... this.
1822 (varobj_get_num_children, varobj_update): Adjust.
1824 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1826 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1827 (ada_value_has_mutated): Likewise.
1828 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1829 (c_is_path_expr_parent): Likewise.
1830 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1831 (mi_cmd_var_set_frozen): Likewise.
1832 (mi_cmd_var_update_iter): Likewise.
1833 (mi_cmd_var_update): Likewise.
1834 * varobj.c (pretty_printing): Likewise.
1835 (varobj_enable_pretty_printing): Likewise.
1836 (struct varobj_root) <floating, is_valid>: Likewise.
1837 (struct varobj_dynamic) <children_requested>: Likewise.
1838 (delete_variable): Likewise.
1839 (delete_variable_1): Likewise.
1840 (install_variable): Likewise.
1841 (update_type_if_necessary): Likewise.
1842 (install_new_value): Likewise.
1843 (value_of_root): Likewise.
1844 (is_root_p): Likewise.
1845 (varobj_create): Likewise.
1846 (varobj_delete): Likewise.
1847 (varobj_has_more): Likewise.
1848 (varobj_set_frozen): Likewise.
1849 (varobj_get_frozen): Likewise.
1850 (install_dynamic_child): Likewise.
1851 (dynamic_varobj_has_child_method): Likewise.
1852 (update_dynamic_varobj_children): Likewise.
1853 (varobj_get_num_children): Likewise.
1854 (varobj_list_children): Likewise.
1855 (is_path_expr_parent): Likewise.
1856 (varobj_default_is_path_expr_parent): Likewise.
1857 (varobj_is_dynamic_p): Likewise.
1858 (varobj_set_value): Likewise.
1859 (varobj_value_has_mutated): Likewise.
1860 (varobj_update): Likewise.
1861 (check_scope): Likewise.
1862 (value_of_root_1): Likewise.
1863 (varobj_value_get_print_value): Likewise.
1864 (varobj_editable_p): Likewise.
1865 (varobj_value_is_changeable_p): Likewise.
1866 (varobj_floating_p): Likewise.
1867 (varobj_default_value_is_changeable_p): Likewise.
1868 (varobj_invalidate_iter): Likewise.
1869 * varobj.h (struct varobj_update_result) <type_changed,
1870 children_changed, changed, value_installed>: Likewise.
1871 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1872 (struct lang_varobj_ops) <value_is_changeable_p,
1873 value_has_mutated, is_path_expr_parent>: Likewise.
1874 (varobj_delete): Likewise.
1875 (varobj_set_frozen): Likewise.
1876 (varobj_get_frozen): Likewise.
1877 (varobj_set_value): Likewise.
1878 (varobj_update): Likewise.
1879 (varobj_editable_p): Likewise.
1880 (varobj_floating_p): Likewise.
1881 (varobj_has_more): Likewise.
1882 (varobj_is_dynamic_p): Likewise.
1883 (varobj_default_value_is_changeable_p): Likewise.
1884 (varobj_value_is_changeable_p): Likewise.
1885 (varobj_is_anonymous_child): Likewise.
1886 (varobj_default_is_path_expr_parent): Likewise.
1888 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1890 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1891 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1892 <type_str>: Convert to 'std::string'.
1893 <expr>: Convert to 'expression_up'.
1894 (dtrace_probe_arg_s): Delete type and VEC.
1895 (dtrace_probe_enabler_s): Likewise.
1896 (struct dtrace_probe): Replace by...
1897 (class dtrace_static_probe_ops): ...this and...
1898 (class dtrace_probe): ...this.
1899 (dtrace_probe_is_linespec): Rename to...
1900 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1902 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1903 Adjust code. Create new instance of 'dtrace_probe'.
1904 (dtrace_build_arg_exprs): Rename to...
1905 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1907 (dtrace_get_probes): Rename to...
1908 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1910 (dtrace_get_arg): Rename to...
1911 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1913 (dtrace_probe_is_enabled): Rename to...
1914 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
1916 (dtrace_get_probe_address): Rename to...
1917 (dtrace_probe::get_relocated_address): ...this. Adjust code
1919 (dtrace_get_probe_argument_count): Rename to...
1920 (dtrace_probe::get_argument_count): ...this. Adjust code to
1922 (dtrace_can_evaluate_probe_arguments): Rename to...
1923 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
1925 (dtrace_evaluate_probe_argument): Rename to...
1926 (dtrace_probe::evaluate_argument): ...this. Adjust code to
1928 (dtrace_compile_to_ax): Rename to...
1929 (dtrace_probe::compile_to_ax): ...this. Adjust code to
1931 (dtrace_probe_destroy): Delete.
1932 (dtrace_type_name): Rename to...
1933 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
1935 (dtrace_probe::get_static_ops): New method.
1936 (dtrace_gen_info_probes_table_header): Rename to...
1937 (dtrace_static_probe_ops::gen_info_probes_table_header):
1938 ...this. Adjust code to reflect change.
1939 (dtrace_gen_info_probes_table_values): Rename to...
1940 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
1941 code to reflect change.
1942 (dtrace_enable_probe): Rename to...
1943 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
1945 (dtrace_disable_probe): Rename to...
1946 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
1948 (struct probe_ops dtrace_probe_ops): Delete.
1949 (info_probes_dtrace_command): Call 'info_probes_for_spops'
1950 instead of 'info_probes_for_ops'.
1951 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
1954 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1955 Simon Marchi <simark@simark.ca>
1957 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
1959 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
1960 <aexpr>: Change type to 'expression_up'.
1961 (stap_probe_arg_s): Delete type and VEC.
1962 (struct stap_probe): Delete. Replace by...
1963 (class stap_static_probe_ops): ...this and...
1964 (class stap_probe): ...this. Rename variables to add 'm_'
1965 prefix. Do not use 'union' for arguments anymore.
1966 (stap_get_expected_argument_type): Receive probe name instead
1967 of 'struct stap_probe'. Adjust code.
1968 (stap_parse_probe_arguments): Rename to...
1969 (stap_probe::parse_arguments): ...this. Adjust code to
1971 (stap_get_probe_address): Rename to...
1972 (stap_probe::get_relocated_address): ...this. Adjust code
1974 (stap_get_probe_argument_count): Rename to...
1975 (stap_probe::get_argument_count): ...this. Adjust code
1977 (stap_get_arg): Rename to...
1978 (stap_probe::get_arg_by_number'): ...this. Adjust code to
1980 (can_evaluate_probe_arguments): Rename to...
1981 (stap_probe::can_evaluate_arguments): ...this. Adjust code
1983 (stap_evaluate_probe_argument): Rename to...
1984 (stap_probe::evaluate_argument): ...this. Adjust code
1986 (stap_compile_to_ax): Rename to...
1987 (stap_probe::compile_to_ax): ...this. Adjust code to
1989 (stap_probe_destroy): Delete.
1990 (stap_modify_semaphore): Adjust comment.
1991 (stap_set_semaphore): Rename to...
1992 (stap_probe::set_semaphore): ...this. Adjust code to reflect
1994 (stap_clear_semaphore): Rename to...
1995 (stap_probe::clear_semaphore): ...this. Adjust code to
1997 (stap_probe::get_static_ops): New method.
1998 (handle_stap_probe): Adjust code to create instance of
2000 (stap_get_probes): Rename to...
2001 (stap_static_probe_ops::get_probes): ...this. Adjust code to
2003 (stap_probe_is_linespec): Rename to...
2004 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
2006 (stap_type_name): Rename to...
2007 (stap_static_probe_ops::type_name): ...this. Adjust code to
2009 (stap_gen_info_probes_table_header): Rename to...
2010 (stap_static_probe_ops::gen_info_probes_table_header):
2011 ...this. Adjust code to reflect change.
2012 (stap_gen_info_probes_table_values): Rename to...
2013 (stap_probe::gen_info_probes_table_values): ...this. Adjust
2014 code to reflect change.
2015 (struct probe_ops stap_probe_ops): Delete.
2016 (info_probes_stap_command): Use 'info_probes_for_spops'
2017 instead of 'info_probes_for_ops'.
2018 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
2021 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
2023 * break-catch-throw.c (fetch_probe_arguments): Use
2024 'probe.prob' instead of 'probe.probe'.
2025 * breakpoint.c (create_longjmp_master_breakpoint): Call
2026 'can_evaluate_arguments' and 'get_relocated_address' methods
2028 (create_exception_master_breakpoint): Likewise.
2029 (add_location_to_breakpoint): Use 'sal->prob' instead of
2031 (bkpt_probe_insert_location): Call 'set_semaphore' method from
2033 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
2034 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
2036 (probe_key_free): Call 'delete' on probe.
2037 (check_exception_resume): Use 'probe.prob' instead of
2039 * location.c (string_to_event_location_basic): Call
2040 'probe_linespec_to_static_ops'.
2041 * probe.c (class any_static_probe_ops): New class.
2042 (any_static_probe_ops any_static_probe_ops): New variable.
2043 (parse_probes_in_pspace): Receive 'static_probe_ops' as
2044 argument. Adjust code to reflect change.
2045 (parse_probes): Use 'static_probe_ops' instead of
2046 'probe_ops'. Adjust code to reflect change.
2047 (find_probes_in_objfile): Call methods to get name and
2048 provider from probe.
2049 (find_probe_by_pc): Use 'result.prob' instead of
2050 'result.probe'. Call 'get_relocated_address' method from
2052 (collect_probes): Adjust comment and argument list to receive
2053 'static_probe_ops' instead of 'probe_ops'. Adjust code to
2054 reflect change. Call necessary methods from probe.
2055 (compare_probes): Call methods to get name and provider from
2057 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
2058 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
2059 adjust code accordingly.
2060 (print_ui_out_not_applicables): Likewise.
2061 (info_probes_for_ops): Rename to...
2062 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
2063 as argument instead of 'probe_ops'. Adjust code. Call
2064 necessary methods from probe.
2065 (info_probes_command): Use 'info_probes_for_spops'.
2066 (enable_probes_command): Pass correct argument to
2067 'collect_probes'. Call methods from probe.
2068 (disable_probes_command): Likewise.
2069 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
2070 (get_probe_argument_count): Move to
2071 'any_static_probe_ops::get_argument_count'.
2072 (can_evaluate_probe_arguments): Move to
2073 'any_static_probe_ops::can_evaluate_arguments'.
2074 (evaluate_probe_argument): Move to
2075 'any_static_probe_ops::evaluate_argument'.
2076 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
2078 (probe_linespec_to_ops): Rename to...
2079 (probe_linespec_to_static_ops): ...this. Adjust code.
2080 (probe_any_is_linespec): Rename to...
2081 (any_static_probe_ops::is_linespec): ...this.
2082 (probe_any_get_probes): Rename to...
2083 (any_static_probe_ops::get_probes): ...this.
2084 (any_static_probe_ops::type_name): New method.
2085 (any_static_probe_ops::gen_info_probes_table_header): New
2087 (compute_probe_arg): Use 'pc_probe.prob' instead of
2088 'pc_probe.probe'. Call methods from probe.
2089 (compile_probe_arg): Likewise.
2090 (std::vector<const probe_ops *> all_probe_ops): Delete.
2091 (std::vector<const static_probe_ops *> all_static_probe_ops):
2093 (_initialize_probe): Use 'all_static_probe_ops' instead of
2095 * probe.h (struct info_probe_column) <field_name>: Delete
2097 (info_probe_column_s): Delete type and VEC.
2098 (struct probe_ops): Delete. Replace with...
2099 (class static_probe_ops): ...this and...
2100 (clas probe): ...this.
2101 (struct bound_probe) <bound_probe>: Delete extraneous
2102 newline. Adjust constructor to receive 'probe' instead of
2104 <probe>: Rename to...
2105 <prob>: ...this. Delete extraneous newline.
2106 <objfile>: Delete extraneous newline.
2107 (register_probe_ops): Delete unused prototype.
2108 (info_probes_for_ops): Rename to...
2109 (info_probes_for_spops): ...this. Adjust comment.
2110 (get_probe_address): Move to 'probe::get_address'.
2111 (get_probe_argument_count): Move to
2112 'probe::get_argument_count'.
2113 (can_evaluate_probe_arguments): Move to
2114 'probe::can_evaluate_arguments'.
2115 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
2116 * solib-svr4.c (struct svr4_info): Adjust comment.
2117 (struct probe_and_action) <probe>: Rename to...
2119 (register_solib_event_probe): Receive 'probe' instead of
2120 'struct probe' as argument. Use 'prob' instead of 'probe'
2122 (solib_event_probe_action): Call 'get_argument_count' method
2123 from probe. Adjust comment.
2124 (svr4_handle_solib_event): Adjust comment. Call
2125 'evaluate_argument' method from probe.
2126 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
2128 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
2129 'struct probe'. Call 'can_evaluate_arguments' from probe.
2130 * symfile.h: Forward declare 'class probe' instead of 'struct
2132 * symtab.h: Likewise.
2133 (struct symtab_and_line) <probe>: Rename to...
2135 * tracepoint.c (start_tracing): Use 'prob' when applicable.
2137 (stop_tracing): Likewise.
2139 2017-11-22 Joel Brobecker <brobecker@adacore.com>
2141 * ravenscar-thread.c (ravenscar_inferior_created): Remove
2142 trailing newline at end of string in call to warning.
2144 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2146 * osdata.h: Include vector isntead of vec.h.
2147 (osdata_column_s): Remove typedef.
2148 (struct osdata_column): Add constructor.
2149 <name, value>: Change type to std::string.
2150 (DEF_VEC_O (osdata_column_s)): Remove.
2151 (osdata_item_s): Remove typedef.
2152 (struct osdata_item) <columns>: Change type to std::vector.
2153 (DEF_VEC_O (osdata_item_s)): Remove.
2154 (struct osdata): Add constructor.
2155 <type>: Change type to std::string.
2156 <items>: Change type to std::vector.
2157 (osdata_p): Remove typedef.
2158 (DEF_VEC_P (osdata_p)): Remove.
2159 (osdata_parse): Return a unique_ptr.
2160 (osdata_free): Remove.
2161 (make_cleanup_osdata_free): Remove.
2162 (get_osdata): Return a unique_ptr.
2163 (get_osdata_column): Return pointer to std::string, take a
2164 reference to osdata_item as parameter.
2165 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
2167 <property_name>: Change type to std::string.
2168 (osdata_start_osdata): Allocate osdata with new and adjust.
2169 (osdata_start_item): Adjust.
2170 (osdata_start_column): Adjust.
2171 (osdata_end_column): Adjust.
2172 (clear_parsing_data): Remove.
2173 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
2174 (osdata_item_clear): Remove.
2175 (get_osdata): return a unique_ptr and adjust.
2176 (get_osdata_column): Return a pointer to std::string and adjust.
2177 (info_osdata): Adjust.
2178 * mi/mi-main.c: Include <map>.
2179 (free_vector_of_osdata_items): Remove.
2180 (list_available_thread_groups): Adjust, use std::map instead of
2183 2017-11-22 Simon Marchi <simon.marchi@ericsson.com>
2185 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
2188 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2190 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
2192 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2194 * varobj.h (struct varobj_update_result): Add constructor, add
2195 move constructor, disable copy and assign, initialize fields.
2196 <newobj>: Change type to std::vector.
2197 (varobj_update): Return std::vector.
2198 * varobj.c (install_dynamic_child): Change VEC parameters to
2199 std::vector and adjust.
2200 (update_dynamic_varobj_children): Likewise.
2201 (varobj_update): Return std::vector and adjust.
2202 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
2204 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2206 * varobj.h (struct varobj) <parent>: Remove const.
2207 <children>: Change type to std::vector.
2208 (varobj_list_children): Return std::vector const reference.
2209 (varobj_restrict_range): Change parameter type to std::vector
2211 * varobj.c (varobj_has_more): Adjust.
2212 (varobj_restrict_range): Change parameter type to std::vector
2213 const reference and adjust.
2214 (install_dynamic_child): Adjust.
2215 (update_dynamic_varobj_children): Adjust.
2216 (varobj_list_children): Return std::vector const reference and
2218 (varobj_add_child): Adjust.
2219 (update_type_if_necessary): Adjust.
2220 (varobj_update): Adjust.
2221 (delete_variable_1): Adjust.
2222 * ada-varobj.c (ada_value_has_mutated): Adjust.
2223 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
2225 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2227 * varobj.h (struct varobj): Add constructor and destructor,
2229 * varobj.c (struct varobj_root): Initialize fields.
2230 (struct varobj_dynamic): Initialize fields.
2231 (varobj_create): Use unique_ptr instead of cleanup. Create
2232 varobj with new instead of new_root_variable.
2233 (delete_variable_1): Free variable with delete instead of
2235 (create_child_with_value): Create variable with new instead of
2237 (varobj::varobj): New.
2238 (varobj::~varobj): New (body mostly coming from free_variable).
2239 (new_variable): Remove.
2240 (free_variable): Remove.
2241 (do_free_variable_cleanup): Remove.
2242 (make_cleanup_free_variable): Remove.
2244 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2246 * core-regset.c: Remove file.
2247 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
2249 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2251 * NEWS: Document use of GNU MPFR.
2254 * Makefile.in (LIBMPFR): Add define.
2255 (CLIBS): Add $(LIBMPFR).
2256 * configure.ac: Add --with-mpfr configure option.
2257 * configure: Regenerate.
2258 * config.in: Regenerate.
2260 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
2261 (class mpfr_float_ops): New type.
2262 (mpfr_float_ops::from_target): Two new overloaded functions.
2263 (mpfr_float_ops::to_target): Likewise.
2264 (mpfr_float_ops::to_string): New function.
2265 (mpfr_float_ops::from_string): Likewise.
2266 (mpfr_float_ops::to_longest): Likewise.
2267 (mpfr_float_ops::from_longest): Likewise.
2268 (mpfr_float_ops::from_ulongest): Likewise.
2269 (mpfr_float_ops::to_host_double): Likewise.
2270 (mpfr_float_ops::from_host_double): Likewise.
2271 (mpfr_float_ops::convert): Likewise.
2272 (mpfr_float_ops::binop): Likewise.
2273 (mpfr_float_ops::compare): Likewise.
2274 (get_target_float_ops): Use mpfr_float_ops if available.
2276 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2278 * target-float.c: Do not include <math.h>.
2279 Include <cmath> and <limits>.
2280 (DOUBLEST): Do not define.
2281 (class target_float_ops): New type.
2282 (class host_float_ops): New templated type.
2283 (class decimal_float_ops): New type.
2285 (floatformat_to_doublest): Rename to ...
2286 (host_float_ops<T>::from_target): ... this. Use template type T
2287 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2288 (host_float_ops<T>::from_target): New overload using a type argument.
2289 (floatformat_from_doublest): Rename to ...
2290 (host_float_ops<T>::to_target): ... this. Use template type T
2291 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2292 (host_float_ops<T>::to_target): New overload using a type argument.
2293 (floatformat_printf_format): New function.
2294 (struct printf_length_modifier): New templated type.
2295 (floatformat_to_string): Rename to ...
2296 (host_float_ops<T>::to_string): ... this. Use type instead of
2297 floatformat argument. Use floatformat_printf_format and
2298 printf_length_modifier. Remove special handling of invalid numbers,
2299 infinities and NaN (moved to target_float_to_string).
2300 (struct scanf_length_modifier): New templated type.
2301 (floatformat_from_string): Rename to ...
2302 (host_float_ops<T>::from_string): ... this. Use type instead of
2303 floatformat argument. Use scanf_length_modifier.
2304 (floatformat_to_longest): Rename to ...
2305 (host_float_ops<T>::to_longest): ... this. Use type instead of
2306 floatformat argument. Handle out-of-range values deterministically.
2307 (floatformat_from_longest): Rename to ...
2308 (host_float_ops<T>::from_longest): ... this. Use type instead of
2309 floatformat argument.
2310 (floatformat_from_ulongest): Rename to ...
2311 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
2312 floatformat argument.
2313 (floatformat_to_host_double): Rename to ...
2314 (host_float_ops<T>::to_host_double): ... this. Use type instead of
2315 floatformat argument.
2316 (floatformat_from_host_double): Rename to ...
2317 (host_float_ops<T>::from_host_double): ... this. Use type instead of
2318 floatformat argument.
2319 (floatformat_convert): Rename to ...
2320 (host_float_ops<T>::convert): ... this. Use type instead of
2321 floatformat arguments. Remove handling of no-op conversions.
2322 (floatformat_binop): Rename to ...
2323 (host_float_ops<T>::binop): ... this. Use type instead of
2324 floatformat arguments.
2325 (floatformat_compare): Rename to ...
2326 (host_float_ops<T>::compare): ... this. Use type instead of
2327 floatformat arguments.
2329 (match_endianness): Use type instead of length/byte_order arguments.
2330 (set_decnumber_context): Likewise.
2331 (decimal_from_number): Likewise. Update calls.
2332 (decimal_to_number): Likewise.
2333 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
2334 (decimal_float_ops::to_host_double): New dummy function.
2335 (decimal_float_ops::from_host_double): Likewise.
2336 (decimal_to_string): Rename to ...
2337 (decimal_float_ops::to_string): ... this. Use type instead of
2338 length/byte_order arguments. Update calls.
2339 (decimal_from_string): Rename to ...
2340 (decimal_float_ops::from_string): ... this. Use type instead of
2341 length/byte_order arguments. Update calls.
2342 (decimal_from_longest): Rename to ...
2343 (decimal_float_ops::from_longest): ... this. Use type instead of
2344 length/byte_order arguments. Update calls.
2345 (decimal_from_ulongest): Rename to ...
2346 (decimal_float_ops::from_ulongest): ... this. Use type instead of
2347 length/byte_order arguments. Update calls.
2348 (decimal_to_longest): Rename to ...
2349 (decimal_float_ops::to_longest): ... this. Use type instead of
2350 length/byte_order arguments. Update calls.
2351 (decimal_binop): Rename to ...
2352 (decimal_float_ops::binop): ... this. Use type instead of
2353 length/byte_order arguments. Update calls.
2354 (decimal_compare): Rename to ...
2355 (decimal_float_ops::compare): ... this. Use type instead of
2356 length/byte_order arguments. Update calls.
2357 (decimal_convert): Rename to ...
2358 (decimal_float_ops::convert): ... this. Use type instead of
2359 length/byte_order arguments. Update calls.
2361 (target_float_same_category_p): New function.
2362 (target_float_same_format_p): Likewise.
2363 (target_float_format_length): Likewise.
2364 (enum target_float_ops_kind): New type.
2365 (get_target_float_ops_kind): New function.
2366 (get_target_float_ops): Three new overloaded functions.
2368 (target_float_is_zero): Update call.
2369 (target_float_to_string): Add special handling of invalid numbers,
2370 infinities and NaN (moved from floatformat_to_string). Use
2371 target_float_ops callback.
2372 (target_float_from_string): Use target_float_ops callback.
2373 (target_float_to_longest): Likewise.
2374 (target_float_from_longest): Likewise.
2375 (target_float_from_ulongest): Likewise.
2376 (target_float_to_host_double): Likewise.
2377 (target_float_from_host_double): Likewise.
2378 (target_float_convert): Add special case for no-op conversions.
2379 Use target_float_ops callback.
2380 (target_float_binop): Use target_float_ops callback.
2381 (target_float_compare): Likewise.
2383 2017-11-22 Yao Qi <yao.qi@linaro.org>
2385 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
2387 2017-11-22 Yao Qi <yao.qi@linaro.org>
2389 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
2390 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
2392 2017-11-21 Jerome Guitton <guitton@adacore.com>
2394 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
2395 with event ptid from the lower layer before doing the
2396 ravenscar-specific update.
2398 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2400 * ravenscar-thread.c (is_ravenscar_task): Also verify that
2401 the ptid's TID is nonzero.
2403 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2405 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
2406 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
2407 Make non-static. Change return type to char *. Adjust code
2408 accordingly. Rewrite the function's documentation.
2409 (read_atcb): Adjust call to get_tcb_types_info accordingly.
2410 * ravenscar-thread.c (ravenscar_inferior_created): Check that
2411 we have enough debugging information in the runtime to support
2412 Ada task debugging before we enable the ravenscar-thread layer.
2414 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2416 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
2417 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
2418 * ravenscar-thread.c: Add into comment.
2419 (base_magic_null_ptid): Delete.
2420 (base_ptid): Change documentation.
2421 (ravenscar_active_task): Renames ravenscar_running_thread.
2422 All callers updated throughout.
2423 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
2424 (ravenscar_task_is_currently_active): Likewise.
2425 (get_base_thread_from_ravenscar_task): Ditto.
2426 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
2427 (ravenscar_runtime_initialized): Likewise.
2428 (get_running_thread_id): Add new parameter "cpu". Adjust
2429 implementation to handle this new parameter.
2430 (ravenscar_fetch_registers): Small adjustment to use
2431 is_ravenscar_task and ravenscar_task_is_currently_active in
2432 order to decide whether to use the target beneath or this
2434 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
2435 (ravenscar_stopped_by_sw_breakpoint): Use
2436 get_base_thread_from_ravenscar_task to get the underlying
2437 thread, rather than using base_ptid.
2438 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2439 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2441 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
2443 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2445 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
2446 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
2447 (get_tcb_types_info): Set fieldnos.base_cpu.
2448 (read_atcb): Set task_info->base_cpu.
2449 (info_task): Print "Base CPU" info if set by runtime.
2451 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2453 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
2454 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2455 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2457 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
2458 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
2459 to_stopped_data_address and to_core_of_thread fields of
2462 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
2464 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
2465 (struct gdbarch_tdep): New member long_double_abi.
2466 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
2467 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
2468 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
2469 format depending on long_double_abi tdep member.
2470 (ppc_floatformat_for_type): Handle __ibm128 type.
2472 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
2474 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
2476 2017-11-21 Pedro Alves <palves@redhat.com>
2478 * dwarf2read.c (mapped_index::find_name_components_bounds)
2479 <completion mode, upper bound>: Use std::lower_bound instead of
2481 (test_mapped_index_find_name_component_bounds): Remove incorrect
2482 "t1_fund" from expected symbols.
2484 2017-11-21 Pedro Alves <palves@redhat.com>
2486 * dwarf2read.c (mapped_index::name_components_casing): New field.
2487 (mapped_index) <build_name_components,
2488 find_name_components_bounds): Declare new methods.
2489 (mapped_index::find_name_components_bounds)
2490 (mapped_index::build_name_components): New methods, factored out
2491 from dw2_expand_symtabs_matching_symbol.
2492 (check_find_bounds_finds)
2493 (test_mapped_index_find_name_component_bounds): New.
2494 (run_test): Rename to ...
2495 (test_dw2_expand_symtabs_matching_symbol): ... this.
2496 (run_test): Reimplement.
2498 2017-11-21 Pedro Alves <palves@redhat.com>
2500 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
2501 (symbol_end): Use cp_ident_is_alnum.
2502 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
2503 * dwarf2read.c (make_sort_after_prefix_name): New function.
2504 (dw2_expand_symtabs_matching_symbol): Use it.
2505 (test_symbols): Add more symbols.
2506 (run_test): Add tests.
2508 2017-11-17 Tom Tromey <tom@tromey.com>
2510 * symtab.h (enum symbol_subclass_kind): New.
2511 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
2513 <subclass>: New member.
2514 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
2515 * rust-lang.c (rust_get_trait_object_pointer): Update.
2516 * dwarf2read.c (read_func_scope): Update.
2517 (read_variable): Update.
2519 2017-11-17 Tom Tromey <tom@tromey.com>
2521 * dwarf2read.c (read_func_scope): Update.
2522 * symtab.h (struct template_symbol): Derive from symbol.
2525 2017-11-17 Tom Tromey <tom@tromey.com>
2527 * symtab.h (struct symbol) <is_rust_vtable>: New member.
2528 (struct rust_vtable_symbol): New.
2529 (find_symbol_at_address): Declare.
2530 * symtab.c (find_symbol_at_address): New function.
2531 * symfile.h (struct quick_symbol_functions)
2532 <find_compunit_symtab_by_address>: New member.
2533 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
2535 (debug_sym_quick_functions): Link to
2536 debug_qf_find_compunit_symtab_by_address.
2537 * rust-lang.c (rust_get_trait_object_pointer): New function.
2538 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
2539 rust_get_trait_object_pointer.
2540 * psymtab.c (psym_relocate): Clear psymbol_map.
2541 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
2543 (psym_functions): Link to psym_find_compunit_symtab_by_address.
2544 * objfiles.h (struct objfile) <psymbol_map>: New member.
2545 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
2546 (process_die) <DW_TAG_variable>: New case. Call read_variable.
2547 (rust_containing_type, read_variable): New functions.
2549 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2551 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
2553 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2555 * common/filestuff.c: Include <algorithm>.
2556 (open_fds): Change type to std::vector<int>.
2557 (do_mark_open_fd): Adjust.
2558 (unmark_fd_no_cloexec): Adjust.
2561 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2563 * breakpoint.c (output_thread_groups): Take an std::vector.
2564 (print_one_breakpoint_location): Adjust.
2566 2017-11-17 Joel Brobecker <brobecker@adacore.com>
2568 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2569 (ada_evaluate_subexp_for_cast): New function.
2570 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2571 ada_evaluate_subexp_for_cast.
2572 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2574 * eval.c (evaluate_var_value): Make non-static.
2575 (evaluate_var_msym_value, eval_skip_value): Likewise.
2576 * value.h (evaluate_var_value, evaluate_var_msym_value)
2577 (eval_skip_value): Declare.
2579 2017-11-16 Joel Brobecker <brobecker@adacore.com>
2581 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2584 2017-11-16 Pedro Alves <palves@redhat.com>
2586 * python/py-unwind.c (pyuw_sniffer): Translate
2587 PyExc_KeyboardInterrupt to a GDB Quit exception.
2589 2017-11-16 Pedro Alves <palves@redhat.com>
2591 * infrun.c (resume_cleanups): Delete.
2592 (resume): No longer install a resume_cleanups cleanup nor call
2594 (proceed): Pass the terminal to the inferior.
2595 (keep_going_pass_signal): No longer install a resume_cleanups
2598 2017-11-16 Pedro Alves <palves@redhat.com>
2600 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2601 if the prompt is blocked.
2603 2017-11-16 Pedro Alves <palves@redhat.com>
2605 * breakpoint.c (insert_bp_location): Replace bp_err and
2606 bp_err_message locals by a gdb_exception local.
2608 2017-11-16 Pedro Alves <palves@redhat.com>
2610 * inflow.c (scoped_ignore_sigttou): New class.
2611 (child_terminal_ours_1, new_tty): Use it.
2613 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2615 * target-float.c (decimal_from_number): Add byte_order argument and
2616 call match_endianness. Error if unknown floating-point type.
2617 (decimal_to_number): Add byte_order argument and call match_endianness.
2618 (decimal_from_longest): Update call. Do not call match_endianness.
2619 (decimal_from_ulongest): Likewise.
2620 (decimal_binop): Likewise.
2621 (decimal_is_zero): Likewise.
2622 (decimal_compare): Likewise.
2623 (decimal_convert): Likewise.
2625 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2627 * python/python.c (gdbpy_rbreak): New function.
2628 * NEWS: Document Python rbreak feature.
2630 2017-11-16 Yao Qi <yao.qi@linaro.org>
2632 * features/tic6x-c62x.xml: Remove.
2633 * features/tic6x-c64x.xml: Remove.
2634 * features/tic6x-c64xp.xml: Remove.
2636 2017-11-15 John Baldwin <jhb@FreeBSD.org>
2638 * symtab.h: Include <array>.
2640 2017-11-15 John Baldwin <jhb@FreeBSD.org>
2642 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2643 (bsd_kvm_proc_cmd): Likewise.
2645 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2647 * tui/tui-win.c (window_name_completer): Replace VEC with
2650 2017-11-15 Andrew Cagney <cagney@gnu.org>
2652 * MAINTAINERS: Remove no-longer applicable entries.
2654 2017-11-15 Andrew Cagney <cagney@gnu.org>
2656 * MAINTAINERS: Move self to Past Maintainers.
2658 2017-11-15 Yao Qi <yao.qi@linaro.org>
2660 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2661 * features/nios2-linux.c: Remove.
2662 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2663 initialize_tdesc_nios2_linux.
2665 2017-11-15 Yao Qi <yao.qi@linaro.org>
2667 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2668 M68HC11_LAST_HARD_REG + 1.
2670 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2673 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2674 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2675 Return TARGET_XFER_EOF if size of returned data is 0.
2677 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2679 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2680 memory-map-selftests.c.
2681 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2682 * memory-map.c (memory_map_start_memory): Fix computation of hi
2684 * unittests/memory-map-selftests.c: New file.
2686 2017-11-09 Joel Brobecker <brobecker@adacore.com>
2688 * ada-lang.c: Fix some typos in the general command documenting
2689 how Ada expressions are being evaluated and how their result
2692 2017-11-09 Tom Tromey <tom@tromey.com>
2694 * psymtab.c (psymbol_hash): Do not hash string contents.
2695 (psymbol_compare): Add comment.
2697 2017-11-09 Tom Tromey <tom@tromey.com>
2699 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2701 2017-11-08 Joel Brobecker <brobecker@adacore.com>
2703 * ada-exp.y (write_var_from_sym): Remove parameter
2704 "orig_left_context". Update all callers.
2706 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2708 * tracepoint.h (class collection_list) <stringify>: Return
2709 std::vector<std::string>.
2710 (encode_actions_rsp): Change parameters to
2711 std::vector<std::string> *.
2712 * tracepoint.c (collection_list::stringify): Return
2713 std::vector<std::string> and adjust accordingly.
2714 (encode_actions_rsp): Changee parameters to
2715 std::vector<std::string> and adjust accordingly.
2716 * remote.c (free_actions_list),
2717 free_actions_list_cleanup_wrapper): Remove.
2718 (remote_download_tracepoint): Adjust to std::vector.
2720 2017-11-08 Tom Tromey <tom@tromey.com>
2722 * dwarf2read.c (symbolp): Remove typedef.
2723 (read_func_scope): Use std::vector.
2724 (process_structure_scope): Use std::vector.
2726 2017-11-08 Pedro Alves <palves@redhat.com>
2728 * ada-lang.c (ada_make_symbol_completion_list): Use
2729 completion_skip_symbol.
2730 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2731 (symbol_is_function_or_method(symbol*)): New.
2732 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2733 completion_skip_symbol.
2734 (default_collect_symbol_completion_matches_break_on): Use
2735 completion_skip_symbol. Pass down mode.
2736 (collect_file_symbol_completion_matches): Pass down mode.
2737 * symtab.h (symbol_is_function_or_method): New declarations.
2738 (completion_skip_symbol): New template function.
2740 2017-11-08 Pedro Alves <palves@redhat.com>
2742 * linespec.c (iterate_over_all_matching_symtabs): Add
2743 search_domain parameter. Pass it down to expand_symtabs_matching.
2744 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2745 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2747 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2749 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2751 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2754 2017-11-08 Pedro Alves <palves@redhat.com>
2756 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2757 text_len locals and don't pass them down.
2758 * symtab.c (completion_list_add_name): Remove
2759 sym_text/sym_text_len parameters and adjust.
2760 (completion_list_add_symbol, completion_list_add_msymbol)
2761 (completion_list_objc_symbol, completion_list_add_fields)
2762 (add_symtab_completions): Likewise.
2763 (default_collect_symbol_completion_matches_break_on)
2764 (collect_file_symbol_completion_matches): Remove sym_text_len
2765 local and don't pass it down.
2766 * symtab.h (completion_list_add_name): Remove
2767 sym_text/sym_text_len parameters.
2769 2017-11-08 Pedro Alves <palves@redhat.com>
2771 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2772 unittests/lookup_name_info-selftests.c.
2773 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2774 * cp-support.c: Include "selftest.h".
2775 (cp_remove_params_1): Rename from cp_remove_params. Add
2776 'require_param' parameter, and handle it.
2777 (cp_remove_params): Reimplement.
2778 (cp_remove_params_if_any): New.
2779 (selftests::quote): New.
2780 (selftests::check_remove_params): New.
2781 (selftests::test_cp_remove_params): New.
2782 (_initialize_cp_support): Install
2783 selftests::test_cp_remove_params.
2784 * cp-support.h (cp_remove_params_if_any): Declare.
2785 * dwarf2read.c :Include "selftest.h".
2786 (dw2_expand_symtabs_matching_symbol): Use
2787 lookup_name_info::make_ignore_params.
2788 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2789 (selftests::dw2_expand_symtabs_matching::string_or_null)
2790 (selftests::dw2_expand_symtabs_matching::check_match)
2791 (selftests::dw2_expand_symtabs_matching::test_symbols)
2792 (selftests::dw2_expand_symtabs_matching::run_test): New.
2793 (_initialize_dwarf2_read): Register
2794 selftests::dw2_expand_symtabs_matching::run_test.
2795 * psymtab.c (psym_expand_symtabs_matching): Use
2796 lookup_name_info::make_ignore_params.
2797 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2798 If the lookup name wants to ignore parameters, strip them.
2799 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2801 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2802 (default_collect_symbol_completion_matches_break_on): Don't try to
2804 * symtab.h (lookup_name_info::lookup_name_info): Add
2805 'ignore_parameters' parameter.
2806 (lookup_name_info::ignore_parameters)
2807 (lookup_name_info::make_ignore_params): New methods.
2808 (lookup_name_info::m_ignore_parameters): New field.
2809 * unittests/lookup_name_info-selftests.c: New file.
2811 2017-11-08 Pedro Alves <palves@redhat.com>
2813 * dwarf2read.c (dw2_expand_marked_cus)
2814 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2815 (dw2_expand_symtabs_matching): Move further below.
2816 (dw2_expand_marked_cus): Reindent.
2818 2017-11-08 Pedro Alves <palves@redhat.com>
2820 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2821 (struct name_component): New.
2822 (mapped_index::name_components): New field.
2823 (mapped_index::symbol_name_at): New method.
2824 (dwarf2_read_index): Call mapped_index ctor.
2825 (dw2_map_matching_symbols): Add comment about name_components
2827 (dw2_expand_symtabs_matching): Factor part to...
2828 (dw2_expand_symtabs_matching_symbol): ... this new function.
2829 Build name components table, and lookup symbols in it before
2830 calling the name matcher.
2831 (dw2_expand_marked_cus): New, factored out from
2832 dw2_expand_symtabs_matching.
2833 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2835 2017-11-08 Pedro Alves <palves@redhat.com>
2837 * ada-lang.c (ada_encode): Rename to ..
2838 (ada_encode_1): ... this. Add throw_errors parameter and handle
2840 (ada_encode): Reimplement.
2841 (match_name): Delete, folded into full_name.
2842 (resolve_subexp): No longer pass the encoded name to
2843 ada_lookup_symbol_list.
2844 (should_use_wild_match): Delete.
2845 (name_match_type_from_name): New.
2846 (ada_lookup_simple_minsym): Use lookup_name_info and the
2847 language's symbol_name_matcher_ftype.
2848 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2849 (ada_add_block_renamings): Adjust to use lookup_name_info.
2850 (ada_lookup_name): New.
2851 (add_nonlocal_symbols, ada_add_all_symbols)
2852 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2853 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2854 (ada_name_for_lookup): Delete.
2855 (ada_lookup_encoded_symbol): Construct a verbatim name.
2856 (wild_match): Reverse sense of return type. Use bool.
2857 (full_match): Reverse sense of return type. Inline bits of old
2859 (ada_add_block_symbols): Adjust to use lookup_name_info.
2860 (symbol_completion_match): Delete, folded into...
2861 (ada_lookup_name_info::matches): ... .this new method.
2862 (symbol_completion_add): Delete.
2863 (ada_collect_symbol_completion_matches): Add name_match_type
2864 parameter. Adjust to use lookup_name_info and
2865 completion_list_add_name.
2866 (get_var_value, ada_add_global_exceptions): Adjust to use
2868 (ada_get_symbol_name_cmp): Delete.
2869 (do_wild_match, do_full_match): New functions.
2870 (ada_lookup_name_info::ada_lookup_name_info): New method.
2871 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2873 (ada_language_defn): Install ada_get_symbol_name_matcher.
2874 * ada-lex.l (processId): If name starts with '<', copy it
2876 * block.c (block_iter_match_step, block_iter_match_first)
2877 (block_iter_match_next, block_lookup_symbol)
2878 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2880 * block.h (block_iter_match_first, block_iter_match_next)
2881 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2882 * c-lang.c (c_language_defn, cplus_language_defn)
2883 (asm_language_defn, minimal_language_defn): Adjust comments to
2884 refer to la_get_symbol_name_matcher.
2885 * completer.c (complete_files_symbols)
2886 (collect_explicit_location_matches, symbol_completer): Pass a
2887 symbol_name_match_type down.
2888 * completer.h (class completion_match, completion_match_result):
2890 (completion_tracker::reset_completion_match_result): New method.
2891 (completion_tracker::m_completion_match_result): New field.
2892 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2894 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2896 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2897 * d-lang.c: Adjust comments to refer to
2898 la_get_symbol_name_matcher.
2899 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2900 Adjust to use lookup_name_info.
2901 (dict_iter_match_first, dict_iter_match_next)
2902 (iter_match_first_hashed, iter_match_next_hashed)
2903 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2904 with a lookup_name_info.
2905 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2907 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2908 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2909 (gdb_index_symbol_name_matcher): New class.
2910 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2911 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2912 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2913 with a symbol_name_match_type.
2914 (f_language_defn): Adjust comments to refer to
2915 la_get_symbol_name_matcher.
2916 * go-lang.c (go_language_defn): Adjust comments to refer to
2917 la_get_symbol_name_matcher.
2918 * language.c (default_symbol_name_matcher)
2919 (language_get_symbol_name_matcher): New functions.
2920 (unknown_language_defn, auto_language_defn): Adjust comments to
2921 refer to la_get_symbol_name_matcher.
2922 * language.h (symbol_name_cmp_ftype): Delete.
2923 (language_defn) <la_collect_symbol_completion_matches>: Add match
2925 <la_get_symbol_name_cmp>: Delete field.
2926 <la_get_symbol_name_matcher>: New field.
2927 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
2928 (default_symbol_name_matcher, language_get_symbol_name_matcher):
2930 * linespec.c (iterate_over_all_matching_symtabs)
2931 (iterate_over_file_blocks): Adjust to use lookup_name_info.
2932 (find_methods): Add language parameter, and use lookup_name_info
2933 and the language's symbol_name_matcher_ftype.
2934 (linespec_complete_function): Adjust.
2935 (lookup_prefix_sym): Use lookup_name_info.
2936 (add_all_symbol_names_from_pspace): Adjust.
2937 (find_superclass_methods): Add language parameter and pass it
2939 (find_method): Pass symbol language down.
2940 (find_linespec_symbols): Don't demangle or Ada encode here.
2941 (search_minsyms_for_name): Add lookup_name_info parameter.
2942 (add_matching_symbols_to_info): Add name_match_type parameter.
2943 Use lookup_name_info.
2944 * m2-lang.c (m2_language_defn): Adjust comments to refer to
2945 la_get_symbol_name_matcher.
2946 * minsyms.c: Include <algorithm>.
2947 (add_minsym_to_demangled_hash_table): Remove table parameter and
2948 add objfile parameter. Use search_name_hash, and add language to
2949 demangled languages vector.
2950 (struct found_minimal_symbols): New struct.
2951 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
2953 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
2954 input names here. Use lookup_name_info instead. Lookup up
2955 demangled names once for each language in the demangled names
2957 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
2958 demangled names once for each language in the demangled names
2960 (build_minimal_symbol_hash_tables): Adjust.
2961 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
2963 * objc-lang.c (objc_language_defn): Adjust comment to refer to
2964 la_get_symbol_name_matcher.
2965 * objfiles.h: Include <vector>.
2966 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
2967 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
2968 la_get_symbol_name_matcher.
2969 * p-lang.c (pascal_language_defn): Adjust comment to refer to
2970 la_get_symbol_name_matcher.
2971 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
2972 (match_partial_symbol): Use symbol_name_match_type,
2973 lookup_name_info and psymbol_name_matches.
2974 (lookup_partial_symbol): Use lookup_name_info.
2975 (map_block): Use symbol_name_match_type and lookup_name_info.
2976 (psym_map_matching_symbols): Use symbol_name_match_type.
2977 (psymbol_name_matches): New.
2978 (recursively_search_psymtabs): Use lookup_name_info and
2979 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
2980 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
2981 'kind' parameter to 'domain'.
2982 * rust-lang.c (rust_language_defn): Adjust comment to refer to
2983 la_get_symbol_name_matcher.
2984 * symfile-debug.c (debug_qf_map_matching_symbols)
2985 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
2986 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
2987 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
2988 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
2989 Adjust to use symbol_name_match_type.
2990 <expand_symtabs_matching>: Adjust to use lookup_name_info.
2991 (expand_symtabs_matching): Adjust to use lookup_name_info.
2992 * symmisc.c (maintenance_expand_symtabs): Use
2993 lookup_name_info::match_any ().
2994 * symtab.c (symbol_matches_search_name): New.
2995 (eq_symbol_entry): Adjust to use lookup_name_info and the
2997 (demangle_for_lookup_info::demangle_for_lookup_info): New.
2998 (lookup_name_info::match_any): New.
2999 (iterate_over_symbols, search_symbols): Use lookup_name_info.
3000 (compare_symbol_name): Add language, lookup_name_info and
3001 completion_match_result parameters, and use them.
3002 (completion_list_add_name): Make extern. Add language and
3003 lookup_name_info parameters. Use them.
3004 (completion_list_add_symbol, completion_list_add_msymbol)
3005 (completion_list_objc_symbol): Add lookup_name_info parameters and
3006 adjust. Pass down language.
3007 (completion_list_add_fields): Add lookup_name_info parameters and
3008 adjust. Pass down language.
3009 (add_symtab_completions): Add lookup_name_info parameters and
3011 (default_collect_symbol_completion_matches_break_on): Add
3012 name_match_type parameter, and use it. Use lookup_name_info.
3013 (default_collect_symbol_completion_matches)
3014 (collect_symbol_completion_matches): Add name_match_type
3015 parameter, and pass it down.
3016 (collect_symbol_completion_matches_type): Adjust.
3017 (collect_file_symbol_completion_matches): Add name_match_type
3018 parameter, and use lookup_name_info.
3019 * symtab.h: Include <string> and "common/gdb_optional.h".
3020 (enum class symbol_name_match_type): New.
3021 (class ada_lookup_name_info): New.
3022 (struct demangle_for_lookup_info): New.
3023 (class lookup_name_info): New.
3024 (symbol_name_matcher_ftype): New.
3025 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
3026 (symbol_matches_search_name): Declare.
3027 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
3028 (default_collect_symbol_completion_matches)
3029 (collect_symbol_completion_matches)
3030 (collect_file_symbol_completion_matches): Add name_match_type
3032 (iterate_over_symbols): Use lookup_name_info.
3033 (completion_list_add_name): Declare.
3034 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
3035 (strncmp_iw_with_mode): Now extern.
3036 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
3037 (strncmp_iw_with_mode): Declare.
3039 2017-11-08 Keith Seitz <keiths@redhat.com>
3040 Pedro Alves <palves@redhat.com>
3042 * ada-lang.c (ada_language_defn): Install
3043 default_search_name_hash.
3044 * buildsym.c (struct buildsym_compunit): <language>: New field.
3045 (finish_block_internal): Pass language when creating dictionaries.
3046 (start_buildsym_compunit, start_symtab): New language parameters.
3048 (restart_symtab): Pass down compilation unit's language.
3049 * buildsym.h (enum language): Forward declare.
3050 (start_symtab): New 'language' parameter.
3051 * c-lang.c (c_language_defn, cplus_language_defn)
3052 (asm_language_defn, minimal_language_defn): Install
3053 default_search_name_hash.
3054 * coffread.c (coff_start_symtab): Adjust.
3055 * d-lang.c (d_language_defn): Install default_search_name_hash.
3056 * dbxread.c (struct symloc): Add 'pst_language' field.
3057 (PST_LANGUAGE): Define.
3058 (start_psymtab, read_ofile_symtab): Use it.
3059 (process_one_symbol): New 'language' parameter. Pass it down.
3060 * dictionary.c (struct dictionary) <language>: New field.
3061 (DICT_LANGUAGE): Define.
3062 (dict_create_hashed, dict_create_hashed_expandable)
3063 (dict_create_linear, dict_create_linear_expandable): New parameter
3064 'language'. Set the dictionary's language.
3065 (iter_match_first_hashed): Adjust to rename.
3066 (insert_symbol_hashed): Assert we don't see mismatching
3067 languages. Adjust to rename.
3068 (dict_hash): Rename to ...
3069 (default_search_name_hash): ... this and make extern.
3070 * dictionary.h (struct language_defn): Forward declare.
3071 (dict_create_hashed): New parameter 'language'.
3072 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
3073 * f-lang.c (f_language_defn): Install default_search_name_hash.
3074 * go-lang.c (go_language_defn): Install default_search_name_hash.
3075 * jit.c (finalize_symtab): Pass compunit's language to dictionary
3077 * language.c (unknown_language_defn, auto_language_defn):
3078 * language.h (language_defn::la_search_name_hash): New field.
3079 (default_search_name_hash): Declare.
3080 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
3081 * mdebugread.c (new_block): New parameter 'language'.
3082 * mdebugread.c (parse_symbol): Pass symbol language to block
3084 (psymtab_to_symtab_1): Pass down language.
3085 (new_symtab): Pass compunit's language to block allocation.
3086 * objc-lang.c (objc_language_defn): Install
3087 default_search_name_hash.
3088 * opencl-lang.c (opencl_language_defn):
3089 * p-lang.c (pascal_language_defn): Install
3090 default_search_name_hash.
3091 * rust-lang.c (rust_language_defn): Install
3092 default_search_name_hash.
3093 * stabsread.h (enum language): Forward declare.
3094 (process_one_symbol): Add 'language' parameter.
3095 * symtab.c (search_name_hash): New function.
3096 * symtab.h (search_name_hash): Declare.
3097 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
3099 2017-11-08 Pedro Alves <palves@redhat.com>
3101 * cp-name-parser.y (main): Don't initialize extra_chars.
3103 2017-11-07 Tom Tromey <tom@tromey.com>
3105 * event-top.h (command_handler): Constify.
3106 * record-full.c (cmd_record_full_start): Update.
3107 * thread.c (thread_apply_all_command): Update.
3108 * printcmd.c (eval_command): Update.
3109 * mi/mi-main.c (mi_execute_cli_command): Update.
3110 (mi_execute_async_cli_command): Update.
3111 * tui/tui-stack.c (tui_update_command): Update.
3112 * cli/cli-interp.c (safe_execute_command): Constify.
3113 * record.c (record_start): Update.
3114 (record_start, record_stop, cmd_record_start): Update.
3115 * record-btrace.c (cmd_record_btrace_bts_start): Update.
3116 (cmd_record_btrace_pt_start): Update.
3117 (cmd_record_btrace_start): Update.
3118 (cmd_record_btrace_start): Update.
3119 * reverse.c (exec_reverse_once): Update.
3120 * python/python.c (execute_gdb_command): Don't copy the command.
3121 * event-top.c (command_line_handler): Update.
3122 (command_handler): Constify.
3123 * defs.h (deprecated_call_command_hook): Constify.
3124 * cli/cli-script.h (execute_user_command): Constify.
3125 * cli/cli-script.c (execute_user_command): Constify.
3126 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
3127 (enum command_control_type): Update.
3128 * main.c (catch_command_errors): Remove non-const overload.
3129 (catch_command_errors_ftype): Remove.
3130 * python/py-cmd.c (cmdpy_function): Constify.
3131 * guile/scm-cmd.c (cmdscm_function): Constify.
3132 * cli/cli-dump.c (call_dump_func): Constify.
3133 * cli/cli-decode.c (do_const_cfunc): Constify.
3134 (do_sfunc): Constify.
3135 (cmd_func): Constify.
3136 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
3137 * top.h (execute_command): Constify.
3138 * top.c (execute_command): Constify.
3139 (execute_command_to_string): Constify.
3140 (deprecated_call_command_hook): Constify.
3141 * command.h (cmd_func): Constify.
3142 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
3144 2017-11-07 Tom Tromey <tom@tromey.com>
3146 * ada-lang.c (catch_ada_exception_command): Constify.
3147 (catch_assert_command): Constify.
3148 * break-catch-throw.c (catch_catch_command, catch_throw_command)
3149 (catch_rethrow_command): Constify.
3150 (catch_exception_command_1): Constify.
3151 * breakpoint.h (add_catch_command): Constify.
3152 * break-catch-syscall.c (catch_syscall_command_1): Constify.
3153 (catch_syscall_split_args): Constify.
3154 * break-catch-sig.c (catch_signal_command): Constify.
3155 (catch_signal_split_args): Constify.
3156 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
3157 cmd_const_sfunc_ftype.
3158 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
3159 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3160 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3161 (add_setshow_string_cmd, struct cmd_list_element)
3162 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3163 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3164 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
3166 (set_cmd_sfunc): Constify.
3167 (empty_sfunc): Constify.
3168 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3169 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3170 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
3171 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3172 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3173 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
3175 (set_cmd_sfunc): Constify.
3176 (cmd_sfunc_ftype): Remove.
3177 * compile/compile.c (set_compile_args): Constify.
3178 * infrun.c (set_disable_randomization): Constify.
3179 * infcmd.c (set_args_command, set_cwd_command): Constify.
3180 * breakpoint.c (set_condition_evaluation_mode): Constify.
3181 (add_catch_command): Constify.
3182 (catch_fork_command_1, catch_exec_command_1)
3183 (catch_load_command_1, catch_unload_command_1): Constify.
3184 (catch_load_or_unload): Constify.
3185 * guile/scm-param.c (pascm_set_func): Constify.
3186 (add_setshow_generic): Constify.
3187 * python/py-param.c (get_set_value): Constify.
3188 * top.h (set_verbose): Constify.
3189 * tui/tui-win.c (tui_set_var_cmd): Constify.
3190 * mi/mi-main.c (set_mi_async_command): Constify.
3191 * cli/cli-logging.c (set_logging_overwrite)
3192 (set_logging_redirect): Constify.
3193 * value.c (set_max_value_size): Constify.
3194 * valprint.c (set_input_radix, set_output_radix): Constify.
3195 * utils.c (set_width_command, set_height_command): Constify.
3196 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
3197 * tracepoint.c (set_disconnected_tracing)
3198 (set_circular_trace_buffer, set_trace_buffer_size)
3199 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
3200 * top.c (set_history_size_command, set_verbose, set_editing)
3201 (set_gdb_datadir, set_history_filename): Constify.
3202 * target.c (set_targetdebug, maint_set_target_async_command)
3203 (maint_set_target_non_stop_command, set_target_permissions)
3204 (set_write_memory_permission): Constify.
3205 (open_target): Constify.
3206 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
3207 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
3208 * symtab.c (set_symbol_cache_size_handler): Constify.
3209 * symfile.c (set_ext_lang_command): Constify.
3210 * symfile-debug.c (set_debug_symfile): Constify.
3211 * source.c (set_directories_command): Constify.
3212 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
3213 * serial.c (set_parity): Constify.
3214 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
3215 * remote.c (set_remote_exec_file, set_remotebreak)
3216 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
3217 * record.c (set_record_insn_history_size)
3218 (set_record_call_history_size): Constify.
3219 * record-full.c (set_record_full_insn_max_num): Constify.
3220 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
3221 * osabi.c (set_osabi): Constify.
3222 * mips-tdep.c (set_mips64_transfers_32bit_regs)
3223 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
3224 * maint.c (maintenance_set_profile_cmd): Constify.
3225 * linux-thread-db.c (set_libthread_db_search_path): Constify.
3226 * language.c (set_language_command, set_range_command)
3227 (set_case_command): Constify.
3228 * infrun.c (set_non_stop, set_observer_mode)
3229 (set_stop_on_solib_events, set_schedlock_func)
3230 (set_exec_direction_func): Constify.
3231 * infcmd.c (set_inferior_tty_command): Constify.
3232 * disasm.c (set_disassembler_options_sfunc): Constify.
3233 * demangle.c (set_demangling_command): Constify.
3234 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
3235 * cris-tdep.c (set_cris_version, set_cris_mode)
3236 (set_cris_dwarf2_cfi): Constify.
3237 * corefile.c (set_gnutarget_command): Constify.
3238 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
3239 (set_target_wide_charset_sfunc): Constify.
3240 * breakpoint.c (update_dprintf_commands): Constify.
3241 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
3242 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
3243 (set_disassembly_style_sfunc): Constify.
3244 * arch-utils.c (set_endian, set_architecture): Constify.
3245 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
3246 * agent.c (set_can_use_agent): Constify.
3248 2017-11-07 Tom Tromey <tom@tromey.com>
3250 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
3251 (go32_pde, go32_pte, go32_pte_for_address): Constify.
3252 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
3253 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
3254 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
3255 (parse_int_arg, show_thread_default_detach_sc_cmd)
3256 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
3257 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
3258 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
3259 (show_task_pause_cmd, set_task_detach_sc_cmd)
3260 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
3261 (set_noninvasive_cmd, set_thread_pause_cmd)
3262 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
3263 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
3264 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
3265 * windows-nat.c (display_selectors): Constify.
3266 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
3268 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
3269 (cmd_cfunc_eq): Likewise.
3270 (struct cmd_list_element): Likewise.
3272 (cli_user_command_p): Update.
3273 * command.h (add_cmd): Remove non-const overload.
3274 (cmd_cfunc_ftype): Remove typedef.
3275 (cmd_cfunc_eq): Remove non-const overload.
3276 * value.c (show_values): Constify.
3277 * thread.c (thread_apply_all_command): Constify.
3278 * symfile.c (load_command): Constify.
3279 * source.c (directory_command): Constify.
3280 * maint.c (maintenance_internal_error)
3281 (maintenance_demangler_warning, maintenance_space_display)
3282 (maintenance_print_architecture, maintenance_translate_address)
3283 (maintenance_info_selftests, maintenance_internal_warning):
3285 * breakpoint.c (disable_trace_command, enable_trace_command):
3287 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
3289 (add_auto_load_safe_path): Constify.
3290 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
3291 * top.h (show_commands): Constify.
3292 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
3293 * sparc64-tdep.c (adi_examine_command): Constify.
3294 (adi_assign_command): Constify.
3296 2017-11-07 Tom Tromey <tom@tromey.com>
3298 * frame.h (info_locals_command, info_args_command): Constify.
3299 * auto-load.h (auto_load_info_scripts): Constify.
3300 * inferior.h (registers_info): Constify.
3301 * copying.c: Rebuild.
3302 * copying.awk: Constify generated commands.
3303 * auto-load.c (auto_load_info_scripts)
3304 (info_auto_load_gdb_scripts): Constify.
3305 * cli/cli-decode.c (struct cmd_list_element): Take a
3306 cmd_const_cfunc_ftype.
3307 * command.h (add_info): Take a cmd_const_cfunc_ftype.
3308 * tui/tui-win.c (tui_all_windows_info): Constify.
3309 * python/py-auto-load.c (info_auto_load_python_scripts):
3311 * cli/cli-cmds.c (show_command): Remove non-const overload.
3312 * tracepoint.c (info_tvariables_command, info_scope_command):
3314 (info_static_tracepoint_markers_command): Constify.
3315 * thread.c (info_threads_command): Constify.
3316 (print_thread_info_1): Constify.
3317 * target.c (info_target_command): Constify.
3318 * symtab.c (info_sources_command, info_functions_command)
3319 (info_types_command): Constify.
3320 (info_variables_command): Remove non-const overload.
3321 * symfile.c (info_ext_lang_command): Constify.
3322 * stack.c (info_frame_command, info_locals_command)
3323 (info_args_command): Constify.
3324 (backtrace_command): Remove non-const overload.
3325 * source.c (info_source_command, info_line_command): Constify.
3326 * solib.c (info_sharedlibrary_command): Constify.
3327 * skip.c (info_skip_command): Constify.
3328 * ser-go32.c (info_serial_command): Constify.
3329 * reverse.c (info_bookmarks_command): Constify.
3330 * printcmd.c (info_symbol_command, info_address_command)
3331 (info_display_command): Constify.
3332 * osdata.c (info_osdata_command): Constify.
3333 * objc-lang.c (info_selectors_command, info_classes_command):
3335 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
3336 * memattr.c (info_mem_command): Constify.
3337 * macrocmd.c (info_macro_command, info_macros_command): Constify.
3338 * linux-fork.c (info_checkpoints_command): Constify.
3339 * infrun.c (info_signals_command): Constify.
3340 * inflow.c (info_terminal_command): Constify.
3341 * inferior.c (info_inferiors_command): Constify.
3342 (print_inferior): Constify.
3343 * infcmd.c (info_program_command, info_all_registers_command)
3344 (info_registers_command, info_vector_command)
3345 (info_float_command): Constify.
3346 (registers_info): Constify.
3347 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
3348 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
3350 * f-valprint.c (info_common_command): Constify.
3351 * dcache.c (info_dcache_command): Constify.
3352 (dcache_info_1): Constify.
3353 * darwin-nat-info.c (info_mach_tasks_command)
3354 (info_mach_task_command, info_mach_ports_command)
3355 (info_mach_port_command, info_mach_threads_command)
3356 (info_mach_thread_command, info_mach_regions_command)
3357 (info_mach_regions_recurse_command, info_mach_region_command)
3358 (info_mach_exceptions_command): Constify.
3359 (get_task_from_args): Constify.
3360 * cp-support.c (info_vtbl_command): Constify.
3361 * breakpoint.c (info_watchpoints_command)
3362 (info_tracepoints_command): Constify.
3363 (info_breakpoints_command): Remove non-const overload.
3364 * avr-tdep.c (avr_io_reg_read_command): Constify.
3365 * auxv.c (info_auxv_command): Constify.
3366 * ada-tasks.c (info_tasks_command): Constify.
3367 (info_task): Constify.
3368 * ada-lang.c (info_exceptions_command): Constify.
3370 2017-11-07 Tom Tromey <tom@tromey.com>
3372 * solib.h (no_shared_libraries): Constify.
3373 * frame.h (return_command): Constify.
3374 * cli/cli-cmds.h (quit_command): Constify.
3375 * top.h (quit_command, execute_command): Constify.
3376 * target.h (flash_erase_command): Constify.
3377 * inferior.h (set_inferior_args, attach_command): Constify.
3378 * tracepoint.h (start_tracing, stop_tracing): Constify.
3379 * breakpoint.h (break_command, tbreak_command)
3380 (hbreak_command_wrapper, thbreak_command_wrapper)
3381 (rbreak_command_wrapper, watch_command_wrapper)
3382 (awatch_command_wrapper, rwatch_command_wrapper)
3383 (get_tracepoint_by_number): Constify.
3384 * symtab.c (info_variables_command, rbreak_command)
3385 (symtab_symbol_info): Constify.
3386 (info_variables_command): Add non-const overload.
3387 * top.c (dont_repeat_command): Constify.
3388 * breakpoint.c (ignore_command, commands_command)
3389 (condition_command, tbreak_command, hbreak_command)
3390 (thbreak_command, clear_command, break_command)
3391 (info_breakpoints_command, watch_command, rwatch_command)
3392 (awatch_command, trace_command, ftrace_command, strace_command)
3393 (trace_pass_command, break_range_command, dprintf_command)
3394 (agent_printf_command, get_tracepoint_by_number)
3395 (watch_maybe_just_location, trace_pass_command): Constify.
3396 (info_breakpoints_command): Add non-const overload.
3397 * tracefile.c (tsave_command): Constify.
3398 * infcmd.c (attach_command, disconnect_command, signal_command)
3399 (queue_signal_command, stepi_command, nexti_command)
3400 (finish_command, next_command, step_command, until_command)
3401 (advance_command, jump_command, continue_command, run_command)
3402 (start_command, starti_command, interrupt_command)
3403 (run_command_1, set_inferior_args, step_1): Constify.
3404 * inferior.c (add_inferior_command, remove_inferior_command)
3405 (clone_inferior_command): Constify.
3406 * linux-fork.c (checkpoint_command, restart_command): Constify.
3407 * windows-nat.c (signal_event_command): Constify.
3408 * guile/guile.c (guile_repl_command, guile_command): Constify.
3409 * printcmd.c (x_command, display_command, printf_command)
3410 (output_command, set_command, call_command, print_command)
3411 (eval_command): Constify.
3412 (non_const_set_command): Remove.
3413 (_initialize_printcmd): Update.
3414 * source.c (forward_search_command, reverse_search_command):
3416 * jit.c (jit_reader_load_command, jit_reader_unload_command):
3418 * infrun.c (handle_command): Constify.
3419 * memattr.c (mem_command): Constify.
3420 * stack.c (return_command, up_command, up_silently_command)
3421 (down_command, down_silently_command, frame_command)
3422 (backtrace_command, func_command, backtrace_command_1): Constify.
3423 (backtrace_command): Add non-const overload.
3424 * remote-sim.c (simulator_command): Constify.
3425 * exec.c (set_section_command): Constify.
3426 * tracepoint.c (tdump_command, trace_variable_command)
3427 (tstatus_command, tstop_command, tstart_command)
3428 (end_actions_pseudocommand, while_stepping_pseudocommand)
3429 (collect_pseudocommand, teval_pseudocommand, actions_command)
3430 (start_tracing, stop_tracing): Constify.
3431 * value.c (init_if_undefined_command): Constify.
3432 * tui/tui-stack.c (tui_update_command): Constify.
3433 * tui/tui-win.c (tui_refresh_all_command)
3434 (tui_set_tab_width_command, tui_set_win_height_command)
3435 (tui_set_focus_command, tui_scroll_forward_command)
3436 (tui_scroll_backward_command, tui_scroll_left_command)
3437 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
3438 (tui_set_win_height): Constify.
3439 * tui/tui-layout.c (tui_layout_command): Constify.
3440 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
3441 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
3442 (proc_untrace_sysexit_cmd): Constify.
3443 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
3444 (threadset_test_cmd, threadlist_update_test_cmd)
3445 (threadalive_test): Constify.
3446 * objc-lang.c (print_object_command): Constify.
3447 * command.h (add_com): Constify.
3448 * cli/cli-dump.c (restore_command): Constify.
3449 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
3450 (help_command, complete_command, shell_command, edit_command)
3451 (list_command, disassemble_command, make_command)
3452 (apropos_command, alias_command): Constify.
3453 * cli/cli-script.c (document_command, define_command)
3454 (while_command, if_command, validate_comname): Constify.
3455 * cli/cli-decode.c (struct cmd_list_element): Change type of
3457 * target.c (do_monitor_command, flash_erase_command): Constify.
3458 * regcache.c (reg_flush_command): Constify.
3459 * reverse.c (reverse_step, reverse_next, reverse_stepi)
3460 (reverse_nexti, reverse_continue, reverse_finish)
3461 (save_bookmark_command, goto_bookmark_command)
3462 (exec_reverse_once): Constify.
3463 * python/python.c (python_interactive_command, python_command):
3465 * typeprint.c (ptype_command, whatis_command, whatis_exp):
3467 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
3468 * gcore.c (gcore_command): Constify.
3470 2017-11-07 Tom Tromey <tom@tromey.com>
3472 * printcmd.c (x_command): Call set_repeat_arguments.
3473 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
3474 * top.c (repeat_arguments): New global.
3475 (set_repeat_arguments): New function.
3476 (execute_command): Handle repeat_arguments.
3477 (show_commands): Calls set_repeat_arguments.
3478 * command.h (set_repeat_arguments): Declare.
3480 2017-11-07 Tom Tromey <tom@tromey.com>
3482 * stack.c (backtrace_command): Use std::string.
3483 (backtrace_command_1): Make "count_exp" const.
3485 2017-11-07 Tom Tromey <tom@tromey.com>
3487 * source.c (directory_switch, mod_path, add_path): Constify.
3488 * defs.h (add_path, mod_path, directory_switch): Constify.
3489 * mi/mi-cmd-env.c (env_mod_path): Constify.
3491 2017-11-07 Tom Tromey <tom@tromey.com>
3493 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
3494 (run_command_1, continue_command, step_1, jump_command)
3495 (signal_command, until_command, advance_command, finish_command)
3496 (attach_command): Update.
3498 2017-11-07 Tom Tromey <tom@tromey.com>
3500 * command.h (set_cmd_cfunc): Don't declare.
3501 * cli/cli-decode.c (set_cmd_cfunc): Now static.
3503 2017-11-07 Tom Tromey <tom@tromey.com>
3505 * stack.c (select_frame_command): Constify.
3506 * cli/cli-decode.c (add_com_suppress_notification): Constify.
3507 * command.h (add_com_suppress_notification): Constify.
3509 2017-11-07 Tom Tromey <tom@tromey.com>
3511 * breakpoint.c (stop_command): Constify.
3512 * cli/cli-decode.c (struct cmd_list_element): Constify.
3513 * command.h (add_abbrev_prefix_cmd): Constify.
3515 2017-11-07 Pedro Alves <palves@redhat.com>
3517 * breakpoint.c (extract_bp_kind): New enum.
3518 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
3519 factored out from ...
3520 (extract_bp_number_and_location): ... here.
3521 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
3523 2017-11-07 Pedro Alves <palves@redhat.com>
3525 * breakpoint.c (extract_bp_number_and_location): Change return
3526 type to void. Throw error instead of warning.
3527 (enable_disable_command): Adjust.
3529 2017-11-07 Xavier Roirand <roirand@adacore.com>
3530 Pedro Alves <palves@redhat.com>
3532 * breakpoint.c (map_breakpoint_number_range): New, factored out
3534 (map_breakpoint_numbers): ... here.
3535 (find_location_by_number): Change parameters from string to
3536 breakpoint number and location.
3537 (extract_bp_number_and_location): New function.
3538 (enable_disable_bp_num_loc)
3539 (enable_disable_breakpoint_location_range)
3540 (enable_disable_command): New functions, factored out ...
3541 (enable_command, disable_command): ... these functions, and
3542 adjusted to support ranges.
3543 * NEWS: Document enable/disable breakpoint location range feature.
3545 2017-11-06 Luis Machado <luis.machado@linaro.org>
3547 * MAINTAINERS (Write After Approval): Update my e-mail address.
3549 2017-11-06 Pedro Alves <palves@redhat.com>
3551 * gnu-nat.c (gnu_terminal_init): Delete.
3552 (gnu_target): Don't install gnu_terminal_init.
3553 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
3554 (child_terminal_init): ... this function.
3556 2017-11-06 Pedro Alves <palves@redhat.com>
3558 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
3560 * config.in, configure: Regenerate.
3562 2017-11-06 Pedro Alves <palves@redhat.com>
3564 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
3565 (async_init_signals): Adjust.
3566 (handle_stop_sig): Rename to ...
3567 (handle_sigtstp): ... this.
3568 (async_stop_sig): Rename to ...
3569 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3571 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3572 instead of STOP_SIGNAL thoughout.
3573 (handle_stop_sig): Rename to ...
3574 (handle_sigtstp): ... this.
3575 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3577 2017-11-06 Pedro Alves <palves@redhat.com>
3579 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3580 longer set flags twice in row.
3582 2017-11-06 Pedro Alves <palves@redhat.com>
3584 * Makefile.in (SER_HARDWIRE): Update comment.
3585 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3586 * common/gdb_termios.h: Delete file.
3587 * common/job-control.c: Include termios.h and unistd.h instead of
3589 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3591 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3593 * configure.ac: No longer check for termio.h and sgtty.h.
3594 * configure: Regenerate.
3595 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3596 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3597 Replace PROCESS_GROUP_TYPE references with pid_t references
3599 (gdb_getpgrp): Delete.
3600 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3601 (child_terminal_inferior): Remove comment. Remove sgtty code.
3602 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3603 gdb_getpgrp. Use serial_set_tty_state instead aof
3604 serial_noflush_set_tty_state. Remove sgtty code.
3605 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3606 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3607 (inferior_process_group): Now returns pid_t.
3608 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3609 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3610 * ser-event.c (serial_event_ops): Update.
3611 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3613 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3614 * ser-pipe.c (pipe_ops): Update.
3615 * ser-tcp.c (tcp_ops): Update.
3616 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3617 HAVE_TERMIOS checks.
3618 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3619 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3620 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3622 (hardwire_noflush_set_tty_state): Delete.
3623 (hardwire_print_tty_state, hardwire_drain_output)
3624 (hardwire_flush_output, hardwire_flush_input)
3625 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3626 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3627 code, and assume termios.
3628 (hardwire_ops): Update.
3629 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3630 * serial.c (serial_noflush_set_tty_state): Delete.
3631 * serial.h (serial_noflush_set_tty_state): Delete.
3632 (serial_ops::noflush_set_tty_state): Delete.
3634 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3636 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3637 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3638 (COMMON_OBS): Remove doublest.o and dfp.o.
3639 Do not build target-float.c (instead of doublest.c)
3640 with -Wformat-nonliteral.
3642 * doublest.c: Remove file.
3643 * doublest.h: Remove file.
3644 * dfp.c: Remove file.
3645 * dfp.h: Remove file.
3647 * target-float.c: Do not include "doublest.h" and "dfp.h".
3648 (DOUBLEST): Move here from doublest.h.
3649 (enum float_kind): Likewise.
3650 (FLOATFORMAT_CHAR_BIT): Likewise.
3651 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3652 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3653 (floatformat_precision): Likewise.
3654 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3655 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3657 (host_float_format, host_double_format, host_long_double_format):
3659 (floatformat_to_string, floatformat_from_string): Likewise.
3660 (floatformat_to_doublest): Likewise. Also, inline the original
3661 convert_floatformat_to_doublest.
3662 (floatformat_from_doublest): Likewise. Also, inline the original
3663 convert_floatformat_from_doublest.
3665 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3666 (MAX_DECIMAL_STRING): Move here from dfp.c.
3667 (match_endianness): Likewise.
3668 (set_decnumber_context, decimal_check_errors): Likewise.
3669 (decimal_from_number, decimal_to_number): Likewise.
3670 (decimal_to_string, decimal_from_string): Likewise. Make static.
3671 (decimal_from_longest, decimal_from_ulongest): Likewise.
3672 (decimal_to_longest): Likewise.
3673 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3674 (decimal_convert): Likewise.
3676 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3678 * doublest.c: Do not include "gdbtypes.h".
3679 (extract_typed_floating): Remove.
3680 (store_typed_floating): Remove.
3681 (convert_typed_floating): Remove.
3682 * doublest.h (struct type): Remove.
3683 (DOUBLEST_PRINT_FORMAT): Remove.
3684 (DOUBLEST_SCAN_FORMAT): Remove.
3685 (extract_typed_floating): Remove.
3686 (store_typed_floating): Remove.
3687 (convert_typed_floating): Remove.
3689 * dfp.c (decimal_from_doublest): Remove.
3690 (decimal_to_doublest): Remove.
3691 * dfp.h: Do not include "doublest.h".
3692 (decimal_from_doublest): Remove.
3693 (decimal_to_doublest): Remove.
3695 * value.c: Do not include "doublest.h" and "dfp.h".
3696 (value_as_double): Remove.
3697 (unpack_double): Remove.
3698 (value_from_double): Remove.
3699 (value_from_decfloat): Remove.
3700 * value.h: Do not include "doublest.h".
3701 (value_as_double): Remove.
3702 (unpack_double): Remove.
3703 (value_from_double): Remove.
3704 (value_from_decfloat): Remove.
3706 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3708 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3709 (i386_extract_return_value): Use target_float_convert.
3710 (i386_store_return_value): Likewise.
3711 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3712 (i387_value_to_register): Likewise.
3713 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3714 (ia64_register_to_value): Use target_float_convert.
3715 (ia64_value_to_register): Likewise.
3716 (ia64_extract_return_value): Likewise.
3717 (ia64_store_return_value): Likewise.
3718 (ia64_push_dummy_call): Likewise.
3719 * m68k-tdep.c: Include "target-float.h".
3720 (m68k_register_to_value): Use target_float_convert.
3721 (m68k_value_to_register): Likewise.
3722 (m68k_svr4_extract_return_value): Likewise.
3723 (m68k_svr4_store_return_value): Likewise.
3724 * ppc-sysv-tdep.c: Include "target-float.h".
3725 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3726 (do_ppc_sysv_return_value): Likewise.
3727 (ppc64_sysv_abi_push_freg): Likewise.
3728 (ppc64_sysv_abi_return_value_base): Likewise.
3729 * rs6000-aix-tdep.c: Include "target-float.h".
3730 (rs6000_push_dummy_call): Use target_float_convert.
3731 (rs6000_return_value): Likewise.
3732 * rs6000-lynx178-tdep.c: Include "target-float.h".
3733 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3734 (rs6000_lynx178_return_value): Likewise.
3735 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3736 (rs6000_register_to_value): Use target_float_convert.
3737 (rs6000_value_to_register): Likewise.
3738 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3739 (arm_extract_return_value): Use target_float_convert.
3740 (arm_store_return_value): Likewise.
3741 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3742 (sh_register_convert_to_virtual): Use target_float_convert.
3743 (sh_register_convert_to_raw): Likewise.
3744 * sh64-tdep.c: Include "target-float.h".
3745 (sh64_extract_return_value): Use target_float_convert.
3746 (sh64_register_convert_to_virtual): Likewise.
3747 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3749 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3751 * target-float.c (floatformat_to_host_double): New function.
3752 (floatformat_from_host_double): Likewise.
3753 (target_float_to_host_double): Likewise.
3754 (target_float_from_host_double): Likewise.
3755 * target-float.h (target_float_to_host_double): Add prototype.
3756 (target_float_from_host_double): Likewise.
3758 * guile/scm-value.c: Include "target-float.h".
3759 (gdbscm_value_to_real): Use target_float_to_host_double.
3760 Handle integer source values via value_as_long.
3761 * guile/scm-math.c: Include "target-float.h". Do not include
3762 "doublest.h", "dfp.h", and "expression.h".
3763 (vlscm_convert_typed_number): Use target_float_from_host_double.
3764 (vlscm_convert_number): Likewise.
3766 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3767 (convert_value_from_python): Use target_float_from_host_double.
3769 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3771 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3772 (cast_from_fixed): Likewise.
3773 (ada_scaling_type): New function.
3774 (ada_delta): Return value instead of DOUBLEST. Perform target
3775 arithmetic instead of host arithmetic.
3776 (scaling_factor): Rename to ...
3777 (ada_scaling_factor) ... this. Make non-static. Return value instead
3778 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3779 (ada_fixed_to_float): Remove.
3780 (ada_float_to_fixed): Remove.
3781 * ada-lang.h (ada_fixed_to_float): Remove.
3782 (ada_float_to_fixed): Remove.
3783 (ada_delta): Return value instead of DOUBLEST.
3784 (ada_scaling_factor): Add prototype.
3786 * ada-typeprint.c: Include "target-float.h".
3787 (print_fixed_point_type): Perform target arithmetic instead of
3789 * ada-valprint.c: Include "target-float.h".
3790 (ada_val_print_num): Perform target arithmetic instead of
3791 host arithmetic for fixed-point types.
3793 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3795 * target-float.c: Include <math.h>.
3796 (floatformat_binop): New function.
3797 (floatformat_compare): Likewise.
3798 (target_float_binop): Likewise.
3799 (target_float_compare): Likewise.
3800 * target-float.h: Include "expression.h".
3801 (target_float_binop): Add prototype.
3802 (target_float_compare): Likewise.
3804 * valarith.c: Do not include "doublest.h" and "dfp.h".
3805 Include "common/byte-vector.h".
3806 (value_args_as_decimal): Remove, replace by ...
3807 (value_args_as_target_float): ... this function. Handle both
3808 binary and decimal target floating-point formats.
3809 (scalar_binop): Handle both binary and decimal FP using
3810 value_args_as_target_float and target_float_binop.
3811 (value_equal): Handle both binary and decimal FP using
3812 value_args_as_target_float and target_float_compare.
3813 (value_less): Likewise.
3814 (value_pos): Handle all scalar types as simple copy.
3815 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3816 * dfp.c (decimal_binop): Throw error instead of internal_error
3817 when called with an unsupported operation code.
3819 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3821 * target-float.c (target_float_to_string): New function.
3822 (target_float_from_string): New function.
3823 * target-float.h (target_float_to_string): Add prototype.
3824 (target_float_from_string): Add prototype.
3826 * valprint.c: Include "target-float.h". Do not include
3827 "doublest.h" and "dfp.h".
3828 (print_floating): Use target_float_to_string.
3829 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3830 (printf_floating): Use target_float_to_string.
3831 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3832 (print_i387_value): Use target_float_to_string.
3833 * mips-tdep.c: Include "target-float.h".
3834 (mips_print_fp_register): Use target_float_to_string.
3835 * sh64-tdep.c: Include "target-float.h".
3836 (sh64_do_fp_register): Use target_float_to_string.
3838 * parse.c: Include "target-float.h". Do not include
3839 "doublest.h" and "dfp.h".
3840 (parse_float): Use target_float_from_string.
3841 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3842 (define_symbol): Use target_float_from_string.
3843 * gdbarch-selftests.c: Include "target-float.h".
3844 (register_to_value_test): Use target_float_from_string.
3846 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3848 * Makefile.c (SFILES): Add target-float.c.
3849 (HFILES_NO_SRCDIR): Add target-float.h.
3850 (COMMON_OBS): Add target-float.o.
3851 * target-float.h: New file.
3852 * target-float.c: New file.
3854 * doublest.c (floatformat_classify): Fix detection of float_zero.
3856 * gdbtypes.c (is_floating_type): New function.
3857 * gdbtypes.h (is_floating_type): Add prototype.
3859 * value.c: Do not include "floatformat.h".
3860 (unpack_double): Use target_float_is_valid.
3861 (is_floating_value): New function.
3862 * value.h (is_floating_value): Add prototype-
3864 * valarith.c: Include "target-float.h".
3865 (value_logical_not): Use target_float_is_zero.
3867 * python/py-value.c: Include "target-float.h".
3868 (valpy_nonzero): Use target_float_is_zero.
3870 2017-11-04 Tom Tromey <tom@tromey.com>
3872 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3874 2017-11-04 Tom Tromey <tom@tromey.com>
3876 * breakpoint.c (set_momentary_breakpoint): Return
3878 (until_break_command): Update.
3879 (new_until_break_fsm): Change argument types to
3881 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3882 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3884 * infcmd.c (finish_forward): Update.
3885 * breakpoint.h (set_momentary_breakpoint)
3886 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3887 (make_cleanup_delete_breakpoint): Remove.
3888 (struct breakpoint_deleter): New.
3889 (breakpoint_up): New typedef.
3890 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3891 (insert_exception_resume_breakpoint): Update.
3892 (insert_exception_resume_from_probe): Update.
3893 (insert_longjmp_resume_breakpoint): Update.
3894 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3895 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3896 * infcall.c (call_function_by_hand_dummy): Update
3898 2017-11-04 Tom Tromey <tom@tromey.com>
3900 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3902 2017-11-04 Tom Tromey <tom@tromey.com>
3904 * linux-tdep.c (linux_core_info_proc_mappings): Use
3906 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3908 (linux_corefile_thread): Update.
3909 (linux_make_corefile_notes): Remove unused variable.
3911 2017-11-04 Tom Tromey <tom@tromey.com>
3913 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
3916 2017-11-04 Tom Tromey <tom@tromey.com>
3918 * objfiles.c (do_free_objfile_cleanup): Remove.
3919 * compile/compile-object-load.c (compile_object_load): Update.
3920 * objfiles.h (make_cleanup_free_objfile): Remove.
3922 2017-11-04 Tom Tromey <tom@tromey.com>
3924 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
3925 (adi_read_versions): Change "tags" to "gdb_byte *".
3926 (adi_print_versions): Likewise.
3928 2017-11-04 Tom Tromey <tom@tromey.com>
3931 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
3932 from start_rbreak_breakpoints.
3933 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
3934 * breakpoint.h (class scoped_rbreak_breakpoints): New.
3935 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
3936 * symtab.c (do_end_rbreak_breakpoints): Remove.
3937 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
3939 2017-11-04 Tom Tromey <tom@tromey.com>
3941 * cp-namespace.c (reset_directive_searched): Remove.
3942 (cp_lookup_symbol_via_imports): Use scoped_restore.
3943 * cp-support.c (reset_directive_searched): Remove.
3944 (make_symbol_overload_list_using): Use scoped_restore.
3945 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
3946 (reset_directive_searched): Remove.
3948 2017-11-04 Tom Tromey <tom@tromey.com>
3950 * symfile.c (find_separate_debug_file_by_debuglink): Use
3953 2017-11-04 Tom Tromey <tom@tromey.com>
3955 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
3957 (compute_stack_depth): Likewise.
3958 (do_compile_dwarf_expr_to_c): Use std::vector.
3960 2017-11-04 Tom Tromey <tom@tromey.com>
3962 * compile/compile-object-load.c (link_callbacks_einfo): Use
3965 2017-11-04 Tom Tromey <tom@tromey.com>
3967 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3968 Use scoped_free_pendings.
3969 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
3970 scoped_free_pendings.
3971 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
3972 (xcoff_initial_scan): Likewise.
3973 * buildsym.c (reset_symtab_globals): Update comment.
3974 (scoped_free_pendings): Rename from really_free_pendings.
3975 (prepare_for_building): Update comment.
3976 (buildsym_init): Likewise.
3977 * buildsym.h (class scoped_free_pendings): New class.
3978 (really_free_pendings): Don't declare.
3980 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
3982 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
3983 output when converting a zero value to a special byteorder format.
3985 2017-11-02 Yao Qi <yao.qi@linaro.org>
3987 * frame.c (do_frame_register_read): Remove aspace.
3988 * jit.c (jit_frame_sniffer): Likwise.
3989 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3990 * regcache.c (regcache::regcache): Pass nullptr.
3991 (regcache_print): Caller updated.
3992 * regcache.h (regcache::regcache): Remove one constructor
3995 2017-11-02 Yao Qi <yao.qi@linaro.org>
3997 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
3999 2017-11-02 Yao Qi <yao.qi@linaro.org>
4001 * breakpoint.c (insert_single_step_breakpoints): Update.
4002 * frame.c (struct frame_info) <aspace>: Add const.
4003 (frame_save_as_regcache): Add const.
4004 (get_frame_address_space): Return const address_space *.
4005 * frame.h (get_frame_address_space): Update declaration.
4006 * infrun.c (struct step_over_info) <aspace>: Add const.
4007 (set_step_over_info): Make aspace const.
4008 (displaced_step_prepare_throw): Change variable const.
4010 (proceed): Likewise.
4011 (adjust_pc_after_break): Likewise.
4012 (save_waitstatus): Likewise.
4013 (handle_signal_stop): Likewise.
4014 (keep_going_pass_signal): Likewise.
4015 * jit.c (jit_frame_sniffer): Add const.
4016 * mips-tdep.c (mips_single_step_through_delay): Likewise.
4017 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
4018 * record-full.c (record_full_wait_1): Likewise.
4019 * regcache.c (regcache::regcache): Change parameter to const.
4020 * regcache.h (regcache::regcache): Likewise.
4021 (regcache::aspace): Return const address_space *.
4022 (regcache) <m_aspace>: Add const.
4024 2017-11-02 Yao Qi <yao.qi@linaro.org>
4026 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
4027 * frame.c (create_sentinel_frame): Likewise.
4028 * infrun.c (displaced_step_prepare_throw): Likewise.
4030 (thread_still_needs_step_over_bp): Likewise.
4031 (proceed): Likewise.
4032 (do_target_wait): Likewise.
4033 (adjust_pc_after_break): Likewise.
4034 (handle_syscall_event): Likewise.
4035 (save_waitstatus): Likewise.
4036 (handle_inferior_event_1): Likewise.
4037 (handle_signal_stop): Likewise.
4038 (keep_going_pass_signal): Likewise.
4039 * linux-nat.c (status_callback): Likewise.
4040 (save_stop_reason): Likewise.
4041 (resume_stopped_resumed_lwps): Likewise.
4042 * record-full.c (record_full_exec_insn): Likewise.
4043 (record_full_wait_1): Likewise.
4044 * regcache.c (get_regcache_aspace): Remove.
4045 * regcache.h (get_regcache_aspace): Remove.
4047 2017-11-02 Yao Qi <yao.qi@linaro.org>
4049 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
4050 (init_regcache_descr): Use gdbarch_num_regs.
4051 (regcache::regcache): Likewise.
4052 (regcache::get_register_status): Likewise.
4053 (regcache::assert_raw_regnum): Likewise.
4054 (regcache::cooked_read): Likewise.
4055 (regcache::cooked_read_value): Likewise.
4056 (regcache::cooked_write): Likewise.
4057 (regcache::dump): Likewise.
4058 (regcache::num_raw_registers): New method.
4059 * regcache.h (class regcache) <num_raw_registers>: New.
4061 2017-11-02 Yao Qi <yao.qi@linaro.org>
4063 * regcache.c (regcache::assert_regnum): New method.
4064 (regcache::invalidate): Call assert_regnum.
4065 (regcache::raw_update): Likewise.
4066 (regcache::raw_write): Likewise.
4067 (regcache::raw_read_part): Likewise.
4068 (regcache::raw_write_part): Likewise.
4069 (regcache::raw_supply): Likewise.
4070 (regcache::raw_supply_integer): Likewise.
4071 (regcache::raw_supply_zeroed): Likewise.
4072 (regcache::raw_collect): Likewise.
4073 (regcache::raw_collect_integer): Likewise.
4074 * regcache.h (regcache::assert_regnum): Declare.
4076 2017-11-02 Yao Qi <yao.qi@linaro.org>
4078 * regcache.c (regcache::dump): Remove code.
4080 2017-11-02 Yao Qi <yao.qi@linaro.org>
4082 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
4084 <sizeof_cooked_register_status>: Remove.
4085 (init_regcache_descr): Update.
4086 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
4087 (regcache::save): Likewise.
4088 (regcache::dump): Likewise.
4090 2017-11-01 James Bowman <james.bowman@ftdichip.com>
4092 * ft32-tdep.c (ft32_fetch_instruction): New function.
4093 (ft32_analyze_prologue): Use ft32_fetch_instruction().
4095 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
4097 * cli/cli-script.c (execute_control_command): Rename to ...
4098 (execute_control_command_1): ... this.
4099 (execute_control_command): New function.
4101 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
4103 * tracepoint.c (tfind_command): Remove const_cast.
4105 2017-10-30 Mike Gulick <mgulick@mathworks.com>
4107 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
4109 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
4111 * common/common-utils.h (in_inclusive_range): New function.
4112 * arm-tdep.c (arm_record_extension_space): Use
4114 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
4115 * cris-tdep.c (cris_spec_reg_applicable): Use
4118 2017-10-30 Pedro Alves <palves@redhat.com>
4119 Simon Marchi <simon.marchi@ericsson.com>
4121 * remote.c (remote_set_syscall_catchpoint): Build a std::string
4122 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
4124 2017-10-30 Pedro Alves <palves@redhat.com>
4126 * common/common-utils.c (string_appendf, string_vappendf): New
4128 * common/common-utils.h (string_appendf, string_vappendf): New
4130 * unittests/common-utils-selftests.c (string_appendf_func)
4131 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
4132 (string_vappendf_tests): New functions.
4133 (_initialize_common_utils_selftests): Register "string_appendf" and
4134 "string_vappendf tests".
4136 2017-10-30 Pedro Alves <palves@redhat.com>
4138 * unittests/common-utils-selftests.c (format_func): New typedef.
4139 (string_printf_tests, string_vprintf_tests): Tests factored out
4141 (test_format_func): ... this new function.
4142 (string_printf_tests, string_vprintf_tests): Reimplement on top of
4145 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4147 * darwin-nat.c: Remove include of gdb.h.
4149 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4151 * xtensa-xtregs.c: Fix formatting issues.
4153 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4155 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
4157 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
4160 * python/py-infthread.c (thpy_get_inferior): Increment reference
4161 of inferior before returning it.
4163 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4165 * unittests/common-utils-selftests.c (format): Add
4168 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4170 * xml-syscall.c (struct syscall_desc): Add constructor.
4171 <name>: Change type to std::string.
4172 (syscall_desc_up): New typedef.
4173 (syscall_desc_p): Remove typeder.
4174 (DEF_VEC_P(syscall_desc_p)): Remove.
4175 (struct syscall_group_desc): Add constructor.
4176 <name>: Change type to std::string.
4177 <syscalls>: Change type to std::vector.
4178 (syscall_group_desc_up): New typedef.
4179 (syscall_group_desc_p): Remove typedef.
4180 (DEF_VEC_P(syscall_group_desc_p)): Remove.
4181 (struct syscalls_info) <syscalls>: Change type to std::vector of
4184 <my_gdb_datadir>: Change type to std::string.
4185 (syscalls_info_up): New typedef.
4186 (allocate_syscalls_info): Remove.
4187 (syscalls_info_free_syscalls_desc): Remove.
4188 (syscalls_info_free_syscall_group_desc): Remove.
4189 (free_syscalls_info): Remove.
4190 (make_cleanup_free_syscalls_info): Remove.
4191 (syscall_group_create_syscall_group_desc): Adjust.
4192 (syscall_group_add_syscall): Adjust.
4193 (syscall_create_syscall_desc): Adjust.
4194 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
4195 (init_syscalls_info): Adjust.
4196 (syscall_group_get_group_by_name): Adjust.
4197 (xml_get_syscall_number): Adjust.
4198 (xml_get_syscall_name): Adjust.
4199 (xml_list_of_syscalls): Adjust.
4200 (xml_list_syscalls_by_group): Adjust.
4201 (xml_list_of_groups): Adjust.
4203 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4205 * probe.h: Don't include gdb_vecs.h.
4206 (DEF_VEC_P (probe_p)): Remove.
4207 (find_probes_in_objfile): Return an std::vector.
4208 * probe.c (find_probes_in_objfile): Likewise.
4209 * breakpoint.c (breakpoint_objfile_data)
4210 <longjmp_probes>: Change type to std::vector.
4211 <exception_probes>: Likewise.
4212 (free_breakpoint_probes): Don't manually free vectors.
4213 (create_longjmp_master_breakpoint): Adjust.
4214 (create_exception_master_breakpoint): Adjust.
4215 * solib-svr4.c (svr4_create_probe_breakpoints): Change
4216 parameter type, adjust.
4217 (svr4_create_solib_event_breakpoints): Adjust.
4219 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4221 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
4222 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
4224 (free_breakpoint_probes): Rename to ...
4225 (free_breakpoint_objfile_data): ... this, and call delete on
4228 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4230 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
4231 (loaded_script_ptr): Remove typedef.
4232 (DEF_VEC_P (loaded_script_ptr)): Remove.
4233 (struct collect_matching_scripts_data): Add constructor.
4234 <scripts_p>: Change type to (pointer to) std::vector.
4235 (collect_matching_scripts_data): Adjust.
4236 (sort_scripts_by_name): Make suitable for std::sort.
4237 (print_scripts): Don't sort vector, adjust to std::vector.
4238 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
4240 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4242 * symfile.c (filename_language): Make struct, not typedef. Add
4244 <ext>: Change type to std::string.
4245 (DEF_VEC_O (filename_language)): Remove.
4246 (filename_language_table): Change type to std::vector.
4247 (add_filename_language): Adjust.
4248 (set_ext_lang_command): Adjust.
4249 (info_ext_lang_command): Adjust.
4250 (deduce_language_from_filename): Adjust.
4251 (class scoped_restore_filename_language_table): Remove.
4252 (test_filename_language): Use scoped_restore.
4253 (test_set_ext_lang_command): Use scoped_restore, adjust to
4256 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4258 * symfile.c: Include selftest.h.
4259 (class scoped_restore_filename_language_table): New.
4260 (test_filename_language): New test.
4261 (test_set_ext_lang_command): New test.
4262 (_initialize_symfile): Register tests.
4264 2017-10-27 Keith Seitz <keiths@redhat.com>
4266 * breakpoint.c (print_breakpoint_location): Use the symbol saved
4267 in the bp_location, falling back to find_pc_sect_function when
4269 (add_location_to_breakpoint): Save sal->symbol.
4270 * breakpoint.h (struct bp_location) <symbol>: New field.
4271 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
4272 * symtab.h (struct symtab_and_line) <symbol>: New field.
4274 2017-10-26 Patrick Frants <osscontribute@gmail.com>
4277 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
4280 2017-10-26 Pedro Alves <palves@redhat.com>
4282 * remote.c (remote_async_terminal_ours_p): Delete.
4283 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
4284 Remove references to 'remote_async_terminal_ours_p'.
4286 2017-10-26 Yao Qi <yao.qi@linaro.org>
4288 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
4290 2017-10-26 Yao Qi <yao.qi@linaro.org>
4292 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
4294 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
4296 * breakpoint.c (bpstat_check_location): Remove cast.
4297 (breakpoint_hit_catch_fork): Make aspce const.
4298 (breakpoint_hit_catch_solib): Likewise.
4299 (breakpoint_hit_catch_exec): Likewise.
4300 (breakpoint_hit_ranged_breakpoint): Likewise.
4301 (breakpoint_hit_watchpoint): Likewise.
4302 (base_breakpoint_breakpoint_hit): Likewise.
4303 (bkpt_breakpoint_hit): Likewise.
4304 (dprintf_breakpoint_hit): Likewise.
4305 (tracepoint_breakpoint_hit): Likewise.
4306 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
4308 2017-10-26 Yao Qi <yao.qi@linaro.org>
4310 * breakpoint.c (breakpoint_location_address_match): Change
4311 "struct address_space *" to "const address_space".
4312 (breakpoint_location_address_range_overlap): Likewise.
4313 (breakpoint_here_p): Likewise.
4314 (breakpoint_in_range_p): Likewise.
4315 (moribund_breakpoint_here_p): Likewise.
4316 (bp_location_inserted_here_p): Likewise.
4317 (software_breakpoint_inserted_here_p): Likewise.
4318 (hardware_breakpoint_inserted_here_p): Likewise.
4319 (hardware_watchpoint_inserted_in_range): Likewise.
4320 (bpstat_check_location): Likewise.
4321 (bpstat_stop_status): Likewise.
4322 (breakpoint_address_match): Likewise.
4323 (breakpoint_address_match_range): Likewise.
4324 (breakpoint_location_address_match): Likewise.
4325 (breakpoint_location_address_range_overlap): Likewise.
4326 (insert_single_step_breakpoint): Likewise.
4327 (breakpoint_has_location_inserted_here): Likewise.
4328 (single_step_breakpoint_inserted_here_p): Likewise.
4329 (pc_at_non_inline_function): Likewise.
4330 * breakpoint.h (bpstat_stop_status): Update declaration.
4331 (breakpoint_here_p): Likewise.
4332 (breakpoint_in_range_p): Likewise.
4333 (moribund_breakpoint_here_p): Likewise.
4334 (breakpoint_inserted_here_p): Likewise.
4335 (software_breakpoint_inserted_here_p): Likewise.
4336 (hardware_breakpoint_inserted_here_p): Likewise.
4337 (breakpoint_has_location_inserted_here): Likewise.
4338 (single_step_breakpoint_inserted_here_p): Likewise.
4339 (hardware_watchpoint_inserted_in_range): Likewise.
4340 (breakpoint_address_match): Likewise.
4341 (insert_single_step_breakpoint): Likewise.
4342 (pc_at_non_inline_function): Likewise.
4343 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
4344 * record.c (record_check_stopped_by_breakpoint): Likewise.
4345 * record.h (record_check_stopped_by_breakpoint): Likewise.
4346 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
4348 2017-10-25 Yao Qi <yao.qi@linaro.org>
4350 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
4351 regcache->arch () instead get_regcache_arch.
4352 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
4354 (aarch64_fbsd_store_inferior_registers): Likewise.
4355 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
4356 (store_gregs_to_thread): Likewise.
4357 (fetch_fpregs_from_thread): Likewise.
4358 (store_fpregs_to_thread): Likewise.
4359 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
4360 (aarch64_store_return_value): Likewise.
4361 (aarch64_software_single_step): Likewise.
4362 * aix-thread.c (aix_thread_wait): Likewise.
4363 (supply_reg32): Likewise.
4364 (supply_sprs64): Likewise.
4365 (supply_sprs32): Likewise.
4366 (fill_gprs64): Likewise.
4367 (fill_gprs32): Likewise.
4368 (fill_sprs64): Likewise.
4369 (fill_sprs32): Likewise.
4370 (store_regs_user_thread): Likewise.
4371 (store_regs_kernel_thread): Likewise.
4372 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
4373 (alphabsd_store_inferior_registers): Likewise.
4374 * alpha-tdep.c (alpha_extract_return_value): Likewise.
4375 (alpha_store_return_value): Likewise.
4376 (alpha_deal_with_atomic_sequence): Likewise.
4377 (alpha_next_pc): Likewise.
4378 (alpha_software_single_step): Likewise.
4379 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
4380 (amd64bsd_store_inferior_registers): Likewise.
4381 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
4383 (amd64_linux_store_inferior_registers): Likewise.
4384 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
4385 (amd64_collect_native_gregset): Likewise.
4386 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
4387 (amd64obsd_collect_uthread): Likewise.
4388 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
4389 (amd64_collect_fpregset): Likewise.
4390 (amd64_supply_fxsave): Likewise.
4391 (amd64_supply_xsave): Likewise.
4392 (amd64_collect_fxsave): Likewise.
4393 (amd64_collect_xsave): Likewise.
4394 * arc-tdep.c (arc_write_pc): Likewise.
4395 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
4396 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
4397 (arm_fbsd_store_inferior_registers): Likewise.
4398 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
4399 (store_vfp_regs): Likewise.
4400 (arm_linux_fetch_inferior_registers): Likewise.
4401 (arm_linux_store_inferior_registers): Likewise.
4402 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
4403 (arm_linux_sigreturn_next_pc): Likewise.
4404 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
4405 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
4406 (fetch_register): Likewise.
4407 (store_register): Likewise.
4408 * arm-tdep.c (arm_is_thumb): Likewise.
4409 (displaced_in_arm_mode): Likewise.
4410 (bx_write_pc): Likewise.
4411 (arm_get_next_pcs_addr_bits_remove): Likewise.
4412 (arm_software_single_step): Likewise.
4413 (arm_extract_return_value): Likewise.
4414 (arm_store_return_value): Likewise.
4415 (arm_write_pc): Likewise.
4416 * bfin-tdep.c (bfin_extract_return_value): Likewise.
4417 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
4418 (bsd_uthread_store_registers): Likewise.
4419 * core-regset.c (fetch_core_registers): Likewise.
4420 * corelow.c (get_core_registers): Likewise.
4421 * cris-tdep.c (cris_store_return_value): Likewise.
4422 (cris_extract_return_value): Likewise.
4423 (find_step_target): Likewise.
4424 (find_step_target): Likewise.
4425 (cris_software_single_step): Likewise.
4426 * ctf.c (ctf_fetch_registers): Likewise.
4427 * darwin-nat.c (cancel_breakpoint): Likewise.
4428 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
4429 * frv-tdep.c (frv_extract_return_value): Likewise.
4430 * ft32-tdep.c (ft32_store_return_value): Likewise.
4431 (ft32_extract_return_value): Likewise.
4432 * go32-nat.c (fetch_register): Likewise.
4433 (go32_fetch_registers): Likewise.
4434 (go32_store_registers): Likewise.
4435 (store_register): Likewise.
4436 * h8300-tdep.c (h8300_extract_return_value): Likewise.
4437 (h8300_store_return_value): Likewise.
4438 * hppa-linux-nat.c (fetch_register): Likewise.
4439 (store_register): Likewise.
4440 (hppa_linux_fetch_inferior_registers): Likewise.
4441 (hppa_linux_store_inferior_registers): Likewise.
4442 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
4443 (i386_darwin_store_inferior_registers): Likewise.
4444 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
4445 (gnu_store_registers): Likewise.
4446 * i386-linux-nat.c (fetch_register): Likewise.
4447 (store_register): Likewise.
4448 (supply_gregset): Likewise.
4449 (fill_gregset): Likewise.
4450 (i386_linux_fetch_inferior_registers): Likewise.
4451 (i386_linux_store_inferior_registers): Likewise.
4452 (i386_linux_resume): Likewise.
4453 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
4455 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
4456 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
4457 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
4458 (i386obsd_collect_uthread): Likewise.
4459 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4460 (i386_supply_gregset): Likewise.
4461 (i386_collect_gregset): Likewise.
4462 (i386_supply_fpregset): Likewise.
4463 (i386_collect_fpregset): Likewise.
4464 (i386_mpx_bd_base): Likewise.
4465 * i386-v4-nat.c (supply_fpregset): Likewise.
4466 (fill_fpregset): Likewise.
4467 * i387-tdep.c (i387_supply_fsave): Likewise.
4468 (i387_collect_fsave): Likewise.
4469 (i387_supply_fxsave): Likewise.
4470 (i387_collect_fxsave): Likewise.
4471 (i387_supply_xsave): Likewise.
4472 (i387_collect_xsave): Likewise.
4473 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
4474 (ia64_linux_store_registers): Likewise.
4475 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
4476 (ia64_extract_return_value): Likewise.
4477 (ia64_store_return_value): Likewise.
4478 (find_func_descr): Likewise.
4479 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
4480 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
4481 (inf_ptrace_store_registers): Likewise.
4482 * infrun.c (use_displaced_stepping): Likewise.
4483 (displaced_step_prepare_throw): Likewise.
4485 (proceed): Likewise.
4486 (do_target_wait): Likewise.
4487 (adjust_pc_after_break): Likewise.
4488 (handle_inferior_event_1): Likewise.
4489 (handle_signal_stop): Likewise.
4490 (save_infcall_suspend_state): Likewise.
4491 (restore_infcall_suspend_state): Likewise.
4492 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
4493 * jit.c (jit_frame_prev_register): Likewise.
4494 * linux-nat.c (save_stop_reason): Likewise.
4495 (linux_nat_wait_1): Likewise.
4496 (resume_stopped_resumed_lwps): Likewise.
4497 * linux-record.c (record_linux_sockaddr): Likewise.
4498 (record_linux_msghdr): Likewise.
4499 (record_linux_system_call): Likewise.
4500 * linux-tdep.c (linux_collect_thread_registers): Likewise.
4501 * lm32-tdep.c (lm32_extract_return_value): Likewise.
4502 (lm32_store_return_value): Likewise.
4503 * m32c-tdep.c (m32c_read_flg): Likewise.
4504 (m32c_pseudo_register_read): Likewise.
4505 (m32c_pseudo_register_write): Likewise.
4506 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
4507 (m32r_linux_collect_gregset): Likewise.
4508 * m32r-tdep.c (m32r_store_return_value): Likewise.
4509 (m32r_extract_return_value): Likewise.
4510 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
4511 (m68kbsd_collect_fpregset): Likewise.
4512 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
4513 * m68k-linux-nat.c (fetch_register): Likewise.
4514 (old_fetch_inferior_registers): Likewise.
4515 (old_store_inferior_registers): Likewise.
4516 (store_regs): Likewise.
4517 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
4518 (m68k_svr4_store_return_value): Likewise.
4519 * m88k-tdep.c (m88k_store_arguments): Likewise.
4520 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
4521 (mi_cmd_data_write_register_values): Likewise.
4522 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
4523 (mips_fbsd_store_inferior_registers): Likewise.
4524 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
4525 (mips_fbsd_supply_gregs): Likewise.
4526 (mips_fbsd_collect_fpregs): Likewise.
4527 (mips_fbsd_collect_gregs): Likewise.
4528 (mips_fbsd_supply_fpregset): Likewise.
4529 (mips_fbsd_collect_fpregset): Likewise.
4530 (mips_fbsd_supply_gregset): Likewise.
4531 (mips_fbsd_collect_gregset): Likewise.
4532 * mips-linux-nat.c (supply_gregset): Likewise.
4533 (fill_gregset): Likewise.
4534 (supply_fpregset): Likewise.
4535 (fill_fpregset): Likewise.
4536 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
4537 (mips_fill_gregset): Likewise.
4538 (mips_supply_fpregset): Likewise.
4539 (mips_fill_fpregset): Likewise.
4540 (mips64_supply_gregset): Likewise.
4541 (micromips_linux_sigframe_validate): Likewise.
4542 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
4543 (mipsnbsd_fetch_inferior_registers): Likewise.
4544 (mipsnbsd_store_inferior_registers): Likewise.
4545 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
4546 (mipsnbsd_supply_gregset): Likewise.
4547 (mipsnbsd_iterate_over_regset_sections): Likewise.
4548 (mipsnbsd_supply_reg): Likewise.
4549 (mipsnbsd_supply_fpreg): Likewise.
4550 * mips-tdep.c (mips_in_frame_stub): Likewise.
4551 (mips_dummy_id): Likewise.
4552 (is_octeon_bbit_op): Likewise.
4553 (micromips_bc1_pc): Likewise.
4554 (extended_mips16_next_pc): Likewise.
4555 (mips16_next_pc): Likewise.
4556 (deal_with_atomic_sequence): Likewise.
4557 * moxie-tdep.c (moxie_process_readu): Likewise.
4558 * nios2-tdep.c (nios2_get_next_pc): Likewise.
4559 * nto-procfs.c (procfs_store_registers): Likewise.
4560 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
4561 (ppcfbsd_store_inferior_registers): Likewise.
4562 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
4563 (fetch_altivec_register): Likewise.
4564 (get_spe_registers): Likewise.
4565 (fetch_spe_register): Likewise.
4566 (fetch_altivec_registers): Likewise.
4567 (fetch_all_gp_regs): Likewise.
4568 (fetch_all_fp_regs): Likewise.
4569 (store_vsx_register): Likewise.
4570 (store_altivec_register): Likewise.
4571 (set_spe_registers): Likewise.
4572 (store_spe_register): Likewise.
4573 (store_altivec_registers): Likewise.
4574 (store_all_gp_regs): Likewise.
4575 (store_all_fp_regs): Likewise.
4576 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4577 (ppc_linux_collect_gregset): Likewise.
4578 (ppc_canonicalize_syscall): Likewise.
4579 (ppc_linux_record_signal): Likewise.
4580 (ppu2spu_prev_register): Likewise.
4581 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4582 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4583 (ppcobsd_store_registers): Likewise.
4584 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4586 (ppc_ravenscar_generic_store_registers): Likewise.
4587 * procfs.c (procfs_fetch_registers): Likewise.
4588 (procfs_store_registers): Likewise.
4589 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4590 (ravenscar_store_registers): Likewise.
4591 (ravenscar_prepare_to_store): Likewise.
4592 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4593 * record-full.c (record_full_wait_1): Likewise.
4594 (record_full_registers_change): Likewise.
4595 (record_full_store_registers): Likewise.
4596 (record_full_core_fetch_registers): Likewise.
4597 (record_full_save): Likewise.
4598 (record_full_goto_insn): Likewise.
4599 * regcache.c (regcache_register_size): Likewise.
4600 (get_regcache_arch): Remove.
4601 (regcache_read_pc): Likewise.
4602 * regcache.h (get_regcache_arch): Remove.
4603 * remote-sim.c (gdbsim_fetch_register): Likewise.
4604 (gdbsim_store_register): Likewise.
4605 * remote.c (fetch_register_using_p): Likewise.
4606 (send_g_packet): Likewise.
4607 (remote_prepare_to_store): Likewise.
4608 (store_registers_using_G): Likewise.
4609 * reverse.c (save_bookmark_command): Likewise.
4610 (goto_bookmark_command): Likewise.
4611 * rs6000-aix-tdep.c (branch_dest): Likewise.
4612 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4613 (fetch_register): Likewise.
4614 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4615 (ppc_collect_reg): Likewise.
4616 (ppc_collect_gregset): Likewise.
4617 (ppc_collect_fpregset): Likewise.
4618 (ppc_collect_vsxregset): Likewise.
4619 (ppc_collect_vrregset): Likewise.
4620 (ppc_displaced_step_hw_singlestep): Likewise.
4621 (rs6000_pseudo_register_read): Likewise.
4622 (rs6000_pseudo_register_write): Likewise.
4623 * s390-linux-nat.c (supply_gregset): Likewise.
4624 (fill_gregset): Likewise.
4625 (s390_linux_fetch_inferior_registers): Likewise.
4626 * s390-linux-tdep.c (s390_write_pc): Likewise.
4627 (s390_software_single_step): Likewise.
4628 (s390_all_but_pc_registers_record): Likewise.
4629 (s390_linux_syscall_record): Likewise.
4630 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4631 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4632 (shnbsd_store_inferior_registers): Likewise.
4633 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4634 (sh_extract_return_value_fpu): Likewise.
4635 (sh_store_return_value_nofpu): Likewise.
4636 (sh_corefile_supply_regset): Likewise.
4637 (sh_corefile_collect_regset): Likewise.
4638 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4639 (sh64_store_return_value): Likewise.
4640 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4641 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4642 (sparc_store_inferior_registers): Likewise.
4643 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4644 (sparc_ravenscar_prepare_to_store): Likewise.
4645 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4646 (sparc_analyze_control_transfer): Likewise.
4647 (sparc_step_trap): Likewise.
4648 (sparc_software_single_step): Likewise.
4649 (sparc32_gdbarch_init): Likewise.
4650 (sparc_supply_rwindow): Likewise.
4651 (sparc_collect_rwindow): Likewise.
4652 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4653 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4654 (sparc64nbsd_collect_gregset): Likewise.
4655 (sparc64nbsd_supply_fpregset): Likewise.
4656 (sparc64nbsd_collect_fpregset): Likewise.
4657 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4658 (sparc64_supply_gregset): Likewise.
4659 (sparc64_collect_gregset): Likewise.
4660 (sparc64_supply_fpregset): Likewise.
4661 (sparc64_collect_fpregset): Likewise.
4662 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4663 * spu-tdep.c (spu_unwind_sp): Likewise.
4664 (spu2ppu_prev_register): Likewise.
4665 (spu_memory_remove_breakpoint): Likewise.
4666 * stack.c (return_command): Likewise.
4667 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4668 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4669 * tracefile.c (trace_save_ctf): Likewise.
4670 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4671 (do_windows_store_inferior_registers): Likewise.
4672 (windows_resume): Likewise.
4673 * xtensa-linux-nat.c (fill_gregset): Likewise.
4674 (supply_gregset_reg): Likewise.
4675 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4676 (xtensa_register_read_masked): Likewise.
4677 (xtensa_supply_gregset): Likewise.
4678 (xtensa_extract_return_value): Likewise.
4679 (xtensa_store_return_value): Likewise.
4681 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4683 * doublest.c (floatformat_from_string): New function.
4684 * doublest.h (floatformat_from_string): Add prototype.
4686 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4687 (OP_FLOAT): ... this.
4688 * expression.h: Do not include "doublest.h".
4689 (union exp_element): Replace doubleconst and decfloatconst by
4690 new element floatconst.
4691 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4692 (ada_evaluate_subexp): Likewise.
4693 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4694 OP_DOUBLE and OP_DECFLOAT.
4695 * expprint.c (print_subexp_standard): Likewise.
4696 (dump_subexp_body_standard): Likewise.
4697 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4699 * parse.c: Include "dfp.h".
4700 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4701 (write_exp_elt_floatcst): New function.
4702 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4704 (operator_check_standard): Likewise.
4705 (parse_float): Do not accept suffix. Take type as input. Return bool.
4706 Return target format buffer instead of host DOUBLEST.
4707 Use floatformat_from_string and decimal_from_string to parse
4708 either binary or decimal floating-point types.
4709 (parse_c_float): Remove.
4710 * parser-defs.h: Do not include "doublest.h".
4711 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4712 (write_exp_elt_floatcst): Add prototype.
4713 (parse_float): Update prototype.
4714 (parse_c_float): Remove.
4716 * c-exp.y: Do not include "dfp.h".
4717 (typed_val_float): Use byte buffer instead of DOUBLEST.
4718 (typed_val_decfloat): Remove.
4720 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4721 (parse_number): Update to new parse_float interface.
4722 Parse suffixes and determine type before calling parse_float.
4723 Handle decimal and binary FP types the same way.
4725 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4726 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4727 (parse_number): Update to new parse_float interface.
4728 Parse suffixes and determine type before calling parse_float.
4730 * f-exp.y: Replace dval by typed_val_float.
4731 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4732 (parse_number): Use parse_float instead of atof.
4734 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4735 (parse_go_float): Remove.
4736 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4737 (parse_number): Call parse_float instead of parse_go_float.
4738 Parse suffixes and determine type before calling parse_float.
4740 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4741 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4742 (parse_number): Update to new parse_float interface.
4743 Parse suffixes and determine type before calling parse_float.
4745 * m2-exp.y: Replace dval by byte buffer val.
4746 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4747 (parse_number): Call parse_float instead of atof.
4749 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4750 (lex_number): Call parse_float instead of strtod.
4751 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4752 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4753 Use write_exp_elt_floatcst.
4754 (unit_testing): Remove static variable.
4755 (rust_type): Do not check unit_testing.
4756 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4758 * ada-exp.y (type_float, type_double): Remove.
4759 (typed_val_float): Use byte buffer instead of DOUBLEST.
4760 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4761 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4763 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4765 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4766 * arch/aarch64.h: New file.
4768 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4770 * dfp.h (decimal_from_string): Use const reference for argument.
4771 * dfp.c (decimal_from_string): Likewise.
4773 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4775 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4776 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4777 * mips-tdep.c (mips_print_fp_register): Likewise.
4779 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4781 * common/format.h (enum argclass): Replace decfloat_arg by
4782 dec32float_arg, dec64float_arg, and dec128float_arg.
4783 * common/format.c (parse_format_string): Update to return
4784 new decimal float argument classes.
4786 * printcmd.c (printf_decfloat): Rename to ...
4787 (printf_floating): ... this. Add argclass argument, and use it
4788 instead of parsing the format string again. Add support for
4789 binary floating-point values, using floatformat_to_string.
4790 Convert value to the target format if it doesn't already match.
4791 (ui_printf): Call printf_floating instead of printf_decfloat,
4792 also for double_arg / long_double_arg. Pass argclass.
4794 * dfp.c (decimal_to_string): Add format string argument.
4795 * dfp.h (decimal_to_string): Likewise.
4797 * doublest.c (floatformat_to_string): Add format string argument.
4798 * doublest.h (floatformat_to_string): Likewise.
4800 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4802 * doublest.c (floatformat_precision): New routine.
4803 (floatformat_to_string): Likewise.
4804 * doublest.c (floatformat_to_string): Add prototype.
4806 * printcmd.c (print_scalar_formatted): Only call print_floating
4807 on floating-point types.
4808 * valprint.c: Do not include "floatformat.h".
4809 (generic_val_print_decfloat): Remove.
4810 (generic_val_print): Call generic_val_print_float for both
4811 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4812 (print_floating): Use floatformat_to_string. Handle decimal float.
4813 (print_decimal_floating): Remove, merge into floatformat_to_string.
4814 * value.h (print_decimal_floating): Remove.
4816 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4818 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4820 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4822 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4824 * memattr.h: Don't include vec.h.
4825 (struct mem_attrib): Initialize fields.
4826 <unknown>: New static method.
4827 (struct mem_region): Add constructors, operator<, initialize
4829 * memattr.c: Include algorithm.
4830 (default_mem_attrib, unknown_mem_attrib): Remove.
4831 (user_mem_region_list): New global.
4832 (target_mem_region_list, mem_region_list): Change type to
4833 std::vector<mem_region>.
4834 (mem_use_target): Now a function.
4835 (target_mem_regions_valid): Change type to bool.
4836 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4837 (require_user_regions): Adjust.
4838 (require_target_regions): Adjust.
4839 (create_mem_region): Adjust.
4840 (lookup_mem_region): Adjust.
4841 (invalidate_target_mem_regions): Adjust.
4842 (mem_clear): Rename to...
4843 (user_mem_clear): ... this, and adjust.
4844 (mem_command): Adjust.
4845 (info_mem_command): Adjust.
4846 (mem_enable, enable_mem_command, mem_disable,
4847 disable_mem_command): Adjust.
4848 (mem_delete): Adjust.
4849 (delete_mem_command): Adjust.
4850 * memory-map.h (parse_memory_map): Return an std::vector.
4851 * memory-map.c (parse_memory_map): Likewise.
4852 (struct memory_map_parsing_data): Add constructor.
4853 <memory_map>: Point to std::vector.
4854 (memory_map_start_memory): Adjust.
4855 (memory_map_end_memory): Adjust.
4856 (memory_map_end_property): Adjust.
4857 (clear_result): Remove.
4858 * remote.c (remote_memory_map): Return an std::vector.
4859 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4861 (target_debug_print_mem_region_vector): New.
4862 * target-delegates.c: Regenerate.
4863 * target.h (mem_region_vector): New typedef.
4864 (to_memory_map): Return mem_region_vector.
4865 (target_memory_map): Return an std::vector.
4866 * target.c (target_memory_map): Return an std::vector.
4867 (flash_erase_command): Adjust.
4869 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4871 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4872 Change type to std::string.
4873 (memory_map_start_property): Adjust.
4874 (memory_map_end_property): Adjust.
4876 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4878 * infrun.h: Include common/byte-vector.h.
4879 (struct displaced_step_closure): New struct.
4880 (struct buf_displaced_step_closure): New struct.
4881 * infrun.c (displaced_step_closure::~displaced_step_closure):
4882 Provide default implementation.
4883 (displaced_step_clear): Deallocate step closure with delete.
4884 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4885 (aarch64_displaced_step_closure): ... this, extend
4886 displaced_step_closure.
4887 (aarch64_displaced_step_data) <dsc>: Change type to
4888 aarch64_displaced_step_closure.
4889 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4891 (aarch64_displaced_step_fixup): Add cast for displaced step
4893 * amd64-tdep.c (displaced_step_closure): Rename to ...
4894 (amd64_displaced_step_closure): ... this, extend
4895 displaced_step_closure.
4896 <insn_buf>: Change type to std::vector<gdb_byte>.
4898 (fixup_riprel): Change type of DSC parameter, adjust to type
4900 (fixup_displaced_copy): Change type of DSC parameter.
4901 (amd64_displaced_step_copy_insn): Instantiate
4902 amd64_displaced_step_closure.
4903 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4904 to type change of insn_buf.
4905 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4907 (arm_linux_copy_svc): Likewise.
4908 (cleanup_kernel_helper_return): Likewise.
4909 (arm_catch_kernel_helper_return): Likewise.
4910 (arm_linux_displaced_step_copy_insn): Instantiate
4911 arm_displaced_step_closure.
4912 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4913 (displaced_read_reg): Change type of parameter DSC.
4914 (branch_write_pc): Likewise.
4915 (load_write_pc): Likewise.
4916 (alu_write_pc): Likewise.
4917 (displaced_write_reg): Likewise.
4918 (arm_copy_unmodified): Likewise.
4919 (thumb_copy_unmodified_32bit): Likewise.
4920 (thumb_copy_unmodified_16bit): Likewise.
4921 (cleanup_preload): Likewise.
4922 (install_preload): Likewise.
4923 (arm_copy_preload): Likewise.
4924 (thumb2_copy_preload): Likewise.
4925 (install_preload_reg): Likewise.
4926 (arm_copy_preload_reg): Likewise.
4927 (cleanup_copro_load_store): Likewise.
4928 (install_copro_load_store): Likewise.
4929 (arm_copy_copro_load_store) Likewise.
4930 (thumb2_copy_copro_load_store): Likewise.
4931 (cleanup_branch): Likewise.
4932 (install_b_bl_blx): Likewise.
4933 (arm_copy_b_bl_blx): Likewise.
4934 (thumb2_copy_b_bl_blx): Likewise.
4935 (thumb_copy_b): Likewise.
4936 (install_bx_blx_reg): Likewise.
4937 (arm_copy_bx_blx_reg): Likewise.
4938 (thumb_copy_bx_blx_reg): Likewise.
4939 (cleanup_alu_imm): Likewise.
4940 (arm_copy_alu_imm): Likewise.
4941 (thumb2_copy_alu_imm): Likewise.
4942 (cleanup_alu_reg): Likewise.
4943 (install_alu_reg): Likewise.
4944 (arm_copy_alu_reg): Likewise.
4945 (thumb_copy_alu_reg): Likewise.
4946 (cleanup_alu_shifted_reg): Likewise.
4947 (install_alu_shifted_reg): Likewise.
4948 (arm_copy_alu_shifted_reg): Likewise.
4949 (cleanup_load): Likewise.
4950 (cleanup_store): Likewise.
4951 (arm_copy_extra_ld_st): Likewise.
4952 (install_load_store): Likewise.
4953 (thumb2_copy_load_literal): Likewise.
4954 (thumb2_copy_load_reg_imm): Likewise.
4955 (arm_copy_ldr_str_ldrb_strb): Likewise.
4956 (cleanup_block_load_all): Likewise.
4957 (cleanup_block_store_pc): Likewise.
4958 (cleanup_block_load_pc): Likewise.
4959 (arm_copy_block_xfer): Likewise.
4960 (thumb2_copy_block_xfer): Likewise.
4961 (cleanup_svc): Likewise.
4962 (install_svc): Likewise.
4963 (arm_copy_svc): Likewise.
4964 (thumb_copy_svc): Likewise.
4965 (arm_copy_undef): Likewise.
4966 (thumb_32bit_copy_undef): Likewise.
4967 (arm_copy_unpred): Likewise.
4968 (arm_decode_misc_memhint_neon): Likewise.
4969 (arm_decode_unconditional): Likewise.
4970 (arm_decode_miscellaneous): Likewise.
4971 (arm_decode_dp_misc): Likewise.
4972 (arm_decode_ld_st_word_ubyte): Likewise.
4973 (arm_decode_media): Likewise.
4974 (arm_decode_b_bl_ldmstm): Likewise.
4975 (arm_decode_ext_reg_ld_st): Likewise.
4976 (thumb2_decode_dp_shift_reg): Likewise.
4977 (thumb2_decode_ext_reg_ld_st): Likewise.
4978 (arm_decode_svc_copro): Likewise.
4979 (thumb2_decode_svc_copro): Likewise.
4980 (install_pc_relative): Likewise.
4981 (thumb_copy_pc_relative_16bit): Likewise.
4982 (thumb_decode_pc_relative_16bit): Likewise.
4983 (thumb_copy_pc_relative_32bit): Likewise.
4984 (thumb_copy_16bit_ldr_literal): Likewise.
4985 (thumb_copy_cbnz_cbz): Likewise.
4986 (thumb2_copy_table_branch): Likewise.
4987 (cleanup_pop_pc_16bit_all): Likewise.
4988 (thumb_copy_pop_pc_16bit): Likewise.
4989 (thumb_process_displaced_16bit_insn): Likewise.
4990 (decode_thumb_32bit_ld_mem_hints): Likewise.
4991 (thumb_process_displaced_32bit_insn): Likewise.
4992 (thumb_process_displaced_insn): Likewise.
4993 (arm_process_displaced_insn): Likewise.
4994 (arm_displaced_init_closure): Likewise.
4995 (arm_displaced_step_fixup): Add cast for closure.
4996 * arm-tdep.h: Include infrun.h.
4997 (displaced_step_closure): Rename to ...
4998 (arm_displaced_step_closure): ... this, extend
4999 displaced_step_closure.
5000 <u::svc::copy_svc_os>: Change type of parameter DSC.
5001 <cleanup>: Likewise.
5002 (arm_process_displaced_insn): Likewise.
5003 (arm_displaced_init_closure): Likewise.
5004 (displaced_read_reg): Likewise.
5005 (displaced_write_reg): Likewise.
5006 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5008 * i386-tdep.h: Include infrun.h.
5009 (i386_displaced_step_closure): New typedef.
5010 * i386-tdep.c (i386_displaced_step_copy_insn): Use
5011 i386_displaced_step_closure.
5012 (i386_displaced_step_fixup): Adjust.
5013 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
5014 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
5016 (ppc_displaced_step_fixup): Adjust.
5017 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
5018 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
5020 (s390_displaced_step_fixup): Adjust.
5022 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
5024 * interps.h (interp_resume, interp_suspend, interp_set_temp):
5025 Remove declarations.
5027 2017-10-20 Tom Tromey <tom@tromey.com>
5029 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
5031 (gdb_bfd_record_inclusion): Update.
5032 (bfdp): Remove typedef.
5034 2017-10-20 Tom Tromey <tom@tromey.com>
5036 * gdb_bfd.c (gdb_bfd_ref): Use new.
5037 (struct gdb_bfd_data): Add constructor, destructor, and member
5039 (gdb_bfd_unref): Use delete.
5041 2017-10-20 Tom Tromey <tom@tromey.com>
5043 * exec.c (exec_file_attach): Use new_bfd_ref.
5044 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
5045 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
5046 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
5048 * gdb_bfd.h (new_bfd_ref): New function.
5050 2017-10-20 Pedro Alves <palves@redhat.com>
5052 * main.c (captured_command_loop): Add attribute noinline.
5054 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
5056 * interps.c (struct interp_factory): Add constructor.
5057 (interp_factory_p): Remove typedef.
5058 (DEF_VEC_P(interp_factory_p)): Remove.
5059 (interpreter_factories): Change type to std::vector.
5060 (interp_factory_register): Adjust.
5061 (interp_lookup): Adjust.
5062 (interpreter_completer): Adjust.
5064 2017-10-19 Tom Tromey <tom@tromey.com>
5066 * break-catch-syscall.c (catch_syscall_completer): Use
5067 std::string, gdb::unique_xmalloc_ptr.
5069 2017-10-19 Tom Tromey <tom@tromey.com>
5071 * infcall.c (call_function_by_hand_dummy): Use std::string.
5073 2017-10-19 Tom Tromey <tom@tromey.com>
5075 * mi/mi-main.c (mi_cmd_execute): Update.
5076 * top.h (prepare_execute_command): Return scoped_value_mark.
5077 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
5078 Add move constructor.
5079 * top.c (prepare_execute_command): Return scoped_value_mark.
5080 (execute_command): Update.
5082 2017-10-19 Pedro Alves <palves@redhat.com>
5084 * xml-support.c (xml_fetch_content_from_file): Check fread's
5087 2017-10-19 Pedro Alves <palves@redhat.com>
5089 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
5091 (handle_error_fd): New function.
5092 (ser_base_async): Add/delete an event loop file handler for
5095 2017-10-19 Pedro Alves <palves@redhat.com>
5097 * xml-support.c (xml_fetch_content_from_file): Don't read in
5098 chunks. Instead use fseek to determine the file's size, and read
5101 2017-11-18 Keith Seitz <keiths@redhat.com>
5103 * c-exp.y (oper): Canonicalize conversion operators of user-defined
5105 Add whitespace to front of type name.
5107 2017-10-18 Keith Seitz <keiths@redhat.com>
5109 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
5110 DW_AT_accessibility.
5112 2017-10-18 Yao Qi <yao.qi@linaro.org>
5114 * features/tic6x-c62x-linux.c: Remove.
5116 2017-10-17 Tom Tromey <tom@tromey.com>
5118 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
5119 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
5120 (do_mixed_source_and_assembly): Likewise.
5122 2017-10-17 Tom Tromey <tom@tromey.com>
5124 * regcache.c (regcache::xfer_part): Remove assertion.
5126 2017-10-17 Pedro Alves <palves@redhat.com>
5128 * xml-support.c (xml_fetch_content_from_file): Call
5129 unique_ptr::release() instead unique_ptr::get() when passing
5132 2017-10-17 Yao Qi <yao.qi@linaro.org>
5134 * regcache.c (regcache::xfer_part): Remove parameters read and
5135 write, add parameter is_raw. All callers are updated.
5137 2017-10-16 Keith Seitz <keiths@redhat.com>
5139 * c-typeprint.c (enum access_specifier): Moved here from
5141 (output_access_specifier): New function.
5142 (c_type_print_base): Consider typedefs when assessing
5143 whether access labels are needed.
5144 Use output_access_specifier as needed.
5145 Output access specifier for typedefs, if needed.
5146 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
5147 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
5149 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
5152 2017-10-16 Tom Tromey <tom@tromey.com>
5154 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
5155 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
5156 * target.c (target_fileio_read_stralloc): Update.
5157 * sparc64-tdep.c (adi_is_addr_mapped): Update.
5158 * target.h (target_fileio_read_stralloc): Return
5161 2017-10-16 Tom Tromey <tom@tromey.com>
5163 * xml-syscall.c (xml_init_syscalls_info): Update.
5164 * xml-support.c (xinclude_start_include): Update.
5165 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
5166 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
5167 (xml_fetch_content_from_file): Likewise.
5168 * osdata.c (get_osdata): Update.
5169 * target.h (target_read_stralloc, target_get_osdata): Return
5171 * solib-aix.c (solib_aix_get_library_list): Update.
5172 * solib-target.c (solib_target_current_sos): Update.
5173 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
5174 * xml-tdesc.c (fetch_available_features_from_target): Update.
5175 (target_fetch_description_xml): Update.
5176 (file_read_description_xml): Update.
5177 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
5178 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
5179 (remote_pid_to_exec_file): Update.
5180 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
5181 (target_get_osdata): Likewise.
5183 2017-10-16 Tom Tromey <tom@tromey.com>
5185 * remote.c (remote_register_number_and_offset): Use std::vector.
5186 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
5187 (putpkt_binary): Use gdb::def_vector.
5188 (compare_sections_command): Use gdb::byte_vector.
5190 2017-10-16 Tom Tromey <tom@tromey.com>
5192 * ppc-linux-nat.c (hwdebug_insert_point): Use
5193 gdb::unique_xmalloc_ptr, XDUP.
5195 2017-10-16 Tom Tromey <tom@tromey.com>
5197 * probe.c (parse_probes): Use std::string.
5198 (info_probes_for_ops, enable_probes_command)
5199 (disable_probes_command): Remove cleanups.
5201 2017-10-16 Tom Tromey <tom@tromey.com>
5203 * buildsym.c (block_compar): Remove.
5204 (end_symtab_get_static_block): Use std::vector.
5206 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
5208 * memrange.h (struct mem_range): Define operator< and operator==.
5209 (mem_range_s): Remove.
5210 (DEF_VEC_O (mem_range_s)): Remove.
5211 (normalize_mem_ranges): Change parameter type to std::vector.
5212 * memrange.c (compare_mem_ranges): Remove.
5213 (normalize_mem_ranges): Change parameter type to std::vector,
5214 adjust to vector change.
5215 * exec.c (section_table_available_memory): Return vector, remove
5217 (section_table_read_available_memory): Adjust to std::vector
5219 * remote.c (remote_read_bytes): Adjust to std::vector
5221 * tracepoint.h (traceframe_available_memory): Change parameter
5222 type to std::vector.
5223 * tracepoint.c (traceframe_available_memory): Change parameter
5224 type to std::vector, adjust.
5225 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
5227 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5228 unittests/memrange-selftests.c.
5229 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
5230 * gdb/unittests/memrange-selftests.c: New file.
5232 2017-10-16 Pedro Alves <palves@redhat.com>
5234 * elfread.c (probe_key_free): Rename range-for variable.
5235 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
5236 (find_probe_by_pc, collect_probes): Rename range-for variable.
5238 2017-10-16 Yao Qi <yao.qi@linaro.org>
5240 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
5241 * features/tic6x-c62x.c: Remove.
5242 * features/tic6x-c64x-linux.c: Remove.
5243 * features/tic6x-c64x.c: Remove.
5244 * features/tic6x-c64xp-linux.c: Remove.
5245 * features/tic6x-c64xp.c: Remove.
5246 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
5247 initialize_tdesc_tic6x_*_linux functions.
5248 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
5249 initialize_tdesc_tic6x_* functions.
5251 2017-10-16 Yao Qi <yao.qi@linaro.org>
5253 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
5255 * regformats/tic6x-c62x.dat: Remove.
5256 * regformats/tic6x-c64x.dat: Remove.
5257 * regformats/tic6x-c64xp.dat: Remove.
5259 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
5261 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
5262 (the !HAVE_LIBEXPAT version).
5264 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5266 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
5269 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5271 * target.h: Include tracepoint.h.
5272 (enum trace_find_type): Move to tracepoint.h.
5273 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
5274 * tracepoint.h: Don't include target.h
5275 (enum trace_find_type): Move from target.h.
5276 (parse_traceframe_info): Return a unique ptr.
5277 * tracepoint.c (current_traceframe_info): Change type to unique
5279 (free_traceframe_info): Remove.
5280 (clear_traceframe_info): Don't manually free
5281 current_traceframe_info.
5282 (free_result): Remove.
5283 (parse_traceframe_info): Return a unique ptr.
5284 (get_traceframe_info): Adjust to unique ptr.
5285 * ctf.c (ctf_traceframe_info): Return a unique ptr.
5286 * remote.c (remote_traceframe_info): Return a unique ptr.
5287 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
5289 * target-debug.h (target_debug_print_traceframe_info_up): New
5291 * target-delegates.c: Regenerate.
5293 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5295 * memrange.h (struct mem_range): Add constructors.
5296 * tracepoint.h (struct traceframe_info) <memory>: Change type to
5297 std::vector<mem_range>.
5298 * tracepoint.c (free_traceframe_info): Don't manually free
5300 (traceframe_info_start_memory): Adjust to vector change.
5301 (traceframe_available_memory): Likewise.
5302 * tracefile-tfile.c (build_traceframe_info): Likewise.
5303 * ctf.c (ctf_traceframe_info): Likewise.
5305 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5307 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
5309 * tracepoint.c (free_traceframe_info): Deallocate with delete.
5310 (traceframe_info_start_tvar): Adjust to vector change.
5311 (parse_traceframe_info): Allocate with new.
5312 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
5314 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
5316 tfile_traceframe_info): Allocate with new.
5317 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
5320 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5322 * tracepoint.c (traceframe_info): Rename to...
5323 (current_traceframe_info): ...this.
5324 (clear_traceframe_info): Adjust.
5325 (get_traceframe_info): Adjust.
5327 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5329 * nat/linux-osdata.c: Include algorithm.
5330 (compare_processes): Remove.
5331 (struct pid_pgid_entry): New struct.
5332 (linux_xfer_osdata_processgroups): Use std::vector instead of
5335 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5337 * objfiles.h: Don't include symfile.h.
5338 (struct partial_symbol): Remove forward-declaration.
5339 (struct objfile) <global_psymbols, static_psymbols>: Change type
5340 to std::vector<partial_symbol *>.
5341 * objfiles.c (objfile::objfile): Don't memset those fields.
5342 (objfile::~objfile): Don't free those fields.
5343 * psympriv.h (struct psymbol_allocation_list): Remove
5344 forward-declaration.
5345 (add_psymbol_to_list): Change psymbol_allocation_list parameter
5347 (start_psymtab_common): Change parameters to std::vector.
5348 * psymtab.c: Include algorithm.
5349 (require_partial_symbols): Call shrink_to_fit.
5350 (find_pc_sect_psymbol): Adjust to vector change.
5351 (match_partial_symbol): Likewise.
5352 (lookup_partial_symbol): Likewise.
5353 (psym_relocate): Likewise.
5354 (dump_psymtab): Likewise.
5355 (recursively_search_psymtabs): Likewise.
5356 (compare_psymbols): Remove.
5357 (sort_pst_symbols): Adjust to vector change.
5358 (start_psymtab_common): Likewise.
5359 (end_psymtab_common): Likewise.
5360 (psymbol_bcache_full): De-constify return value.
5361 (add_psymbol_to_bcache): Likewise.
5362 (extend_psymbol_list): Remove.
5363 (append_psymbol_to_list): Adjust to vector change.
5364 (add_psymbol_to_list): Likewise.
5365 (init_psymbol_list): Likewise.
5366 (maintenance_info_psymtabs): Likewise.
5367 (maintenance_check_psymtabs): Likewise.
5368 * symfile.h (struct psymbol_allocation_list): Remove.
5369 * symfile.c (reread_symbols): Adjust to vector change.
5370 * dbxread.c (start_psymtab): Change type of parameters.
5371 (dbx_symfile_read): Adjust to vector change.
5372 (read_dbx_symtab): Likewise.
5373 (start_psymtab): Change type of parameters.
5374 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
5375 (create_partial_symtab): Likewise.
5376 (add_partial_symbol): Likewise.
5377 (write_one_signatured_type): Likewise.
5378 (recursively_write_psymbols): Likewise.
5379 * mdebugread.c (parse_partial_symbols): Likewise.
5380 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
5381 (scan_xcoff_symtab): Adjust to vector change.
5382 (xcoff_initial_scan): Likewise.
5384 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
5386 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
5388 2017-10-13 Yao Qi <yao.qi@linaro.org>
5390 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
5391 Remove s390x-*-expedite, add s390x-expedite.
5393 2017-10-13 Yao Qi <yao.qi@linaro.org>
5395 * features/s390-gs-linux64.c: Regenerated.
5396 * features/s390x-gs-linux64.c: Regenerated.
5398 2017-10-13 Tom Tromey <tom@tromey.com>
5400 * compile/compile-object-run.c (do_module_cleanup): Use delete.
5401 * solib.c (update_solib_list, reload_shared_libraries_1): Use
5403 * symfile.c (symbol_file_add_with_addrs): Use new.
5404 (symbol_file_add_separate): Update comment.
5405 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
5406 * jit.c (jit_object_close_impl): Use new.
5407 (jit_unregister_code): Use delete.
5408 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
5409 (~objfile): Rename from free_objfile.
5410 (free_objfile_separate_debug, do_free_objfile_cleanup)
5411 (free_all_objfiles, objfile_purge_solibs): Use delete.
5412 * objfiles.h (struct objfile): Add constructor and destructor.
5413 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
5414 (allocate_objfile, free_objfile): Don't declare.
5415 (struct objstats): Add initializers.
5417 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5419 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
5420 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
5421 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
5422 * gdbarch.h: Regenerate.
5423 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5425 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
5426 (i386_displaced_step_fixup): Adjust comment.
5427 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
5429 2017-10-12 Tom Tromey <tom@tromey.com>
5431 * prologue-value.h (pv_area::store_would_trash): Return bool.
5432 (pv_area::find_reg): Likewise.
5433 * prologue-value.c (pv_area::store_would_trash): Return bool.
5434 (pv_area::find_reg): Likewise.
5436 2017-10-12 Tom Tromey <tom@tromey.com>
5438 * s390-linux-tdep.c (s390_store, s390_load)
5439 (s390_check_for_saved, s390_analyze_prologue): Update.
5440 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
5441 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
5442 * prologue-value.h (class pv_area): Move from prologue-value.c.
5443 Change names of members. Add constructor, destructor, member
5445 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
5446 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
5447 (pv_area_fetch, pv_area_scan): Don't declare.
5448 * prologue-value.c (struct pv_area::area_entry): Now member of
5450 (struct pv_area): Move to prologue-value.h.
5451 (pv_area::pv_area): Rename from make_pv_area.
5452 (pv_area::~pv_area): Rename from free_pv_area.
5453 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
5454 (clear_entries, find_entry, overlaps, store_would_trash, store)
5455 (fetch, find_reg, scan): Now member of pv_area.
5456 Remove "area" argument. Update.
5457 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
5459 * mn10300-tdep.c (push_reg, check_for_saved)
5460 (mn10300_analyze_prologue): Update.
5461 * mep-tdep.c (is_arg_spill, check_for_saved)
5462 (mep_analyze_prologue): Update.
5463 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
5464 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
5465 (m32c_is_struct_return, m32c_analyze_prologue): Update.
5466 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
5468 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
5469 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
5471 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5473 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
5474 * linux-nat.c (linux_nat_delete_thread): New variable.
5475 (lwp_free): Invoke linux_nat_delete_thread if set.
5476 (linux_nat_set_delete_thread): New function.
5477 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
5478 thread delete callback.
5479 * arm-linux-nat.c (arm_linux_delete_thread): New function.
5480 (_initialize_arm_linux_nat): Assign thread delete callback.
5481 * s390-linux-nat.c (s390_delete_thread): New function.
5482 (_initialize_s390_nat): Assign thread delete callback.
5483 * x86-linux-nat.c (x86_linux_add_target): Likewise.
5484 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
5486 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
5488 * nat/x86-linux.c (x86_linux_delete_thread): New function.
5489 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
5491 2017-10-09 Tom Tromey <tom@tromey.com>
5493 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
5495 * tui/tui-layout.c (enum tui_status): Use std::string.
5497 2017-10-11 Tom Tromey <tom@tromey.com>
5499 * gdbthread.h (thread_command): Constify.
5500 * inferior.h (detach_command): Constify.
5501 * top.h (set_history, show_history): Constify.
5502 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
5503 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
5504 * bsd-kvm.c (bsd_kvm_cmd): Constify.
5505 * printcmd.c (set_command): Constify.
5506 (non_const_set_command): New function.
5507 * dcache.c (set_dcache_command, show_dcache_command): Constify.
5508 * breakpoint.c (enable_command, disable_command, delete_command)
5509 (catch_command, tcatch_command, set_breakpoint_cmd)
5510 (show_breakpoint_cmd): Constify.
5511 * macrocmd.c (macro_command): Constify.
5512 * infcmd.c (unset_command, kill_command, detach_command)
5513 (info_proc_cmd): Constify.
5514 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
5515 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
5516 (info_auto_load_cmd): Constify.
5517 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5518 (unset_tdesc_cmd): Constify.
5519 * ada-lang.c (set_ada_command, show_ada_command)
5520 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
5521 * guile/guile.c (set_guile_command, show_guile_command)
5522 (info_guile_command): Constify.
5523 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
5525 * skip.c (skip_command): Constify.
5526 * compile/compile.c (_initialize_compile): Constify.
5527 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
5528 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5529 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5530 (maint_btrace_pt_show_cmd): Constify.
5531 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
5533 * python/python.c (user_show_python, user_set_python): Constify.
5534 * mips-tdep.c (set_mips_command, show_mips_command)
5535 (set_mipsfpu_command): Constify.
5536 * record-btrace.c (cmd_record_btrace_start)
5537 (cmd_set_record_btrace, cmd_show_record_btrace)
5538 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
5539 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
5540 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
5542 * symfile.c (overlay_command): Constify.
5543 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
5544 * cli/cli-logging.c (set_logging_command, show_logging_command):
5546 * cli/cli-dump.c (dump_command, append_command)
5547 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5548 (tekhex_dump_command, binary_dump_command)
5549 (binary_append_command): Constify.
5550 * cli/cli-decode.c (struct cmd_list_element): Change type of
5552 * cli/cli-cmds.c (info_command, show_command, set_debug)
5553 (show_debug): Constify.
5554 (show_command): Add non-const overload.
5555 * top.c (set_history, show_history): Constify.
5556 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
5557 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
5558 * target.c (target_command): Constify.
5559 * sparc64-tdep.c (info_adi_command): Constify.
5560 * record-full.c (cmd_record_full_start): Constify.
5561 (set_record_full_command): Constify. Fix typo.
5562 (show_record_full_command): Constify.
5563 * thread.c (thread_command, thread_apply_command): Constify.
5564 * memattr.c (dummy_cmd): Constify.
5565 * value.c (function_command): Constify.
5566 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
5567 * probe.c (info_probes_command): Constify.
5568 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5569 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5570 (show_thread_cmd, set_thread_default_cmd)
5571 (show_thread_default_cmd): Constify.
5572 (check_empty): Constify.
5573 * tracepoint.c (tfind_command): Constify.
5574 * cp-support.c (maint_cplus_command): Constify.
5575 * windows-tdep.c (info_w32_command): Constify.
5576 * record.c (cmd_record_start, set_record_command)
5577 (show_record_command, info_record_command, cmd_record_goto):
5579 * ravenscar-thread.c (set_ravenscar_command)
5580 (show_ravenscar_command): Constify.
5581 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5583 (add_internal_problem_command): Remove casts.
5584 * arc-tdep.c (maintenance_print_arc_command): Constify.
5585 * valprint.c (set_print, show_print, set_print_raw)
5586 (show_print_raw): Constify.
5587 * maint.c (maintenance_command, maintenance_info_command)
5588 (maintenance_print_command, maintenance_set_cmd)
5589 (maintenance_show_cmd, set_per_command_cmd)
5590 (show_per_command_cmd, maintenance_check_command): Constify.
5591 * language.c (set_check, show_check): Constify.
5592 * typeprint.c (show_print_type, set_print_type): Constify.
5593 * go32-nat.c (go32_info_dos_command): Constify.
5595 2017-10-11 Tom Tromey <tom@tromey.com>
5597 * breakpoint.c (prepare_re_set_context): Remove.
5598 (breakpoint_re_set_one): Update. Don't use cleanups.
5599 (breakpoint_re_set): Use scoped_restore, std::string, and
5600 scoped_restore_current_language.
5602 2017-10-11 Tom Tromey <tom@tromey.com>
5604 * breakpoint.c (commands_command_1): Use std::string.
5605 (cleanup_executing_breakpoints): Remove.
5606 (bpstat_do_actions_1): Use scoped_restore.
5607 (bpstat_check_watchpoint): Use std::string.
5608 (decode_static_tracepoint_spec): Likewise.
5609 (break_range_command): Likewise.
5610 (watch_command_1): Likewise.
5611 (compare_breakpoints): Change argument types.
5612 (clear_command): Use std::vector.
5613 (cleanup_executing_breakpoints): Remove.
5614 (update_global_location_list): Use unique_xmalloc_ptr.
5615 (strace_command): Remove unused declaration.
5617 2017-10-11 John Baldwin <jhb@FreeBSD.org>
5619 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5620 * NEWS: Mention new FreeBSD/arm native configuration.
5621 * configure.host: Add arm*-*-freebsd*.
5622 * configure.nat: Likewise.
5623 * arm-fbsd-nat.c: New file.
5625 2017-10-11 John Baldwin <jhb@FreeBSD.org>
5627 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5628 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5629 * NEWS: Mention new FreeBSD/arm target.
5630 * configure.tgt: Add arm*-*-freebsd*.
5631 * arm-fbsd-tdep.c: New file.
5632 * arm-fbsd-tdep.h: New file.
5634 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5636 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5637 `gdbarch_elfcore_write_linux_prpsinfo'.
5638 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5640 (elf_internal_linux_prpsinfo): Remove declaration.
5641 * gdbarch.h: Regenerate.
5642 * gdbarch.c: Regenerate.
5644 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5646 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5647 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5649 2017-10-11 Pedro Alves <palves@redhat.com>
5651 * breakpoint.c (reattach_breakpoints): Delete.
5652 * breakpoint.h (reattach_breakpoints): Delete.
5654 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5656 * symfile.c (registered_sym_fns): Make struct, not typedef.
5657 (DEF_VEC_O (registered_sym_fns)): Remove.
5658 (symtab_fns): Change type to std::vector.
5659 (add_symtab_fns): Adjust.
5660 (find_sym_fns): Adjust.
5662 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5664 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5665 * arc-tdep.h (arc_arch_is_em): New function.
5666 (arc_arch_is_hs): Likewise.
5668 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5670 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5671 parentheses in the declaration.
5672 (macro_lookup_inclusion): Likewise.
5673 (macro_lookup_definition): Likewise.
5674 * p-lang.h (pascal_builtin_types): Likewise.
5675 * tui/tui-data.c (tui_win_list): Likewise.
5676 * tui/tui-data.h (tui_win_list): Likewise.
5677 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5679 2017-10-11 Mark Rages <markrages@gmail.com>
5681 * target-memory.c (block_boundaries): Fix for block address not
5682 aligned on block size.
5684 2017-10-10 Pedro Alves <palves@redhat.com>
5685 Tom Tromey <tom@tromey.com>
5687 * breakpoint.c (struct captured_breakpoint_query_args)
5688 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5689 (print_breakpoint): New.
5690 * breakpoint.h (print_breakpoint): Declare.
5691 * common/common-exceptions.h (enum return_reason): Remove
5692 references to catch_exceptions.
5693 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5695 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5696 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5698 * gdbthread.h (thread_select): Declare.
5699 * mi/mi-cmd-break.c: Don't include gdb.h.
5700 (breakpoint_notify): Use print_breakpoint.
5701 * mi/mi-cmd-catch.c: Don't include gdb.h.
5702 * mi/mi-interp.c: Don't include gdb.h.
5703 (mi_print_breakpoint_for_event): New.
5704 (mi_breakpoint_created, mi_breakpoint_modified): Use
5705 mi_print_breakpoint_for_event.
5706 * mi/mi-main.c: Don't include gdb.h.
5707 (mi_cmd_thread_select): Parse the global thread ID here. Use
5708 thread_select instead of gdb_thread_select.
5709 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5710 of using gdb_list_thread_ids.
5711 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5713 (remote_fileio_request): Use TRY/CATCH instead of
5715 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5716 (symbol_file_add_from_memory_wrapper): Delete.
5717 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5718 * thread.c: Don't include gdb.h.
5719 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5720 (thread_alive): Use thread_select.
5721 (do_captured_thread_select): Delete, parts salvaged as ...
5722 (thread_select): ... this new function.
5723 (gdb_thread_select): Delete.
5725 2017-10-10 Pedro Alves <palves@redhat.com>
5726 Tom Tromey <tom@tromey.com>
5728 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5730 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5731 No longer macros. Instead ...
5732 (enum wp_check_result): They're now values of this new
5734 (watchpoint_check): Change return type to wp_check_result and
5735 parameter type to bpstat.
5736 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5737 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5738 catch_errors. Reverse logic of watchpoint_check call.
5739 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5740 pointer as parameter.
5741 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5742 * common/common-exceptions.c (throw_exception_sjlj): Update
5743 comments to avoid mentioning catch_errors.
5744 * exceptions.c (catch_errors): Delete.
5745 * exceptions.h: Update comments to avoid mentioning catch_errors.
5746 (catch_errors_ftype, catch_errors): Delete.
5747 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5748 (hook_stop_stub): Delete.
5749 (restore_selected_frame): Change return type to void, and
5750 parameter type to const frame_id &.
5751 (restore_infcall_control_state): Use TRY/CATCH instead of
5753 * main.c (captured_command_loop): Return void and remove
5754 parameter. Remove references to catch_errors.
5755 (captured_main): Use TRY/CATCH instead of catch_errors.
5756 * objc-lang.c (objc_submethod_helper_data)
5757 (find_objc_msgcall_submethod_helper): Delete.
5758 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5760 * record-full.c (record_full_message): Return void.
5761 (record_full_message_args, record_full_message_wrapper): Delete.
5762 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5763 instead of catch_errors.
5764 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5765 parameter type to int.
5766 * solib-darwin.c (open_symbol_file_object): Ditto.
5767 * solib-dsbt.c (open_symbol_file_object): Ditto.
5768 * solib-frv.c (open_symbol_file_object): Ditto.
5769 * solib-svr4.c (open_symbol_file_object): Ditto.
5770 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5771 * solib.c (update_solib_list): Use TRY/CATCH instead of
5773 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5775 * symmisc.c (struct print_symbol_args): Remove.
5776 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5777 (print_symbol): Change type.
5778 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5779 and remove parameters.
5780 (catch_errors): New.
5781 (get_windows_debug_event): Adjust.
5783 2017-10-09 Tom Tromey <tom@tromey.com>
5785 * mi/mi-main.c (free_splay_tree): Remove.
5786 (list_available_thread_groups): Use splay_tree_up.
5787 * common/gdb_splay_tree.h: New file.
5789 2017-10-09 Tom Tromey <tom@tromey.com>
5791 * mi/mi-main.c (do_nothing): Remove.
5792 (list_available_thread_groups): Update.
5794 2017-10-09 Pedro Alves <palves@redhat.com>
5796 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5797 reading registers when switching context.
5799 2017-10-09 John Baldwin <jhb@FreeBSD.org>
5801 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5802 (fbsd_convert_siginfo): Likewise.
5803 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5805 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5807 * configure.ac (try_guile_versions): Remove guile-2.2.
5808 * configure: Regenerate.
5810 2017-10-09 Tom Tromey <tom@tromey.com>
5812 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5813 (COMPILE.pre): Use $(CXX).
5815 2017-10-09 Pedro Alves <palves@redhat.com>
5817 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5819 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5820 * cp-support.h (cp_remove_params): Now returns a
5821 gdb::unique_xmalloc_ptr.
5822 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5823 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5824 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5825 returning a gdb::unique_xmalloc_ptr.
5826 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5827 * stack.c (find_frame_funname): Adjust to cp_remove_params
5828 returning a gdb::unique_xmalloc_ptr.
5830 2017-10-08 Tom Tromey <tom@tromey.com>
5832 * dwarf2read.c (dwarf2_get_dwz_file): Use
5833 gdb::unique_xmalloc_ptr.
5834 (find_slot_in_mapped_hash): Likewise.
5835 (dwarf2_physname): Likewise.
5836 (create_dwo_unit_in_dwp_v1): Use std::string.
5837 (create_dwo_unit_in_dwp_v2): Likewise.
5838 (lookup_dwo_cutu): Likewise.
5839 (inherit_abstract_dies): Use std::vector.
5840 (read_array_type): Likewise.
5841 (dwarf_decode_macros): Remove unused declaration.
5842 (unsigned_int_compar): Remove.
5843 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5844 (psymtabs_addrmap_cleanup): Remove.
5846 2017-10-08 Tom Tromey <tom@tromey.com>
5848 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5849 * frame.h (frame_cleanup_after_sniffer): Declare.
5850 (frame_prepare_for_sniffer): Return void.
5851 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5853 (frame_prepare_for_sniffer): Return void.
5855 2017-10-08 Tom Tromey <tom@tromey.com>
5857 * utils.h (make_cleanup_value_free): Remove.
5858 * utils.c (do_value_free, struct cleanup): Remove.
5859 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5861 * value.h (struct value_deleter): New.
5862 (gdb_value_up): New typedef.
5864 2017-10-08 Tom Tromey <tom@tromey.com>
5866 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5867 (make_cleanup_free_search_symbols): Remove.
5868 (search_symbols): Return std::vector.
5869 (symbol_search::compare_search_syms): Now member of
5870 symbol_search. Change arguments.
5871 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5872 (symtab_symbol_info, rbreak_command): Update.
5873 * symtab.h (struct symbol_search) <next>: Remove.
5875 (symbol_search::operator<): New function.
5876 (symbol_search::operator==): New function.
5877 (search_symbols): Remove std::vector.
5878 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5879 (symbol_search::compare_search_syms): Declare.
5881 2017-10-06 Yao Qi <yao.qi@linaro.org>
5883 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5884 arch/aarch64-insn.o.
5886 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5888 2017-10-06 Yao Qi <yao.qi@linaro.org>
5890 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5891 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5892 arch/arm-linux.o respectively.
5893 * configure.tgt: Likewise.
5895 2017-10-06 Yao Qi <yao.qi@linaro.org>
5897 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5898 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5900 2017-10-06 Pedro Alves <palves@redhat.com>
5902 * windows-nat.c: Include <algorithm>.
5904 2017-10-06 Yao Qi <yao.qi@linaro.org>
5906 * configure.tgt (i386_tobjs): New variable.
5907 (amd64_tobjs): New variable.
5908 Set $cpu_obs and $os_obs.
5910 2017-10-06 Yao Qi <yao.qi@linaro.org>
5912 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5913 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
5914 (clean): Remove object files and dependency files.
5915 (distclean): Remove the directory.
5916 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5917 * configure: Re-generated.
5918 * configure.tgt: Replace amd64.o with arch/amd64.o.
5920 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
5923 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
5926 2017-10-05 Pedro Alves <palves@redhat.com>
5928 * linux-nat.c (linux_child_follow_fork): When following the parent
5929 and detaching the child, consult the parent thread's architecture
5930 instead of the child's.
5932 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5934 * ax.h: Do not include "doublest.h".
5935 (union agent_val): Remove.
5937 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5939 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
5940 (decimal_to_string): Return std::string object.
5941 (decimal_from_string): Accept std::string object. Return bool.
5942 (decimal_from_integral, decimal_from_doublest): Remove.
5943 (decimal_from_longest): Add prototype.
5944 (decimal_from_ulongest): Likewise.
5945 (decimal_to_longest): Likewise.
5946 (decimal_from_doublest): Likewise.
5947 * dfp.c: Do not include "gdbtypes.h" or "value.h".
5948 (MAX_DECIMAL_STRING): Move here.
5949 (decimal_to_string): Return std::string object.
5950 (decimal_from_string): Accept std::string object. Return bool.
5951 (decimal_from_integral): Remove, replace by ...
5952 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
5953 (decimal_to_longest): New function.
5954 (decimal_from_floating): Remove, replace by ...
5955 (decimal_from_doublest): ... this new function.
5956 (decimal_to_doublest): Update to new decimal_to_string interface.
5958 * value.c (unpack_long): Use decimal_to_longest.
5959 * valops.c (value_cast): Use decimal_from_doublest instead of
5960 decimal_from_floating. Use decimal_from_[u]longest isntead of
5961 decimal_from_integral.
5962 * valarith.c (value_args_as_decimal): Likewise.
5963 * valprint.c (print_decimal_floating): Update to new
5964 decimal_to_string interface.
5965 * printcmd.c (printf_decfloat): Likewise.
5966 * c-exp.y (parse_number): Update to new decimal_from_string interface.
5968 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5970 * doublest.h: Do not include "floatformat.h". Remove stale comments.
5971 * gdbtypes.c: Include "floatformat.h".
5972 * value.c: Likewise.
5973 * m68k-tdep.c: Likewise.
5975 * findvar.c: Do not include "floatformat.h".
5976 * amd64-darwin-tdep.c: Likewise.
5977 * arm-linux-tdep.c: Likewise.
5978 * i386-darwin-tdep.c: Likewise.
5979 * i387-tdep.c: Likewise.
5980 * m68k-linux-tdep.c: Likewise.
5981 * mep-tdep.c: Likewise.
5982 * mips-tdep.c: Likewise.
5983 * nios2-tdep.c: Likewise.
5984 * s390-linux-tdep.c: Likewise.
5985 * sparc-obsd-tdep.c: Likewise.
5986 * sparc-tdep.c: Likewise.
5987 * sparc64-tdep.c: Likewise.
5988 * spu-tdep.c: Likewise.
5989 * tic6x-tdep.c: Likewise.
5990 * tilegx-tdep.c: Likewise.
5991 * vax-tdep.c: Likewise.
5992 * xstormy16-tdep.c: Likewise.
5993 * xtensa-tdep.c: Likewise.
5995 * top.c: Do not include "doublest.h".
5996 * aarch64-tdep.c: Likewise.
5997 * alpha-tdep.c: Likewise.
5998 * arm-linux-tdep.c: Likewise.
5999 * m68k-linux-tdep.c: Likewise.
6000 * tilegx-tdep.c: Likewise.
6001 * xstormy16-tdep.c: Likewise.
6003 2017-10-05 John Baldwin <jhb@FreeBSD.org>
6005 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
6006 (mipsn32_fbsd_sigframe): Define.
6007 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
6008 for FreeBSD/mipsn32.
6010 2017-10-05 John Baldwin <jhb@FreeBSD.org>
6012 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
6015 2017-10-05 Tristan Gingold <tgingold@free.fr>
6017 * MAINTAINERS (Misc): Update my email address.
6019 2017-10-04 Pedro Alves <palves@redhat.com>
6021 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
6022 it instead of target_gdbarch.
6023 (get_remote_state, get_remote_packet_size): Adjust
6024 get_remote_arch_state calls, passing down target_gdbarch
6026 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
6027 'gdbarch' and use it instead of target_gdbarch.
6028 (get_memory_packet_size): Adjust get_remote_arch_state calls,
6029 passing down target_gdbarch explicitly.
6030 (struct stop_reply) <arch>: New field.
6031 (remote_parse_stop_reply): Use the stopped thread's architecture,
6032 not the current inferior's. Save the architecture in the
6034 (process_stop_reply): Use the stop reply's architecture.
6035 (process_g_packet, remote_fetch_registers)
6036 (remote_prepare_to_store, store_registers_using_G)
6037 (remote_store_registers): Adjust get_remote_arch_state calls,
6038 using the regcache's architecture.
6039 (remote_get_trace_status): Adjust get_remote_arch_state calls,
6040 passing down target_gdbarch explicitly.
6041 * spu-multiarch.c (spu_thread_architecture): Defer to the target
6042 beneath instead of calling target_gdbarch.
6043 * target.c (default_thread_architecture): Use the specified
6044 inferior's architecture, instead of the current inferior's
6045 architecture (via target_gdbarch).
6047 2017-10-04 Pedro Alves <palves@redhat.com>
6049 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
6051 (regcache_print): Handle !target_has_registers here instead.
6053 2017-10-04 Pedro Alves <palves@redhat.com>
6055 * frame.c (create_test_frame): Delete.
6056 * frame.h (create_test_frame): Delete.
6057 * gdbarch-selftests.c: Include gdbthread.h and target.h.
6058 (class regcache_test): Delete.
6059 (test_target_has_registers, test_target_has_stack)
6060 (test_target_has_memory, test_target_prepare_to_store)
6061 (test_target_store_registers): New functions.
6062 (test_target_ops): New class.
6063 (register_to_value_test): Error out if there's already a
6064 process_stratum (or higher) target pushed. Create a fuller mock
6065 environment, with mock target_ops, inferior, address space, thread
6067 * progspace.c (struct address_space): Move to ...
6068 * progspace.h (struct address_space): ... here.
6069 * regcache.h (regcache::~regcache, regcache::raw_write)
6070 [GDB_SELF_TEST]: No longer virtual.
6072 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
6074 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
6076 2017-10-04 Pedro Alves <palves@redhat.com>
6078 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
6079 out of 'between TRY and CATCH'.
6081 2017-10-04 Pedro Alves <palves@redhat.com>
6083 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
6084 * common/common-exceptions.h (TRY): Open an outermost scope.
6085 Expand intro comment.
6087 (END_CATCH): Close the outermost scope.
6088 * completer.c (complete_line_internal): Add missing END_CATCH.
6090 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6092 * NEWS (Changes since GDB 8.0): Add entry about new
6093 'set-cwd-on-gdbserver' feature.
6094 (New remote packets): Add entry for QSetWorkingDir.
6095 * common/common-inferior.h (set_inferior_cwd): New prototype.
6096 * infcmd.c (set_inferior_cwd): Remove "static".
6097 (show_cwd_command): Expand text to include remote debugging.
6098 * remote.c: Add PACKET_QSetWorkingDir.
6099 (remote_protocol_features) <QSetWorkingDir>: New entry for
6100 PACKET_QSetWorkingDir.
6101 (extended_remote_set_inferior_cwd): New function.
6102 (extended_remote_create_inferior): Call
6103 "extended_remote_set_inferior_cwd".
6104 (_initialize_remote): Call "add_packet_config_cmd" for
6107 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6109 * NEWS (New commands): Mention "set/show cwd".
6110 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
6111 "cd" command's help text.
6112 * common/common-inferior.h (get_inferior_cwd): New prototype.
6113 * infcmd.c (inferior_cwd_scratch): New global variable.
6114 (set_inferior_cwd): New function.
6115 (get_inferior_cwd): Likewise.
6116 (set_cwd_command): Likewise.
6117 (show_cwd_command): Likewise.
6118 (_initialize_infcmd): Add "set/show cwd" commands.
6119 * inferior.h (class inferior) <cwd>: New field.
6120 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
6121 (fork_inferior): Change inferior's cwd before its execution.
6122 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
6125 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6127 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
6128 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
6129 (COMMON_OBS): Add gdb_tilde_expand.o.
6130 * common/gdb_tilde_expand.c: New file.
6131 * common/gdb_tilde_expand.h: Likewise.
6133 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
6135 * gdbarch.sh (objfile): Remove duplicate declaration.
6136 * gdbarch.h: Regenerate.
6138 2017-10-03 Tom Tromey <tom@tromey.com>
6140 * utils.c (internal_vproblem): Use string_vprintf.
6142 2017-10-03 Tom Tromey <tom@tromey.com>
6144 * printcmd.c (info_symbol_command): Use std::string.
6146 2017-10-03 Tom Tromey <tom@tromey.com>
6148 * top.c (gdb_safe_append_history): Use std::string.
6150 2017-10-03 Tom Tromey <tom@tromey.com>
6152 * event-top.c (stdin_event_handler): Update.
6153 * main.c (captured_main_1): Update.
6154 * top.h (make_delete_ui_cleanup): Remove.
6155 (struct ui): Add constructor and destructor.
6156 (new_ui, delete_ui): Remove.
6157 * top.c (make_delete_ui_cleanup): Remove.
6158 (new_ui_command): Use std::unique_ptr.
6159 (delete_ui_cleanup): Remove.
6160 (ui::ui): Rename from new_ui. Update.
6162 (ui::~ui): Rename from delete_ui. Update.
6164 2017-10-03 Tom Tromey <tom@tromey.com>
6166 * symfile.c (load_progress): Use gdb::byte_vector.
6168 2017-10-03 Tom Tromey <tom@tromey.com>
6170 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
6172 * printcmd.c (x_command): Remove unused declaration.
6173 * symfile.c (symbol_file_command): Remove unused declaration.
6175 2017-10-03 Tom Tromey <tom@tromey.com>
6177 * utils.c (internal_vproblem): Use std::string.
6178 (defaulted_query): Likewise.
6180 2017-10-03 Tom Tromey <tom@tromey.com>
6182 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
6183 * top.c (execute_command_to_string): Update.
6184 * utils.c (make_cleanup_restore_page_info): Remove.
6185 (do_restore_page_info_cleanup): Remove.
6186 (set_batch_flag_and_restore_page_info):
6188 (make_cleanup_restore_page_info): Remove.
6189 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6190 (~set_batch_flag_and_restore_page_info): New
6191 (make_cleanup_restore_uinteger): Remove.
6192 (make_cleanup_restore_integer): Remove.
6193 (struct restore_integer_closure): Remove.
6194 (restore_integer): Remove.
6195 * utils.h (struct set_batch_flag_and_restore_page_info): New
6197 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6198 (make_cleanup_restore_page_info): Remove.
6199 (make_cleanup_restore_uinteger) Remove.
6200 (make_cleanup_restore_integer) Remove.
6202 2017-10-03 Tom Tromey <tom@tromey.com>
6204 * record-full.h (record_full_gdb_operation_disable_set): Return
6205 scoped_restore_tmpl<int>.
6206 * infrun.c (adjust_pc_after_break): Update.
6207 (handle_signal_stop): Update.
6208 * record-full.c (record_full_gdb_operation_disable_set): Return
6209 scoped_restore_tmpl<int>.
6210 (record_full_wait_1, record_full_insert_breakpoint)
6211 (record_full_remove_breakpoint, record_full_save)
6212 (record_full_goto_insn): Update.
6214 2017-10-02 Tom Tromey <tom@tromey.com>
6217 * rust-lang.c (rust_val_print_str): New function.
6218 (val_print_struct): Call it.
6219 (rust_subscript): Preserve name of slice type.
6221 2017-10-02 Tom Tromey <tom@tromey.com>
6223 * rust-lang.c (rust_subscript): Handle slices in
6224 EVAL_AVOID_SIDE_EFFECTS case.
6226 2017-10-02 Tom Tromey <tom@tromey.com>
6228 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
6230 2017-10-02 Tom Tromey <tom@tromey.com>
6232 * rust-lang.h (rust_slice_type): Add "extern".
6234 2017-10-02 Tom Tromey <tom@tromey.com>
6235 Pedro Alves <palves@redhat.com>
6237 * ada-lang.h (ada_exc_info::operator<): Make const.
6238 (ada_exc_info::operator==): Make const.
6239 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
6242 2017-09-29 Tom Tromey <tom@tromey.com>
6244 * target.c (read_whatever_is_readable): Change type of "result".
6246 (free_memory_read_result_vector): Remove.
6247 (read_memory_robust): Change return type. Update.
6248 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
6249 bin2hex, std::string.
6250 * target.h (memory_read_result_s): Remove typedef.
6251 (free_memory_read_result_vector): Remove.
6252 (read_memory_robust): Return std::vector.
6254 2017-09-29 Tom Tromey <tom@tromey.com>
6256 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
6258 2017-09-29 Tom Tromey <tom@tromey.com>
6260 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
6261 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
6262 operator< and operator==.
6263 (ada_exceptions_list): Return a std::vector.
6264 * ada-lang.c (ada_exc_info::operator<): Rename from
6265 compare_ada_exception_info.
6266 (ada_exc_info::operator==): New.
6267 (sort_remove_dups_ada_exceptions_list): Change type of
6269 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
6270 (ada_add_global_exceptions): Likewise.
6271 (ada_exceptions_list_1): Return a std::vector.
6272 (ada_exceptions_list): Likewise.
6274 2017-09-29 Tom Tromey <tom@tromey.com>
6276 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
6278 (print_one_inferior): Update.
6279 (free_vector_of_ints): Remove.
6280 (list_available_thread_groups): Change "ids" to std::set.
6281 (mi_cmd_list_thread_groups): Update.
6282 (struct collect_cores_data) <core>: Now a std::set.
6283 (collect_cores): Update.
6285 (print_one_inferior): Update.
6287 2017-09-29 Tom Tromey <tom@tromey.com>
6289 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
6290 (mi_execute_async_cli_command): Likewise.
6291 (mi_cmd_trace_frame_collected): Use field_fmt.
6293 2017-09-29 Tom Tromey <tom@tromey.com>
6295 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
6298 2017-09-29 Tom Tromey <tom@tromey.com>
6300 * mi/mi-parse.c (mi_parse): Remove unused declaration.
6302 2017-09-29 Tom Tromey <tom@tromey.com>
6304 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
6306 2017-09-29 Tom Tromey <tom@tromey.com>
6308 * varobj.h (varobj_gen_name): Return std::string.
6309 * varobj.c (varobj_gen_name): Return std::string.
6310 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
6311 (mi_cmd_var_delete): Don't copy "name".
6313 2017-09-29 Tom Tromey <tom@tromey.com>
6315 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
6316 (mi_cmd_break_insert_1): Update.
6318 2017-09-29 Tom Tromey <tom@tromey.com>
6320 * target.h (make_scoped_defer_target_commit_resume): Update.
6321 * target.c (make_scoped_defer_target_commit_resume): Rename from
6322 make_cleanup_defer_target_commit_resume. Return a
6324 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
6326 2017-09-29 Tom Tromey <tom@tromey.com>
6328 * main.c (captured_main_1): Remove unused declaration.
6329 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
6331 2017-09-29 Tom Tromey <tom@tromey.com>
6333 * symtab.c (search_symbols): Remove unused outer cleanup.
6334 (make_source_files_completion_list): Remove unused declaration.
6336 2017-09-29 Tom Tromey <tom@tromey.com>
6338 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
6340 2017-09-29 Tom Tromey <tom@tromey.com>
6342 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
6345 2017-09-29 Tom Tromey <tom@tromey.com>
6347 * complaints.c (vcomplaint): Use std::string.
6349 2017-09-29 Tom Tromey <tom@tromey.com>
6351 * tracepoint.c (trace_variable_command): Use std::string.
6352 (encode_actions_1): Remove unused declarations.
6353 (create_tsv_from_upload): Use std::string.
6355 2017-09-29 Tom Tromey <tom@tromey.com>
6357 * cp-support.c (gdb_demangle): Use std::string.
6359 2017-09-29 Tom Tromey <tom@tromey.com>
6361 * stack.c (parse_frame_specification): Use std::string
6362 (info_frame_command): Use gdb::unique_xmalloc_ptr.
6364 2017-09-29 Tom Tromey <tom@tromey.com>
6366 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
6368 2017-09-29 Tom Tromey <tom@tromey.com>
6370 * utils.c (vfprintf_maybe_filtered): Use std::string.
6371 (vfprintf_unfiltered): Likewise.
6373 2017-09-29 Tom Tromey <tom@tromey.com>
6375 * event-top.c (top_level_prompt): Return std::string.
6376 (display_gdb_prompt): Update.
6378 2017-09-29 Tom Tromey <tom@tromey.com>
6380 * unittests/common-utils-selftests.c (format): New function.
6381 (string_vprintf_tests): New function.
6382 (_initialize_common_utils_selftests): Register new tests.
6383 * common/common-utils.c (string_vprintf): New function.
6384 * common/common-utils.h (string_vprintf): Declare.
6386 2017-09-29 Pedro Alves <palves@redhat.com>
6388 * common/rsp-low.c (unpack_varlen_hex): Constify.
6389 * common/rsp-low.h (unpack_varlen_hex): Constify.
6390 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6392 * remote.c (remote_set_permissions, read_ptid)
6393 (remote_current_thread, remote_get_threads_with_qthreadinfo)
6394 (remote_static_tracepoint_marker_at)
6395 (remote_static_tracepoint_markers_by_strid)
6396 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
6397 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
6398 (parse_tracepoint_definition, parse_tsv_definition)
6399 (parse_static_tracepoint_marker_definition): Constify.
6400 * tracepoint.h (parse_static_tracepoint_marker_definition)
6401 (parse_trace_status, parse_tracepoint_status)
6402 (parse_tracepoint_definition, parse_tsv_definition): Constify.
6404 2017-09-29 Pedro Alves <palves@redhat.com>
6406 * remote.c (target_buf, target_buf_size): Delete.
6407 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
6408 Use the connection's packet buffer instead.
6409 All callers adjusted.
6410 (_initialize_remote): Remove references to target_buf and
6413 2017-09-28 Pedro Alves <palves@redhat.com>
6415 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6416 unittests/common-utils-selftests.c.
6417 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
6418 (COMMON_OBS): Remove utils-selftests.o.
6419 * utils-selftests.c: Move to ...
6420 * unittests/common-utils-selftests.c: ... here and rename self
6421 test to "string_printf".
6423 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
6425 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
6426 having NULL cus or tus.
6428 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6430 * arm-tdep.c: (convert_from_extended): Remove.
6431 (convert_to_extended): Likewise.
6432 (arm_extract_return_value): Use convert_typed_floating.
6433 (arm_store_return_value): Likewise.
6435 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6436 * sh-tdep.c: Do not include "floatformat.h".
6437 (sh_littlebyte_bigword_type): New function.
6438 (sh_register_convert_to_virtual): Use convert_typed_floating.
6439 (sh_register_convert_to_raw): Likewise.
6440 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6441 (sh64_littlebyte_bigword_type): New function.
6442 (sh64_extract_return_value): Use convert_typed_floating.
6443 (sh64_register_convert_to_virtual): Likewise.
6444 (sh64_register_convert_to_raw): Likewise.
6446 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6448 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
6449 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
6451 * gdbtypes.h (union type_specific): Make field floatformat hold
6452 just a single struct floatformat, not an array.
6453 (floatformat_from_type): Move here.
6454 * gdbtypes.c (floatformat_from_type): Move here. Update to
6455 changed TYPE_FLOATFORMAT definition.
6456 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
6457 (recursive_dump_type): Likewise.
6458 (init_float_type): Install correct floatformat for byte order.
6459 (arch_float_type): Likewise.
6461 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6463 * gdbtypes.c (init_type): Change incoming argument from
6464 length-in-bytes to length-in-bits. Assert length is a
6465 multiple of TARGET_CHAR_BITS.
6466 (arch_type, arch_flags_type): Likewise.
6467 (init_integer_type): Update call to init_type.
6468 (init_character_type): Likewise.
6469 (init_boolean_type): Likewise.
6470 (init_float_type): Likewise.
6471 (init_decfloat_type): Likewise.
6472 (init_complex_type): Likewise.
6473 (init_pointer_type): Likewise.
6474 (objfile_type): Likewise.
6475 (arch_integer_type): Update call to arch_type.
6476 (arch_character_type): Likewise.
6477 (arch_boolean_type): Likewise.
6478 (arch_float_type): Likewise.
6479 (arch_decfloat_type): Likewise.
6480 (arch_complex_type): Likewise.
6481 (arch_pointer_type): Likewise.
6482 (gdbtypes_post_init): Likewise.
6484 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
6485 (read_base_type): Likewise.
6486 * mdebugread.c (basic_type): Likewise.
6487 * stabsread.c (dbx_init_float_type): Likewise.
6488 (rs6000_builtin_type): Likewise.
6489 (read_range_type): Likewise. Also, fix call to init_integer_type
6490 with erroneous length argument.
6492 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
6493 * d-lang.c (build_d_types): Likewise.
6494 * f-lang.c (build_fortran_types): Likewise.
6495 * go-lang.c (build_go_types): Likewise.
6496 * opencl-lang.c (build_opencl_types): Likewise.
6497 * jit.c (finalize_symtab): Likewise.
6498 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
6499 (build_std_type_info_type): Likewise.
6500 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
6501 update call to arch_flags_type.
6503 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
6505 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
6506 * windows-tdep.c (windows_get_tlb_type): Likewise.
6508 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
6509 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6510 * m32c-tdep.c (make_types): Likewise.
6511 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
6512 (rl78_psw_type): Update call to arch_flags_type.
6513 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
6514 * rx-tdep.c (rx_psw_type): Likewise.
6515 (rx_fpsw_type): Likewise.
6516 * sparc-tdep.c (sparc_psr_type): Likewise.
6517 (sparc_fsr_type): Likewise.
6518 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
6519 (sparc64_ccr_type): Likewise.
6520 (sparc64_fsr_type): Likewise.
6521 (sparc64_fprs_type): Likewise.
6523 2017-09-27 Tom Tromey <tom@tromey.com>
6525 * findcmd.c (find_command): Constify.
6527 2017-09-27 Tom Tromey <tom@tromey.com>
6529 * ada-tasks.c (task_command_1, task_command): Constify.
6531 2017-09-27 Tom Tromey <tom@tromey.com>
6533 * symtab.c (maintenance_print_symbol_cache)
6534 (maintenance_flush_symbol_cache)
6535 (maintenance_print_symbol_cache_statistics): Constify.
6537 2017-09-27 Tom Tromey <tom@tromey.com>
6539 * inferior.c (detach_inferior_command, kill_inferior_command)
6540 (inferior_command): Constify.
6542 2017-09-27 Tom Tromey <tom@tromey.com>
6544 * regcache.c (regcache_print, maintenance_print_registers)
6545 (maintenance_print_raw_registers)
6546 (maintenance_print_cooked_registers)
6547 (maintenance_print_register_groups)
6548 (maintenance_print_remote_registers): Constify.
6550 2017-09-27 Tom Tromey <tom@tromey.com>
6552 * printcmd.c (map_display_numbers, undisplay_command)
6553 (enable_disable_display_command, enable_display_command)
6554 (disable_display_command): Constify.
6556 2017-09-27 Tom Tromey <tom@tromey.com>
6558 * breakpoint.h (delete_command): Don't declare.
6559 * breakpoint.c (delete_command, enable_once_command)
6560 (enable_count_command, enable_delete_command, breakpoint_1)
6561 (maintenance_info_breakpoints, stopin_command, stopat_command)
6562 (delete_command, delete_trace_command, save_breakpoints)
6563 (save_breakpoints_command, save_tracepoints_command): Constify.
6565 2017-09-27 Tom Tromey <tom@tromey.com>
6567 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6568 (skip_ws, extract_identifier, macro_define_command)
6569 (macro_undef_command, macro_list_command): Constify.
6571 2017-09-27 Tom Tromey <tom@tromey.com>
6573 * infcmd.c (environment_info, set_environment_command)
6574 (unset_environment_command, path_info, info_proc_cmd_1)
6575 (info_proc_cmd_mappings, info_proc_cmd_stat)
6576 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6577 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6579 2017-09-27 Tom Tromey <tom@tromey.com>
6581 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6584 2017-09-27 Tom Tromey <tom@tromey.com>
6586 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6588 2017-09-27 Tom Tromey <tom@tromey.com>
6590 * demangle.c (demangle_command): Constify.
6592 2017-09-27 Tom Tromey <tom@tromey.com>
6594 * progspace.c (maintenance_info_program_spaces_command):
6597 2017-09-27 Tom Tromey <tom@tromey.com>
6599 * compile/compile.c (check_raw_argument, compile_file_command)
6600 (compile_code_command, compile_print_command): Constify.
6602 2017-09-27 Tom Tromey <tom@tromey.com>
6604 * reggroups.c (maintenance_print_reggroups): Constify.
6606 2017-09-27 Tom Tromey <tom@tromey.com>
6608 * dwarf2read.c (save_gdb_index_command): Constify.
6610 2017-09-27 Tom Tromey <tom@tromey.com>
6612 * stap-probe.c (info_probes_stap_command): Constify.
6614 2017-09-27 Tom Tromey <tom@tromey.com>
6616 * fork-child.c (unset_exec_wrapper_command): Constify.
6618 2017-09-27 Tom Tromey <tom@tromey.com>
6620 * btrace.c (get_uint, get_context_size, no_chunk)
6621 (maint_btrace_packet_history_cmd)
6622 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6623 (maint_info_btrace_cmd): Constify.
6625 2017-09-27 Tom Tromey <tom@tromey.com>
6627 * reverse.c (delete_bookmark_command): Constify.
6629 2017-09-27 Tom Tromey <tom@tromey.com>
6631 * remote.c (set_memory_packet_size)
6632 (set_memory_write_packet_size, show_memory_write_packet_size)
6633 (set_memory_read_packet_size, show_memory_read_packet_size)
6634 (compare_sections_command, packet_command, remote_put_command)
6635 (remote_get_command, remote_delete_command): Constify.
6637 2017-09-27 Tom Tromey <tom@tromey.com>
6639 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6640 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6641 (set_mipsfpu_auto_command): Constify.
6643 2017-09-27 Tom Tromey <tom@tromey.com>
6645 * cli/cli-cmds.h (cd_command): Constify.
6646 * cli/cli-cmds.c (cd_command): Constify.
6648 2017-09-27 Tom Tromey <tom@tromey.com>
6650 * thread.c (thread_name_command, thread_find_command): Constify.
6652 2017-09-27 Tom Tromey <tom@tromey.com>
6654 * probe.c (enable_probes_command, disable_probes_command):
6657 2017-09-27 Tom Tromey <tom@tromey.com>
6659 * symfile.c (symbol_file_command): Constify.
6660 * gdbcore.h (deprecated_file_changed_hook): Constify.
6661 * exec.c (deprecated_file_changed_hook, exec_file_command)
6662 (file_command): Constify.
6663 * defs.h (symbol_file_command): Constify.
6665 2017-09-27 Tom Tromey <tom@tromey.com>
6667 * remote-fileio.c (set_system_call_allowed)
6668 (show_system_call_allowed): Constify.
6670 2017-09-27 Tom Tromey <tom@tromey.com>
6672 * tracepoint.c (delete_trace_variable_command)
6673 (tfind_end_command, tfind_start_command, tfind_pc_command)
6674 (tfind_tracepoint_command, tfind_line_command)
6675 (tfind_range_command, tfind_outside_command): Constify.
6677 2017-09-27 Tom Tromey <tom@tromey.com>
6679 * ax-gdb.c (maint_agent_printf_command, agent_command)
6680 (agent_eval_command): Constify.
6682 2017-09-27 Tom Tromey <tom@tromey.com>
6684 * tracepoint.c (info_scope_command): Constify.
6685 * python/python.c (gdbpy_decode_line): Constify.
6686 * python/py-breakpoint.c (bppy_init): Constify.
6687 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6688 * location.h: (new_linespec_location)
6689 (string_to_event_location_basic, string_to_event_location):
6691 * location.c (new_linespec_location)
6692 (string_to_event_location_basic, string_to_event_location):
6694 * linespec.h (decode_line_with_current_source)
6695 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6696 * linespec.c (linespec_lex_to_end)
6697 (decode_line_with_current_source)
6698 (decode_line_with_last_displayed): Constify.
6699 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6701 * cli/cli-cmds.c (edit_command, list_command): Constify.
6702 * breakpoint.h (until_break_command, watch_command_wrapper)
6703 (awatch_command_wrapper, rwatch_command_wrapper)
6704 (init_ada_exception_breakpoint): Constify.
6705 * breakpoint.c (break_command_1, dprintf_command)
6706 (break_range_command, watch_command_wrapper)
6707 (rwatch_command_wrapper, awatch_command_wrapper)
6708 (until_break_command, init_ada_exception_breakpoint)
6709 (strace_marker_create_sals_from_location, trace_command)
6710 (ftrace_command, strace_command, struct tracepoint): Constify.
6711 * ax-gdb.c (agent_command_1): Constify.
6712 * ada-lang.c (ada_exception_sal): Constify.
6714 2017-09-27 Tom Tromey <tom@tromey.com>
6716 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6717 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6718 (get_context_size, no_chunk, get_insn_history_modifiers)
6719 (cmd_record_insn_history, get_call_history_modifiers)
6720 (cmd_record_call_history): Constify.
6722 2017-09-27 Tom Tromey <tom@tromey.com>
6724 * source.c (show_substitute_path_command)
6725 (unset_substitute_path_command, set_substitute_path_command):
6728 2017-09-27 Tom Tromey <tom@tromey.com>
6730 * typeprint.c (maintenance_print_type): Constify.
6731 * maint.c (maintenance_dump_me, maintenance_demangle)
6732 (maintenance_time_display, maintenance_info_sections)
6733 (maintenance_print_statistics, maintenance_deprecate)
6734 (maintenance_undeprecate): Constify.
6735 (maintenance_do_deprecate): Constify. Use std::string.
6736 (maintenance_selftest): Constify.
6737 * gdbtypes.h (maintenance_print_type): Constify.
6739 2017-09-27 Tom Tromey <tom@tromey.com>
6741 * hppa-tdep.c (unwind_command): Constify.
6743 2017-09-27 Tom Tromey <tom@tromey.com>
6745 * target-descriptions.c (unset_tdesc_filename_cmd)
6746 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6749 2017-09-27 Tom Tromey <tom@tromey.com>
6751 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6753 2017-09-27 Tom Tromey <tom@tromey.com>
6755 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6757 2017-09-27 Tom Tromey <tom@tromey.com>
6759 * tui/tui-regs.c (tui_reg_command): Constify.
6761 2017-09-27 Tom Tromey <tom@tromey.com>
6763 * skip.c (skip_file_command, skip_function_command)
6764 (skip_enable_command, skip_disable_command, skip_delete_command):
6767 2017-09-27 Tom Tromey <tom@tromey.com>
6769 * record-btrace.c (cmd_record_btrace_bts_start)
6770 (cmd_record_btrace_pt_start): Constify.
6772 2017-09-27 Tom Tromey <tom@tromey.com>
6774 * symmisc.c (maintenance_print_symbols)
6775 (maintenance_print_msymbols, maintenance_print_objfiles)
6776 (maintenance_info_symtabs, maintenance_check_symtabs)
6777 (maintenance_expand_symtabs, maintenance_info_line_tables):
6780 2017-09-27 Tom Tromey <tom@tromey.com>
6782 * top.c (new_ui_command): Constify.
6784 2017-09-27 Tom Tromey <tom@tromey.com>
6786 * symfile.c (add_symbol_file_command)
6787 (remove_symbol_file_command, list_overlays_command)
6788 (map_overlay_command, unmap_overlay_command)
6789 (overlay_auto_command, overlay_manual_command)
6790 (overlay_off_command, overlay_load_command): Constify.
6792 2017-09-27 Tom Tromey <tom@tromey.com>
6794 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6795 (info_spu_mailbox_command, info_spu_dma_command)
6796 (info_spu_proxydma_command): Constify.
6798 2017-09-27 Tom Tromey <tom@tromey.com>
6800 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6802 2017-09-27 Tom Tromey <tom@tromey.com>
6804 * cli/cli-script.c (user_defined_command): Constify.
6806 2017-09-27 Tom Tromey <tom@tromey.com>
6808 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6809 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6810 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6811 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6812 (dump_binary_value, append_binary_memory, append_binary_value):
6814 (struct dump_context) <func>: Constify.
6815 (add_dump_command): Update.
6817 2017-09-27 Tom Tromey <tom@tromey.com>
6819 * cli/cli-cmds.c (show_version, show_configuration)
6820 (source_command, show_user): Constify.
6822 2017-09-27 Tom Tromey <tom@tromey.com>
6824 * target.c (maintenance_print_target_stack): Constify.
6826 2017-09-27 Tom Tromey <tom@tromey.com>
6828 * interps.c (interpreter_exec_cmd): Constify.
6830 2017-09-27 Tom Tromey <tom@tromey.com>
6832 * record-full.c (cmd_record_full_restore): Constify.
6834 2017-09-27 Tom Tromey <tom@tromey.com>
6836 * memattr.c (enable_mem_command, disable_mem_command)
6837 (delete_mem_command): Constify.
6839 2017-09-27 Tom Tromey <tom@tromey.com>
6841 * value.c (show_convenience): Constify.
6843 2017-09-27 Tom Tromey <tom@tromey.com>
6845 * gdbcore.h (core_file_command): Update.
6846 * corefile.c (core_file_command): Constify.
6848 2017-09-27 Tom Tromey <tom@tromey.com>
6850 * user-regs.c (maintenance_print_user_registers): Constify.
6852 2017-09-27 Tom Tromey <tom@tromey.com>
6854 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6856 2017-09-27 Tom Tromey <tom@tromey.com>
6858 * cp-support.c (first_component_command): Constify.
6860 2017-09-27 Tom Tromey <tom@tromey.com>
6862 * psymtab.c (maintenance_print_psymbols)
6863 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6866 2017-09-27 Tom Tromey <tom@tromey.com>
6868 * windows-tdep.c (display_tib): Constify.
6870 2017-09-27 Tom Tromey <tom@tromey.com>
6872 * linux-fork.c (delete_checkpoint_command)
6873 (detach_checkpoint_command): Constify.
6875 2017-09-27 Tom Tromey <tom@tromey.com>
6877 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6879 2017-09-27 Tom Tromey <tom@tromey.com>
6881 * arc-tdep.c (dump_arc_instruction_command): Constify.
6883 2017-09-27 Tom Tromey <tom@tromey.com>
6885 * valprint.c (set_radix, show_radix): Constify.
6887 2017-09-27 Tom Tromey <tom@tromey.com>
6889 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6891 2017-09-27 Tom Tromey <tom@tromey.com>
6893 * command.h (not_just_help_class_command): Update.
6894 * cli/cli-decode.h (not_just_help_class_command): Update.
6895 * cli/cli-decode.c (not_just_help_class_command): Constify.
6897 2017-09-27 Tom Tromey <tom@tromey.com>
6899 * gdb_bfd.c (maintenance_info_bfds): Constify.
6901 2017-09-27 Tom Tromey <tom@tromey.com>
6903 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6905 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6906 (do_const_cfunc): New function.
6907 (cmd_cfunc_eq): New overload.
6908 (cli_user_command_p): Check do_const_cfunc.
6909 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6911 * command.h (add_cmd): Add const overload and no-function
6913 (set_cmd_cfunc): Add const overload.
6914 (cmd_const_cfunc_ftype): Declare.
6915 (cmd_cfunc_eq): Add const overload.
6916 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
6917 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
6920 2017-09-27 Tom Tromey <tom@tromey.com>
6922 * macroexp.c (get_next_token_for_substitution): New function.
6923 (substitute_args): Call it. Check for __VA_OPT__.
6925 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6926 Pedro Alves <palves@redhat.com>
6928 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
6929 producer_is_icc_lt_14.
6930 (producer_is_icc_lt_14): New function.
6931 (check_producer): Add code for checking version of ICC.
6932 (producer_is_icc): Move to producer.c.
6933 (read_structure_type): Restrict ICC workaround to ICC<14.
6934 * producer.c: Include selftest.h.
6935 (producer_is_icc, producer_parsing_tests, _initialize_producer):
6937 * producer.h (producer_is_icc): New declaration.
6939 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6941 * Makefile.in (SFILES): Add producer.c.
6942 (COMMON_OBS): Add producer.o
6943 * amd64-tdep.c (producer.h): Add new include.
6944 * dwarf2read.c (producer.h): Add new include.
6945 * producer.c: New file.
6946 * producer.h: New file.
6947 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
6949 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
6952 2017-09-26 Matthias Klose <doko@ubuntu.com>
6954 * configure.ac: Search ncursesw before ncurses.
6955 Check ncursesw/ncurses.h before ncurses/ncurses.h.
6956 * gdb_curses.h: Include <ncursesw/ncurses.h>
6957 * config.in, configure: Regenerate.
6959 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6962 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
6964 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
6965 Remove i386sol2 support.
6966 * configure.nat <i386sol2>: Remove.
6967 <sol2-64>: Fold into ...
6969 Move common settings to default section.
6971 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
6972 x86_64-*-solaris2.1[0-9]*>: Rename to ...
6973 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
6974 <i[34567]86-*-solaris*>: Remove.
6975 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
6977 * configure.ac: Remove wctype in libw check.
6978 (_MSE_INT_H): Don't define on Solaris 7-9.
6979 <solaris*>: Remove libthread_db.so.1 check.
6980 * configure: Regenerate.
6981 * config.in: Regenerate.
6983 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
6984 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
6985 (gdb_ps_size_t): Remove.
6986 Use base types in users.
6987 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
6989 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
6991 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6994 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
6995 (adi_is_addr_mapped): Likewise.
6996 (PSR_ICC): Don't redefine.
6997 (PSR_IMPL): Likewise.
6999 2017-09-25 Tom Tromey <tom@tromey.com>
7001 * regcache.c (regcache::dump): Use string_printf.
7003 2017-09-25 Tom Tromey <tom@tromey.com>
7005 * regcache.c (class regcache_invalidator): New.
7006 (struct register_to_invalidate): Remove.
7007 (make_cleanup_regcache_invalidate): Remove.
7008 (regcache::raw_write): Use regcache_invalidator.
7010 2017-09-25 Tom Tromey <tom@tromey.com>
7012 * spu-tdep.c (spu2ppu_sniffer): Update.
7013 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
7014 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
7016 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
7017 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
7018 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
7019 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
7020 (frame_pop): Update.
7022 2017-09-25 Tom Tromey <tom@tromey.com>
7024 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
7025 * regcache.h (regcache_xfree): Don't declare.
7026 * regcache.c (regcache_xfree): Remove.
7027 (do_regcache_xfree): Use delete.
7028 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
7029 * linux-fork.c (free_fork): Use delete.
7030 (fork_save_infrun_state): Likewise.
7031 * jit.c (jit_dealloc_cache): Use delete.
7032 * infrun.c (discard_infcall_suspend_state): Use delete.
7034 2017-09-25 Tom Tromey <tom@tromey.com>
7036 * regcache.h (regcache_xmalloc): Don't declare.
7037 (regcache_raw_set_cached_value): Update comment.
7038 * regcache.c (regcache_xmalloc): Remove.
7039 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
7040 * jit.c (jit_frame_sniffer): Use new.
7041 * frame.c (frame_save_as_regcache): Use new.
7043 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
7045 * NEWS: Advertise support for guarded-storage registers on IBM z.
7047 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
7049 * s390-linux-nat.c (have_regset_gs): New static variable.
7050 (s390_linux_fetch_inferior_registers): Handle guarded-storage
7051 control block and guarded-storage broadcast control regsets.
7052 (s390_read_description): Detect whether the target has
7053 guarded-storage support, return appropriate tdesc.
7054 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
7055 (features/s390x-gs-linux64.c): Likewise.
7056 (struct gdbarch_tdep) <have_gs>: New field.
7057 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
7058 (s390_gsbc_regset): New variables.
7059 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
7060 and s390_gsbc_regset, if applicable.
7061 (s390_core_read_description): Check whether core file was from a
7062 target with guarded-storage support; include appropriate regsets.
7063 (s390_gdbarch_init): Add registers for guarded-storage support.
7064 (_initialize_s390_tdep): Initialize new target descriptions that
7065 include registers for guarded-storage support.
7066 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
7067 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
7068 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
7069 (S390_NUM_REGS): Adjust macro definition.
7070 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
7071 (tdesc_s390x_gs_linux64): New declarations.
7073 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
7075 * features/s390-gs-linux64.xml: New file.
7076 * features/s390-gs.xml: New file.
7077 * features/s390-gsbc.xml: New file.
7078 * features/s390x-gs-linux64.xml: New file.
7079 * features/Makefile (WHICH): Add s390-gs-linux64 and
7081 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
7082 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
7083 * features/s390-gs-linux64.c: New generated file.
7084 * features/s390x-gs-linux64.c: New file.
7085 * regformats/s390-gs-linux64.dat: New file.
7086 * regformats/s390x-gs-linux64.dat: New file.
7088 2017-09-23 Tom Tromey <tom@tromey.com>
7090 * defs.h (make_cleanup_override_quit_handler): Don't declare.
7092 2017-09-22 Tom Tromey <tom@tromey.com>
7094 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
7095 type to scoped_restore_tmpl.
7096 <scoped_input_handler>: Initialize m_quit_handler directly.
7098 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
7100 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
7101 (cd_command): Likewise. Free "current_directory" before
7103 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
7104 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
7105 * top.c (gdb_dirbuf): Remove global declaration.
7106 * top.h (gdb_dirbuf): Likewise.
7108 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
7110 * gnulib/aclocal.m4: Regenerate.
7111 * gnulib/config.in: Regenerate.
7112 * gnulib/configure: Regenerate.
7113 * gnulib/import/Makefile.am: Regenerate.
7114 * gnulib/import/Makefile.in: Regenerate.
7115 * gnulib/import/assure.h: New file.
7116 * gnulib/import/at-func.c: Likewise
7117 * gnulib/import/chdir-long.c: New file.
7118 * gnulib/import/chdir-long.h: New file.
7119 * gnulib/import/cloexec.c: New file.
7120 * gnulib/import/cloexec.h: New file.
7121 * gnulib/import/close.c: New file.
7122 * gnulib/import/closedir.c: New file.
7123 * gnulib/import/dirent-private.h: New file.
7124 * gnulib/import/dup-safer.c: New file.
7125 * gnulib/import/dup.c: New file.
7126 * gnulib/import/dup2.c: New file.
7127 * gnulib/import/error.c: New file.
7128 * gnulib/import/error.h: New file.
7129 * gnulib/import/exitfail.c: New file.
7130 * gnulib/import/exitfail.h: New file.
7131 * gnulib/import/fchdir.c: New file.
7132 * gnulib/import/fcntl.c: New file.
7133 * gnulib/import/fcntl.in.h: New file.
7134 * gnulib/import/fd-hook.c: New file.
7135 * gnulib/import/fd-hook.h: New file.
7136 * gnulib/import/fd-safer.c: New file.
7137 * gnulib/import/fdopendir.c: New file.
7138 * gnulib/import/filename.h: New file.
7139 * gnulib/import/filenamecat-lgpl.c: New file.
7140 * gnulib/import/filenamecat.h: New file.
7141 * gnulib/import/fstat.c: New file.
7142 * gnulib/import/fstatat.c: New file.
7143 * gnulib/import/getcwd-lgpl.c: New file.
7144 * gnulib/import/getcwd.c: New file.
7145 * gnulib/import/getdtablesize.c: New file.
7146 * gnulib/import/getlogin_r.c: New file.
7147 * gnulib/import/getprogname.c: New file.
7148 * gnulib/import/getprogname.h: New file.
7149 * gnulib/import/gettext.h: New file.
7150 * gnulib/import/glob-libc.h: New file.
7151 * gnulib/import/glob.c: New file.
7152 * gnulib/import/glob.in.h: New file.
7153 * gnulib/import/intprops.h: New file.
7154 * gnulib/import/m4/chdir-long.m4: New file.
7155 * gnulib/import/m4/close.m4: New file.
7156 * gnulib/import/m4/closedir.m4: New file.
7157 * gnulib/import/m4/d-ino.m4: New file.
7158 * gnulib/import/m4/d-type.m4: New file.
7159 * gnulib/import/m4/dup.m4: New file.
7160 * gnulib/import/m4/dup2.m4: New file.
7161 * gnulib/import/m4/error.m4: New file.
7162 * gnulib/import/m4/fchdir.m4: New file.
7163 * gnulib/import/m4/fcntl.m4: New file.
7164 * gnulib/import/m4/fcntl_h.m4: New file.
7165 * gnulib/import/m4/fdopendir.m4: New file.
7166 * gnulib/import/m4/filenamecat.m4: New file.
7167 * gnulib/import/m4/fstat.m4: New file.
7168 * gnulib/import/m4/fstatat.m4: New file.
7169 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
7170 * gnulib/import/m4/getcwd-path-max.m4: New file.
7171 * gnulib/import/m4/getcwd.m4: New file.
7172 * gnulib/import/m4/getdtablesize.m4: New file.
7173 * gnulib/import/m4/getlogin_r.m4: New file.
7174 * gnulib/import/m4/getprogname.m4: New file.
7175 * gnulib/import/m4/glob.m4: New file.
7176 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7177 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7178 * gnulib/import/m4/mempcpy.m4: New file.
7179 * gnulib/import/m4/memrchr.m4: New file.
7180 * gnulib/import/m4/mode_t.m4: New file.
7181 * gnulib/import/m4/msvc-inval.m4: New file.
7182 * gnulib/import/m4/msvc-nothrow.m4: New file.
7183 * gnulib/import/m4/open.m4: New file.
7184 * gnulib/import/m4/openat.m4: New file.
7185 * gnulib/import/m4/opendir.m4: New file.
7186 * gnulib/import/m4/readdir.m4: New file.
7187 * gnulib/import/m4/realloc.m4: New file.
7188 * gnulib/import/m4/rewinddir.m4: New file.
7189 * gnulib/import/m4/save-cwd.m4: New file.
7190 * gnulib/import/m4/strdup.m4: New file.
7191 * gnulib/import/m4/strerror.m4: New file.
7192 * gnulib/import/m4/unistd-safer.m4: New file.
7193 * gnulib/import/mempcpy.c: New file.
7194 * gnulib/import/memrchr.c: New file.
7195 * gnulib/import/msvc-inval.c: New file.
7196 * gnulib/import/msvc-inval.h: New file.
7197 * gnulib/import/msvc-nothrow.c: New file.
7198 * gnulib/import/msvc-nothrow.h: New file.
7199 * gnulib/import/open.c: New file.
7200 * gnulib/import/openat-die.c: New file.
7201 * gnulib/import/openat-priv.h: New file.
7202 * gnulib/import/openat-proc.c: New file.
7203 * gnulib/import/openat.c: New file.
7204 * gnulib/import/openat.h: New file.
7205 * gnulib/import/opendir.c: New file.
7206 * gnulib/import/pipe-safer.c: New file.
7207 * gnulib/import/readdir.c: New file.
7208 * gnulib/import/realloc.c: New file.
7209 * gnulib/import/rewinddir.c: New file.
7210 * gnulib/import/save-cwd.c: New file.
7211 * gnulib/import/save-cwd.h: New file.
7212 * gnulib/import/strdup.c: New file.
7213 * gnulib/import/strerror-override.c: New file.
7214 * gnulib/import/strerror-override.h: New file.
7215 * gnulib/import/strerror.c: New file.
7216 * gnulib/import/unistd--.h: New file.
7217 * gnulib/import/unistd-safer.h: New file.
7218 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
7219 "getcwd" and "glob".
7220 * ser-tcp.c: Undefine "close" before redefining it.
7222 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7224 * guile/scm-value.c (gdbscm_value_address): Initialize address,
7227 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7229 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
7230 <sol2,sparc>: Likewise.
7231 <sol2-64,i386>: Likewise.
7233 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
7234 -Wdeprecated-declarations on *-*-solaris*.
7235 * configure: Regenerate.
7237 * procfs.c: Include "nat/inferior.h".
7238 (procfs_info_proc): Fix typo.
7240 2017-09-21 Kevin Buettner <kevinb@redhat.com>
7242 * remote.c (vector): Include.
7243 (struct private_thread_info): Add field, thread_handle.
7244 (free_private_thread_info): Deallocate storage associated with
7246 (get_private_info_thread): Initialize `thread_handle' field.
7247 (struct thread_item): Add field, thread_handle.
7248 (clear_threads_listing_context): Deallocate storage associated
7250 (start_thread): Add support for "handle" attribute.
7251 (thread_attributes): Add "handle".
7252 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
7254 (remote_update_thread_list): Update thread_handle.
7255 (remote_thread_handle_to_thread_info): New function.
7256 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
7258 2017-09-21 Kevin Buettner <kevinb@redhat.com>
7260 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
7262 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
7263 * python/python-internal.h (thread_object_type): Declare.
7265 2017-09-21 Kevin Buettner <kevinb@redhat.com>
7267 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
7268 (target_thread_handle_to_thread_info): Declare.
7269 * target.c (target_thread_handle_to_thread_info): New function.
7270 * target-delegates.c: Regenerate.
7271 * gdbthread.h (find_thread_by_handle): Declare.
7272 * thread.c (find_thread_by_handle): New function.
7273 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
7275 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
7277 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7279 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
7281 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7283 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
7285 2017-09-21 Yao Qi <yao.qi@linaro.org>
7287 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
7290 2017-09-20 Tom Tromey <tom@tromey.com>
7292 * breakpoint.c (struct counted_command_line): Remove.
7293 (breakpoint_commands): Update.
7294 (alloc_counted_command_line, incref_counted_command_line)
7295 (decref_counted_command_line, do_cleanup_counted_command_line)
7296 (make_cleanup_decref_counted_command_line): Remove.
7297 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
7298 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
7299 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
7300 (save_breakpoints): Update.
7301 * breakpoint.h (counted_command_line): Now a typedef to
7303 (struct breakpoint) <commands>: Now a counted_command_line.
7304 (struct bpstats) <command>: Likewise.
7306 2017-09-20 Tom Tromey <tom@tromey.com>
7308 * breakpoint.c (struct commands_info, do_map_commands_command):
7310 (commands_command_1): Update.
7311 (iterate_over_related_breakpoints): Take a function_view.
7312 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
7313 (delete_command): Update.
7314 (map_breakpoint_numbers): Take a function_view.
7315 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
7316 (disable_command): Update.
7317 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
7318 (enable_command): Update.
7319 (struct disp_data, do_enable_breakpoint_disp)
7320 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
7321 (do_map_enable_delete_breakpoint): Remove.
7322 (enable_once_command, enable_count_command, enable_delete_command)
7323 (delete_trace_variable_command): Update.
7325 2017-09-20 Tom Tromey <tom@tromey.com>
7327 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
7328 (bpstat_clear): Use delete.
7329 (bpstats): New constructors.
7330 (bpstat_copy, bpstat_stop_status): Use new.
7331 (dprintf_after_condition_true): Update.
7332 * breakpoint.h (bpstats::bpstats): Add constructors.
7333 (bpstats::~bpstats): Add destructor.
7335 2017-09-20 Pedro Alves <palves@redhat.com>
7337 * eval.c (make_params): Delete, refactored as ...
7338 (class fake_method): ... this new type's ctor.
7339 (fake_method::~fake_method): New.
7340 (evaluate_subexp_standard): Use 'fake_method'.
7342 2017-09-20 Tom Tromey <tom@tromey.com>
7344 * windows-nat.c (get_windows_debug_event, windows_wait)
7345 (do_initial_windows_stuff, windows_attach): Update.
7346 * utils.c (vwarning, internal_vproblem): Update.
7347 (ui_unregister_input_event_handler_cleanup)
7348 (prepare_to_handle_input): Remove.
7349 (class scoped_input_handler): New.
7350 (defaulted_query, prompt_for_continue): Update.
7351 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
7353 * top.c (undo_terminal_modifications_before_exit): Update.
7354 * target/target.h (target_terminal_init, target_terminal_inferior)
7355 (target_terminal_ours): Don't declare.
7356 (class target_terminal): New.
7357 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
7358 (target_terminal_ours_for_output)
7359 (make_cleanup_restore_target_terminal): Don't declare.
7360 (target_terminal_info): Remove.
7361 * target.c (enum terminal_state, terminal_state): Remove.
7362 (target_terminal::terminal_state): Define.
7363 (target_terminal::init): Rename from target_terminal_init.
7364 (target_terminal::inferior): Rename from
7365 target_terminal_inferior.
7366 (target_terminal::ours): Rename from target_terminal_ours.
7367 (target_terminal::ours_for_output): Rename from
7368 target_terminal_ours_for_output.
7369 (target_terminal::info): New method.
7370 (cleanup_restore_target_terminal)
7371 (make_cleanup_restore_target_terminal): Remove.
7372 * solib.c (handle_solib_event): Update.
7373 * remote.c (remote_serial_quit_handler): Update.
7374 (remote_terminal_inferior, remote_wait_as): Update.
7375 * record-full.c (record_full_wait_1): Update.
7376 * nto-procfs.c (procfs_create_inferior): Update.
7377 * nat/fork-inferior.c (startup_inferior): Update.
7378 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
7379 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
7380 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
7381 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
7382 (mi_breakpoint_created, mi_breakpoint_deleted)
7383 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
7384 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7385 (mi_user_selected_context_changed, report_initial_inferior):
7387 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
7388 (linux_nat_terminal_inferior): Update.
7389 * infrun.c (follow_fork_inferior)
7390 (handle_vfork_child_exec_or_exit, do_target_resume)
7391 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
7392 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
7394 * inflow.c (child_terminal_init, info_terminal_command): Update.
7395 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
7396 (attach_command): Update.
7397 * infcall.c (call_thread_fsm_should_stop): Update.
7398 * gnu-nat.c (gnu_attach): Update.
7399 * extension.c (struct active_ext_lang_state)
7400 (restore_active_ext_lang): Update.
7401 * exceptions.c (print_flush): Update.
7402 * event-top.c (async_enable_stdin, default_quit_handler): Update.
7403 (struct quit_handler_cleanup_data, restore_quit_handler)
7404 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
7406 * cp-support.c (gdb_demangle): Update.
7407 * breakpoint.c (update_inserted_breakpoint_locations)
7408 (insert_breakpoint_locations, handle_jit_event)
7409 (disable_breakpoints_in_unloaded_shlib): Update.
7410 * annotate.c (annotate_breakpoints_invalid)
7411 (annotate_frames_invalid): Update.
7413 2017-09-20 Tom Tromey <tom@tromey.com>
7415 * main.c (catch_command_errors): Rename from
7416 catch_command_errors_const.
7417 (captured_main_1): Update.
7419 2017-09-20 Pedro Alves <palves@redhat.com>
7421 * cli/cli-cmds.c (list_command): Use print_sal_location.
7422 (print_sal_location): New function.
7423 (ambiguous_line_spec): Use print_sal_location.
7424 * linespec.c (symbol_to_sal): Record the symbol in the sal.
7425 * symtab.c (find_function_start_sal): Likewise.
7426 * symtab.h (symtab_and_line::symbol): New field.
7428 2017-09-20 Pedro Alves <palves@redhat.com>
7430 * linespec.c (minsym_found): Handle non-text minsyms.
7431 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
7433 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7435 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
7438 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7440 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
7441 vmovups instead vmovaps.
7442 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
7444 2017-09-19 John Baldwin <jhb@FreeBSD.org>
7446 * NEWS (Changes since GDB 8.0): Add starti.
7447 * infcmd.c (enum run_break): New.
7448 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
7450 (run_command): Use enum run_how.
7451 (start_command): Likewise.
7452 (starti_command): New function.
7453 (RUN_ARGS_HELP): New macro.
7454 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
7455 commands. Add starti command.
7457 2017-09-19 Yao Qi <yao.qi@linaro.org>
7459 * Makefile.in (monitor.o): Remove the rule.
7461 2017-09-19 Yao Qi <yao.qi@linaro.org>
7463 * annotate.h (struct annotate_arg_emitter): Use
7464 DISABLE_COPY_AND_ASSIGN.
7465 * common/refcounted-object.h (refcounted_object): Likewise.
7466 * completer.h (struct completion_result): Likewise.
7467 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
7468 * filename-seen-cache.h (filename_seen_cache): Likewise.
7469 * gdbcore.h (thread_section_name): Likewise.
7470 * gdb_regex.h (compiled_regex): Likewise.
7471 * gdbthread.h (scoped_restore_current_thread): Likewise.
7472 * inferior.h (scoped_restore_current_inferior): Likewise.
7473 * jit.c (jit_reader): Likewise.
7474 * linespec.h (struct linespec_result): Likewise.
7475 * mi/mi-parse.h (struct mi_parse): Likewise.
7476 * nat/fork-inferior.c (execv_argv): Likewise.
7477 * progspace.h (scoped_restore_current_program_space): Likewise.
7478 * python/python-internal.h (class gdbpy_enter): Likewise.
7479 * regcache.h (regcache): Likewise.
7480 * target-descriptions.c (struct tdesc_reg): Likewise.
7481 (struct tdesc_type): Likewise.
7482 (struct tdesc_feature): Likewise.
7483 * ui-out.h (ui_out_emit_type): Likewise.
7485 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
7487 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
7488 label abort_expression.
7490 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7492 * common/buffer.c (buffer_xml_printf): Adjust.
7493 * common/xml-utils.c (xml_escape_text): Change return type to
7494 std::string, update code accordingly.
7495 * common/xml-utils.h (xml_escape_text): Change return type to
7497 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
7498 * windows-tdep.c (windows_xfer_shared_library): Adjust.
7499 * unittests/xml-utils-selftests.c (test_xml_escape_text):
7502 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7504 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
7505 (SUBDIR_UNITTESTS_OBS): Add new object file.
7506 * unittests/xml-utils-selftests.c: New file.
7508 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7510 * common/selftest.h (selftest): New struct/interface.
7511 (register_test): Add name parameter, add new overload.
7512 (run_tests): Add filter parameter.
7513 (for_each_selftest_ftype): New typedef.
7514 (for_each_selftest): New declaration.
7515 * common/selftest.c (tests): Change type to
7516 map<string, unique_ptr<selftest>>.
7517 (simple_selftest): New struct.
7518 (register_test): New function.
7519 (register_test): Add name parameter and use it.
7520 (run_tests): Add filter parameter and use it. Add prints.
7521 Adjust to vector -> map change.
7522 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
7523 registering selftests.
7524 * arm-tdep.c (_initialize_arm_tdep): Likewise.
7525 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
7526 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
7527 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
7528 * findvar.c (_initialize_findvar): Likewise.
7529 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
7530 * maint.c (maintenance_selftest): Update call to run_tests.
7531 (maintenance_info_selftests): New function.
7532 (_initialize_maint_cmds): Register "maintenance info selftests"
7533 command. Update "maintenance selftest" doc.
7534 * regcache.c (_initialize_regcache): Add names when registering
7536 * rust-exp.y (_initialize_rust_exp): Likewise.
7537 * selftest-arch.c (gdbarch_selftest): New struct.
7538 (gdbarch_tests): Remove.
7539 (register_test_foreach_arch): Add name parameter. Call
7541 (tests_with_arch): Remove, move most content to
7542 gdbarch_selftest::operator().
7543 (_initialize_selftests_foreach_arch): Remove.
7544 * selftest-arch.h (register_test_foreach_arch): Add name
7546 (run_tests_with_arch): New declaration.
7547 * utils-selftests.c (_initialize_utils_selftests): Add names
7548 when registering selftests.
7549 * utils.c (_initialize_utils): Likewise.
7550 * unittests/array-view-selftests.c
7551 (_initialize_array_view_selftests): Likewise.
7552 * unittests/environ-selftests.c (_initialize_environ_selftests):
7554 * unittests/function-view-selftests.c
7555 (_initialize_function_view_selftests): Likewise.
7556 * unittests/offset-type-selftests.c
7557 (_initialize_offset_type_selftests): Likewise.
7558 * unittests/optional-selftests.c
7559 (_initialize_optional_selftests): Likewise.
7560 * unittests/scoped_restore-selftests.c
7561 (_initialize_scoped_restore_selftests): Likewise.
7562 * NEWS: Document "maintenance selftest" and "maint info
7565 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7567 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7570 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7572 * mi/mi-main.c (mi_load_progress): Make uiout variable
7575 2017-09-15 Pedro Alves <palves@redhat.com>
7577 * compile/compile-c-types.c (convert_enum, convert_int)
7578 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7580 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7582 * dwarf2read.c (copy_string): Remove.
7583 (parse_macro_definition): Replace copy_string with savestring.
7585 2017-09-15 Yao Qi <yao.qi@linaro.org>
7587 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7589 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7591 (i[34567]86-*-linux*): Likewise.
7593 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7595 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7596 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7597 <stack>: Change type to std::vector.
7598 <stack_len, stack_allocated>: Remove.
7599 <grow_stack>: Remove.
7600 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7601 (dwarf_expr_context::~dwarf_expr_context): Remove.
7602 (dwarf_expr_context::grow_stack): Remove.
7603 (dwarf_expr_context::push): Adjust.
7604 (dwarf_expr_context::pop): Adjust.
7605 (dwarf_expr_context::fetch): Adjust.
7606 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7607 (dwarf_expr_context::stack_empty_p): Adjust.
7608 (dwarf_expr_context::execute_stack_op): Adjust.
7610 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7612 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7613 return type to bool.
7614 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7616 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7618 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7619 Change type to bool.
7620 (dwarf_stack_value) <in_stack_memory>: Likewise.
7621 (dwarf_expr_context) <push_address>: Change parameter type to
7623 <fetch_in_stack_memory>: Change return type to bool.
7624 <push>: Change parameter type to bool.
7625 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7627 (dwarf_expr_context::push_address): Likewise.
7628 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7630 (dwarf_expr_context::execute_stack_op): Adjust.
7631 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7633 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7635 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7636 (struct dwarf_expr_context) <n_pieces>: Remove.
7637 <pieces>: Change type to std::vector.
7638 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7639 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7641 (dwarf_expr_context::add_piece): Adjust.
7642 * dwarf2loc.c (struct piece_closure): Initialize fields.
7644 <pieces>: Change type to std::vector.
7645 (allocate_piece_closure): Adjust, change parameter to
7646 std::vector rvalue and std::move it to piece_closure.
7647 (rw_pieced_value): Adjust.
7648 (check_pieced_synthetic_pointer): Adjust.
7649 (indirect_synthetic_pointer): Adjust.
7650 (coerce_pieced_ref): Adjust.
7651 (free_pieced_value_closure): Adjust. Use delete to free
7653 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7654 to allocate_piece_closure.
7655 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7657 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7659 * probe.h (probe_ops_cp): Remove typedef.
7660 (DEF_VEC_P (probe_ops_cp)): Remove.
7661 (all_probe_ops): Change type to std::vector.
7662 * probe.c (info_probes_for_ops): Adjust to vector change.
7663 (probe_linespec_to_ops): Likewise.
7664 (all_probe_ops): Change type to std::vector.
7665 (_initialize_probe): Adjust to vector change.
7666 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7667 * elfread.c (elf_get_probes): Likewise.
7668 * stap-probe.c (_initialize_stap_probe): Likewise.
7670 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7672 * probe.h (struct bound_probe): Define constructors.
7673 * probe.c (bound_probe_s): Remove typedef.
7674 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7675 (collect_probes): Change return type to std::vector, remove
7677 (compare_probes): Return bool, change parameter type. Change
7678 semantic to "less than".
7679 (gen_ui_out_table_header_info): Change parameter to std::vector
7681 (exists_probe_with_pops): Likewise.
7682 (info_probes_for_ops): Update to std::vector change.
7683 (enable_probes_command): Likewise.
7684 (disable_probes_command): Likewise.
7686 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7688 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7690 * probe.c (parse_probes_in_pspace): Update.
7691 (find_probes_in_objfile): Update.
7692 (find_probe_by_pc): Update.
7693 (collect_probes): Update.
7694 (probe_any_get_probes): Update.
7695 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7696 return type to reference to std::vector.
7697 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7698 std::vector and update.
7699 (dtrace_process_dof): Likewise.
7700 (dtrace_get_probes): Likewise.
7701 * elfread.c (elf_get_probes): Change return type to std::vector,
7702 store an std::vector in bfd_data.
7703 (probe_key_free): Update to std::vector.
7704 * stap-probe.c (handle_stap_probe): Change parameter to
7705 std::vector and update.
7706 (stap_get_probes): Likewise.
7707 * symfile-debug.c (debug_sym_get_probes): Change return type to
7708 std::vector and update.
7710 2017-09-11 Tom Tromey <tom@tromey.com>
7712 * breakpoint.c (program_breakpoint_here_p): Update.
7713 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7714 from make_show_memory_breakpoints_cleanup. Return a
7715 scoped_restore_tmpl<int>.
7716 (restore_show_memory_breakpoints): Remove.
7717 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7718 * mem-break.c (memory_validate_breakpoint): Update.
7719 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7720 (ia64_memory_remove_breakpoint): Update.
7721 (ia64_breakpoint_from_pc): Update.
7722 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7723 from make_show_memory_breakpoints_cleanup.
7725 2017-09-11 Tom Tromey <tom@tromey.com>
7727 * d-namespace.c (d_lookup_symbol): Use std::string.
7728 (find_symbol_in_baseclass): Likewise.
7730 2017-09-11 Tom Tromey <tom@tromey.com>
7732 * ctf.c (ctf_start): Use std::string.
7734 2017-09-11 Tom Tromey <tom@tromey.com>
7736 * ada-lang.c (is_known_support_routine): Update.
7737 (ada_unhandled_exception_name_addr_from_raise): Update.
7738 * guile/scm-frame.c (gdbscm_frame_name): Update.
7739 * python/py-frame.c (frapy_name): Update.
7740 (frapy_function): Update.
7741 * stack.h (find_frame_funname): Update.
7742 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7743 (print_frame): Update.
7745 2017-09-11 Tom Tromey <tom@tromey.com>
7747 * findcmd.c (put_bits): Take a gdb::byte_vector.
7748 (parse_find_args): Return gdb::byte_vector. "args" now const.
7749 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7751 (find_command): Update.
7753 2017-09-11 Tom Tromey <tom@tromey.com>
7755 * cli/cli-script.c (class scoped_restore_hook_in): New.
7756 (clear_hook_in_cleanup): Remove.
7757 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7758 scoped_restore_hook_in.
7760 2017-09-11 Tom Tromey <tom@tromey.com>
7762 * cli/cli-script.c (restore_interp): Remove.
7763 (read_command_lines): Use scoped_restore_interp.
7764 * interps.c (scoped_restore_interp::set_temp): Rename from
7766 * interps.h (class scoped_restore_interp): New.
7767 (interp_set_temp): Remove.
7769 2017-09-11 Tom Tromey <tom@tromey.com>
7771 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7772 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7773 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7775 (mi_cmd_break_insert_1): Update.
7776 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7779 2017-09-11 Tom Tromey <tom@tromey.com>
7781 * demangle.c (demangle_command): Update.
7782 * breakpoint.c (disable_command): Update.
7783 (enable_command): Update.
7784 (find_location_by_number): Make "number" const. Use
7786 * cli/cli-utils.c (extract_arg): Return std::string.
7787 * probe.c (parse_probe_linespec): Update. Change types.
7788 (collect_probes): Take string arguments.
7789 (parse_probe_linespec): Likewise.
7790 (info_probes_for_ops): Update.
7791 (enable_probes_command): Update.
7792 (disable_probes_command): Update.
7793 * break-catch-sig.c (catch_signal_split_args): Update.
7794 * mi/mi-parse.c (mi_parse): Update.
7796 2017-09-11 Tom Tromey <tom@tromey.com>
7798 * language.h (language_enum): Make argument const.
7799 * language.c (language_enum): Make argument const.
7801 2017-09-11 Tom Tromey <tom@tromey.com>
7803 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7805 (skip_to_space): Rename from skip_to_space_const.
7806 * common/common-utils.c (skip_to_space): New function.
7807 (skip_to_space): Rename from skip_to_space_const.
7808 * cli/cli-utils.h (get_number): Rename from get_number_const.
7809 (extract_arg): Rename from extract_arg_const.
7810 * cli/cli-utils.c (get_number): Rename from get_number_const.
7811 (extract_arg): Rename from extract_arg_const.
7812 (number_or_range_parser::get_number): Use ::get_number.
7813 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7814 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7815 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7816 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7817 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7818 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7819 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7820 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7822 2017-09-11 Tom Tromey <tom@tromey.com>
7824 * python/python.c (do_start_initialization): Use
7825 py-event-types.def to initialize types.
7826 Define all object type structures.
7827 * python/python-internal.h: Don't declare event initialization
7829 * python/py-threadevent.c (thread_event_object_type): Don't
7831 * python/py-stopevent.c (stop_event_object_type): Don't define.
7832 * python/py-signalevent.c (signal_event_object_type): Don't
7834 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7835 (clear_objfiles_event_object_type): Don't declare or define.
7836 * python/py-infevents.c (inferior_call_pre_event_object_type)
7837 (inferior_call_post_event_object_type)
7838 (register_changed_event_object_type)
7839 (memory_changed_event_object_type): Don't declare or define.
7840 * python/py-inferior.c (new_thread_event_object_type)
7841 (new_inferior_event_object_type)
7842 (inferior_deleted_event_object_type): Don't declare or define.
7843 * python/py-exitedevent.c (exited_event_object_type): Don't
7845 * python/py-evts.c (gdbpy_initialize_py_events): Use
7847 * python/py-events.h (thread_event_object_type): Don't declare.
7848 (events_object): Use py-all-events.def.
7849 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7851 * python/py-event-types.def: New file.
7852 * python/py-continueevent.c (create_continue_event_object): Don't
7854 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7856 * python/py-all-events.def: New file.
7858 2017-09-11 Tom Tromey <tom@tromey.com>
7860 * python/py-threadevent.c (create_thread_event_object): Return
7862 * python/py-stopevent.h (create_stop_event_object)
7863 (create_breakpoint_event_object, create_signal_event_object):
7865 * python/py-stopevent.c (create_stop_event_object): Return
7867 (emit_stop_event): Update.
7868 * python/py-signalevent.c (create_signal_event_object): Return
7870 * python/py-infevents.c (create_inferior_call_event_object):
7872 * python/py-event.h (create_event_object)
7873 (create_thread_event_object): Update.
7874 * python/py-event.c (create_event_object): Return gdbpy_ref.
7875 * python/py-continueevent.c: Return gdbpy_ref.
7876 * python/py-bpevent.c (create_breakpoint_event_object): Return
7879 2017-09-11 Tom Tromey <tom@tromey.com>
7883 * python/python.c (do_start_initialization): Initialize new event
7885 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7886 (gdbpy_initialize_inferior_deleted_event)
7887 (gdbpy_initialize_new_thread_event): Declare.
7888 * python/py-threadevent.c (create_thread_event_object): Add option
7890 * python/py-inferior.c (new_thread_event_object_type)
7891 (new_inferior_event_object_type)
7892 (inferior_deleted_event_object_type): Declare.
7893 (python_new_inferior, python_inferior_deleted): New functions.
7894 (add_thread_object): Emit new_thread event.
7895 (gdbpy_initialize_inferior): Attach new functions to corresponding
7897 (new_thread, new_inferior, inferior_deleted): Define new event
7899 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7901 * python/py-events.h (events_object) <new_inferior,
7902 inferior_deleted, new_thread>: New fields.
7903 * python/py-event.h (create_thread_event_breakpoint): Add optional
7906 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7908 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7909 check current_ui instead.
7910 (internal_vproblem): Likewise.
7912 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7914 * thread.c (print_thread_info_1): Remove unnecessary calls to
7915 uiout->is_mi_like_p.
7917 2017-09-09 Tom Tromey <tom@tromey.com>
7919 * namespace.h (add_using_directive): Update.
7920 * namespace.c (add_using_directive): Change type of excludes to
7922 * dwarf2read.c (read_import_statement): Use std::vector.
7923 (read_namespace): Update.
7924 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
7926 2017-09-09 Tom Tromey <tom@tromey.com>
7928 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
7930 2017-09-09 Tom Tromey <tom@tromey.com>
7932 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
7934 2017-09-09 Tom Tromey <tom@tromey.com>
7936 * stack.c (func_command): Use gdb::def_vector.
7938 2017-09-09 Tom Tromey <tom@tromey.com>
7940 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
7941 ui_out_emit_list, ui_out_emit_tuple.
7942 (mi_cmd_var_update): Likewise.
7944 2017-09-09 Tom Tromey <tom@tromey.com>
7946 * mi/mi-interp.c (mi_user_selected_context_changed): Use
7947 ui_out_redirect_pop.
7948 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7949 ui_out_redirect_pop.
7950 * utils.c (do_ui_out_redirect_pop)
7951 (make_cleanup_ui_out_redirect_pop): Remove.
7952 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
7953 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
7954 * ui-out.h (ui_out_redirect_pop): New class.
7956 2017-09-09 Tom Tromey <tom@tromey.com>
7958 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
7959 (list_available_thread_groups, mi_cmd_list_thread_groups)
7960 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
7961 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
7964 2017-09-09 Tom Tromey <tom@tromey.com>
7966 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
7969 2017-09-09 Tom Tromey <tom@tromey.com>
7971 * target.c (flash_erase_command): Use ui_out_emit_tuple.
7972 * stack.c (print_frame): Use ui_out_emit_tuple.
7973 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
7974 (info_spu_mailbox_command, info_spu_dma_command)
7975 (info_spu_proxydma_command): Likewise.
7976 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
7977 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
7978 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7980 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
7982 2017-09-09 Tom Tromey <tom@tromey.com>
7984 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
7985 (class ui_out_emit_table): Update comment.
7986 * ui-out.c (do_cleanup_table_end)
7987 (make_cleanup_ui_out_table_begin_end): Remove.
7988 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
7989 (info_spu_dma_cmdlist): Likewise.
7990 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
7991 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
7994 2017-09-09 Tom Tromey <tom@tromey.com>
7996 * thread.c (print_thread_info_1): Use ui_out_emit_table,
7997 ui_out_emit_list, gdb::optional.
7999 2017-09-09 John Baldwin <jhb@FreeBSD.org>
8001 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
8003 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
8005 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
8007 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
8008 * ada-exp.y: Remove _initialize_ada_exp prototype.
8009 * ada-lang.c: Remove _initialize_ada_language prototype.
8010 * ada-tasks.c: Remove _initialize_tasks prototype.
8011 * addrmap.c: Remove _initialize_addrmap prototype.
8012 * agent.c: Remove _initialize_agent prototype.
8013 * aix-thread.c: Remove _initialize_aix_thread prototype.
8014 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
8015 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
8016 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
8018 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
8019 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
8020 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
8021 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
8023 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
8025 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
8026 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
8027 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
8028 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
8030 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
8031 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
8032 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
8033 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
8034 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
8035 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
8036 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
8038 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
8040 * annotate.c: Remove _initialize_annotate prototype.
8041 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
8042 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
8043 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
8044 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
8045 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
8046 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
8047 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
8048 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
8050 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
8051 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
8052 * auto-load.c: Remove _initialize_auto_load prototype.
8053 * auxv.c: Remove _initialize_auxv prototype.
8054 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
8055 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
8056 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
8057 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
8058 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
8059 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
8061 * break-catch-throw.c: Remove _initialize_break_catch_throw
8063 * breakpoint.c: Remove _initialize_breakpoint prototype.
8064 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
8065 * btrace.c: Remove _initialize_btrace prototype.
8066 * charset.c: Remove _initialize_charset prototype.
8067 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
8068 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
8069 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
8070 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
8071 * cli/cli-script.c: Remove _initialize_cli_script prototype.
8072 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
8073 * coffread.c: Remove _initialize_coffread prototype.
8074 * compile/compile.c: Remove _initialize_compile prototype.
8075 * complaints.c: Remove _initialize_complaints prototype.
8076 * completer.c: Remove _initialize_completer prototype.
8077 * copying.awk: Remove _initialize_copying prototype.
8078 * copying.c: Regenerate.
8079 * core-regset.c: Remove _initialize_core_regset prototype.
8080 * corefile.c: Remove _initialize_core prototype.
8081 * corelow.c: Remove _initialize_corelow prototype.
8082 * cp-abi.c: Remove _initialize_cp_abi prototype.
8083 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
8084 * cp-support.c: Remove _initialize_cp_support prototype.
8085 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
8086 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
8087 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
8088 * ctf.c: Remove _initialize_ctf prototype.
8089 * d-lang.c: Remove _initialize_d_language prototype.
8090 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
8092 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
8093 * dbxread.c: Remove _initialize_dbxread prototype.
8094 * dcache.c: Remove _initialize_dcache prototype.
8095 * demangle.c: Remove _initialize_demangler prototype.
8096 * disasm-selftests.c: Remove _initialize_disasm_selftests
8098 * disasm.c: Remove _initialize_disasm prototype.
8099 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
8100 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
8101 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
8103 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
8104 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
8105 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
8106 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
8107 * elfread.c: Remove _initialize_elfread prototype.
8108 * exec.c: Remove _initialize_exec prototype.
8109 * extension.c: Remove _initialize_extension prototype.
8110 * f-lang.c: Remove _initialize_f_language prototype.
8111 * f-valprint.c: Remove _initialize_f_valprint prototype.
8112 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
8113 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
8114 * filesystem.c: Remove _initialize_filesystem prototype.
8115 * findcmd.c: Remove _initialize_mem_search prototype.
8116 * fork-child.c: Remove _initialize_fork_child prototype.
8117 * frame-base.c: Remove _initialize_frame_base prototype.
8118 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
8119 * frame.c: Remove _initialize_frame prototype.
8120 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
8121 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
8122 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
8123 * gcore.c: Remove _initialize_gcore prototype.
8124 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
8125 * gdbarch.c: Regenerate.
8126 * gdbarch.sh: Remove _initialize_gdbarch prototype.
8127 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
8128 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
8129 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
8130 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
8131 * go-lang.c: Remove _initialize_go_language prototype.
8132 * go32-nat.c: Remove _initialize_go32_nat prototype.
8133 * guile/guile.c: Remove _initialize_guile prototype.
8134 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
8135 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
8136 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
8137 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
8138 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
8139 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
8140 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
8141 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
8142 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
8143 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
8145 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
8147 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
8148 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
8149 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
8150 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
8151 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
8152 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
8153 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
8154 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
8155 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
8156 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
8157 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
8158 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
8159 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
8160 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
8161 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
8162 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
8164 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
8166 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
8167 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
8168 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
8169 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
8170 * infcall.c: Remove _initialize_infcall prototype.
8171 * infcmd.c: Remove _initialize_infcmd prototype.
8172 * inferior.c: Remove _initialize_inferiors prototype.
8173 * inflow.c: Remove _initialize_inflow prototype.
8174 * infrun.c: Remove _initialize_infrun prototype.
8175 * interps.c: Remove _initialize_interpreter prototype.
8176 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
8177 * jit.c: Remove _initialize_jit prototype.
8178 * language.c: Remove _initialize_language prototype.
8179 * linux-fork.c: Remove _initialize_linux_fork prototype.
8180 * linux-nat.c: Remove _initialize_linux_nat prototype.
8181 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
8182 * linux-thread-db.c: Remove _initialize_thread_db prototype.
8183 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
8184 * m2-lang.c: Remove _initialize_m2_language prototype.
8185 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
8186 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
8187 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
8188 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
8189 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
8190 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8191 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8192 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
8193 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
8194 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
8195 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8196 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8197 * machoread.c: Remove _initialize_machoread prototype.
8198 * macrocmd.c: Remove _initialize_macrocmd prototype.
8199 * macroscope.c: Remove _initialize_macroscope prototype.
8200 * maint.c: Remove _initialize_maint_cmds prototype.
8201 * mdebugread.c: Remove _initialize_mdebugread prototype.
8202 * memattr.c: Remove _initialize_mem prototype.
8203 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
8204 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
8205 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
8206 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
8207 * mi/mi-main.c: Remove _initialize_mi_main prototype.
8208 * microblaze-linux-tdep.c: Remove
8209 _initialize_microblaze_linux_tdep prototype.
8210 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
8211 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
8212 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
8213 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
8214 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
8215 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
8216 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
8217 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
8218 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
8219 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
8220 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
8222 * mipsread.c: Remove _initialize_mipsread prototype.
8223 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
8225 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
8226 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
8227 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
8228 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
8229 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
8230 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
8232 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
8233 * nto-procfs.c: Remove _initialize_procfs prototype.
8234 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
8235 * objc-lang.c: Remove _initialize_objc_language prototype.
8236 * objfiles.c: Remove _initialize_objfiles prototype.
8237 * observer.c: Remove observer_test_first_notification_function,
8238 observer_test_second_notification_function,
8239 observer_test_third_notification_function, and
8240 _initialize_observer prototypes.
8241 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
8242 * osabi.c: Remove _initialize_gdb_osabi prototype.
8243 * osdata.c: Remove _initialize_osdata prototype.
8244 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
8245 * parse.c: Remove _initialize_parse prototype.
8246 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
8247 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
8248 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
8249 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
8250 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
8251 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
8252 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
8253 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
8254 * printcmd.c: Remove _initialize_printcmd prototype.
8255 * probe.c: Remove _initialize_probe prototype.
8256 * proc-api.c: Remove _initialize_proc_api prototype.
8257 * proc-events.c: Remove _initialize_proc_events prototype.
8258 * proc-service.c: Remove _initialize_proc_service prototype.
8259 * procfs.c: Remove _initialize_procfs prototype.
8260 * psymtab.c: Remove _initialize_psymtab prototype.
8261 * python/python.c: Remove _initialize_python prototype.
8262 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
8263 * record-btrace.c: Remove _initialize_record_btrace prototype.
8264 * record-full.c: Remove _initialize_record_full prototype.
8265 * record.c: Remove _initialize_record prototype.
8266 * regcache.c: Remove _initialize_regcache prototype.
8267 * reggroups.c: Remove _initialize_reggroup prototype.
8268 * remote-notif.c: Remove _initialize_notif prototype.
8269 * remote-sim.c: Remove _initialize_remote_sim prototype.
8270 * remote.c: Remove _initialize_remote prototype.
8271 * reverse.c: Remove _initialize_reverse prototype.
8272 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
8273 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
8274 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
8276 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
8277 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
8278 * rust-exp.y: Remove _initialize_rust_exp prototype.
8279 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
8280 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
8281 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
8282 * score-tdep.c: Remove _initialize_score_tdep prototype.
8283 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
8285 * ser-go32.c: Remove _initialize_ser_dos prototype.
8286 * ser-mingw.c: Remove _initialize_ser_windows prototype.
8287 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
8288 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
8289 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
8290 * serial.c: Remove _initialize_serial prototype.
8291 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
8292 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
8293 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
8294 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
8295 * skip.c: Remove _initialize_step_skip prototype.
8296 * sol-thread.c: Remove _initialize_sol_thread prototype.
8297 * solib-aix.c: Remove _initialize_solib_aix prototype.
8298 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
8299 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
8300 * solib-frv.c: Remove _initialize_frv_solib prototype.
8301 * solib-spu.c: Remove _initialize_spu_solib prototype.
8302 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
8303 * solib-target.c: Remove _initialize_solib_target prototype.
8304 * solib.c: Remove _initialize_solib prototype.
8305 * source.c: Remove _initialize_source prototype.
8306 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
8307 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
8309 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
8310 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
8311 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
8312 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
8314 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
8315 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
8316 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
8317 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
8319 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
8321 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
8323 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
8325 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
8326 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
8328 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
8330 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
8332 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
8334 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
8336 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
8337 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
8338 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
8339 * stabsread.c: Remove _initialize_stabsread prototype.
8340 * stack.c: Remove _initialize_stack prototype.
8341 * stap-probe.c: Remove _initialize_stap_probe prototype.
8342 * std-regs.c: Remove _initialize_frame_reg prototype.
8343 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
8344 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
8345 * symfile.c: Remove _initialize_symfile prototype.
8346 * symmisc.c: Remove _initialize_symmisc prototype.
8347 * symtab.c: Remove _initialize_symtab prototype.
8348 * target-dcache.c: Remove _initialize_target_dcache prototype.
8349 * target-descriptions.c: Remove _initialize_target_descriptions
8351 * thread.c: Remove _initialize_thread prototype.
8352 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
8354 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
8355 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
8356 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
8358 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
8359 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
8360 * tracefile.c: Remove _initialize_tracefile prototype.
8361 * tracepoint.c: Remove _initialize_tracepoint prototype.
8362 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
8363 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
8364 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
8365 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
8366 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
8367 * tui/tui-win.c: Remove _initialize_tui_win prototype.
8368 * tui/tui.c: Remove _initialize_tui prototype.
8369 * typeprint.c: Remove _initialize_typeprint prototype.
8370 * user-regs.c: Remove _initialize_user_regs prototype.
8371 * utils.c: Remove _initialize_utils prototype.
8372 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
8373 * valarith.c: Remove _initialize_valarith prototype.
8374 * valops.c: Remove _initialize_valops prototype.
8375 * valprint.c: Remove _initialize_valprint prototype.
8376 * value.c: Remove _initialize_values prototype.
8377 * varobj.c: Remove _initialize_varobj prototype.
8378 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
8379 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
8380 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
8381 * windows-nat.c: Remove _initialize_windows_nat,
8382 _initialize_check_for_gdb_ini, and _initialize_loadable
8384 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
8385 * xcoffread.c: Remove _initialize_xcoffread prototype.
8386 * xml-support.c: Remove _initialize_xml_support prototype.
8387 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
8388 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
8390 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
8392 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
8394 2017-09-08 Keith Seitz <keiths@redhat.com>
8396 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
8399 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
8401 * f-valprint.c (f_val_print): Remove check for one byte
8402 sized integers. Remove printing of character type.
8404 2017-09-08 Frank Penczek <frank.penczek@intel.com>
8405 Christoph Weinmann <christoph.t.weinmann@intel.com>
8406 Bernhard Heckel <bernhard.heckel@intel.com>
8408 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
8409 to maintain proper indentation when printing pointers/refs.
8411 2017-09-07 Joel Brobecker <brobecker@adacore.com>
8415 2017-09-07 Joel Brobecker <brobecker@adacore.com>
8417 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
8419 2017-09-05 Tom Tromey <tom@tromey.com>
8421 * parse.c (funcall_chain): Now a std::vector.
8422 (start_arglist, end_arglist): Simplify.
8423 (free_funcalls): Remove.
8424 (parse_exp_in_context_1): Remove cleanup.
8426 2017-09-05 Tom Tromey <tom@tromey.com>
8428 * go-exp.y (go_parse): Don't create a cleanup.
8430 2017-09-05 Tom Tromey <tom@tromey.com>
8432 * d-exp.y (PrimaryExpression): Use std::string.
8433 (d_parse): Don't create a cleanup.
8435 2017-09-05 Tom Tromey <tom@tromey.com>
8437 * utils.c (do_clear_parser_state): Remove.
8438 (make_cleanup_clear_parser_state): Remove.
8439 * p-exp.y (pascal_parse): Use scoped_restore.
8440 * m2-exp.y (m2_parse): Use scoped_restore.
8441 * f-exp.y (f_parse): Use scoped_restore.
8442 * d-exp.y (d_parse): Use scoped_restore.
8443 * c-exp.y (c_parse): Use scoped_restore.
8444 * ada-exp.y (ada_parse): Use scoped_restore.
8445 * utils.h (make_cleanup_clear_parser_state): Remove.
8447 2017-09-06 Keith Seitz <keiths@redhat.com>
8449 * dwarf2read.c (dw2_linkage_name_attr): New function.
8450 (dw2_linkage_name): New function.
8451 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
8452 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
8453 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
8455 2017-09-06 Kamil Rytarowski <n54@gmx.com>
8457 * config/djgpp/djconfig.sh: Correct shell portability issue.
8459 2017-09-06 Kamil Rytarowski <n54@gmx.com>
8461 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
8463 2017-09-06 John Baldwin <jhb@FreeBSD.org>
8465 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
8466 * NEWS: Mention new FreeBSD/mips native configuration.
8467 * configure.host: Add aarch64*-*-freebsd*.
8468 * configure.nat: Likewise.
8469 * aarch64-fbsd-nat.c: New file.
8471 2017-09-06 John Baldwin <jhb@FreeBSD.org>
8473 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
8474 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
8475 * NEWS: Mention new FreeBSD/aarch64 target.
8476 * configure.tgt: Add aarch64*-*-freebsd*.
8477 * aarch64-fbsd-tdep.c: New file.
8478 * aarch64-fbsd-tdep.h: New file.
8480 2017-09-06 Kamil Rytarowski <n54@gmx.com>
8482 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
8484 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8486 * parse.c (find_minsym_type_and_address): Don't relocate addresses
8489 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8491 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
8494 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8496 * infrun.c (follow_exec): Call add_thread after
8497 target_find_description.
8499 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8501 * infrun.c (handle_inferior_event_1): When exec'ing, read
8502 stop_pc after follow_exec.
8504 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8506 * remote.c (process_g_packet): Update error message.
8508 2017-09-05 Yao Qi <yao.qi@linaro.org>
8510 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
8513 2017-09-05 Pedro Alves <palves@redhat.com>
8515 * eval.c (eval_call, evaluate_funcall): New functions, factored
8517 (evaluate_subexp_standard): ... this.
8519 2017-09-05 Yao Qi <yao.qi@linaro.org>
8521 * amd64-tdep.c (amd64_target_description): Create target
8523 (_initialize_amd64_tdep): Don't call functions
8524 initialize_tdesc_amd64_*. Add self tests.
8525 * arch/amd64.c (amd64_create_target_description): Add parameter
8526 is_linux. Call set_tdesc_osabi if is_linux is true.
8527 * arch/amd64.h (amd64_create_target_description): Update the
8529 * arch/i386.c (i386_create_target_description): Add parameter
8530 is_linux. Call set_tdesc_osabi if is_linux is true.
8531 * arch/i386.h (i386_create_target_description): Update
8533 * configure.tgt: Add i386.o to gdb_target_obs.
8534 * features/Makefile (XMLTOC): Remove i386/*.xml.
8535 * features/i386/amd64-avx-avx512.c: Remove.
8536 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
8537 * features/i386/amd64-avx-mpx.c: Remove.
8538 * features/i386/amd64-avx.c: Remove.
8539 * features/i386/amd64-mpx.c: Remove.
8540 * features/i386/amd64.c: Remove.
8541 * features/i386/i386-avx-avx512.c: Remove.
8542 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
8543 * features/i386/i386-avx-mpx.c: Remove.
8544 * features/i386/i386-avx.c: Remove.
8545 * features/i386/i386-mmx.c: Remove.
8546 * features/i386/i386-mpx.c: Remove.
8547 * features/i386/i386.c: Remove.
8548 * i386-tdep.c: Don't include features/i386/i386*.c., include
8549 target-descriptions.h and arch/i386.h.
8550 (i386_target_description): Create target descriptions.
8551 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
8552 functions. Do self tests.
8554 2017-09-05 Yao Qi <yao.qi@linaro.org>
8556 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
8557 * features/i386/amd64-avx-avx512-linux.c: Removed.
8558 * features/i386/amd64-avx-linux.c: Removed.
8559 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
8560 * features/i386/amd64-avx-mpx-linux.c: Removed.
8561 * features/i386/amd64-linux.c: Removed.
8562 * features/i386/amd64-mpx-linux.c: Removed.
8563 * features/i386/x32-avx-avx512-linux.c: Removed.
8564 * features/i386/x32-avx-linux.c: Removed.
8565 * features/i386/x32-linux.c: Removed.
8567 2017-09-05 Yao Qi <yao.qi@linaro.org>
8569 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8571 (amd64_linux_read_description): Call
8572 amd64_create_target_description.
8573 * arch/amd64.c: New file.
8574 * arch/amd64.h: New file.
8575 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8576 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8578 2017-09-05 Yao Qi <yao.qi@linaro.org>
8580 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8581 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8582 (amd64_linux_read_description): Create target descriptions.
8583 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8584 functions. Add unit tests.
8585 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8587 * features/i386/64bit-avx.c: Generated.
8588 * features/i386/64bit-avx512.c: Generated.
8589 * features/i386/64bit-core.c: Generated.
8590 * features/i386/64bit-linux.c: Generated.
8591 * features/i386/64bit-mpx.c: Generated.
8592 * features/i386/64bit-pkeys.c: Generated.
8593 * features/i386/64bit-segments.c: Generated.
8594 * features/i386/64bit-sse.c: Generated.
8595 * features/i386/x32-core.c: Generated.
8596 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8597 c files for amd64-linux and x32-linux.
8599 2017-09-05 Yao Qi <yao.qi@linaro.org>
8601 * amd64-linux-tdep.c (amd64_linux_read_description): New
8603 (amd64_linux_core_read_description): Call
8604 amd64_linux_read_description.
8605 (amd64_linux_init_abi): Likewise.
8606 (amd64_x32_linux_init_abi): Likewise.
8607 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8608 * x86-linux-nat.c (x86_linux_read_description): Call
8609 amd64_linux_read_description.
8611 2017-09-05 Yao Qi <yao.qi@linaro.org>
8613 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8616 2017-09-05 Yao Qi <yao.qi@linaro.org>
8618 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8619 * features/i386/i386-avx-avx512-linux.c: Remove.
8620 * features/i386/i386-avx-linux.c: Remove.
8621 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8622 * features/i386/i386-avx-mpx-linux.c: Remove.
8623 * features/i386/i386-linux.c: Remove.
8624 * features/i386/i386-mmx-linux.c: Remove.
8625 * features/i386/i386-mpx-linux.c: Remove.
8627 2017-09-05 Yao Qi <yao.qi@linaro.org>
8629 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8630 (SFILES): Add arch/i386.c.
8631 (HFILES_NO_SRCDIR): Add arch/i386.h.
8632 * arch/i386.c: New file.
8633 * arch/i386.h: New file.
8634 * arch/tdesc.h (allocate_target_description): Declare.
8635 (set_tdesc_architecture): Declare.
8636 (set_tdesc_osabi): Declare.
8637 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8638 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8639 include arch/i386.h.
8640 (i386_linux_read_description): Remove code and call
8641 i386_create_target_description.
8642 (set_tdesc_architecture): New function.
8643 (set_tdesc_osabi): New function.
8644 * target-descriptions.h (allocate_target_description): Remove.
8646 2017-09-05 Yao Qi <yao.qi@linaro.org>
8648 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8649 * target-descriptions.c (tdesc_create_feature): Likewise, and
8651 * features/i386/32bit-avx.c: Re-generated.
8652 * features/i386/32bit-avx512.c: Re-generated.
8653 * features/i386/32bit-core.c: Re-generated.
8654 * features/i386/32bit-linux.c: Re-generated.
8655 * features/i386/32bit-mpx.c: Re-generated.
8656 * features/i386/32bit-pkeys.c: Re-generated.
8657 * features/i386/32bit-sse.c: Re-generated.
8659 2017-09-05 Yao Qi <yao.qi@linaro.org>
8661 * regformats/regdef.h (struct reg): Override operator == and !=.
8663 2017-09-05 Yao Qi <yao.qi@linaro.org>
8665 * arch/tdesc.h: New file.
8666 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8667 * target-descriptions.c: Update comments.
8668 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8670 * features/i386/32bit-avx.c: Re-generated.
8671 * features/i386/32bit-avx512.c: Re-generated.
8672 * features/i386/32bit-core.c: Re-generated.
8673 * features/i386/32bit-linux.c: Re-generated.
8674 * features/i386/32bit-mpx.c: Re-generated.
8675 * features/i386/32bit-pkeys.c: Re-generated.
8676 * features/i386/32bit-sse.c: Re-generated.
8678 2017-09-05 Yao Qi <yao.qi@linaro.org>
8680 * regformats/regdat.sh: Update generated code.
8682 2017-09-05 Yao Qi <yao.qi@linaro.org>
8684 * regformats/regdat.sh: Adjust code order.
8686 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8688 * expprint.c (dump_subexp_body_standard): Use constant format
8689 string in fprintf_filtered call.
8691 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8693 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8695 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8697 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8699 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8701 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8703 * bsd-kvm.o: Define _KMEMUSER.
8704 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8705 * configure: Regenerate.
8707 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8709 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8710 * i386-fbsd-nat.c: Likewise.
8712 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8714 * unittests/array-view-selftests.c: Add include of <array>.
8716 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8718 * spu-tdep.c (flush_ea_cache): Add missing argument to
8719 call_function_by_hand.
8721 2017-09-04 Pedro Alves <palves@redhat.com>
8723 * NEWS (Safer support for debugging with no debug info): New.
8725 2017-09-04 Pedro Alves <palves@redhat.com>
8727 * c-exp.y (function_method, function_method_void): Add current
8728 instance flags to TYPE_INSTANCE.
8729 * dwarf2read.c (check_modifier): New.
8730 (compute_delayed_physnames): Assert that only C++ adds delayed
8731 physnames. Mark fn_fields as const/volatile depending on
8733 * eval.c (make_params): New type_instance_flags parameter. Use
8734 it as the new type's instance flags.
8735 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8736 flags element and pass it to make_params.
8737 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8738 instance flags element.
8739 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8740 * gdbtypes.h: Include "enum-flags.h".
8741 (type_instance_flags): New enum-flags type.
8742 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8743 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8744 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8745 (follow_type_instance_flags): New function.
8746 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8747 * parser-defs.h (follow_type_instance_flags): Declare.
8748 * valops.c (value_struct_elt_for_reference): const/volatile must
8751 2017-09-04 Pedro Alves <palves@redhat.com>
8753 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8754 function/method scopes; lookup the nested name as a function local
8757 2017-09-04 Pedro Alves <palves@redhat.com>
8759 (%type <voidval>): Add function_method.
8760 * c-exp.y (exp): New production for calls with no arguments.
8761 (function_method, function_method_void_or_typelist): New
8763 (exp): New production for "method()::static_var".
8764 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8765 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8766 Handle OP_FUNC_STATIC_VAR.
8767 * parse.c (operator_length_standard):
8768 Handle OP_FUNC_STATIC_VAR.
8770 2017-09-04 Pedro Alves <palves@redhat.com>
8772 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8774 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8776 * parse.c (operator_length_standard, operator_check_standard):
8778 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8780 2017-09-04 Pedro Alves <palves@redhat.com>
8782 * ax-gdb.c: Include "typeprint.h".
8783 (gen_expr_for_cast): New function.
8784 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8785 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8787 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8788 nodebug_data_symbol.
8789 * eval.c: Include "typeprint.h".
8790 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8791 Error out if symbol has unknown type.
8792 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8793 evaluate_subexp_for_cast.
8794 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8796 (evaluate_subexp_for_cast): New function.
8797 * gdbtypes.c (init_nodebug_var_type): New function.
8798 (objfile_type): Use it to initialize types of variables with no
8800 * typeprint.c (error_unknown_type): New.
8801 * typeprint.h (error_unknown_type): New declaration.
8802 * compile/compile-c-types.c (convert_type_basic): Handle
8803 TYPE_CODE_ERROR; warn and fallback to int for variables with
8806 2017-09-04 Pedro Alves <palves@redhat.com>
8808 * eval.c (evaluate_var_value): New function, factored out from ...
8809 (evaluate_subexp_standard): ... here.
8811 2017-09-04 Pedro Alves <palves@redhat.com>
8813 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8814 Remove useless assignments to 'op'.
8816 2017-09-04 Pedro Alves <palves@redhat.com>
8818 * eval.c (eval_skip_value): New function.
8819 (evaluate_subexp_standard): Use it.
8821 2017-09-04 Pedro Alves <palves@redhat.com>
8823 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8824 function name from symbol/minsym and pass it to
8825 error_call_unknown_return_type.
8827 2017-09-04 Pedro Alves <palves@redhat.com>
8829 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8830 * ax-gdb.c (gen_msym_var_ref): New function.
8831 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8832 * eval.c (evaluate_var_msym_value): New function.
8833 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8834 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8835 to call_function_by_hand.
8836 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8837 Handle OP_VAR_MSYM_VALUE.
8838 (union exp_element) <msymbol>: New field.
8839 * minsyms.h (struct type): Forward declare.
8840 (find_minsym_type_and_address): Declare.
8841 * parse.c (write_exp_elt_msym): New function.
8842 (write_exp_msymbol): Delete, refactored as ...
8843 (find_minsym_type_and_address): ... this new function.
8844 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8845 (operator_length_standard, operator_check_standard): Handle
8847 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8849 2017-09-04 Pedro Alves <palves@redhat.com>
8851 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8852 TYPE_GNU_IFUNC specially here. Throw error if return type is
8854 * ada-typeprint.c (print_func_type): Handle functions with unknown
8856 * c-typeprint.c (c_type_print_base): Handle functions and methods
8857 with unknown return type.
8858 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8859 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8860 * compile/compile-c-types.c: Include "objfiles.h".
8861 (convert_func): For functions with unknown return type, warn and
8863 * compile/compile-object-run.c (compile_object_run): Adjust call
8864 to call_function_by_hand_dummy.
8865 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8866 call_function_by_hand.
8867 * eval.c (evaluate_subexp_standard): Adjust calls to
8868 call_function_by_hand. Handle functions and methods with unknown
8869 return type. Pass expect_type to call_function_by_hand.
8870 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8872 * gcore.c (call_target_sbrk): Adjust call to
8873 call_function_by_hand.
8874 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8875 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8876 an integer address type instead of nodebug.
8877 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8878 call_function_by_hand.
8879 * infcall.c (error_call_unknown_return_type): New function.
8880 (call_function_by_hand): New "default_return_type" parameter.
8882 (call_function_by_hand_dummy): New "default_return_type"
8883 parameter. Use it instead of defaulting to int. If there's no
8884 default and the return type is unknown, throw an error. If
8885 there's a default return type, and the called function has no
8886 debug info, then assume the function is prototyped.
8887 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8888 New "default_return_type" parameter.
8889 (error_call_unknown_return_type): New declaration.
8890 * linux-fork.c (call_lseek): Cast return type of lseek.
8891 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8892 call_function_by_hand.
8893 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8894 calls to call_function_by_hand.
8895 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8897 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8898 (value_nsstring, print_object_command): Adjust calls to
8899 call_function_by_hand.
8900 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8901 functions with unknown return type.
8902 (pascal_type_print_func_varspec_suffix): New function.
8903 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8904 TYPE_CODE_METHOD>: Use it.
8905 * python/py-value.c (valpy_call): Adjust call to
8906 call_function_by_hand.
8907 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8908 call_function_by_hand.
8909 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8910 call_function_by_hand.
8911 * valops.c (value_allocate_space_in_inferior): Adjust call to
8912 call_function_by_hand.
8913 * typeprint.c (type_print_unknown_return_type): New function.
8914 * typeprint.h (type_print_unknown_return_type): New declaration.
8916 2017-09-04 Pedro Alves <palves@redhat.com>
8918 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
8919 types with more than one parameter as prototyped.
8921 2017-09-04 Pedro Alves <palves@redhat.com>
8923 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
8924 (disassemble_command): Use gdb_disassembly_flags instead of bare
8926 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
8927 (dump_insns, do_mixed_source_and_assembly_deprecated)
8928 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
8929 Use gdb_disassembly_flags instead of bare int.
8930 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
8931 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
8932 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
8933 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
8934 (enum gdb_disassembly_flag): ... values of this new enumeration.
8935 (gdb_disassembly_flags): Define.
8937 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
8938 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
8939 gdb_disassembly_flags instead of bare int.
8940 * record-btrace.c (btrace_insn_history)
8941 (record_btrace_insn_history, record_btrace_insn_history_range)
8942 (record_btrace_insn_history_from): Use gdb_disassembly_flags
8943 instead of bare int.
8944 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
8945 Use gdb_disassembly_flags instead of bare int.
8946 * target-debug.h (target_debug_print_gdb_disassembly_flags):
8948 * target-delegates.c: Regenerate.
8949 * target.c (target_insn_history, target_insn_history_from)
8950 (target_insn_history_range): Use gdb_disassembly_flags instead of
8952 * target.h: Include "disasm.h".
8953 (struct target_ops) <to_insn_history, to_insn_history_from,
8954 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
8956 (target_insn_history, target_insn_history_from)
8957 (target_insn_history_range): Use gdb_disassembly_flags instead of
8960 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8962 * cli/cli-script.c (build_command_line): For if/while commands,
8963 check whether args is empty.
8965 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8967 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
8968 (enum command_control_type): Likewise.
8969 (struct command_line): Likewise.
8970 (free_command_lines): Likewise.
8971 (struct command_lines_deleter): Likewise.
8972 (command_line_up): Likewise.
8973 (read_command_lines): Likewise.
8974 (read_command_lines_1): Likewise.
8975 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
8976 (enum command_control_type): Likewise.
8977 (struct command_line): Likewise.
8978 (free_command_lines): Likewise.
8979 (struct command_lines_deleter): Likewise.
8980 (command_line_up): Likewise.
8981 (read_command_lines): Likewise.
8982 (read_command_lines_1): Likewise.
8983 * breakpoint.h: Include cli/cli-script.h.
8984 * extension-priv.h: Likewise.
8985 * gdbcmd.h: Likewise.
8987 2017-09-04 Pedro Alves <palves@redhat.com>
8989 * ada-lang.c (is_known_support_routine): Move sal declaration to
8990 where it is initialized.
8991 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
8992 (parse_breakpoint_sals, decode_static_tracepoint_spec)
8993 (clear_command, update_static_tracepoint): Remove init_sal
8994 references. Move declarations closer to initializations.
8995 * cli/cli-cmds.c (list_command): Move sal declarations closer to
8997 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
8998 references. Move sal declarations closer to initializations.
8999 * frame.c (find_frame_sal): Return a symtab_and_line via function
9000 return instead of output parameter. Remove init_sal references.
9001 * frame.h (find_frame_sal): Return a symtab_and_line via function
9002 return instead of output parameter.
9003 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
9004 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
9006 (gdbscm_find_pc_line): Remove init_sal reference.
9007 * infcall.c (call_function_by_hand_dummy): Remove init_sal
9008 references. Move declarations closer to initializations.
9009 * infcmd.c (set_step_frame): Update. Move declarations closer to
9011 (finish_backward): Remove init_sal references. Move declarations
9012 closer to initializations.
9013 * infrun.c (process_event_stop_test, handle_step_into_function)
9014 (insert_hp_step_resume_breakpoint_at_frame)
9015 (insert_step_resume_breakpoint_at_caller): Likewise.
9016 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
9017 (symbol_to_sal): Likewise.
9018 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
9019 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
9020 to its initialization.
9021 * reverse.c (save_bookmark_command): Use new/delete. Remove
9022 init_sal references. Move declarations closer to initializations.
9023 * source.c (get_current_source_symtab_and_line): Remove brace
9025 (set_current_source_symtab_and_line): Now takes the sal by const
9026 reference. Remove brace initialization.
9027 (line_info): Remove init_sal reference.
9028 * source.h (set_current_source_symtab_and_line): Now takes a
9029 symtab_and_line via const reference.
9030 * stack.c (set_current_sal_from_frame): Adjust.
9031 (print_frame_info): Adjust.
9032 (get_last_displayed_sal): Return the sal via function return
9033 instead of via output parameter. Simplify.
9034 (frame_info): Adjust.
9035 * stack.h (get_last_displayed_sal): Return the sal via function
9036 return instead of via output parameter.
9037 * symtab.c (init_sal): Delete.
9038 (find_pc_sect_line): Remove init_sal references. Move
9039 declarations closer to initializations.
9040 (find_function_start_sal): Remove init_sal references. Move
9041 declarations closer to initializations.
9042 * symtab.h (struct symtab_and_line): In-class initialize all
9044 * tracepoint.c (set_traceframe_context)
9045 (print_one_static_tracepoint_marker): Remove init_sal references.
9046 Move declarations closer to initializations.
9047 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
9048 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
9049 declarations closer to initializations.
9050 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
9051 init_sal references. Adjust.
9053 2017-09-04 Pedro Alves <palves@redhat.com>
9055 * ax-gdb.c (agent_command_1): Use range-for.
9056 * break-catch-throw.c (re_set_exception_catchpoint): Update.
9057 * breakpoint.c: Include "common/array-view.h".
9058 (init_breakpoint_sal, create_breakpoint_sal): Change sals
9059 parameter from struct symtabs_and_lines to
9060 array_view<symtab_and_line>. Adjust. Use range-for. Update.
9061 (breakpoint_sals_to_pc): Change sals parameter from struct
9062 symtabs_and_lines to std::vector reference.
9063 (check_fast_tracepoint_sals): Change sals parameter from struct
9064 symtabs_and_lines to std::array_view. Use range-for.
9065 (decode_static_tracepoint_spec): Return a std::vector instead of
9066 symtabs_and_lines. Update.
9067 (create_breakpoint): Update.
9068 (break_range_command, until_break_command, clear_command): Update.
9069 (base_breakpoint_decode_location, bkpt_decode_location)
9070 (bkpt_probe_create_sals_from_location)
9071 (bkpt_probe_decode_location, tracepoint_decode_location)
9072 (tracepoint_probe_decode_location)
9073 (strace_marker_create_sals_from_location): Return a std::vector
9074 instead of symtabs_and_lines.
9075 (strace_marker_create_breakpoints_sal): Update.
9076 (strace_marker_decode_location): Return a std::vector instead of
9077 symtabs_and_lines. Update.
9078 (update_breakpoint_locations): Change struct symtabs_and_lines
9079 parameters to gdb::array_view. Adjust.
9080 (location_to_sals): Return a std::vector instead of
9081 symtabs_and_lines. Update.
9082 (breakpoint_re_set_default): Use std::vector instead of struct
9084 (decode_location_default): Return a std::vector instead of
9085 symtabs_and_lines. Update.
9086 * breakpoint.h: Include "common/array-view.h".
9087 (struct breakpoint_ops) <decode_location>: Now returns a
9088 std::vector instead of returning a symtabs_and_lines via output
9090 (update_breakpoint_locations): Change sals parameters to use
9092 * cli/cli-cmds.c (edit_command, list_command): Update to use
9093 std::vector and gdb::array_view.
9094 (ambiguous_line_spec): Adjust to use gdb::array_view and
9096 (compare_symtabs): Rename to ...
9097 (cmp_symtabs): ... this. Change parameters to symtab_and_line
9098 const reference and adjust.
9099 (filter_sals): Rewrite using std::vector and standard algorithms.
9100 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
9101 (jump_command): Update to use std::vector.
9102 * linespec.c (struct linespec_state) <canonical_names>: Update
9104 (add_sal_to_sals_basic): Delete.
9105 (add_sal_to_sals, filter_results, convert_results_to_lsals)
9106 (decode_line_2, create_sals_line_offset)
9107 (convert_address_location_to_sals, convert_linespec_to_sals)
9108 (convert_explicit_location_to_sals, parse_linespec)
9109 (event_location_to_sals, decode_line_full, decode_line_1)
9110 (decode_line_with_current_source)
9111 (decode_line_with_last_displayed, decode_objc)
9112 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
9113 (linespec_result::~linespec_result): Adjust to use std::vector
9114 instead of symtabs_and_lines.
9115 * linespec.h (linespec_sals::sals): Now a std::vector.
9116 (struct linespec_result): Use std::vector, bool, and in-class
9118 (decode_line_1, decode_line_with_current_source)
9119 (decode_line_with_last_displayed): Return std::vector.
9120 * macrocmd.c (info_macros_command): Use std::vector.
9121 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
9122 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
9124 * probe.h (parse_probes): Return a std::vector.
9125 * python/python.c (gdbpy_decode_line): Use std::vector and
9127 * source.c (select_source_symtab, line_info): Use std::vector.
9128 * stack.c (func_command): Use std::vector.
9129 * symtab.h (struct symtabs_and_lines): Delete.
9130 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
9132 2017-09-04 Pedro Alves <palves@redhat.com>
9134 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9135 unittests/array-view-selftests.c.
9136 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
9137 * common/array-view.h: New file.
9138 * unittests/array-view-selftests.c: New file.
9140 2017-09-04 Pedro Alves <palves@redhat.com>
9142 * cli/cli-cmds.c (edit_command): Pass message to
9143 ambiguous_line_spec.
9144 (list_command): Pass message to ambiguous_line_spec. Say
9145 "first"/"last" instead of "start" and "end" to be consistent with
9147 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
9148 them to print formatted message.
9150 2017-09-04 Pedro Alves <palves@redhat.com>
9152 * btrace.c (ftrace_add_pt): Pass btrace_insn to
9153 ftrace_update_insns by reference instead of pointer.
9155 2017-09-04 Yao Qi <yao.qi@linaro.org>
9157 * i386-go32-tdep.c: Include x86-xstate.h.
9158 (i386_go32_init_abi): Call i386_target_description.
9159 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
9160 if xcr0 is X86_XSTATE_X87_MASK.
9161 * i386-tdep.h (tdesc_i386): Remove the declaration.
9162 (tdesc_i386_mmx): Likewise.
9164 2017-09-04 Yao Qi <yao.qi@linaro.org>
9166 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
9167 X86_XSTATE_SSE_MASK instead of 0.
9169 2017-09-04 Yao Qi <yao.qi@linaro.org>
9171 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
9172 i386_target_description.
9173 * i386-fbsd-nat.c (i386fbsd_read_description): Call
9174 i386_target_description.
9175 * i386-tdep.c (i386_gdbarch_init): Likewise.
9177 2017-09-04 Yao Qi <yao.qi@linaro.org>
9179 * amd64-darwin-tdep.c: Include "x86-xstate.h".
9180 (x86_darwin_init_abi_64): Call amd64_target_description.
9181 * amd64-dicos-tdep.c: Likewise.
9182 * amd64-fbsd-nat.c: Likewise.
9183 * amd64-fbsd-tdep.c: Likewise.
9184 * amd64-nbsd-tdep.c: Likewise.
9185 * amd64-obsd-tdep.c: Likewise.
9186 * amd64-sol2-tdep.c: Likewise.
9187 * amd64-windows-tdep.c: Likewise.
9188 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
9190 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
9192 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
9193 (btrace_function) <insn>: Change type to use std::vector.
9194 * btrace.c (ftrace_debug, ftrace_call_num_insn,
9195 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
9196 ftrace_update_insns, ftrace_compute_global_level_offset,
9197 btrace_stitch_bts, btrace_clear, btrace_insn_get,
9198 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
9199 change to std::vector.
9200 (ftrace_update_insns): Adjust to change to std::vector, change
9201 type of INSN parameter.
9202 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
9203 * record-btrace.c (btrace_call_history_insn_range,
9204 btrace_compute_src_line_range,
9205 record_btrace_frame_prev_register): Adjust to change to
9207 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
9208 to change to std::vector.
9210 2017-09-03 Tom Tromey <tom@tromey.com>
9212 * corefile.c (reopen_exec_file): Use std::string.
9214 2017-09-03 Tom Tromey <tom@tromey.com>
9216 * compile/compile.c (compile_register_name_mangled): Return
9218 * compile/compile-loc2c.c (pushf_register_address): Update.
9219 (pushf_register): Update.
9220 * compile/compile-c-types.c (convert_array): Update.
9221 * compile/compile-c-symbols.c (generate_vla_size): Update.
9222 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
9223 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
9224 (convert_one_symbol): Update.
9225 (generate_c_for_for_one_variable): Update.
9226 * compile/compile-c-support.c (c_get_range_decl_name): Return a
9228 (generate_register_struct): Update.
9229 * compile/compile-internal.h (c_get_range_decl_name): Return a
9231 (compile_register_name_mangled): Return std::string.
9233 2017-09-03 Tom Tromey <tom@tromey.com>
9235 * utils.c (perror_string): Return a std::string.
9236 (throw_perror_with_name, perror_warning_with_name): Update.
9238 2017-09-03 Tom Tromey <tom@tromey.com>
9240 * demangle.c (demangle_command): Use std::string,
9243 2017-09-03 Tom Tromey <tom@tromey.com>
9245 * cli/cli-setshow.c (do_set_command): Use std::string.
9247 2017-09-03 Tom Tromey <tom@tromey.com>
9249 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
9251 2017-09-03 Tom Tromey <tom@tromey.com>
9253 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
9255 2017-09-03 Tom Tromey <tom@tromey.com>
9257 * mi/mi-cmd-env.c (env_execute_cli_command): Use
9258 gdb::unique_xmalloc_ptr.
9260 2017-09-03 Tom Tromey <tom@tromey.com>
9262 * thread.c (print_thread_info_1): Use string_printf.
9263 (thread_apply_command, thread_apply_all_command): Use
9266 2017-09-03 Tom Tromey <tom@tromey.com>
9268 * valprint.c (val_print_string): Update.
9269 * gdbcore.h (memory_error_message): Return std::string.
9270 * corefile.c (memory_error_message): Return std::string.
9271 (memory_error): Update.
9272 * breakpoint.c (insert_bp_location): Update.
9274 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
9276 * target/waitstatus.h (target_waitstatus_to_string): Change
9277 return type to std::string.
9278 * target/waitstatus.c (target_waitstatus_to_string): Return
9280 * target.h (target_waitstatus_to_string): Remove declaration.
9281 * infrun.c (resume, clear_proceed_status_thread,
9282 print_target_wait_results, do_target_wait, save_waitstatus,
9283 stop_all_threads): Adjust.
9284 * record-btrace.c (record_btrace_wait): Adjust.
9286 (target_debug_print_struct_target_waitstatus_p): Adjust.
9288 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
9291 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
9294 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
9296 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
9297 for setting/unsetting environment variables on the remote target.
9298 (New remote packets): Add entries for QEnvironmentHexEncoded,
9299 QEnvironmentUnset and QEnvironmentReset.
9300 * common/environ.c (gdb_environ::operator=): Extend method to
9301 handle m_user_set_env_list and m_user_unset_env_list.
9302 (gdb_environ::clear): Likewise.
9303 (match_var_in_string): Change type of first parameter from 'char
9304 *' to 'const char *'.
9305 (gdb_environ::set): Extend method to handle
9306 m_user_set_env_list and m_user_unset_env_list.
9307 (gdb_environ::unset): Likewise.
9308 (gdb_environ::clear_user_set_env): New method.
9309 (gdb_environ::user_set_envp): Likewise.
9310 (gdb_environ::user_unset_envp): Likewise.
9311 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
9312 m_user_unset_env_list on move constructor/assignment.
9313 (unset): Add new default parameter 'update_unset_list = true'.
9314 (clear_user_set_env): New method.
9315 (user_set_envp): Likewise.
9316 (user_unset_envp): Likewise.
9317 (m_user_set_env_list): New std::set.
9318 (m_user_unset_env_list): Likewise.
9319 * common/rsp-low.c (hex2str): New function.
9320 (bin2hex): New overload for bin2hex function.
9321 * common/rsp-low.c (hex2str): New prototype.
9322 (str2hex): New overload prototype.
9323 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
9324 QEnvironmentUnset and QEnvironmentReset.
9325 (remote_protocol_features): Add QEnvironmentHexEncoded,
9326 QEnvironmentUnset and QEnvironmentReset packets.
9327 (send_environment_packet): New function.
9328 (extended_remote_environment_support): Likewise.
9329 (extended_remote_create_inferior): Call
9330 extended_remote_environment_support.
9331 (_initialize_remote): Add QEnvironmentHexEncoded,
9332 QEnvironmentUnset and QEnvironmentReset packet configs.
9333 * unittests/environ-selftests.c (gdb_selftest_env_var):
9335 (test_vector_initialization): New function.
9336 (test_init_from_host_environ): Likewise.
9337 (test_reinit_from_host_environ): Likewise.
9338 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
9340 (test_unset_set_empty_vector): Likewise.
9341 (test_vector_clear): Likewise.
9342 (test_std_move): Likewise.
9343 (test_move_constructor):
9344 (test_self_move): Likewise.
9345 (test_set_unset_reset): Likewise.
9346 (run_tests): Rewrite in terms of the functions above.
9348 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
9350 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
9351 (adi_available): Use a temp variable of type CORE_ADDR as argument
9352 3 when calling target_auxv_search.
9353 (adi_normalize_address): Use masks and xor operators to calculate
9355 (adi_read_versions, adi_write_versions, adi_print_versions)
9356 (do_examine, do_assign): Use paddress.
9358 2017-08-29 John Baldwin <jhb@FreeBSD.org>
9360 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
9361 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
9362 out of loop and add supply of FIR.
9363 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
9366 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
9369 * cli/cli-script.c (define_command): Don't convert command name
9372 2017-08-25 Joel Brobecker <brobecker@adacore.com>
9374 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
9375 Update all callers accordingly. Remove all code blocks handling
9376 the case where DISPP is not NULL.
9378 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9381 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
9382 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9383 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
9385 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9387 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
9388 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
9389 (read_comp_units_from_section): New parameter abbrev_section, use
9390 read_and_check_comp_unit_head, allocate signatured_type if needed.
9391 (create_all_comp_units): Update read_comp_units_from_section caller.
9393 2017-08-23 Pedro Alves <palves@redhat.com>
9396 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
9397 to null_ptid and switch to thread without reading the registers
9398 after adding the inferior.
9400 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9402 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
9404 * compile/compile.c (compile_gcc, show_compile_gcc): New.
9405 (compile_to_object): Implement compile_gcc.
9406 (_initialize_compile): Install "set compile-gcc". Initialize
9409 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9411 * compile/compile.c (compile_to_object): Conditionally call
9412 set_verbose. Conditionally call compile or compile_v0.
9414 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
9416 * sparc64-tdep.h: (adi_normalize_address): New export.
9417 * sparc-nat.h: (open_adi_tag_fd): New export.
9418 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
9419 * sparc64-linux-tdep.c:
9420 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
9421 (sparc64_linux_handle_segmentation_fault): New function.
9422 (sparc64_linux_init_abi): Register
9423 sparc64_linux_handle_segmentation_fault
9424 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
9425 (sparc64_addr_bits_remove): New function.
9426 (sparc64_init_abi): Register sparc64_addr_bits_remove.
9427 (MAX_PROC_NAME_SIZE): New macro.
9428 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
9429 (sparc64adilist): New variable.
9430 (adi_proc_list): New variable.
9431 (find_adi_info): New function.
9432 (add_adi_info): New function.
9433 (get_adi_info_proc): New function.
9434 (get_adi_info): New function.
9435 (info_adi_command): New function.
9436 (read_maps_entry): New function.
9437 (adi_available): New function.
9438 (adi_normalize_address): New function.
9439 (adi_align_address): New function.
9440 (adi_convert_byte_count): New function.
9441 (adi_tag_fd): New function.
9442 (adi_is_addr_mapped): New function.
9443 (adi_read_versions): New function.
9444 (adi_write_versions): New function.
9445 (adi_print_versions): New function.
9446 (do_examine): New function.
9447 (do_assign): New function.
9448 (adi_examine_command): New function.
9449 (adi_assign_command): New function.
9450 (_initialize_sparc64_adi_tdep): New function.
9452 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
9454 * breakpoint.c (breakpoints_info): Rename to ...
9455 (info_breakpoints_command): ... this.
9456 (watchpoints_info): Rename to ...
9457 (info_watchpoints_command): ... this.
9458 (tracepoints_info): Rename to ...
9459 (info_tracepoints_command): ... this.
9460 (_initialize_breakpoint): Adjust.
9461 * dcache.c (dcache_info): Rename to ...
9462 (info_display_command): ... this.
9463 (_initialize_dcache): Adjust.
9464 * frame.h (args_info): Rename to ...
9465 (info_args_command): ... this.
9466 (locals_info): Rename to ...
9467 (info_locals_command): ... this.
9468 * infcmd.c (nofp_registers_info): Rename to ...
9469 (info_registers_command): ... this.
9470 (float_info): Rename to ...
9471 (info_float_command): ... this.
9472 (program_info): Rename to ...
9473 (info_program_command): ... this.
9474 (all_registers_info): Rename to ...
9475 (info_all_registers_command): ... this.
9476 (vector_info): Rename to ...
9477 (info_vector_command): ... this.
9478 (float_info): Rename to ...
9479 (info_float_command): ... this.
9480 (_initialize_infcmd): Adjust.
9481 * inferior.h (term_info): Rename to ...
9482 (info_terminal_command): ... this.
9483 * inflow.c (term_info): Rename to ...
9484 (info_terminal_command): ... this.
9485 (_initialize_inflow): Adjust.
9486 * infrun.c (signals_info): Rename to ...
9487 (info_signals_command): ... this.
9488 (_initialize_infrun): Adjust.
9489 * objc-lang.c (classes_info): Rename to ...
9490 (info_classes_command): ... this.
9491 (selectors_info): Rename to ...
9492 (info_selectors_command): ... this.
9493 (_initialize_objc_language): Adjust.
9494 * printcmd.c (sym_info): Rename to ...
9495 (info_symbol_command): ... this.
9496 (address_info): Rename to ...
9497 (info_address_command): ... this.
9498 (display_info): Rename to ...
9499 (info_display_command): ... this.
9500 (_initialize_printcmd): Adjust.
9501 * reverse.c (bookmarks_info): Rename to ...
9502 (info_breakpoints_command): ... this.
9503 (_initialize_reverse): Adjust.
9504 * ser-go32.c (dos_info): Rename to ...
9505 (info_serial_command): ... this.
9506 (_initialize_ser_dos): Adjust.
9507 * skip.c (skip_info): Rename to ...
9508 (info_skip_command): ... this.
9509 (_initialize_step_skip): Adjust.
9510 * source.c (line_info): Rename to ...
9511 (info_line_command): ... this.
9512 (source_info): Rename to ...
9513 (info_source_command)
9514 * stack.c (frame_info): Rename to ...
9515 (info_frame_command): ... this.
9516 (locals_info): Rename to ...
9517 (info_locals_command): ... this.
9518 (args_info): Rename to ...
9519 (info_args_command): ... this.
9520 (_initialize_stack): Adjust.
9521 * symtab.c (sources_info): Rename to ...
9522 (info_sources_command): ... this.
9523 (variables_info): Rename to ...
9524 (info_variables_command): ... this.
9525 (functions_info): Rename to ...
9526 (info_functions_command): ... this.
9527 (types_info): Rename to ...
9528 (info_types_command): ... this.
9529 (_initialize_symtab): Adjust.
9530 * target.c (target_info): Rename to ...
9531 (info_target_command): ... this.
9532 (initialize_targets): Adjust.
9533 * tracepoint.c (tvariables_info): Rename to ...
9534 (info_tvariables_command): ... this.
9535 (scope_info): Rename to ...
9536 (info_scope_command): ... this.
9537 (trace_dump_actions): Adjust.
9538 (_initialize_tracepoint): Adjust.
9540 2017-08-22 Tom Tromey <tom@tromey.com>
9542 * breakpoint.h (install_breakpoint): Update.
9543 * breakpoint.c (add_solib_catchpoint): Update.
9544 (install_breakpoint): Change argument to a std::unique_ptr.
9545 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
9546 (create_breakpoint_sal, create_breakpoint): Update.
9547 (watch_command_1, catch_exec_command_1)
9548 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
9549 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
9550 Return the breakpoint.
9551 (set_raw_breakpoint_without_location, set_raw_breakpoint)
9552 (new_single_step_breakpoint): Update.
9553 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
9555 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9557 * break-catch-sig.c (create_signal_catchpoint): Use
9559 * ada-lang.c (create_ada_exception_catchpoint): Use
9562 2017-08-22 Tom Tromey <tom@tromey.com>
9564 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
9566 2017-08-22 Tom Tromey <tom@tromey.com>
9568 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9569 (lookup_partial_symbol): Update.
9571 2017-08-22 Tom Tromey <tom@tromey.com>
9573 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9574 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9575 (find_and_open_source, symtab_to_fullname): Update.
9576 * psymtab.c (psymtab_to_fullname): Update.
9578 2017-08-22 Tom Tromey <tom@tromey.com>
9580 * exec.c (exec_file_attach): Update.
9581 * linux-thread-db.c (try_thread_db_load): Update.
9582 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9583 * utils.c (gdb_realpath): Change return type.
9584 (gdb_realpath_keepfile): Update.
9585 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9586 (_initialize_utils): Register the new self test.
9587 * source.c (openp): Update.
9588 (find_and_open_source): Update.
9589 * nto-tdep.c (nto_find_and_open_solib): Update.
9590 * main.c (set_gdb_data_directory): Update.
9591 (captured_main_1): Update.
9592 * dwarf2read.c (dwarf2_get_dwz_file): Update
9593 (dw2_map_symbol_filenames): Update.
9594 * auto-load.c (auto_load_safe_path_vec_update): Update.
9595 (filename_is_in_auto_load_safe_path_vec): Change type of
9597 (auto_load_objfile_script): Update.
9598 (file_is_auto_load_safe): Update. Use std::string.
9599 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9601 2017-08-22 Tom Tromey <tom@tromey.com>
9603 * utils.c (gdb_realpath_keepfile): Return a
9604 gdb::unique_xmalloc_ptr.
9605 * exec.c (exec_file_attach): Update.
9606 * utils.h (gdb_realpath_keepfile): Return a
9607 gdb::unique_xmalloc_ptr.
9609 2017-08-22 Tom Tromey <tom@tromey.com>
9611 * compile/compile.c (compile_file_command): Use
9612 gdb::unique_xmalloc_ptr, std::string.
9613 * utils.c (gdb_abspath): Change return type.
9614 * source.c (openp): Update.
9615 * objfiles.c (allocate_objfile): Update.
9616 * main.c (set_gdb_data_directory): Update.
9617 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9619 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9621 * cli-cmds.c (list_commands): List actual code around more than
9624 2017-08-21 John Baldwin <jhb@FreeBSD.org>
9626 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9628 2017-08-21 Pedro Alves <palves@redhat.com>
9631 * c-exp.y (variable production): Handle function aliases.
9632 * minsyms.c (msymbol_is_text): New function.
9633 * minsyms.h (msymbol_is_text): Declare.
9634 * symtab.c (find_function_alias_target): New function.
9635 * symtab.h (find_function_alias_target): Declare.
9637 2017-08-21 Pedro Alves <palves@redhat.com>
9639 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9641 * typeprint.c (whatis_exp): If handling "whatis", and expression
9642 is OP_TYPE, strip one typedef level. Otherwise don't strip
9644 * valops.c (value_cast): Save "to" type before resolving
9645 stubs/typedefs. Use that type as resulting value's type.
9647 2017-08-18 Tom Tromey <tom@tromey.com>
9648 Pedro Alves <palves@redhat.com>
9650 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9651 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9652 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9653 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9654 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9655 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9656 (linux_get_siginfo_data): Add "thread" argument. Use
9658 * linux-nat.c (linux_child_follow_fork)
9659 (check_stopped_by_watchpoint): Use scoped_restore.
9660 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9661 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9662 (restore_inferior_ptid, save_inferior_ptid): Remove.
9663 * btrace.c (btrace_fetch): Use scoped_restore.
9664 * bsd-uthread.c (bsd_uthread_fetch_registers)
9665 (bsd_uthread_store_registers): Use scoped_restore.
9666 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9668 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9669 (aix_thread_xfer_partial): Use scoped_restore.
9670 * inferior.h (save_inferior_ptid): Remove.
9672 2017-08-18 Yao Qi <yao.qi@linaro.org>
9675 * arm-tdep.c (gdb_print_insn_arm): Mark
9676 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9678 2017-08-18 Yao Qi <yao.qi@linaro.org>
9680 * NEWS: Mention GDBserver's new option "--selftest".
9681 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9682 * selftest.c: Move it to common/selftest.c.
9683 * selftest.h: Move it to common/selftest.h.
9684 * selftest-arch.c (reset): New function.
9685 (tests_with_arch): Call reset.
9687 2017-08-18 Yao Qi <yao.qi@linaro.org>
9689 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9690 instead of exception_fprintf and printf_filtered.
9692 2017-08-18 Yao Qi <yao.qi@linaro.org>
9694 * selftest.c (register_self_test): Rename it to
9695 selftests::register_test.
9696 (run_self_tests): selftest::run_tests.
9697 * selftest.h: Update declarations.
9698 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9699 selftests::register_test_foreach_arch.
9700 * selftest-arch.h: Update declaration.
9701 * aarch64-tdep.c: Update.
9702 * arm-tdep.c: Likewise.
9703 * disasm-selftests.c: Likewise.
9704 * dwarf2loc.c: Likewise.
9705 * dwarf2-frame.c: Likewise.
9706 * findvar.c: Likewise.
9707 * gdbarch-selftests.c: Likewise.
9708 * maint.c (maintenance_selftest): Likewise.
9709 * regcache.c: Likewise.
9710 * rust-exp.y: Likewise.
9711 * selftest-arch.c: Likewise.
9712 * unittests/environ-selftests.c: Likewise.
9713 * unittests/function-view-selftests.c: Likewise.
9714 * unittests/offset-type-selftests.c: Likewise.
9715 * unittests/optional-selftests.c: Likewise.
9716 * unittests/scoped_restore-selftests.c: Likewise.
9717 * utils-selftests.c: Likewise.
9719 2017-08-17 Pedro Alves <palves@redhat.com>
9721 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9724 2017-08-17 Pedro Alves <palves@redhat.com>
9726 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9728 (reset_die_in_process): Delete, replaced by ...
9729 (process_die_scope): ... this new class. Make it responsible for
9730 freeing cu->line_header too.
9731 (process_die): Use process_die_scope.
9732 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9733 cu->line_header_die_owner. Don't release the line header if it's
9735 (setup_type_unit_groups): Make the CU/DIE own the line header.
9736 Don't release the line header here.
9738 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9740 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9742 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9744 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9747 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9749 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9752 2017-08-15 Stafford Horne <shorne@gmail.com>
9754 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9756 2017-08-15 Stafford Horne <shorne@gmail.com>
9758 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9760 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9763 * infcmd.c (unset_environment_command): Use the 'clear' method on
9764 the environment instead of resetting it.
9766 2017-08-15 John Baldwin <jhb@FreeBSD.org>
9768 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9771 2017-08-14 Tom Tromey <tom@tromey.com>
9773 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9774 (print_binary_chars): Likewise.
9775 (BITS_IN_BYTES): Remove.
9777 2017-08-14 Tom Tromey <tom@tromey.com>
9780 * valprint.c (LOW_ZERO): Change value to 034.
9781 (print_octal_chars): Add static_asserts for octal constants.
9782 * printcmd.c (print_scalar_formatted): Add 'd' case.
9784 2017-08-11 Tom Tromey <tom@tromey.com>
9786 * symfile.c (add_symbol_file_command): Use std::vector.
9788 2017-08-14 Tom Tromey <tom@tromey.com>
9790 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9791 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9793 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9795 2017-08-11 Pedro Alves <palves@redhat.com>
9797 * infrun.c (process_event_stop_test): Adjust
9798 function_name_is_marked_for_skip call.
9799 * skip.c: Include <list>.
9800 (skiplist_entry): Make it a class with private fields, and
9802 (skiplist_entry_chain): Delete.
9803 (skiplist_entries): New.
9804 (skiplist_entry_count): Delete.
9805 (highest_skiplist_entry_num): New.
9806 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9807 (add_skiplist_entry): Delete.
9808 (skiplist_entry::skiplist_entry): New.
9809 (skiplist_entry::add_entry): New.
9810 (skip_file_command, skip_function): Adjust.
9811 (compile_skip_regexp): Delete.
9812 (skip_command): Don't compile regexp here. Adjust to use
9813 skiplist_entry::add_entry.
9814 (skip_info): Adjust to use range-for and getters.
9815 (skip_enable_command, skip_disable_command): Adjust to use
9816 range-for and setters.
9817 (skip_delete_command): Adjust to use std::list.
9818 (add_skiplist_entry): Delete.
9819 (skip_file_p): Delete, refactored as ...
9820 (skiplist_entry::do_skip_file_p): ... this new method.
9821 (skip_gfile_p): Delete, refactored as ...
9822 (skiplist_entry::do_gskip_file_p): ... this new method.
9823 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9824 (skiplist_entry::skip_function_p): ... this new method.
9825 (function_name_is_marked_for_skip): Now returns bool, and takes
9826 the function sal by const reference. Adjust to use range-for and
9827 skiplist_entry methods.
9828 (_initialize_step_skip): Remove references to
9829 skiplist_entry_chain, skiplist_entry_count.
9830 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9831 takes the function sal by const reference.
9833 2017-08-11 Yao Qi <yao.qi@linaro.org>
9835 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9836 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9837 (dwarf2_frame_cache):
9838 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9839 RETURN_MASK_ALL and set *this_case to NULL.
9840 * frame-unwind.h: Update comments.
9842 2017-08-11 Yao Qi <yao.qi@linaro.org>
9844 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9845 (dwarf2_frame_state_copy_regs): Remove.
9846 (dwarf2_frame_state_free_regs): Remove.
9847 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9848 (dwarf2_restore_rule): Call method .alloc_regs instead of
9849 dwarf2_frame_state_alloc_regs.
9850 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9851 constructor. Call std::move.
9852 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9853 (dwarf2_frame_cache): Likewise.
9855 [GDB_SELF_TEST]: Include selftest.h and
9857 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9858 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9859 execute_cfa_program_test.
9861 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9862 copy ctor, assignment operator, move assignment.
9863 <alloc_regs>: New method.
9865 (struct dwarf2_frame_state): Delete dtor.
9866 (dwarf2_frame_state_alloc_regs): Remove declaration.
9867 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9868 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9870 2017-08-11 Yao Qi <yao.qi@linaro.org>
9872 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9873 (dwarf2_frame_state::dwarf2_frame_state): New.
9874 (dwarf2_frame_state::~dwarf2_frame_state): New.
9875 (dwarf2_fetch_cfa_info): Update.
9876 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9877 rather than a pointer. Update code.
9878 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9880 <data_align, code_align, retaddr_column>: Change them to const.
9881 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9884 2017-08-11 Yao Qi <yao.qi@linaro.org>
9886 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9887 <loc.exp>: New field.
9888 * dwarf2-frame.c (execute_cfa_program): Update.
9889 (dwarf2_frame_prev_register): Update.
9891 2017-08-10 Pedro Alves <palves@redhat.com>
9893 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9895 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9897 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9898 (fbsd_pending_children): Use std::list.
9899 (fbsd_remember_child): Likewise.
9900 (fbsd_is_child_pending): Likewise.
9901 (fbsd_pending_vfork_done): Use std::forward_list.
9902 (fbsd_add_vfork_done): Likewise.
9903 (fbsd_is_vfork_done_pending): Likewise.
9904 (fbsd_next_vfork_done): Likewise.
9906 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9908 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9909 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9910 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9912 (fbsd_xfer_partial): Use gdb::byte_vector.
9913 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
9915 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9917 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
9919 (fbsd_find_memory_regions): Fix `mapfile' initialization.
9921 2017-08-09 Tom Tromey <tom@tromey.com>
9923 * skip.c (skiplist_entry): New constructor.
9924 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
9925 (skiplist_entry::file_is_glob): Now bool.
9926 (skiplist_entry::file, skiplist_entry::function): Now
9928 (make_skip_entry): Return a unique_ptr. Use new.
9929 (free_skiplist_entry, free_skiplist_entry_cleanup)
9930 (make_free_skiplist_entry_cleanup): Remove.
9931 (skip_command, skip_disable_command, add_skiplist_entry)
9932 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
9933 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
9934 (function_name_is_marked_for_skip): Update.
9935 (skip_delete_command): Update. Use delete.
9937 2017-08-09 Jiong Wang <jiong.wang@arm.com>
9939 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
9940 (aarch64_linux_core_read_description): New function.
9941 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
9943 2017-08-09 Pedro Alves <palves@redhat.com>
9945 * cp-name-parser.y (cp_comp_to_string): Return a
9946 gdb::unique_xmalloc_ptr<char>.
9947 * cp-support.c (replace_typedefs_qualified_name)
9948 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
9949 (cp_canonicalize_string_full): Use op= instead of explicit
9951 (cp_class_name_from_physname, method_name_from_physname)
9952 (cp_func_name, cp_remove_params): Adjust to use
9953 gdb::unique_xmalloc_ptr<char>.
9954 * cp-support.h (cp_comp_to_string): Return a
9955 gdb::unique_xmalloc_ptr<char>.
9956 * python/py-type.c (typy_lookup_type): Adjust to use
9957 gdb::unique_xmalloc_ptr<char>.
9959 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
9961 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
9963 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
9964 Yao Qi <yao.qi@linaro.org>
9966 * cp-support.c (cp_canonicalize_string_full): Use
9967 gdb::unique_xmalloc_ptr<char>.
9968 (cp_canonicalize_string): Likewise.
9970 2017-08-09 Yao Qi <yao.qi@linaro.org>
9972 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
9973 * regformats/i386/amd64-avx-avx512.dat: Remove.
9974 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
9975 * regformats/i386/amd64-avx-mpx.dat:Remove.
9976 * regformats/i386/amd64-avx.dat: Remove.
9977 * regformats/i386/amd64-mpx.dat: Remove.
9978 * regformats/i386/i386-avx-avx512.dat: Remove.
9979 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
9980 * regformats/i386/i386-avx-mpx.dat: Remove.
9981 * regformats/i386/i386-mmx.dat: Remove.
9982 * regformats/i386/i386-mpx.dat: Remove.
9984 2017-08-09 Yao Qi <yao.qi@linaro.org>
9986 * amd64-tdep.h (tdesc_x32): Remove the declaration.
9987 * amd64-tdep.c: Don't include features/i386/x32*.c.
9988 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
9990 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
9991 and i386/x32-avx-avx512.
9992 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
9994 * features/i386/x32-avx-avx512.c: Removed.
9995 * features/i386/x32-avx-avx512.xml: Removed.
9996 * features/i386/x32-avx.c: Removed.
9997 * features/i386/x32-avx.xml: Removed.
9998 * features/i386/x32.c: Removed.
9999 * features/i386/x32.xml: Removed.
10000 * regformats/i386/x32-avx-avx512.dat: Removed.
10001 * regformats/i386/x32-avx.dat: Removed.
10002 * regformats/i386/x32.dat: Removed.
10004 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
10006 PR breakpoints/21886
10007 * mem-break.c (default_memory_insert_breakpoint): Use
10008 `->placed_address' rather than `->reqstd_address' for the
10009 breakpoint location.
10011 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
10013 * arch-utils.c (default_print_insn): Remove arch/mach/endian
10016 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
10018 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
10019 a union of `tdep_info', `tdesc_data' and `id'.
10020 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
10021 rather than `info.tdep_info'.
10022 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
10023 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
10024 * i386-tdep.c (i386_gdbarch_init): Likewise.
10025 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
10026 * mips-tdep.c (mips_gdbarch_init): Likewise.
10027 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10028 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
10029 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
10031 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
10033 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10034 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
10036 * spu-tdep.c (spu_gdbarch_init): Likewise.
10037 * gdbarch.h: Regenerate.
10039 2017-08-07 Leszek Swirski <leszeks@google.com>
10042 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
10044 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
10046 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
10047 (gdbsim_open): Rename gdb_argv args object to argv.
10049 2017-08-05 Tom Tromey <tom@tromey.com>
10051 * compile/compile-object-load.c (compile_object_load): Use
10052 gdb::unique_xmalloc_ptr.
10053 * cli/cli-dump.c (scan_filename): Rename from
10054 scan_filename_with_cleanup. Change return type.
10055 (scan_expression): Rename from scan_expression_with_cleanup.
10056 Change return type.
10057 (dump_memory_to_file, dump_value_to_file, restore_command):
10058 Use gdb::unique_xmalloc_ptr. Update.
10059 * cli/cli-cmds.c (find_and_open_script): Use
10060 gdb::unique_xmalloc_ptr.
10061 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
10062 * symmisc.c (maintenance_print_symbols)
10063 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
10064 * symfile.c (symfile_bfd_open, generic_load)
10065 (add_symbol_file_command, remove_symbol_file_command): Use
10066 gdb::unique_xmalloc_ptr.
10067 * source.c (openp): Use gdb::unique_xmalloc_ptr.
10068 * psymtab.c (maintenance_print_psymbols): Use
10069 gdb::unique_xmalloc_ptr.
10070 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
10071 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
10072 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
10073 (reload_shared_libraries_1): Likewise.
10075 2017-08-05 Tom Tromey <tom@tromey.com>
10077 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
10078 (rust_op_vector, rust_set_vector): New typedefs.
10079 (current_parser): New global.
10080 (work_obstack): Change to pointer type. Update all users.
10081 (rust_ast, pstate): Remove globals.
10082 (struct rust_parser): New.
10083 (%union) <params, field_inits>: Change type.
10084 (start, tuple_expr, unit_expr, struct_expr_list, literal)
10085 (field_expr, expr_list, maybe_expr_list, type_list): Update.
10086 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
10087 (convert_params_to_types, convert_params_to_expression): Change
10089 (ast_string): Change type of "fields".
10090 (rust_parse): Make a rust_parser. Remove cleanups.
10091 (rust_lex_tests): Make and install an auto_obstack.
10093 2017-08-04 Yao Qi <yao.qi@linaro.org>
10095 * configure.srv (ipa_x32_linux_regobj): New.
10096 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
10097 instead of X86_TDESC_AVX512.
10098 (initialize_low_tracepoint): Call
10099 init_registers_x32_avx_avx512_linux.
10101 2017-08-04 Yao Qi <yao.qi@linaro.org>
10103 * utils.h (gdb_argv): Add namespace std for nullptr_t.
10105 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
10107 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
10109 2017-08-03 Tom Tromey <tom@tromey.com>
10111 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
10113 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
10115 2017-08-03 Tom Tromey <tom@tromey.com>
10117 * python/py-param.c (compute_enum_values): Use gdb_argv.
10119 2017-08-03 Tom Tromey <tom@tromey.com>
10121 * utils.h (struct gdb_argv_deleter): New.
10122 (gdb_argv): New class.
10123 * utils.c (gdb_argv::reset): New method.
10124 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
10125 * tracefile.c (tsave_command): Use gdb_argv.
10126 * top.c (new_ui_command): Use gdb_argv.
10127 * symmisc.c (maintenance_print_symbols)
10128 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
10129 * symfile.c (symbol_file_command, generic_load)
10130 (remove_symbol_file_command): Use gdb_argv.
10131 * stack.c (backtrace_command): Use gdb_argv.
10132 * source.c (add_path, show_substitute_path_command)
10133 (unset_substitute_path_command, set_substitute_path_command):
10135 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
10136 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
10137 * remote.c (extended_remote_run, remote_put_command)
10138 (remote_get_command, remote_delete_command): Use gdb_argv.
10139 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
10140 (gdbsim_open): Use gdb_argv.
10141 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
10142 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
10143 * procfs.c (procfs_info_proc): Use gdb_argv.
10144 * interps.c (interpreter_exec_cmd): Use gdb_argv.
10145 * infrun.c (handle_command): Use gdb_argv.
10146 * inferior.c (add_inferior_command, clone_inferior_command):
10148 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
10149 * exec.c (exec_file_command): Use gdb_argv.
10150 * cli/cli-cmds.c (alias_command): Use gdb_argv.
10151 * compile/compile.c (build_argc_argv): Use gdb_argv.
10153 2017-08-03 Tom Tromey <tom@tromey.com>
10155 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
10157 2017-08-03 Tom Tromey <tom@tromey.com>
10159 * python/python.c (compute_python_string): Return std::string.
10160 (gdbpy_eval_from_control_command): Update.
10161 (do_start_initialization): Use std::string.
10162 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
10164 * python/py-breakpoint.c (local_setattro): Use string_printf, not
10167 2017-08-03 Tom Tromey <tom@tromey.com>
10169 * top.h (do_restore_instream_cleanup): Remove.
10170 * top.c (do_restore_instream_cleanup): Remove.
10171 (read_command_file): Use scoped_restore.
10172 * cli/cli-script.c (execute_user_command): Use scoped_restore.
10174 2017-08-03 Tom Tromey <tom@tromey.com>
10176 * cli/cli-script.c (execute_user_command)
10177 (execute_control_command): Use scoped_restore.
10179 2017-08-03 Tom Tromey <tom@tromey.com>
10181 * cli/cli-script.c (do_restore_user_call_depth): Remove.
10182 (execute_user_command): Remove user_call_depth; use
10183 user_args_stack's size instead.
10185 2017-08-03 Tom Tromey <tom@tromey.com>
10187 * top.h (in_user_command): Remove.
10188 * top.c (in_user_command): Remove.
10189 * cli/cli-script.c (do_restore_user_call_depth)
10190 (execute_user_command): Update.
10192 2017-08-03 Tom Tromey <tom@tromey.com>
10194 * valops.c (search_struct_method): Use gdb::byte_vector.
10195 * valarith.c (value_concat): Use std::vector.
10196 * target.c (memory_xfer_partial): Use gdb::byte_vector.
10197 (simple_search_memory): Likewise.
10198 * printcmd.c (find_string_backward): Use gdb::byte_vector.
10199 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
10200 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
10201 * elfread.c (elf_rel_plt_read): Use std::string.
10202 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
10203 * cli/cli-dump.c (restore_section_callback): Use
10206 2017-08-03 Tom Tromey <tom@tromey.com>
10208 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
10210 2017-08-03 Tom Tromey <tom@tromey.com>
10212 * tui/tui-regs.c (tui_restore_gdbout): Remove.
10213 (tui_register_format): Use scoped_restore.
10215 2017-08-03 Tom Tromey <tom@tromey.com>
10217 * reverse.c (exec_direction_default): Remove.
10218 (exec_reverse_once): Use scoped_restore.
10219 * remote.c (restore_remote_timeout): Remove.
10220 (remote_flash_erase, remote_flash_write, remote_flash_done)
10221 (readchar, remote_serial_write): Use scoped_restore.
10222 * cli/cli-script.c (struct source_cleanup_lines_args)
10223 (source_cleanup_lines): Remove.
10224 (script_from_file): Use scoped_restore.
10225 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
10226 (source_command): Use scoped_restore.
10228 2017-08-03 Tom Tromey <tom@tromey.com>
10230 * utils.h (make_cleanup_free_so): Remove.
10231 * utils.c (do_free_so, make_cleanup_free_so): Remove.
10232 * solist.h (struct so_deleter): New.
10233 (so_list_up): New typedef.
10234 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
10236 2017-08-03 Tom Tromey <tom@tromey.com>
10238 * utils.h (make_cleanup_restore_current_language): Remove.
10239 * utils.c (do_restore_current_language)
10240 (make_cleanup_restore_current_language): Remove.
10241 * parse.c (parse_exp_in_context_1)
10242 (parse_expression_with_language): Use
10243 scoped_restore_current_language.
10244 * mi/mi-main.c (mi_cmd_execute): Use
10245 scoped_restore_current_language.
10246 * language.h (scoped_restore_current_language): New class.
10248 2017-08-03 Tom Tromey <tom@tromey.com>
10250 * compile/compile.c (cleanup_unlink_file): Remove.
10251 (compile_to_object): Use gdb::unlinker.
10252 (eval_compile_command): Likewise.
10254 2017-08-03 Tom Tromey <tom@tromey.com>
10256 * utils.h (make_cleanup_fclose): Remove.
10257 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
10259 2017-08-03 Tom Tromey <tom@tromey.com>
10261 * top.c (open_terminal_stream): Return gdb_file_up.
10262 (new_ui_command): Update.
10264 2017-08-03 Tom Tromey <tom@tromey.com>
10266 * source.c (print_source_lines_base, forward_search_command)
10267 (reverse_search_command): Use gdb_file_up.
10269 2017-08-03 Tom Tromey <tom@tromey.com>
10271 * fbsd-nat.c (fbsd_find_memory_regions): Update.
10273 2017-08-03 Tom Tromey <tom@tromey.com>
10275 * cli/cli-cmds.c (find_and_open_script): Change return type.
10276 Remove "streamp" and "full_path" parameters.
10277 (source_script_with_search): Update.
10278 * auto-load.c (source_script_file): Update.
10279 * cli/cli-cmds.h (find_and_open_script): Change type.
10280 (open_script): New struct.
10282 2017-08-03 Tom Tromey <tom@tromey.com>
10284 * xml-support.c (xml_fetch_content_from_file): Update.
10285 * ui-file.c (stdio_file::open): Update.
10286 * tracefile-tfile.c (tfile_start): Update.
10287 * remote.c (remote_file_put, remote_file_get): Update.
10288 * nat/linux-procfs.c (linux_proc_get_int)
10289 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
10290 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
10291 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
10292 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
10293 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
10294 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
10295 * linux-nat.c (linux_proc_pending_signals): Update.
10296 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
10297 (file_closer): Remove.
10298 * compile/compile.c (compile_to_object): Update.
10299 * common/filestuff.h (struct gdb_file_deleter): New.
10300 (gdb_file_up): New typedef.
10301 (gdb_fopen_cloexec): Change return type.
10302 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
10303 * cli/cli-dump.c (fopen_with_cleanup): Remove.
10304 (dump_binary_file, restore_binary_file): Update.
10305 * auto-load.c (auto_load_objfile_script_1): Update.
10307 2017-08-03 Tom Tromey <tom@tromey.com>
10309 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
10310 (info_static_tracepoint_markers_command): Likewise.
10311 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
10312 * skip.c (skip_info): Use ui_out_emit_table.
10313 * progspace.c (print_program_space): Use ui_out_emit_table.
10314 * osdata.c (info_osdata): Use ui_out_emit_table.
10315 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
10317 * linux-thread-db.c (info_auto_load_libthread_db): Use
10319 * inferior.c (print_inferior): Use ui_out_emit_table.
10320 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
10321 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
10322 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
10323 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
10324 * ui-out.h (class ui_out_emit_table): New.
10326 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
10328 * mips-tdep.c (mips_fpu_type_str): New function.
10329 (mips_dump_tdep): Call it.
10331 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
10333 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
10336 2017-07-31 Xavier Roirand <roirand@adacore.com>
10338 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
10340 2017-07-27 Xavier Roirand <roirand@adacore.com>
10342 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
10344 2017-07-26 Yao Qi <yao.qi@linaro.org>
10346 * cli/cli-cmds.c (maintenancechecklist): New variable.
10347 * gdbcmd.h (maintenancechecklist): Declare it.
10348 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
10349 Call i386_linux_read_description with different masks.
10350 * maint.c (maintenance_check_command): New function.
10351 (_initialize_maint_cmds): Call add_prefix_cmd.
10352 * target-descriptions.c (tdesc_reg): override operator != and ==.
10353 (tdesc_type): Likewise.
10354 (tdesc_feature): Likewise.
10355 (target_desc): Likewise.
10356 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
10357 (maintenance_check_xml_descriptions): New function.
10358 (_initialize_target_descriptions) Add command "xml-descriptions".
10359 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
10361 2017-07-26 Yao Qi <yao.qi@linaro.org>
10363 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
10364 Include features/i386/32bit-*.c.
10365 (i386_linux_read_description): Generate target description if it
10367 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
10369 * features/i386/32bit-linux.c: Re-generated.
10370 * features/i386/32bit-sse.c: Likewise.
10371 * target-descriptions.c (print_c_feature::visit): Print code to
10372 set register number if needed.
10373 (print_c_feature) <m_next_regnum>: New field.
10375 2017-07-26 Yao Qi <yao.qi@linaro.org>
10377 * features/Makefile (CFILES): Rename with TDESC_CFILES.
10378 (FEATURE_XMLFILES): New.
10379 (FEATURE_CFILES): New.
10381 (clean-cfiles): Remove generated c files.
10382 * features/i386/32bit-avx.c: Generated.
10383 * features/i386/32bit-avx512.c: Generated.
10384 * features/i386/32bit-core.c: Generated.
10385 * features/i386/32bit-linux.c: Generated.
10386 * features/i386/32bit-mpx.c: Generated.
10387 * features/i386/32bit-pkeys.c: Generated.
10388 * features/i386/32bit-sse.c: Generated.
10389 * target-descriptions.c: Include algorithm.
10390 (tdesc_element_visitor): Add method visit_end.
10391 (print_c_tdesc): Implement visit_end.
10392 (print_c_tdesc:: m_filename_after_features): Move it to
10394 (print_c_feature): New class.
10395 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
10396 name starts with "i386/32bit-".
10398 2017-07-26 Yao Qi <yao.qi@linaro.org>
10400 * target-descriptions.c (tdesc_element_visitor): New class.
10401 (tdesc_element): New class.
10402 (tdesc_reg): Inherit from tdesc_element.
10403 (tdesc_reg::accept): New function.
10404 (tdesc_type): Inherit from tdesc_element.
10405 (tdesc_type::accept): New function.
10406 (tdesc_feature): Inherit from tdesc_element.
10407 (tdesc_feature::accept): New function.
10408 (target_desc): Inherit from tdesc_element.
10409 (target_desc::target_desc): New.
10410 (target_desc::~target_desc): New.
10411 (target_desc::accept): New.
10412 (allocate_target_description): Use new.
10413 (free_target_description): Use delete.
10414 (print_c_tdesc): New class.
10415 (maint_print_c_tdesc_cmd): Adjust.
10417 * features/aarch64.c: Re-generated.
10418 * features/arc-arcompact.c: Re-generated.
10419 * features/arc-v2.c: Re-generated.
10420 * features/arm/arm-with-iwmmxt.c: Re-generated.
10421 * features/arm/arm-with-m.c: Re-generated.
10422 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
10423 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
10424 * features/arm/arm-with-neon.c: Re-generated.
10425 * features/arm/arm-with-vfpv2.c: Re-generated.
10426 * features/arm/arm-with-vfpv3.c: Re-generated.
10427 * features/i386/amd64-avx-avx512.c: Re-generated.
10428 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10429 * features/i386/amd64-avx.c: Re-generated.
10430 * features/i386/amd64-avx-linux.c: Re-generated.
10431 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
10432 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10433 * features/i386/amd64-avx-mpx.c: Re-generated.
10434 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
10435 * features/i386/amd64.c: Re-generated.
10436 * features/i386/amd64-linux.c: Re-generated.
10437 * features/i386/amd64-mpx.c: Re-generated.
10438 * features/i386/amd64-mpx-linux.c: Re-generated.
10439 * features/i386/i386-avx-avx512.c: Re-generated.
10440 * features/i386/i386-avx-avx512-linux.c: Re-generated.
10441 * features/i386/i386-avx.c: Re-generated.
10442 * features/i386/i386-avx-linux.c: Re-generated.
10443 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
10444 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
10445 * features/i386/i386-avx-mpx.c: Re-generated.
10446 * features/i386/i386-avx-mpx-linux.c: Re-generated.
10447 * features/i386/i386.c: Re-generated.
10448 * features/i386/i386-linux.c: Re-generated.
10449 * features/i386/i386-mmx.c: Re-generated.
10450 * features/i386/i386-mmx-linux.c: Re-generated.
10451 * features/i386/i386-mpx.c: Re-generated.
10452 * features/i386/i386-mpx-linux.c: Re-generated.
10453 * features/i386/x32-avx-avx512.c: Re-generated.
10454 * features/i386/x32-avx-avx512-linux.c: Re-generated.
10455 * features/i386/x32-avx.c: Re-generated.
10456 * features/i386/x32-avx-linux.c: Re-generated.
10457 * features/i386/x32.c: Re-generated.
10458 * features/i386/x32-linux.c: Re-generated.
10459 * features/microblaze.c: Re-generated.
10460 * features/microblaze-with-stack-protect.c: Re-generated.
10461 * features/mips64-dsp-linux.c: Re-generated.
10462 * features/mips64-linux.c: Re-generated.
10463 * features/mips-dsp-linux.c: Re-generated.
10464 * features/mips-linux.c: Re-generated.
10465 * features/nds32.c: Re-generated.
10466 * features/nios2.c: Re-generated.
10467 * features/nios2-linux.c: Re-generated.
10468 * features/rs6000/powerpc-32.c: Re-generated.
10469 * features/rs6000/powerpc-32l.c: Re-generated.
10470 * features/rs6000/powerpc-403.c: Re-generated.
10471 * features/rs6000/powerpc-403gc.c : Re-generated.
10472 * features/rs6000/powerpc-405.c: Re-generated.
10473 * features/rs6000/powerpc-505.c: Re-generated.
10474 * features/rs6000/powerpc-601.c: Re-generated.
10475 * features/rs6000/powerpc-602.c: Re-generated.
10476 * features/rs6000/powerpc-603.c: Re-generated.
10477 * features/rs6000/powerpc-604.c: Re-generated.
10478 * features/rs6000/powerpc-64.c: Re-generated.
10479 * features/rs6000/powerpc-64l.c: Re-generated.
10480 * features/rs6000/powerpc-7400.c: Re-generated.
10481 * features/rs6000/powerpc-750.c: Re-generated.
10482 * features/rs6000/powerpc-860.c: Re-generated.
10483 * features/rs6000/powerpc-altivec32.c: Re-generated.
10484 * features/rs6000/powerpc-altivec32l.c: Re-generated.
10485 * features/rs6000/powerpc-altivec64.c: Re-generated.
10486 * features/rs6000/powerpc-altivec64l.c: Re-generated.
10487 * features/rs6000/powerpc-cell32l.c: Re-generated.
10488 * features/rs6000/powerpc-cell64l.c: Re-generated.
10489 * features/rs6000/powerpc-e500.c: Re-generated.
10490 * features/rs6000/powerpc-e500l.c: Re-generated.
10491 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
10492 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
10493 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
10494 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
10495 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
10496 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
10497 * features/rs6000/powerpc-vsx32.c: Re-generated.
10498 * features/rs6000/powerpc-vsx32l.c: Re-generated.
10499 * features/rs6000/powerpc-vsx64.c: Re-generated.
10500 * features/rs6000/powerpc-vsx64l.c: Re-generated.
10501 * features/rs6000/rs6000.c: Re-generated.
10502 * features/s390-linux32.c: Re-generated.
10503 * features/s390-linux32v1.c: Re-generated.
10504 * features/s390-linux32v2.c: Re-generated.
10505 * features/s390-linux64.c: Re-generated.
10506 * features/s390-linux64v1.c: Re-generated.
10507 * features/s390-linux64v2.c: Re-generated.
10508 * features/s390-te-linux64.c: Re-generated.
10509 * features/s390-tevx-linux64.c: Re-generated.
10510 * features/s390-vx-linux64.c: Re-generated.
10511 * features/s390x-linux64.c: Re-generated.
10512 * features/s390x-linux64v1.c: Re-generated.
10513 * features/s390x-linux64v2.c: Re-generated.
10514 * features/s390x-te-linux64.c: Re-generated.
10515 * features/s390x-tevx-linux64.c: Re-generated.
10516 * features/s390x-vx-linux64.c: Re-generated.
10517 * features/sparc/sparc32-solaris.c: Re-generated.
10518 * features/sparc/sparc64-solaris.c: Re-generated.
10519 * features/tic6x-c62x.c: Re-generated.
10520 * features/tic6x-c62x-linux.c: Re-generated.
10521 * features/tic6x-c64x.c: Re-generated.
10522 * features/tic6x-c64x-linux.c: Re-generated.
10523 * features/tic6x-c64xp.c: Re-generated.
10524 * features/tic6x-c64xp-linux.c: Re-generated.
10526 2017-07-26 Yao Qi <yao.qi@linaro.org>
10528 * i386-linux-tdep.c (i386_linux_read_description): New function.
10529 (i386_linux_core_read_description): Call
10530 i386_linux_read_description.
10531 * i386-linux-tdep.h (i386_linux_read_description): Declare.
10532 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
10533 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
10534 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
10535 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
10536 * x86-linux-nat.c (x86_linux_read_description): Call
10537 i386_linux_read_description.
10539 2017-07-26 Yao Qi <yao.qi@linaro.org>
10541 * NEWS: Mention it.
10542 * features/Makefile (%.c: %.xml): Pass the xml file name to
10543 command "maint print c-tdesc".
10544 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
10547 2017-07-26 Yao Qi <yao.qi@linaro.org>
10549 * target-descriptions.c (target_desc): Add ctor and dtor. Do
10550 in-class initialization.
10551 (tdesc_create_feature): Call new instead of XCNEW.
10552 (free_target_description): Ue delete.
10554 2017-07-25 John Baldwin <jhb@FreeBSD.org>
10556 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
10558 2017-07-25 Yao Qi <yao.qi@linaro.org>
10560 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
10562 (amd64_x32_init_abi): Likewise.
10563 * amd64-tdep.h (amd64_init_abi): Update declaration.
10564 (amd64_x32_init_abi): Likewise.
10566 2017-07-25 Yao Qi <yao.qi@linaro.org>
10569 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10570 condition for FPSCR.
10571 (arm_linux_store_inferior_registers): Likewise.
10573 2017-07-22 Tom Tromey <tom@tromey.com>
10575 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10576 <syscalls_counts>: Now a std::vector.
10577 (get_catch_syscall_inferior_data): Use "new".
10578 (catch_syscall_inferior_data_cleanup): Use "delete".
10579 (insert_catch_syscall, remove_catch_syscall)
10580 (clear_syscall_counts): Update.
10582 2017-07-22 Tom Tromey <tom@tromey.com>
10584 * break-catch-syscall.c (syscall_catchpoint)
10585 <syscalls_to_be_caught>: Now a std::vector<int>
10586 (~syscall_catchpoint): Remove.
10587 (insert_catch_syscall, remove_catch_syscall)
10588 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10589 (print_mention_catch_syscall, print_recreate_catch_syscall):
10591 (create_syscall_event_catchpoint): Change type of "filter"
10593 (catch_syscall_split_args): Return a std::vector.
10594 (catch_syscall_command_1, catching_syscall_number_1): Update.
10596 2017-07-22 Tom Tromey <tom@tromey.com>
10598 * break-catch-throw.c (struct exception_catchpoint)
10599 <exception_rx>: Now a std::string.
10600 (~exception_catchpoint): Remove.
10601 (print_one_detail_exception_catchpoint): Update.
10602 (handle_gnu_v3_exceptions): Change type of except_rx.
10603 (extract_exception_regexp): Return a std::string.
10604 (catch_exception_command_1): Update.
10606 2017-07-22 Tom Tromey <tom@tromey.com>
10608 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10609 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10611 <catch_all>: Now a bool.
10612 (~signal_catchpoint): Remove.
10613 (signal_catchpoint_insert_location)
10614 (signal_catchpoint_remove_location)
10615 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10616 (signal_catchpoint_print_mention)
10617 (signal_catchpoint_print_recreate)
10618 (signal_catchpoint_explains_signal): Update.
10619 (create_signal_catchpoint): Change type of "filter" and
10621 (catch_signal_split_args): Return a std::vector. Change type of
10623 (catch_signal_command): Update.
10625 2017-07-20 Pedro Alves <palves@redhat.com>
10627 * ada-lang.c (ada_language_defn): Make extern.
10628 (_initialize_ada_language): Remove add_language call.
10629 * c-lang.c (c_language_defn, cplus_language_defn)
10630 (asm_language_defn, minimal_language_defn): Make extern.
10631 (_initialize_c_language): Delete.
10632 * completer.c (compare_cstrings): Delete, moved to utils.h.
10633 * d-lang.c (d_language_defn): Make extern.
10634 (_initialize_d_language): Remove add_language calls.
10635 * defs.h (enum language): Add comment.
10636 * f-lang.c (f_language_defn): Make extern.
10637 (_initialize_f_language): Remove add_language call.
10638 * go-lang.c (go_language_defn): Make extern.
10639 (_initialize_go_language): Remove add_language call.
10640 * language.c: Include <algorithm>.
10641 (languages): Redefine as const array.
10642 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10643 (set_language_command): Handle "local". Use for-range loop.
10644 (set_language): Remove loop.
10645 (language_enum): Rewrite.
10646 (language_def, language_str): Remove loops.
10647 (add_language): Delete.
10648 (add_set_language_command): New, based on add_languages.
10649 (skip_language_trampoline): Adjust.
10650 (local_language_defn): Delete.
10651 (language_gdbarch_post_init): Adjust.
10652 (_initialize_language): Remove add_language calls. Call
10653 add_set_language_command.
10654 * language.h (add_language): Delete.
10655 (auto_language_defn)
10656 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10657 (asm_language_defn, c_language_defn, cplus_language_defn)
10658 (d_language_defn, f_language_defn, go_language_defn)
10659 (m2_language_defn, objc_language_defn, opencl_language_defn)
10660 (pascal_language_defn, rust_language_defn): Declare.
10661 * m2-lang.c (m2_language_defn): Make extern.
10662 (_initialize_m2_language): Remove add_language call.
10663 * objc-lang.c (objc_language_defn): Make extern.
10664 (_initialize_objc_language): Remove add_language call.
10665 * opencl-lang.c (opencl_language_defn): Make extern.
10666 (_initialize_opencl_language): Remove add_language call.
10667 * p-lang.c (pascal_language_defn): Make extern.
10668 (_initialize_pascal_language): Delete.
10669 * rust-lang.c (rust_language_defn): Make extern.
10670 (_initialize_rust_language): Delete.
10671 * utils.h (compare_cstrings): New static inline function.
10673 2017-07-20 Pedro Alves <palves@redhat.com>
10675 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10676 (get_var_value): Constify parameters.
10677 (get_int_var_value): Change prototype.
10678 (to_fixed_range_type): Adjust.
10679 * ada-lang.h (get_int_var_value): Change prototype.
10681 2017-07-20 Pedro Alves <palves@redhat.com>
10683 * dwarf2read.c (dw2_lookup_symbol): Use
10684 SYMBOL_MATCHES_SEARCH_NAME.
10685 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10687 2017-07-20 Pedro Alves <palves@redhat.com>
10689 * block.c (block_iter_name_step, block_iter_name_first)
10690 (block_iter_name_next): Delete.
10691 (block_lookup_symbol_primary): Adjust to use
10692 dict_iter_match_first/dict_iter_match_next.
10693 * block.h (block_iter_name_first, block_iter_name_next): Delete
10695 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10696 dict_iter_match_first/dict_iter_match_next.
10698 2017-07-20 Pedro Alves <palves@redhat.com>
10700 * cp-support.c (cp_find_first_component_aux): Add missing case for
10703 2017-07-18 David Blaikie <dblaikie@gmail.com>
10705 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10706 of dwo_cu's dwo_file.
10708 2017-07-18 Yao Qi <yao.qi@linaro.org>
10710 * remote.c (store_registers_using_G): Remove one line comment.
10712 2017-07-18 Yao Qi <yao.qi@linaro.org>
10714 * regcache.c (regcache_cpy): Simplify it.
10715 (regcache::cpy_no_passthrough): Remove it.
10716 * regcache.h (cpy_no_passthrough): Remove it.
10717 (regcache_dup, regcache_cpy): Update comments.
10719 2017-07-18 Pedro Alves <palves@redhat.com>
10721 * remote-sim.c (sim_command_completer): Adjust to work with a
10722 completion_tracker instead of a VEC.
10724 2017-07-17 Pedro Alves <palves@redhat.com>
10726 * completer.c (complete_source_filenames): New function.
10727 (complete_address_and_linespec_locations): New function.
10728 (location_completer): Use complete_address_and_linespec_locations.
10729 (completion_tracker::build_completion_result): Honor the tracker's
10730 request to suppress append.
10731 * completer.h (completion_tracker::suppress_append_ws)
10732 (completion_tracker::set_suppress_append_ws): New methods.
10733 (completion_tracker::m_suppress_append_ws): New field.
10734 (complete_source_filenames): New declaration.
10735 * linespec.c (linespec_complete_what): New.
10736 (struct ls_parser) <complete_what, completion_word,
10737 completion_quote_char, completion_quote_end, completion_tracker>:
10739 (string_find_incomplete_keyword_at_end): New.
10740 (linespec_lexer_lex_string): Record quote char. If in completion
10742 (linespec_lexer_consume_token): Advance the completion word point.
10743 (linespec_lexer_peek_token): Save/restore completion info.
10744 (save_stream_and_consume_token): New.
10745 (set_completion_after_number): New.
10746 (linespec_parse_basic): Set what to complete next depending on
10747 token. Handle function and label completions specially.
10748 (parse_linespec): Disable objc shortcut in completion mode. Set
10749 what to complete next depending on token type. Skip keyword if in
10751 (complete_linespec_component, linespec_complete): New.
10752 * linespec.h (linespec_complete): Declare.
10754 2017-07-17 Pedro Alves <palves@redhat.com>
10756 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10757 Handle 'operator<' / 'operator<<'.
10759 2017-07-17 Pedro Alves <palves@redhat.com>
10761 * completer.c (collect_explicit_location_matches): Handle
10763 (convert_explicit_location_to_linespec): New, factored out from
10765 (convert_explicit_location_to_sals): ... this.
10766 (complete_label): New.
10767 (linespec_complete_label, find_label_symbols_in_block): New.
10768 (find_label_symbols): Add completion_mode parameter and adjust to
10769 call find_label_symbols_in_block.
10770 * linespec.h (linespec_complete_label): Declare.
10772 2017-07-17 Pedro Alves <palves@redhat.com>
10774 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10775 complete_symbol_mode parameter.
10776 * cli/cli-cmds.c (complete_command): Get the completion result out
10777 of the handle_brkchars tracker if used a custom word point.
10778 * completer.c: Include "linespec.h".
10779 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10780 (advance_to_expression_complete_word_point): New.
10781 (completion_tracker::completes_to_completion_word): New.
10782 (complete_files_symbols): Pass down
10783 complete_symbol_mode::EXPRESSION.
10784 (explicit_options, probe_options): New.
10785 (collect_explicit_location_matches): Complete on the
10786 explictit_loc->foo instead of word. Use
10787 linespec_complete_function. Handle MATCH_LINE. Handle offering
10788 keyword and options completions.
10789 (backup_text_ptr): Delete.
10790 (skip_keyword): New.
10791 (complete_explicit_location): Remove 'word' parameter. Add
10792 language, quoted_arg_start and quoted_arg_end parameters.
10793 Rewrite, parsing left to right.
10794 (location_completer): Rewrite.
10795 (location_completer_handle_brkchars): New function.
10796 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10797 (enum complete_line_internal_reason): Adjust comments.
10798 (completion_tracker::discard_completions): New.
10799 (completer_handle_brkchars_func_for_completer): Handle
10800 location_completer.
10801 (gdb_custom_word_point_brkchars)
10802 (gdb_org_rl_basic_quote_characters): New.
10803 (gdb_completion_word_break_characters_throw)
10804 (completion_find_completion_word): Handle trackers that use a
10806 (completion_tracker::advance_custom_word_point_by): New.
10807 (completion_tracker::build_completion_result): Don't rely on
10808 readline appending the quote char.
10809 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10810 use a custom word point.
10811 (gdb_rl_attempted_completion_function): Restore
10812 rl_basic_quote_characters.
10813 * completer.h (class completion_tracker): Extend intro comment.
10814 (completion_tracker::set_quote_char)
10815 (completion_tracker::quote_char)
10816 (completion_tracker::set_use_custom_word_point)
10817 (completion_tracker::use_custom_word_point)
10818 (completion_tracker::custom_word_point)
10819 (completion_tracker::set_custom_word_point)
10820 (completion_tracker::advance_custom_word_point_by)
10821 (completion_tracker::completes_to_completion_word)
10822 (completion_tracker::discard_completions): New methods.
10823 (completion_tracker::m_quote_char)
10824 (completion_tracker::m_use_custom_word_point)
10825 (completion_tracker::m_custom_word_point): New fields.
10826 (advance_to_expression_complete_word_point): Declare.
10827 * f-lang.c (f_collect_symbol_completion_matches): Add
10828 complete_symbol_mode parameter.
10829 * language.h (struct language_defn)
10830 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10832 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10833 (linespec_complete_function): New function.
10834 (linespec_lexer_lex_keyword): Adjust.
10835 * linespec.h (linespec_keywords, linespec_complete_function): New
10837 * location.c (find_end_quote): New function.
10838 (explicit_location_lex_one): Add explicit_completion_info
10839 parameter. Save quoting info. Don't throw if being called for
10840 completion. Don't handle Ada operators here.
10841 (is_cp_operator, skip_op_false_positives, first_of)
10842 (explicit_location_lex_one_function): New function.
10843 (string_to_explicit_location): Replace 'dont_throw' parameter with
10844 an explicit_completion_info pointer parameter. Handle it. Don't
10845 use explicit_location_lex_one to lex function names. Use
10846 explicit_location_lex_one_function instead.
10847 * location.h (struct explicit_completion_info): New.
10848 (string_to_explicit_location): Replace 'dont_throw' parameter with
10849 an explicit_completion_info pointer parameter.
10850 * symtab.c (default_collect_symbol_completion_matches_break_on):
10851 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10852 (default_collect_symbol_completion_matches)
10853 (collect_symbol_completion_matches): Add complete_symbol_mode
10855 (collect_symbol_completion_matches_type): Pass down
10856 complete_symbol_mode::EXPRESSION.
10857 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10858 parameter. Handle LINESPEC mode.
10859 * symtab.h (complete_symbol_mode): New.
10860 (default_collect_symbol_completion_matches_break_on)
10861 (default_collect_symbol_completion_matches)
10862 (collect_symbol_completion_matches)
10863 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10866 2017-07-17 Pedro Alves <palves@redhat.com>
10868 * utils.c (enum class strncmp_iw_mode): New.
10869 (strcmp_iw): Rename to ...
10870 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10871 parameters. Handle them.
10873 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10874 * utils.h (strncmp_iw): Declare.
10875 (strcmp_iw): Move describing comments here.
10877 2017-07-17 Pedro Alves <palves@redhat.com>
10879 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10881 * c-typeprint.c (is_type_conversion_operator): Use
10883 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10884 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10886 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10887 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10888 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10889 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10891 * location.c: Include "cp-support.h".
10892 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10894 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10897 2017-07-17 Pedro Alves <palves@redhat.com>
10899 * cli/cli-cmds.c (complete_command): Use a completion tracker
10900 along with completion_find_completion_word for handle_brkchars
10902 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10903 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10904 (struct gdb_rl_completion_word_info): New.
10905 (gdb_rl_find_completion_word): New.
10906 (completion_find_completion_word): New.
10907 * completer.h (completion_find_completion_word): Declare.
10909 2017-07-17 Pedro Alves <palves@redhat.com>
10911 * ada-lang.c (symbol_completion_match): Adjust comments.
10912 (symbol_completion_add): Replace vector parameter with
10913 completion_tracker parameter. Use it.
10914 (ada_make_symbol_completion_list): Rename to...
10915 (ada_collect_symbol_completion_matches): ... this. Add
10916 completion_tracker parameter and use it.
10917 (ada_language_defn): Adjust.
10918 * break-catch-syscall.c (catch_syscall_completer): Adjust
10919 prototype and work with completion_tracker instead of VEC.
10920 * breakpoint.c (condition_completer): Adjust prototype and work
10921 with completion_tracker instead of VEC.
10922 * c-lang.c (c_language_defn, cplus_language_defn)
10923 (asm_language_defn, minimal_language_defn): Adjust to renames.
10924 * cli/cli-cmds.c (complete_command): Rework using
10925 completion_tracker. Catch exceptions when completing.
10926 * cli/cli-decode.c (integer_unlimited_completer)
10927 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
10928 with completion_tracker instead of VEC.
10929 * command.h (struct completion_tracker): Forward declare.
10930 (completer_ftype, completer_handle_brkchars_ftype): Change
10932 (complete_on_cmdlist, complete_on_enum): Adjust.
10933 * completer.c: Include <algorithm>.
10934 (struct gdb_completer_state): New.
10935 (current_completion): New global.
10936 (readline_line_completion_function): Delete.
10937 (noop_completer, filename_completer)
10938 (filename_completer_handle_brkchars, complete_files_symbols)
10939 (linespec_location_completer): Adjust to work with a
10940 completion_tracker instead of a VEC.
10941 (string_or_empty): New.
10942 (collect_explicit_location_matches): Adjust to work with a
10943 completion_tracker instead of a VEC.
10944 (explicit_location_completer): Rename to ...
10945 (complete_explicit_location): ... this and adjust to work with a
10946 completion_tracker instead of a VEC.
10947 (location_completer): Adjust to work with a completion_tracker
10949 (add_struct_fields): Adjust to work with a completion_list instead
10951 (expression_completer): Rename to ...
10952 (complete_expression): ... this and adjust to work with a
10953 completion_tracker instead of a VEC. Use complete_files_symbols.
10954 (expression_completer): Reimplement on top of complete_expression.
10955 (symbol_completer): Adjust to work with a completion_tracker
10957 (enum complete_line_internal_reason): Add describing comments.
10958 (complete_line_internal_normal_command): Adjust to work with a
10959 completion_tracker instead of a VEC.
10960 (complete_line_internal): Rename to ...
10961 (complete_line_internal_1): ... this and adjust to work with a
10962 completion_tracker instead of a VEC. Assert TEXT is NULL in the
10963 handle_brkchars phase.
10964 (new_completion_tracker): Delete.
10965 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
10966 complete_line_internal_1.
10967 (free_completion_tracker): Delete.
10968 (INITIAL_COMPLETION_HTAB_SIZE): New.
10969 (completion_tracker::completion_tracker)
10970 (completion_tracker::~completion_tracker): New.
10971 (maybe_add_completion): Delete.
10972 (completion_tracker::maybe_add_completion)
10973 (completion_tracker::add_completion)
10974 (completion_tracker::add_completions): New.
10975 (throw_max_completions_reached_error): Delete.
10976 (complete_line): Adjust to work with a completion_tracker instead
10977 of a VEC. Don't create a completion_tracker_t or check for max
10979 (command_completer, command_completer_handle_brkchars)
10980 (signal_completer, reg_or_group_completer_1)
10981 (reg_or_group_completer, default_completer_handle_brkchars):
10982 Adjust to work with a completion_tracker.
10983 (gdb_completion_word_break_characters_throw): New.
10984 (gdb_completion_word_break_characters): Reimplement.
10985 (line_completion_function): Delete.
10986 (completion_tracker::recompute_lowest_common_denominator)
10987 (expand_preserving_ws)
10988 (completion_tracker::build_completion_result)
10989 (completion_result::completion_result)
10990 (completion_result::completion_result)
10991 (completion_result::~completion_result)
10992 (completion_result::completion_result)
10993 (completion_result::release_match_list, compare_cstrings)
10994 (completion_result::sort_match_list)
10995 (completion_result::reset_match_list)
10996 (gdb_rl_attempted_completion_function_throw)
10997 (gdb_rl_attempted_completion_function): New.
10998 * completer.h (completion_list, struct completion_result)
10999 (class completion_tracker): New.
11000 (complete_line): Add completion_tracker parameter.
11001 (readline_line_completion_function): Delete.
11002 (gdb_rl_attempted_completion_function): New.
11003 (noop_completer, filename_completer, expression_completer)
11004 (location_completer, symbol_completer, command_completer)
11005 (signal_completer, reg_or_group_completer): Update prototypes.
11006 (completion_tracker_t, new_completion_tracker)
11007 (make_cleanup_free_completion_tracker): Delete.
11008 (enum maybe_add_completion_enum): Delete.
11009 (maybe_add_completion): Delete.
11010 (throw_max_completions_reached_error): Delete.
11011 * corefile.c (complete_set_gnutarget): Adjust to work with a
11012 completion_tracker instead of a VEC.
11013 * cp-abi.c (cp_abi_completer): Adjust to work with a
11014 completion_tracker instead of a VEC.
11015 * d-lang.c (d_language_defn): Adjust.
11016 * disasm.c (disassembler_options_completer): Adjust to work with a
11017 completion_tracker instead of a VEC.
11018 * f-lang.c (f_make_symbol_completion_list): Rename to ...
11019 (f_collect_symbol_completion_matches): ... this. Adjust to work
11020 with a completion_tracker instead of a VEC.
11021 (f_language_defn): Adjust.
11022 * go-lang.c (go_language_defn): Adjust.
11023 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
11024 Adjust to work with a completion_tracker instead of a VEC.
11025 * infrun.c (handle_completer): Likewise.
11026 * interps.c (interpreter_completer): Likewise.
11027 * interps.h (interpreter_completer): Likewise.
11028 * language.c (unknown_language_defn, auto_language_defn)
11029 (local_language_defn): Adjust.
11030 * language.h (language_defn::la_make_symbol_completion_list):
11032 (language_defn::la_collect_symbol_completion_matches): ... this
11033 and adjust to work with a completion_tracker instead of a VEC.
11034 * m2-lang.c (m2_language_defn): Adjust.
11035 * objc-lang.c (objc_language_defn): Adjust.
11036 * opencl-lang.c (opencl_language_defn): Adjust.
11037 * p-lang.c (pascal_language_defn): Adjust.
11038 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
11039 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
11040 with a completion_tracker.
11041 * rust-lang.c (rust_language_defn): Adjust.
11042 * symtab.c (free_completion_list, do_free_completion_list)
11043 (return_val, completion_tracker): Delete.
11044 (completion_list_add_name, completion_list_add_symbol)
11045 (completion_list_add_msymbol, completion_list_objc_symbol)
11046 (completion_list_add_fields, add_symtab_completions): Add
11047 completion_tracker parameter and use it.
11048 (default_make_symbol_completion_list_break_on_1): Rename to...
11049 (default_collect_symbol_completion_matches_break_on): ... this.
11050 Add completion_tracker parameter and use it instead of allocating
11051 a completion tracker here.
11052 (default_make_symbol_completion_list_break_on): Delete old
11054 (default_make_symbol_completion_list): Delete.
11055 (default_collect_symbol_completion_matches): New.
11056 (make_symbol_completion_list): Delete.
11057 (collect_symbol_completion_matches): New.
11058 (make_symbol_completion_type): Rename to ...
11059 (collect_symbol_completion_matches_type): ... this. Add
11060 completion_tracker parameter and use it instead of VEC.
11061 (make_file_symbol_completion_list_1): Rename to...
11062 (collect_file_symbol_completion_matches): ... this. Add
11063 completion_tracker parameter and use it instead of VEC.
11064 (make_file_symbol_completion_list): Delete.
11065 (add_filename_to_list): Use completion_list instead of a VEC.
11066 (add_partial_filename_data::list): Now a completion_list.
11067 (make_source_files_completion_list): Work with a completion_list
11069 * symtab.h: Include "completer.h".
11070 (default_make_symbol_completion_list_break_on)
11071 (default_make_symbol_completion_list, make_symbol_completion_list)
11072 (make_symbol_completion_type, make_file_symbol_completion_list)
11073 (make_source_files_completion_list): Delete.
11074 (default_collect_symbol_completion_matches_break_on)
11075 (default_collect_symbol_completion_matches)
11076 (collect_symbol_completion_matches)
11077 (collect_symbol_completion_matches_type)
11078 (collect_file_symbol_completion_matches)
11079 (make_source_files_completion_list): New.
11080 * top.c (init_main): Don't install a rl_completion_entry_function
11081 hook. Install a rl_attempted_completion_function hook instead.
11082 * tui/tui-layout.c (layout_completer): Adjust to work with a
11083 completion_tracker.
11084 * tui/tui-regs.c (tui_reggroup_completer):
11085 * tui/tui-win.c (window_name_completer, focus_completer)
11086 (winheight_completer): Adjust to work with a completion_tracker.
11087 * value.c: Include "completer.h".
11088 (complete_internalvar): Adjust to work with a completion_tracker.
11089 * value.h (complete_internalvar): Likewise.
11091 2017-07-17 Pedro Alves <palves@redhat.com>
11093 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
11095 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
11096 comments to completer_ftype's declaration.
11097 <completer_handle_brkchars>: Change type to
11098 completer_handle_brkchars_ftype.
11099 * command.h (completer_ftype): Add describing comment and give
11100 names to parameters.
11101 (completer_ftype_void): Rename to ...
11102 (completer_handle_brkchars_ftype) ... this. Add describing comment.
11103 (set_cmd_completer_handle_brkchars): Adjust.
11104 * completer.c (filename_completer_handle_brkchars): New function.
11105 (complete_line_internal_normal_command): New function, factored
11107 (complete_line_internal): ... here.
11108 (command_completer_handle_brkchars)
11109 (default_completer_handle_brkchars)
11110 (completer_handle_brkchars_func_for_completer): New functions.
11111 * completer.h (set_gdb_completion_word_break_characters): Delete
11113 (completer_handle_brkchars_func_for_completer): New declaration.
11114 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
11115 completer_handle_brkchars_func_for_completer.
11117 2017-07-17 Pedro Alves <palves@redhat.com>
11119 * completer.c (symbol_completer): New function, based on
11120 make_symbol_completion_list_fn.
11121 * completer.h (symbol_completer): New declaration.
11122 * guile/scm-cmd.c (cmdscm_completers): Adjust.
11123 * python/py-cmd.c (completers): Adjust.
11124 * symtab.c (make_symbol_completion_list_fn): Delete.
11125 * symtab.h (make_symbol_completion_list_fn): Delete.
11126 * cli/cli-decode.c (add_cmd): Adjust.
11128 2017-07-17 Pedro Alves <palves@redhat.com>
11130 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
11131 * dwarf2read.c: Include "filename-seen-cache.h".
11132 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
11133 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
11134 * filename-seen-cache.c: New file.
11135 * filename-seen-cache.h: New file.
11136 * symtab.c: Include "filename-seen-cache.h".
11137 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
11138 (create_filename_seen_cache, clear_filename_seen_cache)
11139 (delete_filename_seen_cache, filename_seen): Delete, parts moved
11140 to filename-seen-cache.h/filename-seen-cache.c.
11141 (output_source_filename, sources_info)
11142 (maybe_add_partial_symtab_filename)
11143 (make_source_files_completion_list): Adjust to use
11144 filename_seen_cache.
11146 2017-07-17 Pedro Alves <palves@redhat.com>
11148 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
11150 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
11151 dwarf2_debug_sections*)): New.
11152 (dwarf2_per_objfile::dwarf2_per_objfile(const
11153 dwarf2_per_objfile&)): Declare as deleted.
11154 (dwarf2_per_objfile::operator=): Declare as deleted.
11155 (dwarf2_per_objfile::dwarf2_per_objfile)
11156 (dwarf2_per_objfile::~dwarf2_per_objfile)
11157 (dwarf2_per_objfile::free_cached_comp_units): New.
11158 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
11159 ctor. Call dwarf2_per_objfile's ctor manually.
11160 (dwarf2_locate_sections): Deleted/refactored as ...
11161 (dwarf2_per_objfile::locate_sections): ... this new method.
11162 (free_cached_comp_units): Defer to
11163 dwarf2_per_objfile::free_cached_comp_units.
11164 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
11166 2017-07-14 Tom Tromey <tom@tromey.com>
11169 * rust-exp.y (convert_ast_to_expression): Add "want_type"
11171 <UNOP_SIZEOF>: Split into separate case.
11172 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
11174 2017-07-14 Tom Tromey <tom@tromey.com>
11177 * symtab.c (symbol_matches_domain): Add language_rust to special
11179 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
11180 treat LOC_TYPEDEF symbols as variables.
11182 2017-07-14 Pedro Alves <palves@redhat.com>
11184 * symtab.c (make_file_symbol_completion_list_1): Iterate over
11185 symtabs matching all symtabs with SRCFILE as file name instead of
11186 only considering the first hit, with lookup_symtab.
11188 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11190 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
11191 operator_name parameters.
11192 (gen_expr): Update function call.
11194 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11196 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
11198 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
11200 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
11201 parameter, use agent_expr::gdbarch instead, update function
11203 (locexpr_tracepoint_var_ref): Likewise.
11204 (loclist_tracepoint_var_ref): Likewise.
11205 * ax-gdb.c (gen_trace_static_fields): Likewise.
11206 (gen_traced_pop): Likewise.
11207 (gen_frame_args_address): Likewise.
11208 (gen_frame_locals_address): Likewise.
11209 (gen_var_ref): Likewise.
11210 (gen_struct_ref_recursive): Likewise.
11211 (gen_static_field): Likewise.
11212 (gen_maybe_namespace_elt): Likewise.
11213 (gen_expr): Likewise.
11214 (gen_trace_for_var): Likewise.
11215 (gen_trace_for_expr): Likewise.
11216 (gen_trace_for_return_address): Likewise.
11218 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11220 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
11222 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
11224 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11226 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
11227 from ax, update calls.
11228 (gen_usual_arithmetic): Likewise.
11229 (gen_integral_promotions): Likewise.
11230 (gen_bitfield_ref): Likewise.
11231 (gen_primitive_field): Likewise.
11232 (gen_struct_ref_recursive): Likewise.
11233 (gen_struct_ref): Likewise.
11234 (gen_maybe_namespace_elt): Likewise.
11235 (gen_struct_elt_for_reference): Likewise.
11236 (gen_namespace_elt): Likewise.
11237 (gen_aggregate_elt_ref): Likewise.
11238 (gen_expr): Get gdbarch from ax, update calls.
11239 (gen_expr_binop_rest): Likewise.
11241 2017-07-13 Pedro Alves <palves@redhat.com>
11243 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
11245 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
11246 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
11247 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
11248 tdesc_amd64_linux as default tdesc. Get final tdesc from the
11250 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
11251 Get final tdesc from the tdep.
11252 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
11254 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
11255 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
11256 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
11257 Use it as default tdesc.
11258 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
11259 down to amd_init_abi. No longer handle fallback tdesc here.
11260 * amd64-tdep.h (tdesc_x32): Declare.
11261 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
11263 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
11266 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11268 * s390-linux-tdep.c (s390_process_record): Add support for
11269 instructions new in arch12.
11271 2017-07-11 John Baldwin <jhb@FreeBSD.org>
11273 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
11274 PT_GETFSBASE and PT_GETGSBASE.
11275 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
11278 2017-07-11 John Baldwin <jhb@FreeBSD.org>
11280 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
11281 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
11282 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
11284 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
11285 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
11286 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
11287 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
11288 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
11289 * features/i386/amd64.xml: Add 64bit-segments.xml.
11290 * features/i386/amd64-avx-avx512.c: Regenerated.
11291 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
11292 * features/i386/amd64-avx-mpx.c: Regenerated.
11293 * features/i386/amd64-avx.c: Regenerated.
11294 * features/i386/amd64-mpx.c: Regenerated.
11295 * features/i386/amd64.c: Regenerated.
11296 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
11297 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11298 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
11299 * regformats/i386/amd64-avx.dat: Regenerated.
11300 * regformats/i386/amd64-mpx.dat: Regenerated.
11301 * regformats/i386/amd64.dat: Regenerated.
11303 2017-07-10 Yao Qi <yao.qi@linaro.org>
11305 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
11306 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
11308 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
11310 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
11312 * gnulib/aclocal.m4: Regenerate.
11313 * gnulib/config.in: Regenerate.
11314 * gnulib/configure: Regenerate.
11315 * gnulib/import/Makefile.am: Regenerate.
11316 * gnulib/import/Makefile.in: Regenerate.
11317 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
11318 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
11319 * gnulib/import/m4/environ.m4: New file.
11320 * gnulib/import/m4/setenv.m4: New file.
11321 * gnulib/import/setenv.c: New file.
11322 * gnulib/import/unsetenv.c: New file.
11324 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
11326 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
11327 address when op is DW_OP_addr.
11329 2017-07-09 Tom Tromey <tom@tromey.com>
11331 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
11332 check and apply to outer type.
11334 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11336 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
11337 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
11338 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
11339 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
11341 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11343 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
11345 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11347 * corelow.c (get_core_siginfo): Remove.
11348 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
11349 instead of get_core_siginfo.
11350 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
11351 * gdbarch.h: Re-generate.
11352 * gdbarch.c: Re-generate.
11353 * linux-tdep.c (linux_core_xfer_siginfo): New.
11354 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
11356 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11358 * corelow.c (thread_section_name): Move to ...
11359 * gdbcore.h (thread_section_name): ... here.
11361 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11363 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
11364 (struct siginfo32): New.
11365 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
11366 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
11367 via ptrace(PT_LWPINFO).
11369 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11371 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
11372 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
11373 (fbsd_get_siginfo_type): New.
11374 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
11375 (_initialize_fbsd_tdep): New.
11377 2017-07-06 David Blaikie <dblaikie@gmail.com>
11379 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
11380 a singular dwo_unit*) to support multiple CUs in the same way that
11381 multiple TUs are supported.
11382 (create_cus_hash_table): Replace create_dwo_cu with a function for
11383 parsing multiple CUs from a DWO file.
11384 (open_and_init_dwo_file): Use create_cus_hash_table rather than
11386 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
11387 htab_find, rather than comparing the signature to a singleton CU in
11390 2017-07-06 Pedro Alves <palves@redhat.com>
11392 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
11394 2017-07-04 Pedro Alves <palves@redhat.com>
11396 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
11397 * gdbtypes.h (TYPE_STATIC): Delete.
11398 (struct fn_field) <is_public, is_abstract, is_static, is_final,
11399 is_synchronized, is_native>: Delete.
11401 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
11402 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
11403 (TYPE_FN_FIELD_ABSTRACT): Delete.
11405 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
11407 * buffer.h (buffer_finish): Fix spelling mistakes.
11409 2017-07-01 Eli Zaretskii <eliz@gnu.org>
11411 * .dir-locals.el: Automatically switch to C-style comments in
11412 versions of Emacs that support the feature.
11414 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11415 Pedro Alves <palves@redhat.com>
11418 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
11419 (process_next_line): New variable 'inline_cmd'.
11420 Adjust 'if' clauses for "python", "compile" and "guile" to use
11421 'command_name_equals' and check for '!inline_cmd'.
11423 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11426 * cli/cli-script.c (command_name_equals_not_inline): New function.
11427 (process_next_line): Adjust 'if' clauses for "python", "compile"
11428 and "guile" to use command_name_equals_not_inline.
11430 2017-06-29 Pedro Alves <palves@redhat.com>
11432 * completer.c (expression_completer): Call
11433 linespec_location_completer instead of location_completer.
11435 2017-06-29 Pedro Alves <palves@redhat.com>
11437 * completer.c (expression_completer): Remove code that recomputes
11438 'text' from 'word'.
11440 2017-06-29 Yao Qi <yao.qi@linaro.org>
11442 * regformats/regdat.sh: Generate code with
11443 "ifndef IN_PROCESS_AGENT".
11445 2017-06-28 Pedro Alves <palves@redhat.com>
11447 * command.h: Include "common/scoped_restore.h".
11449 2017-06-28 Yao Qi <yao.qi@linaro.org>
11451 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
11452 instead of obstack_grow.
11454 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
11457 * symfile.c (reread_symbols): Call objfiles_changed just before
11460 2017-06-27 Pedro Alves <palves@redhat.com>
11462 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
11463 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
11464 (completion_list_add_symbol, completion_list_add_msymbol):
11465 ... these new functions.
11466 (add_symtab_completions)
11467 (default_make_symbol_completion_list_break_on_1): Adjust.
11469 2017-06-27 Pedro Alves <palves@redhat.com>
11471 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
11472 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
11473 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
11475 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
11476 'storage_obstack' field an auto_obstack. In-class initialize all
11477 non-bitfield fields. Make minsyms_read bool.
11478 * symfile.c (read_symbols): Adjust.
11480 2017-06-27 Alan Hayward <alan.hayward@arm.com>
11482 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
11483 (gdbsim_store_register): Likewise.
11485 2017-06-27 Pedro Alves <palves@redhat.com>
11487 * c-exp.y (name_obstack): Now an auto_obstack.
11488 (yylex): Use auto_obstack::clear.
11489 (c_parse): Use auto_obstack::clear instead of reinitializing and
11490 freeing the obstack.
11491 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
11492 * d-exp.y (name_obstack): Now an auto_obstack.
11493 (yylex): Use auto_obstack::clear.
11494 (d_parse): Use auto_obstack::clear instead of reinitializing and
11495 freeing the obstack.
11496 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
11498 * dwarf2read.c (create_addrmap_from_index)
11499 (dwarf2_build_psymtabs_hard)
11500 (update_enumeration_type_from_children): Likewise.
11501 * gdb_obstack.h (auto_obstack): New type.
11502 * go-exp.y (name_obstack): Now an auto_obstack.
11503 (build_packaged_name): Use auto_obstack::clear.
11504 (go_parse): Use auto_obstack::clear instead of reinitializing and
11505 freeing the obstack.
11506 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
11508 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
11509 * rust-exp.y (work_obstack): Now an auto_obstack.
11510 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
11511 reinitializing and freeing the obstack.
11512 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
11513 (host_char_to_target): Use auto_obstack.
11514 * utils.h (make_cleanup_obstack_free): Delete declaration.
11515 * valprint.c (generic_emit_char, generic_printstr): Use
11518 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
11520 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
11522 (darwin_init_thread_list): Don't update dummy thread.
11523 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
11525 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11527 * record-full.c (netorder16): Remove.
11529 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11531 * common/diagnostics.h: Define macros for GCC.
11532 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
11533 * common/vec.h: Include diagnostics.h.
11534 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
11535 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
11538 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11540 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
11542 * ada-lex.l: Ignore deprecated register warnings.
11544 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11546 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
11547 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
11549 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11551 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
11554 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11556 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
11558 2017-06-23 Alan Hayward <alan.hayward@arm.com>
11560 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
11561 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
11562 (xtensa_register_read_masked): Likewise.
11564 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
11566 * common/environ.c (gdb_environ::unset): Update comment.
11568 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11570 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11573 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11575 * record-full.c (record_full_exec_insn): Use byte_vector.
11577 2017-06-22 Yao Qi <yao.qi@linaro.org>
11579 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11580 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11582 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11584 * remote.c (cached_reg): Move from here...
11585 * regcache.h (cached_reg): ...to here.
11586 * python/py-unwind.c (struct reg_info): Remove.
11587 (cached_frame_info): Use cached_reg_t.
11588 (pyuw_prev_register): Likewise.
11589 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11590 (pyuw_dealloc_cache): Free all registers.
11592 2017-06-22 Pedro Alves <palves@redhat.com>
11593 Simon Marchi <simon.marchi@ericsson.com>
11595 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11597 * common/diagnostics.h: New file.
11599 2017-06-22 Pedro Alves <palves@redhat.com>
11601 * common/agent.h: Add include guards.
11603 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11605 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11606 talk about addressable units instead of bytes.
11608 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11610 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11611 of '::const_iterator'.
11613 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11615 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11616 'unittests/environ-selftests.c'.
11617 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11618 * charset.c (find_charset_names): Declare object 'iconv_env'.
11619 Update code to use 'iconv_env' object. Remove call to
11621 * common/environ.c: Include <utility>.
11622 (make_environ): Delete function.
11623 (free_environ): Delete function.
11624 (gdb_environ::clear): New function.
11625 (gdb_environ::operator=): New function.
11626 (gdb_environ::get): Likewise.
11627 (environ_vector): Delete function.
11628 (set_in_environ): Delete function.
11629 (gdb_environ::set): New function.
11630 (unset_in_environ): Delete function.
11631 (gdb_environ::unset): New function.
11632 (gdb_environ::envp): Likewise.
11633 * common/environ.h: Include <vector>.
11634 (struct gdb_environ): Delete; transform into...
11635 (class gdb_environ): ... this class.
11636 (free_environ): Delete prototype.
11637 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11638 environ_vector): Likewise.
11639 * infcmd.c (run_command_1): Update code to call
11640 'envp' from 'gdb_environ' class.
11641 (environment_info): Update code to call methods from 'gdb_environ'
11643 (unset_environment_command): Likewise.
11644 (path_info): Likewise.
11645 (path_command): Likewise.
11646 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11647 (inferior::inferior): Initialize 'environment' using the host's
11649 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11650 Include "environ.h".
11651 (class inferior) <environment>: Change type from 'struct
11652 gdb_environ' to 'gdb_environ'.
11653 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11654 methods from 'gdb_environ' class.
11655 * solib.c (solib_find_1): Likewise
11656 * unittests/environ-selftests.c: New file.
11658 2017-06-20 Yao Qi <yao.qi@linaro.org>
11660 * features/i386/i386-linux.xml: Exchange the order of including
11661 32bit-linux.xml and 32bit-sse.xml.
11662 * features/i386/i386-linux.c: Regenerated.
11664 2017-06-20 Yao Qi <yao.qi@linaro.org>
11666 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11667 Delete copy ctor and assignment operator.
11668 (tdesc_type): Likewise.
11669 (tdesc_feature): Likewise.
11670 (tdesc_free_reg): Remove.
11671 (tdesc_create_reg): Use new.
11672 (tdesc_free_type): Remove.
11673 (tdesc_create_vector): Use new.
11674 (tdesc_create_union): Likewise.
11675 (tdesc_create_flags): Likewise.
11676 (tdesc_create_enum): Likewise.
11677 (tdesc_free_feature): Delete.
11678 (free_target_description): Use delete.
11680 2017-06-19 John Baldwin <jhb@FreeBSD.org>
11682 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11685 2017-06-19 Pedro Alves <palves@redhat.com>
11687 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11688 after gdb::unlinker.
11690 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11692 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11693 gdb_environ to access an environment variable.
11695 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11697 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11700 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11702 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11704 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11706 * configure: Re-generate.
11707 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11709 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11711 * configure: Re-generate.
11712 * warning.m4: Pass -Werror to compiler when checking for
11713 supported warning flags.
11715 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11717 * Makefile.in (COMPILE.pre): Add "-x c++".
11719 2017-06-16 Alan Hayward <alan.hayward@arm.com>
11720 Pedro Alves <palves@redhat.com>
11721 Yao Qi <yao.qi@linaro.org>
11723 * defs.h (RequireLongest): New.
11724 (extract_integer): Declare function template.
11725 (extract_signed_integer): Remove the declaration, but define it
11727 (extract_unsigned_integer): Likewise.
11728 (store_integer): Declare function template.
11729 (store_signed_integer): Remove the declaration, but define it
11731 (store_unsigned_integer): Likewise.
11732 * findvar.c (extract_integer): New function template.
11733 (extract_signed_integer): Remove.
11734 (extract_unsigned_integer): Remove.
11735 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11737 (store_integer): New function template.
11738 (store_signed_integer): Remove.
11739 (store_unsigned_integer): Remove.
11740 (store_integer): Explicit instantiations.
11741 * regcache.c (regcache_raw_read_signed): Update.
11742 (regcache::raw_read): New function.
11743 (regcache::raw_read_signed): Remove.
11744 (regcache::raw_read_unsigned): Remove.
11745 (regcache_raw_read_unsigned): Update.
11746 (regcache_raw_write_unsigned): Update.
11747 (regcache::raw_write_signed): Remove.
11748 (regcache::raw_write): New function.
11749 (regcache_cooked_read_signed): Update.
11750 (regcache::raw_write_unsigned): Remove.
11751 (regcache::cooked_read_signed): Remove.
11752 (regcache_cooked_read_unsigned): Update.
11753 (regcache::cooked_read_unsigned): Remove.
11754 (regcache_cooked_write_signed): Update.
11755 (regcache_cooked_write_unsigned): Update.
11756 * regcache.h (regcache) <raw_read_signed>: Remove.
11757 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11758 <raw_read, raw_write>: New.
11759 <cooked_read_signed, cooked_write_signed>: Remove.
11760 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11761 <cooked_read, cooked_write>: New.
11762 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11763 (sh64_pseudo_register_write): Update.
11765 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11767 * arc-tdep.c (arc_disassembler_options): New variable.
11768 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11769 of default_print_insn.
11770 (arc_delayed_print_insn): Set info->section when needed,
11771 use default_print_insn to retrieve a disassembler.
11773 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11776 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11777 to mention $SHELL and startup-with-shell.
11779 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11781 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11783 2017-06-14 Yao Qi <yao.qi@linaro.org>
11785 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11786 default_print_insn instead of print_insn_aarch64.
11787 * arm-tdep.c (gdb_print_insn_arm): Call
11788 default_print_insn instead of print_insn_big_arm
11789 and print_insn_little_arm.
11790 * i386-tdep.c (i386_print_insn): Call default_print_insn
11791 instead of print_insn_i386.
11792 * ia64-tdep.c (ia64_print_insn): Call
11793 default_print_insn instead of print_insn_ia64.
11794 * mips-tdep.c (gdb_print_insn_mips): Call
11795 default_print_insn instead of print_insn_big_mips
11796 and print_insn_little_mips.
11797 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11798 instead of print_insn_spu.
11800 2017-06-14 Pedro Alves <palves@redhat.com>
11802 * ada-lang.c: Include "common/byte-vector.h".
11803 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11804 * charset.c (wchar_iterator::iterate): Resize the vector instead
11806 * common/byte-vector.h: Include "common/def-vector.h".
11807 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11808 * cli/cli-dump.c: Include "common/byte-vector.h".
11809 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11810 * common/byte-vector.h: New file.
11811 * common/def-vector.h: New file.
11812 * common/default-init-alloc.h: New file.
11813 * dwarf2loc.c: Include "common/byte-vector.h".
11814 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11815 instead of reserving it.
11816 * dwarf2read.c: Include "common/byte-vector.h".
11817 (data_buf::m_vec): Now a gdb::byte_vector.
11818 * gdb_regex.c: Include "common/def-vector.h".
11819 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11820 * mi/mi-main.c: Include "common/byte-vector.h".
11821 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11822 * printcmd.c: Include "common/byte-vector.h".
11823 (print_scalar_formatted): Use gdb::byte_vector.
11824 * valprint.c: Include "common/byte-vector.h".
11825 (maybe_negate_by_bytes, print_decimal_chars): Use
11828 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11830 * darwin-nat.c: Include "nat/fork-inferior.h".
11832 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11834 * configure.nat: Factor out Darwin bits that are not
11835 architecture-specific. Add fork-inferior.o.
11837 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11839 * configure.nat: Factor out AIX bits that are not
11840 architecture-specific. Add fork-inferior.o.
11842 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11844 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11845 (read_pieced_value, write_pieced_value): ...here. Reduce to
11846 wrappers that just call rw_pieced_value.
11848 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11850 * dwarf2loc.c (write_pieced_value): When writing the data for a
11851 memory piece, use write_memory_with_notification instead of
11854 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11856 * valops.c (read_value_memory): Change embedded_offset to
11857 represent a bit offset instead of a byte offset.
11858 * value.h (read_value_memory): Adjust comment.
11860 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11862 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11863 dest_offset_bits and source_offset_bits.
11864 (write_pieced_value): Likewise.
11866 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11868 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11869 given by DW_OP_bit_piece.
11870 (write_pieced_value): Likewise.
11872 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11874 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11875 some other preparations to the places where sufficient information
11877 (write_pieced_value): Likewise.
11879 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11881 * dwarf2loc.c (bits_to_bytes): New function.
11882 (read_pieced_value): Fix offset calculations for register pieces
11883 on big-endian targets.
11884 (write_pieced_value): Likewise.
11886 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11888 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11889 (write_pieced_value): Likewise.
11891 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11893 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11894 transfer the source value's least significant bits, instead of its
11895 lowest-addressed ones. Rename type_len to max_offset.
11896 (read_pieced_value): Mirror above changes to write_pieced_value as
11899 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11901 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11902 truncate full bytes from dest_offset_bits before using it as an
11903 offset into the buffer.
11905 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11907 * dwarf2loc.c (write_pieced_value): Include transfer size in
11910 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11912 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11913 calculation of this_size.
11915 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11917 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
11918 when targeting a bit-field.
11919 (write_pieced_value): Likewise.
11921 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11923 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
11924 (allocate_piece_closure): Drop addr_size parameter.
11925 (dwarf2_evaluate_loc_desc_full): Adjust call to
11926 allocate_piece_closure.
11928 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11931 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
11932 the LSB end, independent of endianness.
11934 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11936 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
11939 2017-06-13 Yao Qi <yao.qi@linaro.org>
11941 * mips-linux-nat.c: Move include features/mips*-linux.c to
11943 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
11944 to mips-linux-tdep.c.
11945 * mips-linux-tdep.c: Include features/mips*-linux.c
11946 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
11948 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
11949 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
11950 (tdesc_mips64_dsp_linux): Declare.
11952 2017-06-12 Tom Tromey <tom@tromey.com>
11954 * valprint.h (val_print_type_code_int): Remove.
11955 * valprint.c (generic_val_print_int): Always call
11956 val_print_scalar_formatted.
11957 (val_print_type_code_int): Remove.
11958 * printcmd.c (print_scalar_formatted): Handle options->format==0.
11959 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
11960 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
11961 * ada-valprint.c (ada_val_print_num): Use
11962 val_print_scalar_formatted.
11964 2017-06-12 Tom Tromey <tom@tromey.com>
11966 * printcmd.c (print_scalar_formatted): Unify the two switches.
11967 Don't convert scalars to LONGEST.
11969 2017-06-12 Tom Tromey <tom@tromey.com>
11972 * valprint.h (print_decimal_chars): Update.
11973 * valprint.c (maybe_negate_by_bytes): New function.
11974 (print_decimal_chars): Add "is_signed" argument.
11975 * printcmd.c (print_scalar_formatted): Update.
11977 2017-06-12 Tom Tromey <tom@tromey.com>
11980 * valprint.h (print_binary_chars, print_hex_chars): Update.
11981 * valprint.c (val_print_type_code_int): Update.
11982 (print_binary_chars): Add "zero_pad" argument.
11983 (emit_octal_digit): New function.
11984 (print_octal_chars): Don't zero-pad.
11985 (print_decimal_chars): Likewise.
11986 (print_hex_chars): Add "zero_pad" argument.
11987 * sh64-tdep.c (sh64_do_fp_register): Update.
11988 * regcache.c (regcache::dump): Update.
11989 * printcmd.c (print_scalar_formatted): Update.
11990 * infcmd.c (default_print_one_register_info): Update.
11992 2017-06-12 Pedro Alves <palves@redhat.com>
11993 Alan Hayward <alan.hayward@arm.com>
11995 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
11996 (mips_eabi_push_dummy_call): Rename local 'regsize' to
11997 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
11998 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
11999 Assert that abi_regsize bytes fit in 'ref_valbuf'.
12001 2017-06-12 Pedro Alves <palves@redhat.com>
12003 * dwarf2read.c (mapped_symtab::data): Now a vector of
12004 symtab_index_entry instead of vector of
12005 std::unique_ptr<symtab_index_entry>. All users adjusted to check
12006 whether an element's name is NULL instead of checking whether the
12007 element itself is NULL.
12008 (find_slot): Change return type. Adjust.
12009 (hash_expand, , add_index_entry, uniquify_cu_indices)
12010 (write_hash_table): Adjust.
12012 2017-06-12 Pedro Alves <palves@redhat.com>
12014 * dwarf2read.c (recursively_count_psymbols): New function.
12015 (write_psymtabs_to_index): Call it to compute number of psyms and
12016 pass estimate size of psyms_seen to unordered_set's ctor.
12018 2017-06-12 Pedro Alves <palves@redhat.com>
12020 * dwarf2read.c (write_hash_table): Check if key already exists
12023 2017-06-12 Pedro Alves <palves@redhat.com>
12025 * dwarf2read.c (data_buf::append_space): Rename to...
12026 (data_buf::grow): ... this, and make private. Adjust all callers.
12027 (data_buf::append_uint): New method.
12028 (add_address_entry, write_one_signatured_type)
12029 (write_psymtabs_to_index): Use it.
12031 2017-06-12 Pedro Alves <palves@redhat.com>
12033 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
12034 (file_write (FILE *, const std::vector<Elem>&)): Delete.
12035 (data_buf::file_write): Call ::fwrite directly.
12037 2017-06-12 Pedro Alves <palves@redhat.com>
12039 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
12040 std::vector::erase.
12042 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12044 Code cleanup: C++ify .gdb_index producer.
12045 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
12046 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
12047 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
12048 (create_strtab, add_string): Remove.
12049 (file_write, data_buf): New.
12050 (struct symtab_index_entry): Use std::vector for cu_indices.
12051 (struct mapped_symtab): Use std::vector for data.
12052 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
12053 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
12055 (find_slot): Change return type. Update it to the new data structures.
12056 (hash_expand, add_index_entry): Update it to the new data structures.
12057 (offset_type_compare): Remove.
12058 (uniquify_cu_indices): Update it to the new data structures.
12059 (c_str_view, c_str_view_hasher, vector_hasher): New.
12060 (add_indices_to_cpool): Remove.
12061 (write_hash_table): Update it to the new data structures.
12062 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
12063 (eq_psymtab_cu_index): Remove.
12064 (psym_index_map): New typedef.
12065 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
12066 reference and std::unordered_map for cu_index_htab.
12067 (add_address_entry, add_address_entry_worker, write_address_map)
12068 (write_psymbols): Update it to the new data structures.
12069 (write_obstack): Remove.
12070 (struct signatured_type_index_data): Change types_list to a data_buf
12071 reference and psyms_seen to a std::unordered_set reference.
12072 (write_one_signatured_type, recursively_write_psymbols)
12073 (write_psymtabs_to_index): Update it to the new data structures.
12075 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
12077 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
12078 separate-debug-file commands.
12079 * symfile.h (separate_debug_file_debug): New global.
12080 * symfile.c (separate_debug_file_debug): New global.
12081 (separate_debug_file_exists, find_separate_debug_file): Add
12083 (_initialize_symfile): Add "set debug separate-debug-file"
12085 * build-id.c (build_id_to_debug_bfd,
12086 find_separate_debug_file_by_buildid): Add debug output.
12088 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
12090 * gdbarch.sh (displaced_step_free_closure): Remove.
12091 * gdbarch.h, gdbarch.c: Re-generate.
12092 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
12093 displaced_step_free_closure.
12094 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
12095 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
12096 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
12097 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
12098 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
12099 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12100 * arch-utils.h (simple_displaced_step_free_closure): Remove.
12101 * arch-utils.c (simple_displaced_step_free_closure): Remove.
12102 * infrun.c (displaced_step_clear): Call xfree instead of
12103 gdbarch_displaced_step_free_closure.
12105 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
12107 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
12110 2017-06-08 Alan Hayward <alan.hayward@arm.com>
12112 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
12113 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
12114 (mn10300_push_dummy_call): Likewise.
12116 2017-06-08 Alan Hayward <alan.hayward@arm.com>
12118 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
12120 2017-06-08 Alan Hayward <alan.hayward@arm.com>
12122 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
12124 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12126 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
12127 able to start inferiors using a shell.
12128 (New remote packets): Announce new packet "QStartupWithShell".
12129 * remote.c: Add PACKET_QStartupWithShell.
12130 (extended_remote_create_inferior): Handle new
12131 PACKET_QStartupWithShell.
12132 (remote_protocol_features) <QStartupWithShell>: New entry for
12133 PACKET_QStartupWithShell.
12134 (_initialize_remote): Call "add_packet_config_cmd" for
12137 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12138 Pedro Alves <palves@redhat.com>
12140 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
12141 and "nat/fork-inferior.h".
12142 * common/common-inferior.h: New file, with contents from
12144 * commom/common-utils.c: Include "common-utils.h".
12145 (stringify_argv): New function.
12146 * common/common-utils.h (stringify_argv): New prototype.
12147 * configure.nat: Add "fork-inferior.o" as a dependency for
12148 "*linux*", "fbsd*" and "nbsd*" hosts.
12149 * corefile.c (get_exec_file): Update comment.
12150 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
12151 instead of "startup_inferior".
12152 (darwin_create_inferior): Call "add_thread_silent" after
12154 * fork-child.c: Cleanup unnecessary includes.
12155 (SHELL_FILE): Move to "common/common-fork-child.c".
12156 (environ): Likewise.
12157 (exec_wrapper): Initialize.
12158 (get_exec_wrapper): New function.
12159 (breakup_args): Move to "common/common-fork-child.c"; rename to
12160 "breakup_args_for_exec".
12161 (escape_bang_in_quoted_argument): Move to
12162 "common/common-fork-child.c".
12163 (saved_ui): New variable.
12164 (prefork_hook): New function.
12165 (postfork_hook): Likewise.
12166 (postfork_child_hook): Likewise.
12167 (gdb_startup_inferior): Likewise.
12168 (fork_inferior): Move to "common/common-fork-child.c". Update
12169 function to support gdbserver.
12170 (startup_inferior): Likewise.
12171 * gdbcore.h (get_exec_file): Remove declaration.
12172 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
12173 instead of "startup_inferior". Call "add_thread_silent" after
12175 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
12176 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
12177 instead of "startup_inferior". Call "add_thread_silent" after
12179 * inferior.h: Include "common-inferior.h".
12180 (trace_start_error): Move to "common/common-utils.h".
12181 (trace_start_error_with_name): Likewise.
12182 (fork_inferior): Move prototype to "nat/fork-inferior.h".
12183 (startup_inferior): Likewise.
12184 (gdb_startup_inferior): New prototype.
12185 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
12186 * nat/fork-inferior.h: New file.
12187 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
12188 instead of "startup_inferior". Call "add_thread_silent" after
12190 * target.h (target_terminal_init): Move prototype to
12192 (target_terminal_inferior): Likewise.
12193 (target_terminal_ours): Likewise.
12194 * target/target.h (target_terminal_init): New prototype, moved
12196 (target_terminal_inferior): Likewise.
12197 (target_terminal_ours): Likewise.
12198 * utils.c (gdb_flush_out_err): New function.
12200 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12202 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
12203 * common/common-gdbthread.h: New file, with parts from
12205 * gdbthread.h: Include "common-gdbthread.h".
12206 (switch_to_thread): Moved to "common/common-gdbthread.h".
12208 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12210 * Makefile.in (SFILES): Add "common/job-control.c".
12211 (HFILES_NO_SRCDIR): Add "common/job-control.h".
12212 (COMMON_OBS): Add "job-control.o".
12213 * common/job-control.c: New file, with contents from
12215 * common/job-control.h: New file, with contents from "terminal.h".
12216 * fork-child.c: Include "job-control.h".
12217 * inflow.c: Include "job-control.h".
12218 (gdb_setpgid): Move to "common/common-inflow.c".
12219 (_initialize_inflow): Move setting of "job_control" to
12220 "handle_job_control".
12221 * terminal.h (job_control): Moved to "common/common-terminal.h".
12222 (gdb_setpgid): Likewise.
12223 * top.c: Include "job_control.h".
12224 * utils.c: Likewise.
12225 (job_control): Moved to "job-control.c".
12227 2017-06-07 Pedro Alves <palves@redhat.com>
12229 * Makefile.in (SFILES): Add gdb_regex.c.
12230 (COMMON_OBS): Add gdb_regex.o.
12231 * ada-lang.c (ada_add_standard_exceptions)
12232 (ada_add_exceptions_from_frame, name_matches_regex)
12233 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
12234 parameter type to compiled_regex. Adjust.
12235 (ada_exceptions_list): Use compiled_regex.
12236 * break-catch-throw.c (exception_catchpoint::pattern): Now a
12237 std::unique_ptr<compiled_regex>.
12238 (exception_catchpoint::~exception_catchpoint): Remove regfree
12240 (check_status_exception_catchpoint): Adjust to use compiled_regex.
12241 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
12242 * breakpoint.c (solib_catchpoint::compiled): Now a
12243 std::unique_ptr<compiled_regex>.
12244 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
12245 (check_status_catch_solib): Adjust to use compiled_regex.
12246 (add_solib_catchpoint): Adjust to use compiled_regex.
12247 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
12248 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
12249 compiled_regex reference. Adjust to use it.
12250 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
12251 declaration. Include "gdb_regex.h".
12252 (apropos_cmd): Change regex parameter to compiled_regex reference.
12253 * gdb_regex.c: New file.
12254 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
12256 (class compiled_regex): New.
12257 * linux-tdep.c: Include "common/gdb_optional.h".
12258 (struct mapping_regexes): New, factored out from
12259 mapping_is_anonymous_p, and adjusted to use compiled_regex.
12260 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
12261 gdb::optional and remove cleanups. Adjust to compiled_regex.
12262 * probe.c: Include "common/gdb_optional.h".
12263 (collect_probes): Use compiled_regex and gdb::optional and remove
12265 * skip.c: Include "common/gdb_optional.h".
12266 (skiplist_entry::compiled_function_regexp): Now a
12267 gdb::optional<compiled_regex>.
12268 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
12269 (free_skiplist_entry): Remove regfree call.
12270 (compile_skip_regexp, skip_rfunction_p): Adjust to use
12271 compiled_regex and gdb::optional.
12272 * symtab.c: Include "common/gdb_optional.h".
12273 (search_symbols): Use compiled_regex and gdb::optional.
12274 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
12275 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
12278 2017-06-07 Alan Hayward <alan.hayward@arm.com>
12280 * regcache.c (regcache::save): Avoid buffer use.
12281 (regcache::dump): Likewise.
12283 2017-06-07 Alan Hayward <alan.hayward@arm.com>
12285 * sh-tdep.c (sh_pseudo_register_read): Remove
12287 (sh_pseudo_register_write): Likewise.
12288 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
12289 (sh64_pseudo_register_write): Likewise
12291 2017-06-07 Alan Hayward <alan.hayward@arm.com>
12293 * aarch64-tdep.c (aarch64_store_return_value): Use
12295 (aarch64_pseudo_read_value): Likewise.
12296 (aarch64_pseudo_write): Likewise.
12298 2017-06-06 Yao Qi <yao.qi@linaro.org>
12300 * regformats/regdef.h (set_register_cache): Remove the
12303 2017-06-06 Alan Hayward <alan.hayward@arm.com>
12305 * frame.c (frame_unwind_register_signed): Use
12306 frame_unwind_register_value.
12308 2017-06-06 Pedro Alves <palves@redhat.com>
12310 PR breakpoints/21553
12311 * breakpoint.c (create_breakpoints_sal_default)
12312 (init_breakpoint_sal, create_breakpoint_sal): Use
12313 gdb::unique_xmalloc_ptr for string parameters.
12314 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12315 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
12316 (base_breakpoint_create_breakpoints_sal)
12317 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
12318 (strace_marker_create_breakpoints_sal)
12319 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
12321 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
12322 gdb::unique_xmalloc_ptr for string parameters.
12323 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12326 2017-06-06 Alan Hayward <alan.hayward@arm.com>
12328 * alpha-tdep.c (alpha_register_to_value): Use
12329 get_frame_register_value.
12330 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
12332 2017-06-06 Alan Hayward <alan.hayward@arm.com>
12334 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
12335 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
12336 (ia64_value_to_register): Likewise.
12337 (ia64_extract_return_value): Likewise.
12338 (ia64_store_return_value): Likewise.
12339 (ia64_push_dummy_call): Likewise.
12341 2017-06-04 Joel Brobecker <brobecker@adacore.com>
12345 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
12347 * x86-linux-nat.c (struct arch_lwp_info): Remove.
12349 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
12351 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
12353 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
12355 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
12357 * event-loop.c (poll_timers): Unallocate timer using delete
12360 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12362 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
12363 (struct breakpoint) <~breakpoint>: New.
12364 (struct watchpoint): Inherit from breakpoint.
12365 <~watchpoint>: New.
12367 (struct tracepoint): Inherit from breakpoint.
12369 * breakpoint.c (longjmp_breakpoint_ops): Remove.
12370 (struct longjmp_breakpoint): Inherit from breakpoint.
12371 <~longjmp_breakpoint>: New.
12373 (new_breakpoint_from_type): Remove casts.
12374 (watchpoint_in_thread_scope): Remove reference to base field.
12375 (watchpoint_del_at_next_stop): Likewise.
12376 (update_watchpoint): Likewise.
12377 (watchpoint_check): Likewise.
12378 (bpstat_check_watchpoint): Likewise.
12379 (set_longjmp_breakpoint): Likewise.
12380 (struct fork_catchpoint): Inherit from breakpoint.
12382 (struct solib_catchpoint): Inherit from breakpoint.
12383 <~solib_catchpoint>: New.
12385 (dtor_catch_solib): Change to ...
12386 (solib_catchpoint::~solib_catchpoint): ... this.
12387 (breakpoint_hit_catch_solib): Remove reference to base field.
12388 (add_solib_catchpoint): Likewise.
12389 (create_fork_vfork_event_catchpoint): Likewise.
12390 (struct exec_catchpoint): Inherit from breakpoint.
12391 <~exec_catchpoint>: New.
12393 (dtor_catch_exec): Change to ...
12394 (exec_catchpoint::~exec_catchpoint): ... this.
12395 (dtor_watchpoint): Change to ...
12396 (watchpoint::~watchpoint): ... this.
12397 (watch_command_1): Remove reference to base field.
12398 (catch_exec_command_1): Likewise.
12399 (base_breakpoint_dtor): Change to ...
12400 (breakpoint::~breakpoint): ... this.
12401 (base_breakpoint_ops): Remove dtor field value.
12402 (longjmp_bkpt_dtor): Change to ...
12403 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
12404 (strace_marker_create_breakpoints_sal): Remove reference to base
12406 (delete_breakpoint): Don't manually call breakpoint destructor.
12407 (create_tracepoint_from_upload): Remove reference to base field.
12408 (trace_pass_set_count): Likewise.
12409 (initialize_breakpoint_ops): Don't initialize
12410 momentary_breakpoint_ops, don't set dtors.
12411 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
12412 <~ada_catchpoint>: New.
12414 (create_excep_cond_exprs): Remove reference to base field.
12415 (dtor_exception): Change to ...
12416 (ada_catchpoint::~ada_catchpoint): ... this.
12417 (dtor_catch_exception): Remove.
12418 (dtor_catch_exception_unhandled): Remove.
12419 (dtor_catch_assert): Remove.
12420 (create_ada_exception_catchpoint): Remove reference to base
12422 (initialize_ada_catchpoint_ops): Don't set dtors.
12423 * break-catch-sig.c (struct signal_catchpoint): Inherit from
12425 <~signal_catchpoint>: New.
12427 (signal_catchpoint_dtor): Change to ...
12428 (signal_catchpoint::~signal_catchpoint): ... this.
12429 (create_signal_catchpoint): Remove reference to base field.
12430 (initialize_signal_catchpoint_ops): Don't set dtor.
12431 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
12433 <~syscall_catchpoint>: New.
12435 (dtor_catch_syscall): Change to ...
12436 (syscall_catchpoint::~syscall_catchpoint): ... this.
12437 (create_syscall_event_catchpoint): Remove reference to base
12439 (initialize_syscall_catchpoint_ops): Don't set dtor.
12440 * break-catch-throw.c (struct exception_catchpoint): Inherit
12442 <~exception_catchpoint>: New.
12444 (dtor_exception_catchpoint): Change to ...
12445 (exception_catchpoint::~exception_catchpoint): ... this.
12446 (handle_gnu_v3_exceptions): Remove reference to base field.
12447 (initialize_throw_catchpoint_ops): Don't set dtor.
12448 * ctf.c (ctf_get_traceframe_address): Remove reference to base
12450 * remote.c (remote_get_tracepoint_status): Likewise.
12451 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
12452 * tracefile.c (tracefile_fetch_registers): Likewise.
12453 * tracepoint.c (actions_command): Likewise.
12454 (validate_actionline): Likewise.
12455 (tfind_1): Likewise.
12456 (get_traceframe_location): Likewise.
12457 (find_matching_tracepoint_location): Likewise.
12458 (parse_tracepoint_status): Likewise.
12459 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
12461 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12463 * breakpoint.c (struct longjmp_breakpoint): New struct.
12464 (is_tracepoint_type): Change return type to bool.
12465 (is_longjmp_type): New function.
12466 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
12467 (set_raw_breakpoint_without_location): Use
12468 new_breakpoint_from_type.
12469 (set_raw_breakpoint): Likewise.
12471 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12473 * breakpoint.c (new_breakpoint_from_type): New function.
12474 (create_breakpoint_sal): Use new_breakpoint_from_type and
12476 (create_breakpoint): Likewise.
12478 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
12480 * memattr.c (mem_info_command): Rename to ...
12481 (info_mem_command): ... this.
12482 (mem_enable_command): Rename to ...
12483 (enable_mem_command): ... this.
12484 (mem_disable_command): Rename to ...
12485 (disable_mem_command): ... this.
12486 (mem_delete_command): Rename to ...
12487 (delete_mem_command): ... this.
12488 (_initialize_mem): Adjust function names.
12490 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12492 * btrace.c (handle_pt_insn_events): New.
12493 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
12494 STATUS. Split into this and ...
12495 (handle_pt_insn_event_flags): ... this.
12497 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12499 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
12500 and struct pt_insn.resynced.
12501 * configure: Regenerated.
12502 * config.in: Regenerated.
12504 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12506 * btrace.c (ftrace_find_call_by_number): New function.
12507 (ftrace_new_function): Store objects, not pointers.
12508 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
12509 ftrace_new_gap, ftrace_update_function,
12510 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
12511 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
12512 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
12513 btrace_ends_with_single_insn, btrace_call_get): Account for
12514 btrace_thread_info::functions now storing objects.
12515 * btrace.h (struct btrace_thread_info): Add constructor.
12516 (struct btrace_thread_info) <functions>: Make std::vector.
12517 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
12518 Initialize with default values.
12519 * record-btrace.c (record_btrace_frame_sniffer): Account for
12520 btrace_thread_info::functions now storing objects.
12522 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12524 * btrace.c: Remove typedef bfun_s.
12525 (ftrace_new_gap): Directly add gaps to the list of gaps.
12526 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
12527 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
12528 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
12529 instead of gdb VEC.
12531 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12533 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
12534 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
12535 with btrace_thread_info::next_segment and
12536 btrace_thread_info::prev_segment.
12537 * btrace.h: Remove struct btrace_func_link.
12538 (struct btrace_function): Replace pair of function segment pointers
12539 with pair of indices.
12540 * python/py-record-btrace.c (btpy_call_prev_sibling,
12541 btpy_call_next_sibling): Replace references to
12542 btrace_thread_info::segment with btrace_thread_info::next_segment and
12543 btrace_thread_info::prev_segment.
12544 * record-btrace.c (record_btrace_frame_this_id): Use
12545 btrace_find_call_by_number.
12547 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12549 * btrace.c (ftrace_new_function, ftrace_fixup_level,
12550 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
12551 btrace_insn_next, btrace_insn_prev): Remove references to
12552 btrace_thread_info::flow.
12553 * btrace.h (struct btrace_function): Remove FLOW.
12555 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12557 * btrace.c (ftrace_find_call_by_number): New function.
12558 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
12559 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
12560 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
12561 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
12563 * btrace.h (struct btrace_function): Turn UP into an index.
12564 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
12566 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
12567 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12568 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12570 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12572 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12573 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12574 ftrace_update_function, ftrace_compute_global_level_offset,
12575 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12576 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12577 btrace_insn_end, btrace_is_empty): Remove references to
12578 btrace_thread_info::begin and btrace_thread_info::end.
12579 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12580 (struct btrace_thread_info) <functions>: Adjust comment.
12581 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12582 btrace_thread_info::begin.
12584 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12586 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12587 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12588 ftrace_update_function): Remove arguments that implicitly were always
12590 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12591 Don't pass BTINFO->END.
12593 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12595 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12596 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12597 btrace_find_insn_by_number): Replace function segment pointer with
12599 (btrace_insn_cmp): Simplify.
12600 * btrace.h: (struct btrace_insn_iterator) Rename index to
12601 insn_index. Replace function segment pointer with index into function
12603 * record-btrace.c (record_btrace_call_history): Replace function
12604 segment pointer use with index.
12605 (record_btrace_frame_sniffer): Retrieve function call segment through
12607 (record_btrace_set_replay): Remove defunc't safety check.
12609 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12611 * btrace.c (btrace_ends_with_single_insn): New function.
12612 (btrace_call_get, btrace_call_number, btrace_call_begin,
12613 btrace_call_end, btrace_call_next, btrace_call_prev,
12614 btrace_find_call_by_number): Use index into call segment vector
12615 instead of pointer.
12616 (btrace_call_cmp): Simplify.
12617 * btrace.h (struct btrace_call_iterator): Replace function call segment
12618 pointer with index into vector.
12619 * record-btrace.c (record_btrace_call_history): Use index instead of
12622 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12624 * btrace.c (btrace_insn_begin, btrace_insn_end,
12625 btrace_find_insn_by_number): Add btinfo to iterator.
12626 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12628 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12630 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12631 and save pointers directly.
12632 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12633 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12634 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12635 changed signature of functions.
12636 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12637 (btrace_fetch): Remove code that adds btrace_function pointers to
12638 vector of btrace_functions.
12639 (btrace_clear): Simplify freeing vector of btrace_functions.
12641 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12643 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12644 Replace VEC_* with std::vector functions.
12645 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12646 (struct btrace_thread_info)<functions>: Change type to std::vector.
12648 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12650 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12651 "Removed targets and native configurations" up. Merge duplicate
12652 "New commands" sub-sections. Add "New options" sub-sections.
12654 2017-05-26 Alan Hayward <alan.hayward@arm.com>
12656 * defs.h (copy_integer_to_size): New declaration.
12657 * findvar.c (copy_integer_to_size): New function.
12658 (do_cint_test): New selftest function.
12659 (copy_integer_to_size_test): Likewise.
12660 (_initialize_findvar): Likewise.
12661 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12662 (mips_fbsd_collect_reg): Use raw_collect_integer.
12663 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12664 (mips64_fill_gregset): Use raw_collect_integer
12665 (mips64_fill_fpregset): Use raw_supply_integer.
12666 * regcache.c (regcache::raw_supply_integer): New function.
12667 (regcache::raw_collect_integer): Likewise.
12668 * regcache.h: (regcache::raw_supply_integer): New declaration.
12669 (regcache::raw_collect_integer): Likewise.
12671 2017-05-24 Yao Qi <yao.qi@linaro.org>
12673 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12674 (COMMON_OBS): Add gdbarch-selftests.o.
12675 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12676 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12677 * gdbarch-selftests.c: New file.
12678 * regcache.h (regcache) <~regcache>: Mark it virtual if
12680 <raw_write>: Likewise.
12682 2017-05-24 Yao Qi <yao.qi@linaro.org>
12684 * regcache.c (current_regcache): Change it to
12685 regcache::current_regcache.
12686 (regcache_observer_target_changed): Update.
12687 (regcache_thread_ptid_changed): Make it a regcache static
12689 (regcache_thread_ptid_changed): Update.
12690 (class regcache_access): New.
12691 (current_regcache_test): Update.
12692 (_initialize_regcache): Update.
12693 * regcache.h: Include forward_list.
12694 (regcache): Declare regcache_thread_ptid_changed and declare
12695 registers_changed_ptid as friend.
12697 2017-05-24 Yao Qi <yao.qi@linaro.org>
12699 * i387-tdep.c (i387_register_to_value): Use register_size
12700 instead of TYPE_LENGTH.
12701 * m68k-tdep.c (m68k_register_to_value): Likewise.
12703 2017-05-24 Yao Qi <yao.qi@linaro.org>
12705 * i387-tdep.c (i387_convert_register_p): Return false if type
12706 code isn't TYPE_CODE_FLT.
12708 2017-05-24 Yao Qi <yao.qi@linaro.org>
12710 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12712 (alpha_register_to_value): Remove type length check.
12713 (alpha_value_to_register): Likewise.
12715 2017-05-24 Yao Qi <yao.qi@linaro.org>
12717 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12720 2017-05-24 Yao Qi <yao.qi@linaro.org>
12722 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12723 TYPE_CODE_FLT or not.
12725 2017-05-24 Yao Qi <yao.qi@linaro.org>
12727 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12728 * avr-tdep.c (avr_gdbarch_init): Likewise.
12729 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12730 * cris-tdep.c (cris_gdbarch_init): Likewise.
12731 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12732 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12733 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12734 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12735 * mep-tdep.c (mep_gdbarch_init): Likewise.
12736 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12737 * mips-tdep.c (mips_gdbarch_init): Likewise.
12738 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12739 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12740 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12741 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12742 * v850-tdep.c (v850_gdbarch_init): Likewise.
12744 2017-05-24 Yao Qi <yao.qi@linaro.org>
12746 * selftest-arch.c (tests_with_arch): Call registers_changed
12747 and reinit_frame_cache.
12748 * selftest.c (run_self_tests): Likewise.
12750 2017-05-24 Yao Qi <yao.qi@linaro.org>
12752 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12753 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12755 2017-05-24 Yao Qi <yao.qi@linaro.org>
12757 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12758 set_gdbarch_print_insn.
12760 2017-05-24 Yao Qi <yao.qi@linaro.org>
12762 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12763 set_gdbarch_print_insn.
12765 2017-05-24 Yao Qi <yao.qi@linaro.org>
12767 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12768 set_gdbarch_print_insn.
12769 * arc-tdep.c (arc_gdbarch_init): Likewise.
12770 * arch-utils.c: include dis-asm.h.
12771 (default_print_insn): New function.
12772 * arch-utils.h (default_print_insn): Declare.
12773 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12774 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12775 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12776 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12777 * frv-tdep.c (frv_gdbarch_init): Likewise.
12778 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12779 * gdbarch.sh (print_insn): Use default_print_insn.
12780 * gdbarch.c: Regenerated.
12781 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12782 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12783 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12784 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12785 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12786 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12787 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12788 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12789 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12790 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12791 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12792 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12793 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12794 * mt-tdep.c (mt_gdbarch_init): Likewise.
12795 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12796 * nios2-tdep.c (nios2_print_insn): Remove.
12797 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12798 * rx-tdep.c (rx_gdbarch_init): Likewise.
12799 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12800 * score-tdep.c (score_print_insn): Remove.
12801 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12802 * sh-tdep.c (sh_gdbarch_init): Likewise.
12803 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12804 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12805 * tic6x-tdep.c (tic6x_print_insn): Remove.
12806 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12807 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12808 * v850-tdep.c (v850_gdbarch_init): Likewise.
12809 * vax-tdep.c (vax_gdbarch_init): Likewise.
12810 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12811 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12813 2017-05-23 John Baldwin <jhb@FreeBSD.org>
12815 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12816 (MIPS_FP0_REGNUM): Remove.
12817 (MIPS_FSR_REGNUM): Remove.
12818 (mips_fbsd_supply_fpregs): Use mips_regnum.
12819 (mips_fbsd_supply_gregs): Likewise.
12820 (mips_fbsd_collect_fpregs): Likewise.
12821 (mips_fbsd_collect_gregs): Likewise.
12823 2017-05-23 John Baldwin <jhb@FreeBSD.org>
12825 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12826 (getpfpregs_supplies): New function.
12827 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12828 getfpregs_supplies.
12829 (mips_fbsd_store_inferior_registers): Likewise.
12831 2017-05-22 Pedro Alves <palves@redhat.com>
12833 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12836 2017-05-22 Alan Hayward <alan.hayward@arm.com>
12838 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12839 (store_register): Likewise.
12840 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12841 (get_decimal_float_return_value): Likewise.
12842 (do_ppc_sysv_return_value): Likewise.
12843 (ppc64_sysv_abi_push_integer): Likewise.
12844 (ppc64_sysv_abi_push_freg): Likewise.
12845 (ppc64_sysv_abi_return_value_base): Likewise.
12846 (ppc64_sysv_abi_return_value): Likewise.
12847 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12848 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12849 * rs6000-nat.c: Likewise.
12850 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12851 (rs6000_value_to_register): Likewise.
12852 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12854 2017-05-21 Tom Tromey <tom@tromey.com>
12857 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12858 arrays as "[T]", not "[T; ]".
12860 2017-05-19 Tom Tromey <tom@tromey.com>
12863 * rust-lang.c (exp_descriptor_rust): New function.
12864 (rust_language_defn): Use it.
12865 * p-lang.c (pascal_language_defn): Update.
12866 * opencl-lang.c (opencl_language_defn): Update.
12867 * objc-lang.c (objc_language_defn): Update.
12868 * m2-lang.c (m2_language_defn): Update.
12869 * language.h (struct language_defn)
12870 <la_watch_location_expression>: New member.
12871 * language.c (unknown_language_defn, auto_language_defn)
12872 (local_language_defn): Update.
12873 * go-lang.c (go_language_defn): Update.
12874 * f-lang.c (f_language_defn): Update.
12875 * d-lang.c (d_language_defn): Update.
12876 * c-lang.h (c_watch_location_expression): Declare.
12877 * c-lang.c (c_watch_location_expression): New function.
12878 (c_language_defn, cplus_language_defn, asm_language_defn)
12879 (minimal_language_defn): Use it.
12880 * breakpoint.c (watch_command_1): Call
12881 la_watch_location_expression.
12882 * ada-lang.c (ada_language_defn): Update.
12884 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12887 * gdb_curses.h (NOMACROS): Define.
12888 (NCURSES_NOMACROS): Define.
12890 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12893 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12895 * tui/tui-wingeneral.c (box_win): Likewise.
12896 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12897 (tui_show_source_line): Likewise.
12898 (tui_show_exec_info_content): Likewise.
12900 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12902 * sparc-tdep.c (sparc_structure_return_p)
12903 (sparc_arg_on_registers_p): New functions.
12904 (sparc32_store_arguments): Use them.
12905 * sparc64-tdep.c (sparc64_16_byte_align_p)
12906 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12907 Handle TYPE_CODE_ARRAY.
12909 2017-05-17 Yao Qi <yao.qi@linaro.org>
12911 * cli/cli-decode.c (add_alias_cmd): New function.
12912 * command.h (add_alias_cmd): Declare.
12913 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
12914 instead call add_alias_cmd.
12916 2017-05-17 Pedro Alves <palves@redhat.com>
12918 * Makefile.in (nat_extra_makefile_frag): Rename to ...
12919 (nat_makefile_frag): ... this. All references updated.
12920 * configure.ac: Likewise.
12921 * configure.nat: Likewise. Enhance comments.
12922 * configure: Regenerate.
12924 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12926 * procfs.c (procfs_create_inferior): Change prototype to match
12929 2017-05-13 Eli Zaretskii <eliz@gnu.org>
12931 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
12932 C++ compiler warning.
12934 2017-05-12 Tom Tromey <tom@tromey.com>
12937 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
12938 recurse, just call value_struct_elt directly.
12940 2017-05-12 Tom Tromey <tom@tromey.com>
12942 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
12943 OP_RUST_ARRAY>: Fix.
12945 2017-05-12 Tom Tromey <tom@tromey.com>
12947 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
12949 2017-05-09 Yao Qi <yao.qi@linaro.org>
12951 * regcache.c: Include <forward_list>.
12952 (struct regcache_list): Remove.
12953 (current_regcache): Update.
12954 (get_thread_arch_aspace_regcache): Update for std::forward_list.
12955 (regcache_thread_ptid_changed): Likewise.
12956 (registers_changed_ptid): Likewise.
12957 (current_regcache_size): Likewise.
12959 2017-05-09 Yao Qi <yao.qi@linaro.org>
12961 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
12962 (current_regcache_size): New function.
12963 (current_regcache_test): New function.
12964 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
12966 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12968 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
12969 (print_gp_register_row): Use get_frame_register_value.
12971 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12973 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
12974 (mips_supply_fpregset): Likewise.
12975 (mips64_supply_gregset): Likewise.
12977 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12979 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
12980 regcache->raw_supply_zeroed.
12982 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12984 * configure.nat: Rearrange 'case' statements to match
12987 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12989 * Makefile.in: Remove "@host_makefile_frag@". Add variables
12990 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
12991 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
12992 "@nat_extra_makefile_frag@".
12993 (Makefile): Remove dependency on "@frags@".
12994 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
12995 (data-directory/Makefile): Likewise.
12996 * config/aarch64/linux.mh: Deleted; moved contents to
12997 "gdb/configure.nat".
12998 * config/alpha/alpha-linux.mh: Likewise.
12999 * config/alpha/nbsd.mh: Likewise.
13000 * config/arm/linux.mh: Likewise.
13001 * config/arm/nbsdelf.mh: Likewise.
13002 * config/i386/cygwin.mh: Likewise.
13003 * config/i386/cygwin64.mh: Likewise.
13004 * config/i386/darwin.mh: Likewise.
13005 * config/i386/fbsd.mh: Likewise.
13006 * config/i386/fbsd64.mh: Likewise.
13007 * config/i386/go32.mh: Likewise.
13008 * config/i386/i386gnu.mh: Likewise.
13009 * config/i386/i386sol2.mh: Likewise.
13010 * config/i386/linux.mh: Likewise.
13011 * config/i386/linux64.mh: Likewise.
13012 * config/i386/mingw.mh: Likewise.
13013 * config/i386/mingw64.mh: Likewise.
13014 * config/i386/nbsd64.mh: Likewise.
13015 * config/i386/nbsdelf.mh: Likewise.
13016 * config/i386/nto.mh: Likewise.
13017 * config/i386/obsd.mh: Likewise.
13018 * config/i386/obsd64.mh: Likewise.
13019 * config/i386/sol2-64.mh: Likewise.
13020 * config/ia64/linux.mh: Likewise.
13021 * config/m32r/linux.mh: Likewise.
13022 * config/m68k/linux.mh: Likewise.
13023 * config/m68k/nbsdelf.mh: Likewise.
13024 * config/m68k/obsd.mh: Likewise.
13025 * config/m88k/obsd.mh: Likewise.
13026 * config/mips/fbsd.mh: Likewise.
13027 * config/mips/linux.mh: Likewise.
13028 * config/mips/nbsd.mh: Likewise.
13029 * config/mips/obsd64.mh: Likewise.
13030 * config/pa/linux.mh: Likewise.
13031 * config/pa/nbsd.mh: Likewise.
13032 * config/pa/obsd.mh: Likewise.
13033 * config/powerpc/aix.mh: Likewise.
13034 * config/powerpc/fbsd.mh: Likewise.
13035 * config/powerpc/linux.mh: Likewise.
13036 * config/powerpc/nbsd.mh: Likewise.
13037 * config/powerpc/obsd.mh: Likewise.
13038 * config/powerpc/ppc64-linux.mh: Likewise.
13039 * config/powerpc/spu-linux.mh: Likewise.
13040 * config/s390/linux.mh: Likewise.
13041 * config/sh/nbsd.mh: Likewise.
13042 * config/sparc/fbsd.mh: Likewise.
13043 * config/sparc/linux.mh: Likewise.
13044 * config/sparc/linux64.mh: Likewise.
13045 * config/sparc/nbsd64.mh: Likewise.
13046 * config/sparc/nbsdelf.mh: Likewise.
13047 * config/sparc/obsd64.mh: Likewise.
13048 * config/sparc/sol2.mh: Likewise.
13049 * config/tilegx/linux.mh: Likewise.
13050 * config/vax/nbsdelf.mh: Likewise.
13051 * config/vax/obsd.mh: Likewise.
13052 * config/xtensa/linux.mh: Likewise.
13053 * config/i386/i386gnu.mn: New file, with excerpts from
13054 "config/i386/i386gnu.mh".
13055 * configure: Regenerate.
13056 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
13057 *.mh files under "gdb/config".
13058 * configure.nat: New file, with contents from the
13059 "gdb/config/*/*.mh" files.
13061 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
13063 * btrace.c (btrace_clear): Free insn vector.
13065 2017-05-05 Pedro Alves <palves@redhat.com>
13067 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
13068 * configure: Regenerate.
13070 2017-05-04 Pedro Alves <palves@redhat.com>
13072 * Makefile.in (SFILES): Add progspace-and-thread.c.
13073 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
13074 (COMMON_OBS): Add progspace-and-thread.o.
13075 * breakpoint.c: Include "progspace-and-thread.h".
13076 (update_inserted_breakpoint_locations)
13077 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
13078 Use scoped_restore_current_pspace_and_thread.
13079 (create_std_terminate_master_breakpoint): Use
13080 scoped_restore_current_program_space.
13081 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
13082 (print_breakpoint_location): Use
13083 scoped_restore_current_program_space.
13084 (bp_loc_is_permanent): Use
13085 scoped_restore_current_pspace_and_thread.
13086 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
13087 (download_tracepoint_locations): Use
13088 scoped_restore_current_pspace_and_thread.
13089 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
13090 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
13091 (enum step_over_calls_kind): Moved from inferior.h.
13092 (class scoped_restore_current_thread): New class.
13093 * gdbthread.h (make_cleanup_restore_current_thread): Delete
13095 (scoped_restore_current_thread): New class.
13096 * infcmd.c: Include "common/gdb_optional.h".
13097 (continue_1, proceed_after_attach): Use
13098 scoped_restore_current_thread.
13099 (notice_new_inferior): Use scoped_restore_current_thread.
13100 * inferior.c: Include "progspace-and-thread.h".
13101 (restore_inferior, save_current_inferior): Delete.
13102 (add_inferior_command, clone_inferior_command): Use
13103 scoped_restore_current_pspace_and_thread.
13104 * inferior.h (scoped_restore_current_inferior): New class.
13105 * infrun.c: Include "progspace-and-thread.h" and
13106 "common/gdb_optional.h".
13107 (follow_fork_inferior): Use
13108 scoped_restore_current_pspace_and_thread.
13109 (scoped_restore_exited_inferior): New class.
13110 (handle_vfork_child_exec_or_exit): Use
13111 scoped_restore_exited_inferior,
13112 scoped_restore_current_pspace_and_thread,
13113 scoped_restore_current_thread and scoped_restore.
13114 (fetch_inferior_event): Use scoped_restore_current_thread.
13115 * linespec.c (decode_line_full, decode_line_1): Use
13116 scoped_restore_current_program_space.
13117 * mi/mi-main.c: Include "progspace-and-thread.h".
13118 (exec_continue): Use scoped_restore_current_thread.
13119 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
13120 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
13121 * proc-service.c (ps_pglobal_lookup): Use
13122 scoped_restore_current_program_space.
13123 * progspace-and-thread.c: New file.
13124 * progspace-and-thread.h: New file.
13125 * progspace.c (release_program_space, clone_program_space): Use
13126 scoped_restore_current_program_space.
13127 (restore_program_space, save_current_program_space)
13128 (save_current_space_and_thread): Delete.
13129 (switch_to_program_space_and_thread): Moved to
13130 progspace-and-thread.c.
13131 * progspace.h (save_current_program_space)
13132 (save_current_space_and_thread): Delete declarations.
13133 (scoped_restore_current_program_space): New class.
13134 * remote.c (remote_btrace_maybe_reopen): Use
13135 scoped_restore_current_thread.
13136 * symtab.c: Include "progspace-and-thread.h".
13137 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
13138 * thread.c (print_thread_info_1): Use
13139 scoped_restore_current_thread.
13140 (struct current_thread_cleanup): Delete.
13141 (do_restore_current_thread_cleanup)
13142 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
13143 (scoped_restore_current_thread::~scoped_restore_current_thread):
13145 (make_cleanup_restore_current_thread): Rename/convert to ...
13146 (scoped_restore_current_thread::scoped_restore_current_thread):
13148 (thread_apply_all_command): Use scoped_restore_current_thread.
13149 (thread_apply_command): Use scoped_restore_current_thread.
13150 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
13151 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
13153 2017-05-04 Pedro Alves <palves@redhat.com>
13155 * thread.c (make_cleanup_restore_current_thread): Move
13156 find_thread_ptid call before the is_stopped call. Assert that the
13157 thread is found. Replace is_stopped call by checking the thread's
13158 state directly. Remove unnecessary NULL-thread check.
13160 2017-05-04 Pedro Alves <palves@redhat.com>
13162 * corelow.c (thread_section_name): New class.
13163 (get_core_register_section, get_core_siginfo): Use it.
13165 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
13167 * corelow.c (sniff_core_bfd): Remove extra semicolon.
13168 (get_core_register_section): Remove xfree of NULL pointer.
13170 2017-05-03 Alan Hayward <alan.hayward@arm.com>
13172 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
13173 * regcache.c (regcache::raw_supply_zeroed): New function.
13174 * regcache.h (regcache::raw_supply_zeroed): New declaration.
13176 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
13178 * gdbarch.sh: Remove commented out definition of
13180 * gdbarch.h: Re-generate.
13182 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
13184 * configure: Regenerate.
13186 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
13188 * solib-target.c (solib_target_relocate_section_addresses):
13189 Remove num_section_bases, num_bases, segment_bases variables.
13191 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13193 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
13195 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13197 * solib-target.c: Include <vector>
13198 (struct lm_info_target) <~lm_info_target>: Remove.
13199 <segment_bases, section_bases>: Change type to
13200 std::vector<CORE_ADDR>.
13201 (library_list_start_segment, library_list_start_section,
13202 library_list_end_library,
13203 solib_target_relocate_section_addresses): Adjust.
13205 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13207 * gdbarch.sh (software_single_step): Change return type to
13208 std::vector<CORE_ADDR>.
13209 * gdbarch.c, gdbarch.h: Re-generate.
13210 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
13212 (arm_deal_with_atomic_sequence_raw): Adjust.
13213 (thumb_get_next_pcs_raw): Adjust.
13214 (arm_get_next_pcs_raw): Adjust.
13215 (arm_get_next_pcs): Adjust.
13216 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
13217 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
13218 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
13219 (alpha_software_single_step): Adjust.
13220 * alpha-tdep.h (alpha_software_single_step): Adjust.
13221 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
13222 * arm-tdep.c (arm_software_single_step): Adjust.
13223 (arm_breakpoint_kind_from_current_state): Adjust.
13224 * arm-tdep.h (arm_software_single_step): Adjust.
13225 * breakpoint.c (insert_single_step_breakpoint): Adjust.
13226 * cris-tdep.c (cris_software_single_step): Adjust.
13227 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
13228 (micromips_deal_with_atomic_sequence): Adjust.
13229 (deal_with_atomic_sequence): Adjust.
13230 (mips_software_single_step): Adjust.
13231 * mips-tdep.h (mips_software_single_step): Adjust.
13232 * moxie-tdep.c (moxie_software_single_step): Adjust.
13233 * nios2-tdep.c (nios2_software_single_step): Adjust.
13234 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
13235 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
13236 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
13237 * s390-linux-tdep.c (s390_software_single_step): Adjust.
13238 * sparc-tdep.c (sparc_software_single_step): Adjust.
13239 * spu-tdep.c (spu_software_single_step): Adjust.
13240 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
13242 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13244 * gdbarch.sh: Use semi-colon as field separator instead of colon.
13245 * gdbarch.h: Re-generate.
13247 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13249 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
13250 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
13251 * python/py-instruction.c, python/py-instruction.h: New file.
13252 * python/py-record.c: Add py-instruction.h include.
13253 (gdbpy_initialize_record): Make gdb.Instruction a super class of
13254 gdb.RecordInstruction.
13255 * python/python-internal.h: Add gdbpy_initialize_instruction
13257 * python/python.c (do_start_initialization): Add
13258 gdbpy_initialize_instruction.
13260 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13262 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
13264 (btrace_func_from_recpy_func): New function.
13265 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
13266 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
13267 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
13268 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
13269 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
13270 Also, use new helper functions.
13271 (btpy_list_item): Use new helper functions.
13272 (recpy_bt_function_call_history): Use new type name.
13273 (btpy_call_getset): Remove.
13274 (gdbpy_initialize_btrace): Remove code to initialize
13275 gdb.BtraceFunctionCall.
13276 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
13277 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
13278 recpy_bt_func_prev, recpy_bt_func_next): New export.
13279 * python/py-record.c (recpy_func_type): New static object.
13280 (recpy_func_new, recpy_func_level, recpy_func_symbol,
13281 recpy_func_instructions, recpy_func_up, recpy_func_prev,
13282 recpy_func_next): New function.
13283 (recpy_element_hash, recpy_element_richcompare): Updated comment.
13284 (recpy_func_getset): New static object.
13285 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
13286 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
13288 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13290 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
13291 (btpy_object, btpy_insn_type, btpy_new): Remove.
13292 (btpy_list_object): Use gdb.RecordInstruction type instead of
13293 gdb.BtraceInstruction type.
13294 (btrace_insn_from_recpy_insn): New function.
13295 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
13297 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
13298 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
13299 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
13300 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
13301 instead of btpy_object.
13302 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13303 btpy_insn_data, btpy_insn_decode): Rename to ...
13304 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
13305 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
13306 recpy_bt_insn_decode): This. Also, use new helper functions.
13307 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
13309 (btpy_insn_getset): Remove.
13310 (gdbpy_initialize_btrace): Remove code to initialize
13311 gdb.BtraceInstruction. Use recpy_element_object.
13312 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
13313 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
13314 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
13315 * python/py-record.c (recpy_insn_type): New static object.
13316 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
13317 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
13318 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
13320 (recpy_insn_getset): New static object.
13321 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
13322 * python/py-record.h (recpy_element_object): New typedef.
13323 (recpy_insn_type, recpy_insn_new): New export.
13325 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13327 * py-record-btrace.c (btpy_insn_new): Removed.
13328 (btpy_insn_or_gap_new): New function.
13329 (btpy_insn_error): Removed.
13330 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13331 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
13332 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
13333 btpy_insn_or_gap_new instead of btpy_insn_new.
13334 (btpy_insn_getset): Remove btpy_insn_error.
13335 * py-record.c (recpy_gap_type): New static object.
13336 (recpy_gap_object): New typedef.
13337 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
13338 recpy_gap_reason_string): New function.
13339 (recpy_gap_getset): New static object.
13340 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
13341 * py-record.h (recpy_gap_new): New export.
13343 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13345 * python/py-record.c (recpy_ptid): Remove.
13346 (recpy_record_getset): Remove recpy_ptid.
13348 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13350 * btrace.c (btrace_fetch): Set inferior_ptid.
13351 * python/py-record-btrace.c: Add "py-record.h" include.
13352 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
13353 recpy_bt_end, recpy_bt_instruction_history,
13354 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
13355 in gdb.Record object instead of current ptid.
13356 * python/py-record.c: Include new "py-record.h" file.
13357 (recpy_record_object): Moved to py-record.h.
13358 * python/py-record.h: New file.
13360 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13362 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
13363 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
13366 2017-05-01 Joel Brobecker <brobecker@adacore.com>
13368 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
13369 the past maintainers section.
13371 2017-04-28 Yao Qi <yao.qi@linaro.org>
13373 * infcmd.c (get_return_value): Use regcache ctor, and remove
13376 2017-04-28 Yao Qi <yao.qi@linaro.org>
13377 Pedro Alves <palves@redhat.com>
13379 * regcache.c (regcache::regcache): New tag dispatch ctor.
13380 (do_cooked_read): Moved above.
13381 (regcache_dup): Use the tag dispatch ctor..
13382 * regcache.h (regcache): Declare ctor, delete copy ctor and
13383 assignment operator, remove friend regcache_dup.
13385 2017-04-28 Yao Qi <yao.qi@linaro.org>
13387 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
13388 call method save instead of regcache_cpy.
13389 * regcache.h (struct regcache): Make regcache_dup a friend.
13391 2017-04-28 Yao Qi <yao.qi@linaro.org>
13393 * regcache.c (struct regcache): Move to regcache.h
13394 (regcache::arch): New method.
13395 (regcache_get_ptid): Update.
13396 (get_regcache_arch): Call arch method.
13397 (get_regcache_aspace): Call method aspace.
13398 (register_buffer): Change it to method.
13399 (regcache_save): Change it to regcache::save.
13400 (regcache_restore): Likewise.
13401 (regcache_cpy_no_passthrough): Remove the declaration.
13402 (regcache_cpy): Call methods restore and cpy_no_passthrough.
13403 (regcache_cpy_no_passthrough): Change it to method
13404 cpy_no_passthrough.
13405 (regcache_register_status): Change it to method
13406 get_register_status.
13407 (regcache_invalidate): Change it to method invalidate.
13408 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
13409 (regcache_raw_update): Change it to method raw_update.
13410 (regcache_raw_read): Likewise.
13411 (regcache_raw_read_signed): Likewise.
13412 (regcache_raw_read_unsigned): Likewise.
13413 (regcache_raw_write_signed): Likewise.
13414 (regcache_raw_write_unsigned): Likewise.
13415 (regcache_cooked_read): Likewise.
13416 (regcache_cooked_read_value): Likewise.
13417 (regcache_cooked_read_signed): Likewise.
13418 (regcache_cooked_read_unsigned): Likewise.
13419 (regcache_cooked_write_signed): Likewise.
13420 (regcache_cooked_write_unsigned): Likewise.
13421 (regcache_raw_set_cached_value): Likewise.
13422 (regcache_raw_write): Likewise.
13423 (regcache_cooked_write): Likewise.
13424 (regcache_xfer_part): Likewise.
13425 (regcache_raw_read_part): Likewise.
13426 (regcache_raw_write_part): Likewise.
13427 (regcache_cooked_read_part): Likewise.
13428 (regcache_cooked_write_part): Likewise.
13429 (regcache_raw_supply): Likewise.
13430 (regcache_raw_collect): Likewise.
13431 (regcache_transfer_regset): Likewise.
13432 (regcache_supply_regset): Likewise.
13433 (regcache_collect_regset): Likewise.
13434 (regcache_debug_print_register): Likewise.
13435 (enum regcache_dump_what): Move it to regcache.h.
13436 (regcache_dump): Change it to method dump.
13437 * regcache.h (enum regcache_dump_what): New.
13438 (class regcache): New.
13439 * target.c (target_fetch_registers): Call method
13440 debug_print_register.
13441 (target_store_registers): Likewise.
13443 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13445 * windows-nat.c (struct lm_info_windows): Initialize field.
13446 (windows_make_so): Allocate lm_info_windows with new.
13447 (windows_free_so): Free lm_info_windows with delete.
13449 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13451 * solib-darwin.c (struct lm_info_darwin): Initialize field.
13452 (darwin_current_sos): Allocate lm_info_darwin with new, remove
13454 (darwin_free_so): Free lm_info_darwin with delete.
13456 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13458 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
13459 <l_addr_p>: Change type to bool.
13460 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
13461 (svr4_free_so): Free lm_info_svr4 with delete.
13462 (svr4_copy_library_list): Replace memcpy with call to copy
13464 (library_list_start_library, svr4_default_sos): Allocate
13465 lm_info_svr4 with new.
13467 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13469 * solib-target.c (struct lm_info_target): Add destructor,
13471 <name>: Change type to std::string.
13472 (library_list_start_library): Allocate lm_info_target with new.
13473 (solib_target_free_library_list): Free lm_info_target with
13475 (solib_target_current_sos): Adapt to std::string.
13476 (solib_target_free_so): Free lm_info_target with delete.
13478 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13480 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
13482 (frv_current_sos): Allocate lm_info_frv with new.
13483 (frv_relocate_main_executable): Free lm_info_frv with delete,
13485 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
13487 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13489 * solib-frv.c (struct lm_info_frv): Fix indentation.
13491 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13493 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
13495 (dsbt_current_sos): Allocate lm_info_dsbt with new.
13496 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
13497 and allocate with new.
13498 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
13500 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13502 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
13503 <filename, member_name>: Change type to std::string.
13504 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
13505 (library_list_start_library): Allocate lm_info_aix with new.
13506 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
13507 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
13508 with copy constructor.
13510 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13512 * solist.h (struct lm_info): Remove.
13513 (struct lm_info_base): New class.
13514 (struct so_list) <lm_info>: Change type to lm_info_base *.
13515 * nto-tdep.c (struct lm_info): Remove.
13517 * solib-aix.c (struct lm_info): Rename to ...
13518 (struct lm_info_aix): ... this. Extend lm_info_base.
13519 (lm_info_p): Rename to ...
13520 (lm_info_aix_p): ... this, and adjust.
13521 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
13522 solib_aix_parse_libraries, library_list_start_library,
13523 solib_aix_free_library_list, solib_aix_parse_libraries,
13524 solib_aix_get_library_list,
13525 solib_aix_relocate_section_addresses, solib_aix_free_so,
13526 solib_aix_get_section_offsets,
13527 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
13529 (struct solib_aix_inferior_data) <library_list>: Adjust.
13530 * solib-darwin.c (struct lm_info): Rename to ...
13531 (struct lm_info_darwin): ... this. Extend lm_info_base.
13532 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
13533 * solib-dsbt.c (struct lm_info): Rename to ...
13534 (struct lm_info_dsbt): ... this. Extend lm_info_base.
13535 (struct dsbt_info) <main_executable_lm_info): Adjust.
13536 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
13537 dsbt_relocate_section_addresses): Adjust.
13538 * solib-frv.c (struct lm_info): Rename to ...
13539 (struct lm_info_frv): ... this. Extend lm_info_base.
13540 (main_executable_lm_info): Adjust.
13541 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
13542 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
13543 find_canonical_descriptor_in_load_object,
13544 frv_fdpic_find_canonical_descriptor): Adjust.
13545 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
13547 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
13548 svr4_clear_so, svr4_copy_library_list,
13549 library_list_start_library, svr4_default_sos, svr4_read_so_list,
13550 svr4_current_sos, svr4_fetch_objfile_link_map,
13551 solist_update_incremental): Adjust.
13552 * solib-svr4.h (struct lm_info_svr4): Move here from
13554 * solib-target.c (struct lm_info): Rename to ...
13555 (struct lm_info_target): ... this. Extend lm_info_base.
13556 (lm_info_p): Rename to ...
13557 (lm_info_target_p): ... this.
13558 (solib_target_parse_libraries, library_list_start_segment,
13559 library_list_start_section, library_list_start_library,
13560 library_list_end_library, solib_target_free_library_list,
13561 solib_target_current_sos, solib_target_free_so,
13562 solib_target_relocate_section_addresses): Adjust.
13563 * windows-nat.c (struct lm_info): Rename to ...
13564 (struct lm_info_windows): ... this. Extend lm_info_base.
13565 (windows_make_so, handle_load_dll, handle_unload_dll,
13566 windows_xfer_shared_libraries): Adjust.
13568 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13570 * solib-darwin.c (struct darwin_so_list): Remove.
13571 (darwin_current_sos): Allocate an so_list object instead of a
13572 darwin_so_list, separately allocate an lm_info object.
13573 (darwin_free_so): Free lm_info.
13575 2017-04-28 John Baldwin <jhb@FreeBSD.org>
13577 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13578 with fprintf_filtered.
13580 2017-04-28 Yao Qi <yao.qi@linaro.org>
13582 * regcache.c (regcache::regcache): New function.
13583 (regcache::~regcache): New function.
13584 (regcache_xmalloc_1): Remove.
13585 (regcache_xmalloc): Call new regcache.
13586 (regcache_xfree): Call delete regcache.
13587 (get_thread_arch_aspace_regcache): Call new regcache.
13589 2017-04-28 Yao Qi <yao.qi@linaro.org>
13591 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13592 lwp instead of ptid_get_lwp.
13594 2017-04-28 Yao Qi <yao.qi@linaro.org>
13596 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13597 lwp_info instead of getting from inferior_ptid.
13599 2017-04-27 Keith Seitz <keiths@redhat.com>
13601 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13602 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13603 (CV_CONVERSION_BADNESS): Define.
13604 (rank_one_type): Remove overly restrictive rvalue reference
13606 Add cv-qualifier checks and subranks for type equality.
13607 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13608 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13609 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13611 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13613 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13614 count when creating the object.
13616 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13617 Ulrich Weigand <uweigand@de.ibm.com>
13619 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13620 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13622 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13623 (process_xcoff_symbol): Likewise.
13624 (scan_xcoff_symtab): Likewise.
13626 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13628 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13629 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13630 (ia64_access_reg): Use get_frame_register_unsigned.
13631 (ia64_access_rse_reg): Likewise.
13632 (ia64_libunwind_frame_prev_register): Likewise.
13634 2017-04-26 Jiong Wang <jiong.wang@arm.com>
13636 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13637 * gdbarch.c: Regenerated.
13638 * gdbarch.h: Regenerated.
13639 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13640 visibility external.
13641 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13642 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13643 (enum cfa_how_kind): Move to ...
13644 (struct dwarf2_frame_state_reg_info): Likewise.
13645 (struct dwarf2_frame_state): Likewise.
13646 * dwarf2-frame.h: ... here.
13647 (dwarf2_frame_state_alloc_regs): New declaration.
13648 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13649 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13651 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13653 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13654 regcache_raw_read_unsigned.
13655 (xtensa_pseudo_register_write): Likewise.
13657 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13659 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13660 (nds32_pseudo_register_write): Likewise.
13662 2017-04-25 Yao Qi <yao.qi@linaro.org>
13664 * regcache.c (struct regcache) <readonly_p>: Change its type
13666 (regcache_xmalloc_1): Update parameter type and callers update.
13668 2017-04-25 Yao Qi <yao.qi@linaro.org>
13670 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13671 set_gdbarch_wchar_bit.
13672 * arm-tdep.c (arm_gdbarch_init): Likewise.
13674 2017-04-25 Pedro Alves <palves@redhat.com>
13676 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13677 (BothAreRelocatable, memcopy, memmove): Don't define.
13678 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13681 2017-04-25 Pedro Alves <palves@redhat.com>
13683 * common/common-defs.h: Include "common/poison.h".
13684 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13686 * common/poison.h: New file.
13687 * common/traits.h: Include <type_traits>.
13688 (Not, Or, Requires): New, moved from common/function-view.h.
13690 2017-04-25 Pedro Alves <palves@redhat.com>
13692 * breakpoint.h (struct breakpoint): In-class initialize all
13693 fields. Make boolean fields "bool".
13694 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13695 memset call and initializations no longer necessary.
13697 2017-04-25 Pedro Alves <palves@redhat.com>
13699 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13701 (pt_btrace_insn): New function.
13702 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13704 2017-04-25 Pedro Alves <palves@redhat.com>
13706 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13707 "base" field and inherit from "bp_location" instead. Add
13709 (allocate_location_exception): Use new non-default ctor.
13710 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13711 (init_bp_location): Convert to ...
13712 (bp_location::bp_location): ... this new ctor, and remove memset
13714 (base_breakpoint_allocate_location): Use the new non-default ctor.
13715 * breakpoint.h (bp_location): Now a class. Declare default and
13716 non-default ctors. In-class initialize all members.
13717 (init_bp_location): Remove declaration.
13719 2017-04-25 Pedro Alves <palves@redhat.com>
13721 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13722 assignment operator.
13724 2017-04-24 Yao Qi <yao.qi@linaro.org>
13726 * doublest.c (convert_doublest_to_floatformat): Call
13727 floatformat_totalsize_bytes.
13729 2017-04-22 Tom Tromey <tom@tromey.com>
13731 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13733 * stack.c (print_frame): Use ui_out_emit_list.
13734 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13736 * mi/mi-main.c (print_one_inferior)
13737 (mi_cmd_data_list_register_names)
13738 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13739 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13741 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13742 (mi_output_solib_attribs): Use ui_out_emit_list,
13744 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13745 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13746 (mi_cmd_stack_list_args, list_args_or_locals): Use
13748 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13749 * breakpoint.c (print_solib_event, output_thread_groups): Use
13752 2017-04-22 Tom Tromey <tom@tromey.com>
13754 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13755 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13756 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13758 2017-04-22 Tom Tromey <tom@tromey.com>
13760 * tracepoint.c (tvariables_info_1)
13761 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13763 2017-04-22 Tom Tromey <tom@tromey.com>
13765 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13766 annotate_arg_emitter.
13767 * breakpoint.c (print_mention_watchpoint)
13768 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13769 * annotate.h (struct annotate_arg_emitter): New.
13771 2017-04-22 Tom Tromey <tom@tromey.com>
13773 * record-btrace.c (record_btrace_insn_history)
13774 (record_btrace_insn_history_range, record_btrace_call_history)
13775 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13776 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13778 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13779 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13780 * skip.c (skip_info): Use ui_out_emit_tuple.
13781 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13782 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13783 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13784 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13785 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13787 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13788 (output_register, mi_cmd_data_read_memory)
13789 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13790 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13791 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13792 Use ui_out_emit_tuple.
13793 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13795 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13796 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13797 * linux-thread-db.c (info_auto_load_libthread_db): Use
13799 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13800 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13801 * disasm.c (do_mixed_source_and_assembly_deprecated)
13802 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13803 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13804 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13805 * breakpoint.c (print_one_breakpoint_location)
13806 (print_one_breakpoint): Use ui_out_emit_tuple.
13807 * auto-load.c (print_script, info_auto_load_cmd): Use
13809 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13811 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13813 * thread.c (print_thread_info_1): Remove dead code.
13815 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13817 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13819 * arm-tdep.c (selftests::arm_record_test): Likewise.
13821 2017-04-21 Yao Qi <yao.qi@linaro.org>
13823 * regcache.c (regcache_restore): Remove argument 2. Replace
13824 argument 3 with regcache. Get register status from
13825 src->register_status and get register contents from
13826 register_buffer (src, regnum).
13827 (regcache_cpy): Update.
13829 2017-04-19 Pedro Alves <palves@redhat.com>
13831 * gdbthread.h (thread): Add missing closing parenthesis in
13834 2017-04-19 Pedro Alves <palves@redhat.com>
13836 * common/refcounted-object.h: New file.
13837 * gdbthread.h: Include "common/refcounted-object.h".
13838 (thread_info): Inherit from refcounted_object and add comments.
13839 (thread_info::incref, thread_info::decref)
13840 (thread_info::m_refcount): Delete.
13841 (thread_info::deletable): Use the refcounted_object::refcount()
13843 * inferior.c (current_inferior_): Add comment.
13844 (set_current_inferior): Increment/decrement refcounts.
13845 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13846 not-deletable instead of comparing with the current inferior.
13847 (initialize_inferiors): Increment the initial inferior's refcount.
13848 * inferior.h (struct inferior): Forward declare.
13849 Include "common/refcounted-object.h".
13850 (current_inferior, set_current_inferior): Move declaration to
13851 before struct inferior's definition, and fix comment.
13852 (inferior): Inherit from refcounted_object. Add comments.
13853 * thread.c (switch_to_thread_no_regs): Reference the thread's
13854 inferior pointer directly instead of doing a ptid lookup.
13855 (switch_to_no_thread): New function.
13856 (switch_to_thread(thread_info *)): New function, factored out
13858 (switch_to_thread(ptid_t)): ... this.
13859 (restore_current_thread): Delete.
13860 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13861 fields, and add 'inf' field.
13862 (do_restore_current_thread_cleanup): Check whether old->inf is
13863 alive instead of looking up an inferior by ptid. Use
13864 switch_to_thread and switch_to_no_thread.
13865 (restore_current_thread_cleanup_dtor): Use old->inf directly
13866 instead of lookup up an inferior by id. Decref the inferior.
13867 Don't restore 'removable'.
13868 (make_cleanup_restore_current_thread): Same the inferior pointer
13869 in old, instead of the inferior number. Incref the inferior.
13870 Don't save/clear 'removable'.
13872 2017-04-19 Pedro Alves <palves@redhat.com>
13874 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13875 unittests/scoped_restore-selftests.c.
13876 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13877 * common/scoped_restore.h (scoped_restore_base): Make "class".
13878 (scoped_restore_base::release): New public method.
13879 (scoped_restore_base::scoped_restore_base): New protected ctor.
13880 (scoped_restore_base::m_saved_var): New protected field.
13881 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13882 scoped_restore_base base class instead of m_saved_var directly.
13883 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13884 (scoped_restore_tmpl::scoped_restore_tmpl(const
13885 scoped_restore_tmpl<T>&)): Likewise.
13886 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13888 (scoped_restore_tmpl::saved_var): New method.
13889 (scoped_restore_tmpl::m_saved_var): Delete.
13890 * inferior.h (inferior::detaching): Now a bool.
13891 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13893 * unittests/scoped_restore-selftests.c: New file.
13895 2017-04-19 Pedro Alves <palves@redhat.com>
13897 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13898 Re-sort in alphabetic order.
13900 2017-04-18 Pedro Alves <palves@redhat.com>
13902 * xml-support.c (obstack_xml_printf): Delete.
13903 * xml-support.h (obstack_xml_printf): Delete.
13905 2017-04-18 Pedro Alves <palves@redhat.com>
13907 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13908 vdebug, verror, body_text, start_element, end_element, name,
13909 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13910 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13911 is_xinclude>: Make private and add m_ prefix.
13912 (gdb_xml_parser::body_text): New method, based on ...
13913 (gdb_xml_body_text): ... this. Adjust.
13914 (gdb_xml_parser::vdebug): New method, based on ...
13915 (gdb_xml_debug): ... this. Adjust.
13916 (gdb_xml_parser::verror): New method, based on ...
13917 (gdb_xml_error): ... this. Adjust.
13918 (gdb_xml_parser::start_element): New method, based on ...
13919 (gdb_xml_start_element): ... this. Adjust.
13920 (gdb_xml_start_element_wrapper): Defer to
13921 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
13922 (gdb_xml_parser::end_element): New method, based on ...
13923 (gdb_xml_end_element_wrapper): ... this. Adjust.
13924 (gdb_xml_parser::~gdb_xml_parser): Adjust.
13925 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
13926 (gdb_xml_parser::use_dtd): New method, based on ...
13927 (gdb_xml_use_dtd): ... this. Adjust.
13928 (gdb_xml_parser::parse): New method, based on ...
13929 (gdb_xml_parse): ... this. Adjust.
13930 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
13931 (xinclude_start_include): Adjust to call the parser's name method.
13932 (xml_xinclude_default, xml_xinclude_start_doctype)
13933 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
13935 (xml_process_xincludes): Adjust to call parser methods.
13936 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
13939 2017-04-18 Pedro Alves <palves@redhat.com>
13941 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
13942 gdb::optional<std::string>.
13943 * xml-support.c: Include <string>.
13944 (scope_level::scope_level(scope_level &&))
13945 (scope_level::~scope_level): Delete.
13946 (scope_level::body): Now a std::string.
13947 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
13948 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
13950 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
13951 (xinclude_parsing_data::output): Now a std::string reference.
13952 (xinclude_start_include): Adjust.
13953 (xml_xinclude_default): Adjust.
13954 (xml_process_xincludes): Add 'output' parameter, and return bool.
13955 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
13957 * xml-tdesc.c: Include <unordered_map> and <string>.
13958 (tdesc_xml_cache): Delete.
13959 (tdesc_xml_cache_s): Delete.
13960 (xml_cache): Now an std::unordered_map.
13961 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
13962 (target_fetch_description_xml): Change return type to
13963 gdb::optional<std::string>, and adjust.
13964 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
13965 (target_fetch_description_xml): Change return type to
13966 gdb::optional<std::string>.
13968 2017-04-18 Pedro Alves <palves@redhat.com>
13970 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13971 unittests/optional-selftests.c.
13972 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
13973 * unittests/optional-selftests.c: New file.
13974 * unittests/optional/assignment/1.cc: New file.
13975 * unittests/optional/assignment/2.cc: New file.
13976 * unittests/optional/assignment/3.cc: New file.
13977 * unittests/optional/assignment/4.cc: New file.
13978 * unittests/optional/assignment/5.cc: New file.
13979 * unittests/optional/assignment/6.cc: New file.
13980 * unittests/optional/assignment/7.cc: New file.
13981 * unittests/optional/cons/copy.cc: New file.
13982 * unittests/optional/cons/default.cc: New file.
13983 * unittests/optional/cons/move.cc: New file.
13984 * unittests/optional/cons/value.cc: New file.
13985 * unittests/optional/in_place.cc: New file.
13986 * unittests/optional/observers/1.cc: New file.
13987 * unittests/optional/observers/2.cc: New file.
13989 2017-04-18 Pedro Alves <palves@redhat.com>
13991 * common/gdb_optional.h: Include common/traits.h.
13992 (in_place_t): New type.
13993 (in_place): New constexpr variable.
13994 (optional::optional): Remove member initialization of
13996 (optional::optional(in_place_t...)): New constructor.
13997 (optional::~optional): Use reset.
13998 (optional::optional(const optional&)): New.
13999 (optional::optional(const optional&&)): New.
14000 (optional::optional(T &)): New.
14001 (optional::optional(T &&)): New.
14002 (operator::operator=(const optional &)): New.
14003 (operator::operator=(optional &&)): New.
14004 (operator::operator= (const T &))
14005 (operator::operator= (T &&))
14006 (operator::emplace (Args &&... args)): Return a T&. Use reset.
14007 (operator::reset): New.
14008 (operator::m_instantiated):: Add in-class initializer.
14009 * common/traits.h: Include <type_traits>.
14010 (struct And): New types.
14012 2017-04-18 Pedro Alves <palves@redhat.com>
14014 * xml-support.c: Include <vector>.
14015 (scope_level::scope_level(const gdb_xml_element *))
14016 (scope_level::scope_level(scope_level&&)): New.
14017 (scope_level::~scope_level): New.
14018 (scope_level_s): Delete.
14019 (gdb_xml_parser::scopes): Now a std::vector.
14020 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
14022 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
14023 scope cleanup code.
14024 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
14025 of the scopes member. Use std::vector::emplace_back.
14027 2017-04-18 Pedro Alves <palves@redhat.com>
14029 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
14031 (gdb_xml_end_element): Change type of first parameter.
14032 (gdb_xml_cleanup): Rename to ...
14033 (gdb_xml_parser::~gdb_xml_parser): ... this.
14034 (gdb_xml_create_parser_and_cleanup): Delete with ...
14035 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
14037 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
14038 using gdb_xml_create_parser_and_cleanup.
14039 (xinclude_parsing_data): Add ctor/dtor.
14040 (xml_xinclude_cleanup): Delete.
14041 (xml_process_xincludes): Create a local xinclude_parsing_data
14042 instead of heap-allocating one. Create a local gdb_xml_parser
14043 instead of heap-allocating one with
14044 gdb_xml_create_parser_and_cleanup.
14046 2017-04-18 John Baldwin <jhb@FreeBSD.org>
14049 * fbsd-nat.c (resume_one_thread_cb): Remove.
14050 (resume_all_threads_cb): Remove.
14051 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
14052 iterate_over_threads.
14054 2017-04-17 Joel Brobecker <brobecker@adacore.com>
14056 * NEWS: Create a new section for the next release branch.
14057 Rename the section of the current branch, now that it has
14060 2017-04-17 Joel Brobecker <brobecker@adacore.com>
14062 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
14063 * version.in: Bump version to 8.0.50.DATE-git.
14065 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
14068 * windows-nat.c (windows_create_inferior): Declare 'allargs'
14069 independently of the host, and fix build breakage on Cygwin.
14071 2017-04-13 Pedro Alves <palves@redhat.com>
14073 * inferior.c (free_inferior): Convert to ...
14074 (inferior::~inferior): ... this dtor.
14075 (inferior::inferior): New ctor, factored out from ...
14076 (add_inferior_silent): ... here. Allocate the inferior with a new
14078 (delete_inferior): Call delete instead of free_inferior.
14079 * inferior.h (gdb_environ, continuation): Forward declare.
14080 (inferior): Now a class. Add in-class initialization to all
14081 members. Make boolean fields bool, except 'detaching'.
14082 (inferior::inferior): New explicit ctor.
14083 (inferior::~inferior): New.
14085 2017-04-13 Pedro Alves <palves@redhat.com>
14087 * inferior.c (init_inferior_list): Delete.
14088 * inferior.h (init_inferior_list): Delete.
14090 2017-04-13 Pedro Alves <palves@redhat.com>
14093 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
14094 (top level): Call it twice, with different thread sets.
14096 2017-04-13 Pedro Alves <palves@redhat.com>
14098 * thread.c: Include <algorithm>.
14099 (thread_array_cleanup): Delete.
14100 (scoped_inc_dec_ref): New class.
14101 (live_threads_count): New function.
14102 (set_thread_refcount): Delete.
14103 (tp_array_compar_ascending): Now a bool.
14104 (tp_array_compar): Convert to a std::sort comparison function.
14105 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
14106 and live_threads_count.
14108 2017-04-13 Pedro Alves <palves@redhat.com>
14110 * infrun.c (follow_fork_inferior): Also switch the current
14113 2017-04-13 Pedro Alves <palves@redhat.com>
14115 * breakpoint.c (watch_command_1): Save watchpoint-frame info
14116 before calling create_internal_breakpoint.
14118 2017-04-13 Pedro Alves <palves@redhat.com>
14120 * fork-child.c (execv_argv): New class.
14121 (breakup_args): Refactored as ...
14122 (execv_argv::init_for_no_shell): .. this method of execv_argv.
14123 Copy arguments to storage and replace separators with NULL
14124 terminators in place.
14125 (escape_bang_in_quoted_argument): Adjust to return bool.
14126 (execv_argv::execv_argv): New ctor.
14127 (execv_argv::init_for_shell): New method, factored out from
14128 fork_inferior. Don't strdup strings into the vector.
14129 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
14130 Remove free_vector_argv call.
14132 2017-04-13 Yao Qi <yao.qi@linaro.org>
14134 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
14137 2017-04-13 Yao Qi <yao.qi@linaro.org>
14139 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
14140 * rx-tdep.c (rx_gdbarch_init): Likewise.
14142 2017-04-13 Pedro Alves <palves@redhat.com>
14144 * breakpoint.h (struct breakpoint): Reindent.
14146 2017-04-13 Pedro Alves <palves@redhat.com>
14148 * breakpoint.c (bp_location): Rename to ...
14149 (bp_locations): ... this. All references updated.
14150 (bp_location_count): Rename to ...
14151 (bp_locations_count): ... this. All references updated.
14152 (bp_location_placed_address_before_address_max): Rename to ...
14153 (bp_locations_placed_address_before_address_max): ... this. All
14154 references updated.
14155 (bp_location_shadow_len_after_address_max): Rename to ...
14156 (bp_locations_shadow_len_after_address_max): ... this. All
14157 references updated.
14158 (bp_location_compare_addrs): Rename to ...
14159 (bp_locations_compare_addrs): ... this. All references updated.
14160 (bp_location_compare):Rename to ...
14161 (bp_locations_compare): ... this. All references updated.
14162 (bp_location_target_extensions_update): Rename to ...
14163 (bp_locations_target_extensions_update): ... this. All references
14166 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14168 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
14169 * common/common.m4: Check headers 'termios.h', 'termio.h' and
14171 * common/gdb_termios.h: New file, with parts of "terminal.h".
14172 * inflow.c: Include "gdb_termios.h".
14173 * ser-unix.c: Include "gdb_termios.h".
14174 * terminal.h: Move terminal-related defines to
14175 "common/gdb_termios.h".
14177 2017-04-12 Tom Tromey <tom@tromey.com>
14179 * probe.c (parse_probes): Update.
14180 * location.h (delete_event_location): Don't declare.
14181 (event_location_deleter::operator()): Update.
14182 * location.c (event_location_deleter::operator()): Rename from
14183 delete_event_location.
14184 * linespec.h (linespec_result) <location>: Change type to
14186 * linespec.c (canonicalize_linespec, event_location_to_sals)
14187 (decode_objc): Update.
14188 (linespec_result): Don't call delete_event_location.
14189 * breakpoint.c (create_breakpoints_sal)
14190 (bkpt_probe_create_sals_from_location)
14191 (strace_marker_create_sals_from_location): Update.
14193 2017-04-12 Tom Tromey <tom@tromey.com>
14195 * linespec.h (struct linespec_result): Add constructor and
14197 (init_linespec_result, destroy_linespec_result)
14198 (make_cleanup_destroy_linespec_result): Don't declare.
14199 * linespec.c (init_linespec_result): Remove.
14200 (linespec_result::~linespec_result): Rename from
14201 destroy_linespec_result. Update.
14202 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
14204 * breakpoint.c (create_breakpoint, break_range_command)
14205 (decode_location_default): Update.
14206 * ax-gdb.c (agent_command_1): Update.
14208 2017-04-12 Tom Tromey <tom@tromey.com>
14210 * remote.c (remote_download_tracepoint): Update.
14211 * python/py-breakpoint.c (bppy_get_location): Update.
14212 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
14213 (gdbscm_breakpoint_location): Update.
14214 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
14215 * breakpoint.h (struct breakpoint) <location, location_range_end>:
14216 Change type to event_location_up.
14217 * breakpoint.c (create_overlay_event_breakpoint)
14218 (create_longjmp_master_breakpoint)
14219 (create_std_terminate_master_breakpoint)
14220 (create_exception_master_breakpoint)
14221 (breakpoint_event_location_empty_p, print_breakpoint_location)
14222 (print_one_breakpoint_location, create_thread_event_breakpoint)
14223 (init_breakpoint_sal, create_breakpoint)
14224 (print_recreate_ranged_breakpoint, break_range_command)
14225 (init_ada_exception_breakpoint, say_where): Update.
14226 (base_breakpoint_dtor): Don't call delete_event_location.
14227 (bkpt_print_recreate, tracepoint_print_recreate)
14228 (dprintf_print_recreate, update_static_tracepoint)
14229 (breakpoint_re_set_default): Update.
14231 2017-04-12 Tom Tromey <tom@tromey.com>
14233 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
14234 type of "to_do". Update.
14235 (compute_stack_depth): Use std::vector.
14237 2017-04-12 Tom Tromey <tom@tromey.com>
14239 * printcmd.c (find_instruction_backward): Use std::vector.
14241 2017-04-12 Tom Tromey <tom@tromey.com>
14243 * symfile.c (objfilep): Remove typedef.
14244 (reread_symbols): Use a std::vector.
14246 2017-04-12 Tom Tromey <tom@tromey.com>
14248 * mi/mi-main.c (exec_direction_forward): Remove.
14249 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
14250 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
14252 * guile/guile.c (guile_repl_command, guile_command)
14253 (gdbscm_execute_gdb_command): Use scoped_restore.
14254 * go-exp.y (go_parse): Use scoped_restore.
14255 * d-exp.y (d_parse): Use scoped_restore.
14256 * cli/cli-decode.c (cmd_func): Use scoped_restore.
14257 * c-exp.y (c_parse): Use scoped_restore.
14259 2017-04-12 Tom Tromey <tom@tromey.com>
14261 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
14262 (mi_parse): Update return type.
14263 (mi_parse_free): Remove.
14264 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
14265 (mi_parse::~mi_parse): Rename from mi_parse_free.
14266 (mi_parse_cleanup): Remove.
14267 (mi_parse): Return a unique_ptr. Use new.
14268 * mi/mi-main.c (mi_execute_command): Update.
14270 2017-04-12 Tom Tromey <tom@tromey.com>
14272 * location.c (explicit_location_lex_one): Return a
14273 unique_xmalloc_ptr.
14274 (string_to_explicit_location): Update. Remove cleanups.
14276 2017-04-12 Tom Tromey <tom@tromey.com>
14278 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
14279 (compare_value_and_voffset): Change type. Update.
14280 (compute_vtable_size): Change type of "offset_vec".
14281 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
14282 (gnuv3_get_typeid): Remove extraneous declaration.
14284 2017-04-12 Tom Tromey <tom@tromey.com>
14286 * charset.h (wchar_iterator): Fix comment.
14288 2017-04-12 Tom Tromey <tom@tromey.com>
14290 * charset.c (iconv_wrapper): New class.
14291 (cleanup_iconv): Remove.
14292 (convert_between_encodings): Use it.
14294 2017-04-12 Tom Tromey <tom@tromey.com>
14296 * symfile.h (increment_reading_symtab): Update type.
14297 * symfile.c (decrement_reading_symtab): Remove.
14298 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
14299 * psymtab.c (psymtab_to_symtab): Update.
14300 * dwarf2read.c (dw2_instantiate_symtab): Update.
14302 2017-04-12 Tom Tromey <tom@tromey.com>
14304 * jit.c (struct jit_reader): Declare separately. Add constructor
14305 and destructor. Change type of "handle".
14306 (loaded_jit_reader): Define separately.
14307 (jit_reader_load): Update. New "new".
14308 (jit_reader_unload_command): Use "delete".
14309 * gdb-dlfcn.h (struct dlclose_deleter): New.
14310 (gdb_dlhandle_up): New typedef.
14311 (gdb_dlopen, gdb_dlsym): Update types.
14312 (gdb_dlclose): Remove.
14313 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
14314 (gdb_dlsym): Change type of "handle".
14315 (make_cleanup_dlclose): Remove.
14316 (dlclose_deleter::operator()): Rename from gdb_dlclose.
14317 * compile/compile-c-support.c (load_libcc): Update.
14319 2017-04-12 Tom Tromey <tom@tromey.com>
14321 * symtab.h (find_pcs_for_symtab_line): Change return type.
14322 * symtab.c (find_pcs_for_symtab_line): Change return type.
14323 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
14324 type of "vec". Update.
14325 (ltpy_get_pcs_for_line): Update.
14326 * linespec.c (decode_digits_ordinary): Update.
14328 2017-04-12 Tom Tromey <tom@tromey.com>
14330 * tracepoint.c (actions_command): Update.
14331 * python/python.c (python_command, python_interactive_command):
14333 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
14334 * guile/guile.c (guile_command): Update.
14335 * defs.h (read_command_lines, read_command_lines_1): Return
14337 (command_lines_deleter): New struct.
14338 (command_line_up): New typedef.
14339 * compile/compile.c (compile_code_command)
14340 (compile_print_command): Update.
14341 * cli/cli-script.h (get_command_line, copy_command_lines): Return
14343 (make_cleanup_free_command_lines): Remove.
14344 * cli/cli-script.c (get_command_line, read_command_lines_1)
14345 (copy_command_lines): Return command_line_up.
14346 (while_command, if_command, read_command_lines, define_command)
14347 (document_command): Update.
14348 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
14350 * breakpoint.h (breakpoint_set_commands): Change type of
14352 * breakpoint.c (breakpoint_set_commands): Change type of
14353 "commands". Update.
14354 (do_map_commands_command, update_dprintf_command_list)
14355 (create_tracepoint_from_upload): Update.
14357 2017-04-12 Tom Tromey <tom@tromey.com>
14359 * tracepoint.c (scope_info): Update.
14360 * spu-tdep.c (spu_catch_start): Update.
14361 * python/python.c (gdbpy_decode_line): Update.
14362 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
14363 * python/py-breakpoint.c (bppy_init): Update.
14364 * probe.c (parse_probes): Update.
14365 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
14366 * location.h (event_location_deleter): New struct.
14367 (event_location_up): New typedef.
14368 (new_linespec_location, new_address_location, new_probe_location)
14369 (new_explicit_location, copy_event_location)
14370 (string_to_event_location, string_to_event_location_basic)
14371 (string_to_explicit_location): Update return type.
14372 (make_cleanup_delete_event_location): Remove.
14373 * location.c (new_linespec_location, new_address_location)
14374 (new_probe_location, new_explicit_location, copy_event_location):
14375 Return event_location_up.
14376 (delete_event_location_cleanup)
14377 (make_cleanup_delete_event_location): Remove.
14378 (string_to_explicit_location, string_to_event_location_basic)
14379 (string_to_event_location): Return event_location_up.
14380 * linespec.c (canonicalize_linespec, event_location_to_sals)
14381 (decode_line_with_current_source)
14382 (decode_line_with_last_displayed, decode_objc): Update.
14383 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
14384 * completer.c (location_completer): Update.
14385 * cli/cli-cmds.c (edit_command, list_command): Update.
14386 * breakpoint.c (create_overlay_event_breakpoint)
14387 (create_longjmp_master_breakpoint)
14388 (create_std_terminate_master_breakpoint)
14389 (create_exception_master_breakpoint)
14390 (create_thread_event_breakpoint): Update.
14391 (init_breakpoint_sal): Update. Remove some dead code.
14392 (create_breakpoint_sal): Change type of "location". Update.
14393 (create_breakpoints_sal, create_breakpoint, break_command_1)
14394 (dprintf_command, break_range_command, until_break_command)
14395 (init_ada_exception_breakpoint)
14396 (strace_marker_create_sals_from_location)
14397 (update_static_tracepoint, trace_command, ftrace_command)
14398 (strace_command, create_tracepoint_from_upload): Update.
14399 * break-catch-throw.c (re_set_exception_catchpoint): Update.
14400 * ax-gdb.c (agent_command_1): Update.
14402 2017-04-12 Pedro Alves <palves@redhat.com>
14404 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
14405 * configure.tgt: Handle i[34567]86-*-go32* and
14406 i[34567]86-*-msdosdjgpp*.
14407 * i386-tdep.c (i386_svr4_reg_to_regnum):
14409 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
14411 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
14412 * i386-go32-tdep.c: New file.
14413 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
14416 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
14418 * aix-thread.c (pd_status2str): Change return type to const char *.
14420 2017-04-12 Pedro Alves <palves@redhat.com>
14422 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
14423 calls to set_gdbarch_gnu_triplet_regexp.
14425 2017-04-12 Pedro Alves <palves@redhat.com>
14428 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
14430 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
14431 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
14432 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
14433 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
14434 * gdbarch.h, gdbarch.c: Regenerate.
14435 * aarch64-tdep.c (aarch64_gdbarch_init): Override
14436 gdbarch_wchar_bit and gdbarch_wchar_signed.
14437 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
14438 * arm-tdep.c (arm_gdbarch_init): Likewise.
14439 * avr-tdep.c (avr_gdbarch_init): Likewise.
14440 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
14441 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
14442 * i386-tdep.c (i386_go32_init_abi): Likewise.
14443 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
14444 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
14445 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
14446 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
14447 * sh-tdep.c (sh_gdbarch_init): Likewise.
14448 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
14449 * sparc64-tdep.c (sparc64_init_abi): Likewise.
14450 * windows-tdep.c (windows_init_abi): Likewise.
14451 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
14453 2017-04-12 Pedro Alves <palves@redhat.com>
14456 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
14457 cplus_primitive_type_char32_t>: New enum values.
14458 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
14459 and cplus_primitive_type_char32_t.
14460 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
14461 32, use the archtecture's built-in type for char16_t and char32_t,
14462 respectively. Otherwise, fallback to init_integer_type as before,
14463 but make the type unsigned, and issue a complaint.
14464 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
14466 2017-04-12 Alan Hayward <alan.hayward@arm.com>
14468 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
14469 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
14471 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14473 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
14476 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14478 * common/common-utils.c (free_vector_argv): New function.
14479 * common/common-utils.h: Include <vector>.
14480 (free_vector_argv): New prototype.
14481 * darwin-nat.c (darwin_create_inferior): Rewrite function
14482 prototype in order to constify "exec_file" and accept a
14483 "std::string" for "allargs".
14484 * fork-child.c: Include <vector>.
14485 (breakup_args): Rewrite function, using C++.
14486 (fork_inferior): Rewrite function header, constify "exec_file_arg"
14487 and accept "std::string" for "allargs". Update the code to
14488 calculate "argv" based on "allargs". Update calls to "exec_fun"
14490 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
14491 order to constify "exec_file" and accept a "std::string" for
14493 * go32-nat.c (go32_create_inferior): Likewise.
14494 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
14495 * infcmd.c (run_command_1): Constify "exec_file". Use
14496 "std::string" for inferior arguments.
14497 * inferior.h (fork_inferior): Update prototype.
14498 * linux-nat.c (linux_nat_create_inferior): Rewrite function
14499 prototype in order to constify "exec_file" and accept a
14500 "std::string" for "allargs".
14501 * nto-procfs.c (procfs_create_inferior): Likewise.
14502 * procfs.c (procfs_create_inferior): Likewise.
14503 * remote-sim.c (gdbsim_create_inferior): Likewise.
14504 * remote.c (extended_remote_run): Update code to accept
14505 "std::string" as argument.
14506 (extended_remote_create_inferior): Rewrite function prototype in
14507 order to constify "exec_file" and accept a "std::string" for
14509 * rs6000-nat.c (super_create_inferior): Likewise.
14510 (rs6000_create_inferior): Likewise.
14511 * target.h (struct target_ops) <to_create_inferior>: Likewise.
14512 * windows-nat.c (windows_create_inferior): Likewise.
14514 2017-04-11 Pedro Alves <palves@redhat.com>
14516 * thread.c: Fix whitespace throughout.
14518 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
14520 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
14522 2017-04-11 Alan Hayward <alan.hayward@arm.com>
14524 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
14526 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
14529 * osdata.c (info_osdata): Check if 'type' is an empty string
14532 2017-04-10 Pedro Alves <palves@redhat.com>
14534 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
14535 (ptid_to_global_thread_id, in_thread_list)
14536 (do_captured_list_thread_ids, set_resumed, set_running)
14537 (set_executing, set_stop_requested, finish_thread_state)
14538 (validate_registers_access, can_access_registers_ptid)
14539 (print_thread_info_1, switch_to_thread)
14540 (do_restore_current_thread_cleanup)
14541 (make_cleanup_restore_current_thread, thread_command)
14542 (thread_name_command): Use operator== instead of ptid_equal.
14544 2017-04-10 Pedro Alves <palves@redhat.com>
14546 * thread.c (struct current_thread_cleanup) <next>: Delete field.
14547 (current_thread_cleanup_chain): Delete.
14548 (restore_current_thread_cleanup_dtor)
14549 (make_cleanup_restore_current_thread): Remove references to
14550 current_thread_cleanup_chain.
14552 2017-04-10 Alan Hayward <alan.hayward@arm.com>
14554 * msp430-tdep.c (msp430_pseudo_register_read): Never return
14557 2017-04-10 Yao Qi <yao.qi@linaro.org>
14560 * gdbthread.h (thread_info::deletable): New method.
14561 (thread_info::incref): New method.
14562 (thread_info::decref): New method.
14563 (thread_info::refcount): Move it to private.
14564 * infrun.c (save_stop_context): Call inc_refcount.
14565 (release_stop_context_cleanup): Likewise.
14566 * thread.c (set_thread_exited): New function.
14567 (init_thread_list): Delete "tp" only it is deletable, otherwise
14568 call set_thread_exited.
14569 (delete_thread_1): Call set_thread_exited.
14570 (current_thread_cleanup) <inferior_pid>: Remove.
14571 <thread>: New field.
14572 (restore_current_thread_ptid_changed): Removed.
14573 (do_restore_current_thread_cleanup): Adjust.
14574 (restore_current_thread_cleanup_dtor): Don't call
14576 (set_thread_refcount): Use dec_refcount.
14577 (make_cleanup_restore_current_thread): Adjust.
14578 (thread_apply_all_command): Call inc_refcount.
14579 (_initialize_thread): Don't call
14580 observer_attach_thread_ptid_changed.
14582 2017-04-10 Yao Qi <yao.qi@linaro.org>
14584 * thread.c (delete_thread_1): Hoist code on marking thread as
14587 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14589 * windows-nat.c (windows_detach): Initialize ptid with
14592 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14594 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14596 2017-04-07 Alan Hayward <alan.hayward@arm.com>
14598 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14599 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14600 (bfin_pseudo_register_write): Likewise
14602 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14604 * common/ptid.h (struct ptid): Change to...
14605 (class ptid_t): ... this.
14606 <ptid_t>: New constructors.
14607 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14608 matches>: New methods.
14609 <make_null, make_minus_one>: New static methods.
14610 <pid>: Rename to...
14612 <lwp>: Rename to...
14614 <tid>: Rename to...
14616 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14617 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14618 as references, move comment to class ptid_t.
14619 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14620 ptid_t static methods.
14621 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14622 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14623 Take ptid arguments as references, implement using ptid_t methods.
14624 * unittests/ptid-selftests.c: New file.
14625 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14626 unittests/ptid-selftests.c.
14627 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14629 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14631 * python/python.c (python_run_simple_file): Cast mode literal to
14632 non-const char pointer as expected by PyFile_FromString.
14634 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14636 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14637 minus_one_ptid and null_ptid.
14639 2017-04-05 Pedro Alves <palves@redhat.com>
14641 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14642 * configure: Regenerate.
14644 2017-04-05 Pedro Alves <palves@redhat.com>
14646 * ada-exp.y (yyerror): Constify.
14647 * ada-lang.c (bound_name, get_selections)
14648 (ada_variant_discrim_type)
14649 (ada_variant_discrim_name, ada_value_struct_elt)
14650 (ada_lookup_struct_elt_type, is_unchecked_variant)
14651 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14652 (catch_ada_exception_command_split)
14653 (catch_ada_assert_command_split, catch_assert_command)
14654 (ada_op_name): Constify.
14655 * ada-lang.h (ada_yyerror, get_selections)
14656 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14657 * arc-tdep.c (arc_print_frame_cache): Constify.
14658 * arm-tdep.c (arm_skip_stub): Constify.
14659 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14660 (gen_aggregate_elt_ref): Constify.
14661 * bcache.c (print_bcache_statistics): Constify.
14662 * bcache.h (print_bcache_statistics): Constify.
14663 * break-catch-throw.c (catch_exception_command_1):
14664 * breakpoint.c (struct ep_type_description::description):
14666 (add_solib_catchpoint): Constify.
14667 (catch_fork_command_1): Add cast.
14668 (add_catch_command): Constify.
14669 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14671 * bsd-uthread.c (bsd_uthread_state): Constify.
14672 * buildsym.c (patch_subfile_names): Constify.
14673 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14675 * c-exp.y (yyerror): Constify.
14676 (token::oper): Constify.
14677 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14678 * c-varobj.c (cplus_describe_child): Constify.
14679 * charset.c (find_charset_names): Add cast.
14680 (find_charset_names): Constify array and add const_cast.
14681 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14682 (edit_command): Constify.
14683 * cli/cli-decode.c (lookup_cmd): Constify.
14684 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14686 (struct dump_context): Constify.
14687 (add_dump_command, restore_command): Constify.
14688 * cli/cli-script.c (get_command_line): Constify.
14689 * cli/cli-script.h (get_command_line): Constify.
14690 * cli/cli-utils.c (check_for_argument): Constify.
14691 * cli/cli-utils.h (check_for_argument): Constify.
14692 * coff-pe-read.c (struct read_pe_section_data): Constify.
14693 * command.h (lookup_cmd): Constify.
14694 * common/print-utils.c (decimal2str): Constify.
14695 * completer.c (gdb_print_filename): Constify.
14696 * corefile.c (set_gnutarget): Constify.
14697 * cp-name-parser.y (yyerror): Constify.
14698 * cp-valprint.c (cp_print_class_member): Constify.
14699 * cris-tdep.c (cris_register_name, crisv32_register_name):
14701 * d-exp.y (yyerror): Constify.
14702 (struct token::oper): Constify.
14703 * d-lang.h (d_yyerror): Constify.
14704 * dbxread.c (struct header_file_location::name): Constify.
14705 (add_old_header_file, add_new_header_file, last_function_name)
14706 (dbx_next_symbol_text, add_bincl_to_list)
14707 (find_corresponding_bincl_psymtab, set_namestring)
14708 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14709 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14710 * defs.h (command_line_input, print_address_symbolic)
14711 (deprecated_readline_begin_hook): Constify.
14712 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14714 * event-top.c (handle_line_of_input): Constify and add cast.
14715 * exceptions.c (catch_errors): Constify.
14716 * exceptions.h (catch_errors): Constify.
14717 * expprint.c (print_subexp_standard, op_string, op_name)
14718 (op_name_standard, dump_raw_expression, dump_raw_expression):
14719 * expression.h (op_name, op_string, dump_raw_expression):
14721 * f-exp.y (yyerror): Constify.
14722 (struct token::oper): Constify.
14723 (struct f77_boolean_val::name): Constify.
14724 * f-lang.c (f_word_break_characters): Constify.
14725 * f-lang.h (f_yyerror): Constify.
14726 * fork-child.c (fork_inferior): Add cast.
14727 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14728 (new_variant): Constify.
14729 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14730 * gdbarch.c: Regenerate.
14731 * gdbcore.h (set_gnutarget): Constify.
14732 * go-exp.y (yyerror): Constify.
14733 (token::oper): Constify.
14734 * go-lang.h (go_yyerror): Constify.
14735 * go32-nat.c (go32_sysinfo): Constify.
14736 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14737 * guile/scm-cmd.c (cmdscm_function): Constify.
14738 * guile/scm-param.c (pascm_param_value): Constify.
14739 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14740 (h8300sx_register_name): Constify.
14741 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14743 * ia64-tdep.c (ia64_register_names): Constify.
14744 * infcmd.c (construct_inferior_arguments): Constify.
14745 (path_command, attach_post_wait): Constify.
14746 * language.c (show_range_command, show_case_command)
14747 (unk_lang_error): Constify.
14748 * language.h (language_defn::la_error)
14749 (language_defn::la_name_of_this): Constify.
14750 * linespec.c (decode_line_2): Constify.
14751 * linux-thread-db.c (thread_db_err_str): Constify.
14752 * lm32-tdep.c (lm32_register_name): Constify.
14753 * m2-exp.y (yyerror): Constify.
14754 * m2-lang.h (m2_yyerror): Constify.
14755 * m32r-tdep.c (m32r_register_names): Constify and make static.
14756 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14757 * m88k-tdep.c (m88k_register_name): Constify.
14758 * macroexp.c (appendmem): Constify.
14759 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14760 (upgrade_type, parse_external, parse_partial_symbols)
14761 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14762 (new_symbol): Constify.
14763 * memattr.c (mem_info_command): Constify.
14764 * mep-tdep.c (register_name_from_keyword): Constify.
14765 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14767 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14768 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14769 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14771 (mi_execute_async_cli_command): Constify.
14772 * mips-tdep.c (mips_register_name): Constify.
14773 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14774 (am33_register_name, am33_2_register_name)
14775 * moxie-tdep.c (moxie_register_names): Constify.
14776 * nat/linux-osdata.c (osdata_type): Constify fields.
14777 * nto-tdep.c (nto_parse_redirection): Constify.
14778 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14779 (lookup_child_selector): Constify.
14780 (objc_methcall::name): Constify.
14781 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14782 (lookup_struct_typedef): Constify.
14783 * objfiles.c (pc_in_section): Constify.
14784 * objfiles.h (pc_in_section): Constify.
14785 * p-exp.y (struct token::oper): Constify.
14786 (yyerror): Constify.
14787 * p-lang.h (pascal_yyerror): Constify.
14788 * parser-defs.h (op_name_standard): Constify.
14789 (op_print::string): Constify.
14790 (exp_descriptor::op_name): Constify.
14791 * printcmd.c (print_address_symbolic): Constify.
14792 * psymtab.c (print_partial_symbols): Constify.
14793 * python/py-breakpoint.c (stop_func): Constify.
14794 (bppy_get_expression): Constify.
14795 * python/py-cmd.c (cmdpy_completer::name): Constify.
14796 (cmdpy_function): Constify.
14797 * python/py-event.c (evpy_add_attribute)
14798 (gdbpy_initialize_event_generic): Constify.
14799 * python/py-event.h (evpy_add_attribute)
14800 (gdbpy_initialize_event_generic): Constify.
14801 * python/py-evts.c (add_new_registry): Constify.
14802 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14803 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14804 * python/py-inferior.c (get_buffer): Add cast.
14805 * python/py-param.c (parm_constant::name): Constify.
14806 * python/py-unwind.c (fprint_frame_id): Constify.
14807 * python/python.c (gdbpy_parameter_value): Constify.
14808 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14809 * remote.c (memory_packet_config::name): Constify.
14810 (show_packet_config_cmd, remote_write_bytes)
14811 (remote_buffer_add_string):
14812 * reverse.c (exec_reverse_once): Constify.
14813 * rs6000-tdep.c (variant::name, variant::description): Constify.
14814 * rust-exp.y (rustyyerror): Constify.
14815 * rust-lang.c (rust_op_name): Constify.
14816 * rust-lang.h (rustyyerror): Constify.
14817 * serial.h (serial_ops::name): Constify.
14818 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14819 (sh_sh3e_register_name, sh_sh2e_register_name)
14820 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14821 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14822 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14823 (sh_sh4al_dsp_register_name): Constify.
14824 * sh64-tdep.c (sh64_register_name): Constify.
14825 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14826 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14827 * stabsread.c (patch_block_stabs, read_type_number)
14828 (ref_map::stabs, ref_add, process_reference)
14829 (symbol_reference_defined, define_symbol, define_symbol)
14830 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14831 (read_one_struct_field, read_struct_fields, read_baseclasses)
14832 (read_tilde_fields, read_struct_type, read_array_type)
14833 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14834 (read_huge_number, read_range_type, read_args, common_block_start)
14835 (find_name_end): Constify.
14836 * stabsread.h (common_block_start, define_symbol)
14837 (process_one_symbol, symbol_reference_defined, ref_add):
14838 * symfile.c (get_section_index, add_symbol_file_command):
14839 * symfile.h (get_section_index): Constify.
14840 * target-descriptions.c (tdesc_type::name): Constify.
14841 (tdesc_free_type): Add cast.
14842 * target.c (find_default_run_target):
14843 (add_deprecated_target_alias, find_default_run_target)
14844 (target_announce_detach): Constify.
14845 (do_option): Constify.
14846 * target.h (add_deprecated_target_alias): Constify.
14847 * thread.c (print_thread_info_1): Constify.
14848 * top.c (deprecated_readline_begin_hook, command_line_input):
14850 (init_main): Add casts.
14851 * top.h (handle_line_of_input): Constify.
14852 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14853 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14854 (tfind_command): Rename to ...
14855 (tfind_command_1): ... this and constify.
14856 (tfind_command): New function.
14857 (tfind_end_command, tfind_start_command): Adjust.
14858 (encode_source_string): Constify.
14859 * tracepoint.h (encode_source_string): Constify.
14860 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14861 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14862 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14863 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14864 * tui/tui-win.c (parse_scrolling_args): Constify.
14865 * tui/tui-windata.c (tui_erase_data_content): Constify.
14866 * tui/tui-windata.h (tui_erase_data_content): Constify.
14867 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14868 * tui/tui.c (tui_enable): Add cast.
14869 * utils.c (defaulted_query): Constify.
14870 (init_page_info): Add cast.
14871 (puts_debug, subset_compare): Constify.
14872 * utils.h (subset_compare): Constify.
14873 * varobj.c (varobj_format_string): Constify.
14874 * varobj.h (varobj_format_string): Constify.
14875 * vax-tdep.c (vax_register_name): Constify.
14876 * windows-nat.c (windows_detach): Constify.
14877 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14878 * xml-support.c (gdb_xml_end_element): Constify.
14879 * xml-tdesc.c (tdesc_start_reg): Constify.
14880 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14881 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14882 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14884 2017-04-05 Pedro Alves <palves@redhat.com>
14886 * proc-api.c (struct trans): Constify.
14887 (procfs_note): Constify.
14888 * proc-events.c (struct trans, syscall_table):
14889 * proc-flags.c (struct trans): Constify.
14890 * proc-utils.h (procfs_note): Constify.
14891 * proc-why.c (struct trans): Constify.
14892 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14893 (procfs_detach): Constify.
14894 * sol-thread.c (struct string_map): Constify.
14895 (td_err_string, td_state_string): Constify.
14897 2017-04-05 Pedro Alves <palves@redhat.com>
14899 * proc-api.c (procfs_filename): Don't initialize
14901 (prepare_to_trace): Assume procfs_filename is non-NULL.
14902 (_initialize_proc_api): Give procfs_filename a default value here.
14904 2017-04-05 Pedro Alves <palves@redhat.com>
14906 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14907 'cond_string' parameter.
14908 (extract_exception_regexp): Constify 'string' parameter.
14909 (catch_exception_command_1): Constify.
14910 * breakpoint.c (init_catchpoint)
14911 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14913 (ep_parse_optional_if_clause, catch_fork_command_1)
14914 (catch_exec_command_1): Constify.
14915 * breakpoint.h (init_catchpoint): Constify 'cond_string'
14917 (ep_parse_optional_if_clause): Constify.
14918 * cli/cli-utils.c (remove_trailing_whitespace)
14919 (check_for_argument): Constify.
14920 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
14921 non-const overload.
14922 (check_for_argument): Likewise.
14924 2017-04-05 Pedro Alves <palves@redhat.com>
14926 * event-top.c (command_line_handler): Add cast to execute_command
14928 * record-btrace.c (cmd_record_btrace_bts_start)
14929 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
14930 (cmd_record_btrace_start): Add cast to execute_command call.
14931 * record-full.c (record_full_goto_insn):
14932 * record.c (record_start, record_stop): Add cast to
14933 execute_command_to_string calls.
14934 (cmd_record_start): Add cast to execute_command calls.
14936 2017-04-05 Pedro Alves <palves@redhat.com>
14938 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
14939 static inline function.
14940 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
14941 array and use gdb_PyArg_ParseTupleAndKeywords.
14942 * python/py-cmd.c (cmdpy_init): Likewise.
14943 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
14944 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
14945 (infpy_search_memory): Likewise.
14946 * python/py-objfile.c (objfpy_add_separate_debug_file)
14947 (gdbpy_lookup_objfile): Likewise.
14948 * python/py-symbol.c (gdbpy_lookup_symbol)
14949 (gdbpy_lookup_global_symbol): Likewise.
14950 * python/py-type.c (gdbpy_lookup_type): Likewise.
14951 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
14952 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
14955 2017-04-05 Pedro Alves <palves@redhat.com>
14957 * python/python-internal.h (gdb_PyGetSetDef): New type.
14958 * python/py-block.c (block_object_getset)
14959 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
14960 * python/py-event.c (event_object_getset)
14961 (finish_breakpoint_object_getset): Likewise.
14962 * python/py-inferior.c (inferior_object_getset): Likewise.
14963 * python/py-infthread.c (thread_object_getset): Likewise.
14964 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
14965 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
14966 * python/py-objfile.c (objfile_getset): Likewise.
14967 * python/py-progspace.c (pspace_getset): Likewise.
14968 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
14970 * python/py-record.c (recpy_record_getset): Likewise.
14971 * python/py-symbol.c (symbol_object_getset): Likewise.
14972 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
14974 * python/py-type.c (type_object_getset, field_object_getset):
14976 * python/py-value.c (value_object_getset): Likewise.
14978 2017-04-05 Pedro Alves <palves@redhat.com>
14980 * python/python-internal.h (gdb_PyObject_CallMethod)
14981 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
14983 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
14984 (PySys_GetObject, PySys_SetPath): New macros.
14986 2017-04-05 Pedro Alves <palves@redhat.com>
14988 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
14989 info_osdata_command.
14990 * osdata.c (info_osdata_command): Rename to ...
14991 (info_osdata): ... this. Constify 'type' parameter, and remove
14992 the 'from_tty' parameter. Accept NULL TYPE.
14993 (info_osdata_command): New function.
14994 * osdata.h (info_osdata_command): Remove declaration.
14995 (info_osdata): New declaration.
14997 2017-04-05 Pedro Alves <palves@redhat.com>
14999 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
15000 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
15001 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
15003 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
15004 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
15005 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
15007 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
15008 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
15009 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
15010 (mi_cmd_file_list_exec_source_files)
15011 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
15012 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
15013 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
15015 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
15016 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
15017 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
15018 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
15019 (mi_cmd_stack_info_frame): Constify 'command' parameter.
15020 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
15021 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
15022 'command' parameter.
15023 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
15024 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
15025 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
15026 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
15027 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
15028 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
15029 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
15030 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
15031 (mi_cmd_var_set_update_range): Constify 'command' parameter.
15032 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
15033 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
15035 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
15036 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
15037 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
15038 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
15039 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
15040 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
15041 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
15042 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
15043 (mi_cmd_data_list_changed_registers)
15044 (mi_cmd_data_write_register_values)
15045 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
15046 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
15047 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
15048 (mi_cmd_list_features, mi_cmd_list_target_features)
15049 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
15050 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
15051 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
15052 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
15053 (mi_cmd_trace_frame_collected): Constify 'command'
15055 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
15056 'command' parameter.
15058 2017-04-05 Pedro Alves <palves@redhat.com>
15060 * ada-lang.c (ada_completer_word_break_characters): Now a const
15062 (ada_get_gdb_completer_word_break_characters): Constify.
15063 * completer.c (gdb_completer_command_word_break_characters)
15064 (gdb_completer_file_name_break_characters)
15065 (gdb_completer_quote_characters): Now const arrays.
15066 (get_gdb_completer_quote_characters): Constify.
15067 (set_rl_completer_word_break_characters): New function.
15068 (set_gdb_completion_word_break_characters)
15069 (complete_line_internal): Use it.
15070 * completer.h (get_gdb_completer_quote_characters): Constify.
15071 (set_rl_completer_word_break_characters): Declare.
15072 * f-lang.c (f_word_break_characters): Constify.
15073 * language.c (default_word_break_characters): Constify.
15074 * language.h (language_defn::la_word_break_characters): Constify.
15075 (default_word_break_characters): Constify.
15076 * top.c (init_main): Use set_rl_completer_word_break_characters.
15078 2017-04-05 Pedro Alves <palves@redhat.com>
15080 * aix-thread.c (aix_thread_pid_to_str)
15081 (aix_thread_extra_thread_info): Constify.
15082 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
15083 * bsd-uthread.c (bsd_uthread_extra_thread_info)
15084 (bsd_uthread_pid_to_str): Constify.
15085 * corelow.c (core_pid_to_str): Constify.
15086 * darwin-nat.c (darwin_pid_to_str): Constify.
15087 * fbsd-nat.c (fbsd_pid_to_str): Constify.
15088 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
15090 * gnu-nat.c (gnu_pid_to_str): Constify.
15091 * go32-nat.c (go32_pid_to_str): Constify.
15092 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
15093 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
15094 * inferior.c (inferior_pid_to_str): Constify.
15095 * linux-nat.c (linux_nat_pid_to_str): Constify.
15096 * linux-tdep.c (linux_core_pid_to_str): Constify.
15097 * linux-thread-db.c (thread_db_pid_to_str)
15098 (thread_db_extra_thread_info): Constify.
15099 * nto-tdep.c (nto_extra_thread_info): Constify.
15100 * nto-tdep.h (nto_extra_thread_info): Constify.
15101 * obsd-nat.c (obsd_pid_to_str): Constify.
15102 * procfs.c (procfs_pid_to_str): Constify.
15103 * ravenscar-thread.c (ravenscar_extra_thread_info)
15104 (ravenscar_pid_to_str): Constify.
15105 * remote-sim.c (gdbsim_pid_to_str): Constify.
15106 * remote.c (remote_threads_extra_info, remote_pid_to_str):
15108 * sol-thread.c (solaris_pid_to_str): Constify.
15109 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
15110 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
15111 * target.c (default_pid_to_str, target_pid_to_str)
15112 (normal_pid_to_str, default_pid_to_str): Constify.
15113 * target.h (target_ops::to_pid_to_str)
15114 (target_ops::to_extra_thread_info): Constify.
15115 (target_pid_to_str, normal_pid_to_str): Constify.
15116 * windows-nat.c (windows_pid_to_str): Constify.
15117 * gdbarch.sh (core_pid_to_str): Constify.
15118 * target-delegates.c: Regenerate.
15119 * gdbarch.h, gdbarch.c: Regenerate.
15121 2017-04-05 Pedro Alves <palves@redhat.com>
15123 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
15124 the memory of the temporary warning_pre_print override.
15125 * utils.c (warning_pre_print): Constify.
15126 * utils.h (warning_pre_print): Constify.
15128 2017-04-05 Pedro Alves <palves@redhat.com>
15130 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
15131 (shell_command): New function.
15132 (make_command): Use std::string.
15133 (init_cli_cmds): Register shell_command instead of shell_escape.
15135 2017-04-05 Pedro Alves <palves@redhat.com>
15137 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
15138 * tracepoint.c (default_collect): Don't initialize.
15140 2017-04-05 Pedro Alves <palves@redhat.com>
15142 * macroexp.c (macro_buffer::shared): Now a bool.
15143 (init_buffer): Update.
15144 (init_shared_buffer): Constify 'addr' parameter.
15145 (substitute_args, expand, macro_expand, macro_expand_next): Remove
15148 2017-04-05 Pedro Alves <palves@redhat.com>
15150 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
15151 * disasm.c (set_disassembler_options): Constify local.
15152 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
15154 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
15157 * tracefile.c (tsave_command): Fix argument parsing for '-r'
15160 2017-04-05 Yao Qi <yao.qi@linaro.org>
15162 * frame.c (frame_unwind_register_unsigned): Call
15163 frame_unwind_register_value.
15165 2017-04-05 Yao Qi <yao.qi@linaro.org>
15167 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
15168 Use gdb_test_multiple, and don't match anchor.
15170 2017-04-05 Pedro Alves <palves@redhat.com>
15172 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
15173 (Write After Approval): Remove Simon Marchi.
15175 2017-04-05 Pedro Alves <palves@redhat.com>
15177 * common/gdb_optional.h (optional::optional): Make constexpr and
15178 initialize m_dummy.
15180 2017-04-04 John Baldwin <jhb@FreeBSD.org>
15182 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15183 (amd64fbsd_jmp_buf_reg_offset): Remove.
15184 (amd64fbsd_supply_uthread): Remove function.
15185 (amd64fbsd_collect_uthread): Remove function.
15186 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
15187 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
15188 (x86_64-*-freebsd*): Remove bsd-uthread.o.
15189 (fbsd-nat.c): Update comment.
15190 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15191 (i386fbsd_jmp_buf_reg_offset): Remove.
15192 (i386fbsd_supply_uthread): Remove function.
15193 (i386fbsd_collect_uthread): Remove function.
15194 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
15196 2017-04-04 John Baldwin <jhb@FreeBSD.org>
15198 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
15199 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
15200 * NEWS: Mention that support for FreeBSD/alpha was removed.
15201 * alpha-fbsd-tdep.c: Delete file.
15202 * config/alpha/fbsd.mh: Delete file.
15203 * configure.host: Delete alpha*-*-freebsd* and
15204 alpha*-*-kfreebsd*-gnu.
15205 * configure.tgt: Delete alpha*-*-freebsd* and
15206 alpha*-*-kfreebsd*-gnu.
15208 2017-04-04 John Baldwin <jhb@FreeBSD.org>
15210 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
15211 amd64bsd_store_inferior_registers): Use ptid from regcache.
15213 2017-04-04 Pedro Alves <palves@redhat.com>
15215 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
15216 data fields, make them private and add "m_" prefixes.
15217 (lnp_state_machine::lnp_state_machine): New ctor.
15218 (record_line, check_line_address, handle_set_discriminator)
15219 (handle_set_address, handle_advance_pc, handle_special_opcode)
15220 (handle_advance_line, handle_set_file, handle_negate_stmt)
15221 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
15222 (end_sequence, advance_line): New methods.
15223 (m_gdbarch, m_record_lines_p): New fields.
15224 (lnp_reader_state): Delete.
15225 (dwarf_record_line): Rename to ...
15226 (lnp_state_machine::record_line): ... adjust.
15227 (init_lnp_state_machine): Delete.
15228 (lnp_state_machine::lnp_state_machine): New.
15229 (check_line_address): Rename to ...
15230 (lnp_state_machine::check_line_address): This.
15231 (dwarf_decode_lines_1): Remove reference to "reader_state".
15232 Adjust lnp_state_machine having a non-default ctor. Use bool.
15233 State machine internal state manipulation moved to
15234 lnp_state_machine methods.
15236 2017-04-04 Pedro Alves <palves@redhat.com>
15238 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15239 unittests/offset-type-selftests.c.
15240 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
15241 * common/offset-type.h: New file.
15242 * common/preprocessor.h: New file.
15243 * common/traits.h: New file.
15244 * common/valid-expr.h: New file.
15245 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
15246 sect_offset and cu_offset strong typedefs throughout.
15247 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
15248 typedefs throughout.
15249 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
15250 sect_offset and cu_offset strong typedefs throughout.
15251 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
15252 typedefs throughout.
15253 * gdbtypes.h: Include "common/offset-type.h".
15254 (cu_offset): Now an offset type (strong typedef) instead of a
15256 (sect_offset): Likewise.
15257 (union call_site_parameter_u): Rename "param_offset" field to
15259 * unittests/offset-type-selftests.c: New file.
15261 2017-04-04 Pedro Alves <palves@redhat.com>
15263 * common/underlying.h: New file.
15264 * dwarf2read.c: Include "common/gdb_optional.h" and
15265 "common/underlying.h".
15266 (dir_index, file_name_index): New types.
15267 (file_entry): Use them.
15268 (file_entry::include): Use to_underlying.
15269 (line_header::add_file_name): Use dir_index.
15270 (read_formatted_entries): Use gdb::optional. Read form before
15271 writting to file_entry.
15272 (dwarf_decode_line_header): Use dir_index.
15273 (lnp_state_machine::current_file): Use to_underlying.
15274 (lnp_state_machine::file): Change type to file_name_index.
15275 (dwarf_record_line): Use to_underlying.
15276 (init_lnp_state_machine): Use file_name_index.
15277 (dwarf_decode_lines_1): Use dir_index and file_name_index.
15279 2017-04-04 Pedro Alves <palves@redhat.com>
15281 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
15282 operator bool, has_value and get methods.
15284 2017-04-04 Pedro Alves <palves@redhat.com>
15286 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
15288 (line_header): Initialize all data fields. Change type of
15289 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
15290 Change type of include_dirs to std::vector<const char *>. Remove
15291 num_include_dirs, include_dirs_size. Change type of file_names to
15292 std::vector<file_entry>. Remove num_file_names, file_names_size.
15293 (line_header::line_header): New.
15294 (line_header::add_include_dir, line_header::add_file_name): New
15296 (line_header::include_dir_at): Remove NULL check.
15297 (line_header::file_name_at): Add const overload.
15298 (line_header_up): New unique_ptr typedef.
15299 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
15300 std::vector. Remove free_line_header call.
15301 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
15302 free_line_header call.
15303 (free_cu_line_header): Delete.
15304 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
15305 (setup_type_unit_groups): Use line_header_up instead of cleanups.
15306 Adjust to use std::vector.
15307 (free_line_header): Delete.
15308 (free_line_header_voidp): Use delete.
15309 (add_include_dir): Replace with ...
15310 (line_header::add_include_dir): ... this method. Use std::vector.
15311 (add_file_name): Replace with ...
15312 (line_header::add_file_name): ... this method. Use std::vector.
15313 (add_include_dir_stub): Delete.
15314 (read_formatted_entries): Remove memset.
15315 (dwarf_decode_line_header): Return a line_header_up instead of a
15316 raw pointer. Remove cleanup handling. Pass lambdas to
15317 read_formatted_entries. Adjust to use line_header methods.
15318 (dwarf_decode_lines_1): Adjust to use line_header methods.
15319 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
15322 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
15324 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
15325 instead of struct ptid.
15327 2017-05-04 Alan Hayward <alan.hayward@arm.com>
15329 * frame.c (get_frame_register_bytes): Unwind using value.
15330 (put_frame_register_bytes): Likewise.
15332 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
15334 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
15337 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
15339 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
15341 2017-03-29 Yao Qi <yao.qi@linaro.org>
15343 * gdbthread.h (struct thread_info): Declare constructor and
15344 destructor. Add some in-class member initializers.
15345 * thread.c (free_thread): Remove.
15346 (init_thread_list): Call delete instead of free_thread.
15347 (new_thread): Call thread_info constructor.
15348 (thread_info::thread_info): New function.
15349 (thread_info::~thread_info): New function.
15350 (delete_thread_1): Call delete instead of free_thread.
15351 (make_cleanup_restore_current_thread): Move tp and frame to
15354 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15356 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
15357 (arc_skip_prologue): Likewise.
15358 (arc_make_frame_cache): Likewise.
15359 (arc_pv_get_operand): New function.
15360 (arc_is_in_prologue): Likewise.
15361 (arc_analyze_prologue): Likewise.
15362 (arc_print_frame_cache): Likewise.
15363 (MAX_PROLOGUE_LENGTH): New constant.
15365 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15367 * configure.tgt: Add arc-insn.o.
15368 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
15369 (dump_arc_instruction_command): New function.
15370 (arc_fprintf_disasm): Likewise.
15371 (arc_disassemble_info): Likewise.
15372 (arc_insn_get_operand_value): Likewise.
15373 (arc_insn_get_operand_value_signed): Likewise.
15374 (arc_insn_get_memory_base_reg): Likewise.
15375 (arc_insn_get_memory_offset): Likewise.
15376 (arc_insn_get_branch_target): Likewise.
15377 (arc_insn_dump): Likewise.
15378 (arc_insn_get_linear_next_pc): Likewise.
15379 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
15380 (arc_disassemble_info): Likewise.
15381 (arc_insn_get_branch_target): Likewise.
15382 (arc_insn_get_linear_next_pc): Likewise.
15383 * NEWS: Mention new "maint print arc arc-instruction".
15385 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15387 * arc-tdep (maintenance_print_arc_list): New variable.
15388 (maintenance_print_arc_command): New function.
15390 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15392 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
15393 Add "limm" and "reserved".
15394 (arc_cannot_fetch_register, arc_cannot_store_register): Add
15395 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
15396 * arc-tdep.h (arc_regnum): Likewise.
15398 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15400 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15401 for THREADPTR register.
15402 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
15404 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
15405 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
15406 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
15408 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15410 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
15411 registers above gdbarch_num_regs (gdbarch) as privileged in
15414 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15416 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15417 for a single specified register or for all registers in
15418 a0_base..a0_base + C0_NREGS range.
15419 (supply_gregset_reg): Call regcache_raw_supply for a single
15420 specified register or for all registers in a0_base..a0_base +
15423 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15425 * arch/xtensa.h (C0_NREGS): Add definition.
15426 * xtensa-tdep.c (C0_NREGS): Remove definition.
15428 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15430 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
15431 Drop xtensa_default_isa initialization.
15432 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
15434 2017-03-27 Pedro Alves <palves@redhat.com>
15436 * dwarf2read.c (file_entry) <dir_index>: Add comment.
15437 (file_entry::include_dir): New method.
15438 (line_header::include_dir_at, line_header::file_name_at): New
15440 (setup_type_unit_groups, setup_type_unit_groups)
15441 (psymtab_include_file_name): Simplify using the new methods.
15442 (lnp_state_machine) <the_line_header>: New field.
15443 <file>: Add comment.
15444 (lnp_state_machine::current_file): New method.
15445 (dwarf_record_line): Simplify using the new methods.
15446 (init_lnp_state_machine): Initialize the "the_line_header" field.
15447 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
15448 Simplify using the new methods.
15450 2017-03-27 Pedro Alves <palves@redhat.com>
15452 * cp-name-parser.y (make_empty): Delete.
15453 (demangler_special, nested_name, ptr_operator, array_indicator)
15454 (direct_declarator, declarator_1): Use fill_comp instead of
15457 2017-03-27 Pedro Alves <palves@redhat.com>
15459 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
15460 to ATTRIBUTE_PRINTF.
15461 * solib-target.c (library_list_start_list): Print "string" not
15463 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
15464 gdb_xml_error call.
15466 2017-03-27 Pedro Alves <palves@redhat.com>
15468 * dwarf2read.c (struct file_and_directory): New.
15469 (dwarf2_get_dwz_file): Adjust to use std::string.
15470 (dw2_get_file_names_reader): Adjust to use file_and_directory.
15471 (find_file_and_directory): Adjust to return a file_and_directory
15473 (read_file_scope): Adjust to use file_and_directory. Remove
15474 make_cleanup/do_cleanups calls.
15475 (open_and_init_dwp_file): Adjust to use std::string. Remove
15476 make_cleanup/do_cleanups calls.
15477 * python/python.c (do_start_initialization): Adjust to ldirname
15478 returning a std::string.
15479 * utils.c (ldirname): Now returns a std::string.
15480 * utils.h (ldirname): Change return type to std::string.
15481 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
15482 returning a std::string.
15483 * xml-tdesc.c (file_read_description_xml): Likewise.
15485 2017-03-24 Alan Hayward <alan.hayward@arm.com>
15487 * regcache.c (regcache_debug_print_register): New function.
15488 * regcache.h (regcache_debug_print_register): New declaration.
15489 * target.c (debug_print_register): Remove.
15490 (target_fetch_registers): Call regcache_debug_print_register.
15491 (target_store_registers): Likewise.
15493 2017-03-24 Pádraig Brady <pbrady@fb.com>
15495 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
15496 reference beyond the 'lh->include_dirs' array before accessing to
15498 (psymtab_include_file_name): Likewise.
15499 (dwarf_decode_lines_1): Likewise.
15500 (dwarf_decode_lines): Likewise.
15501 (file_file_name): Likewise.
15503 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
15505 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
15507 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15508 ps_lsetfpregs): Likewise.
15509 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
15510 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15511 ps_lsetfpregs): Likewise.
15512 * target.c (target_fetch_registers, target_store_registers):
15515 2017-03-23 Alan Hayward <alan.hayward@arm.com>
15517 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
15519 2017-03-23 Yao Qi <yao.qi@linaro.org>
15521 * aarch64-tdep.c (aarch64_process_record_test): Declare.
15522 (_initialize_aarch64_tdep): Register it.
15523 (aarch64_record_load_store): Handle PRFM instruction.
15524 (aarch64_process_record_test): New function.
15526 2017-03-23 Yao Qi <yao.qi@linaro.org>
15528 * aarch64-tdep.c (aarch64_record_load_store): Fix code
15531 2017-03-23 Yao Qi <yao.qi@linaro.org>
15533 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
15535 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15537 python/python.c (do_start_initialization): Fix memory leak.
15539 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
15541 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
15542 using get_ptrace_pid.
15543 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
15545 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
15546 inferior_ptid instead of pid.
15548 2017-03-22 Yao Qi <yao.qi@linaro.org>
15550 * aarch64-tdep.c: Wrap locally used classes in anonymous
15552 * arm-tdep.c: Likewise.
15553 * linespec.c: Likewise.
15554 * ui-out.c: Likewise.
15556 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
15559 * python/lib/gdb/printer/bound_registers.py: Import sys.
15561 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15563 * windows-nat.c (do_windows_fetch_inferior_registers): Add
15564 windows_thread_info parameter and use it instead of
15566 (windows_fetch_inferior_registers): Don't set current_thread,
15567 pass the thread to do_windows_fetch_inferior_registers. Use
15568 ptid from regcache instead of inferior_ptid.
15569 (do_windows_store_inferior_registers): Add windows_thread_info
15570 parameter and use it instead of current_thread.
15571 (windows_store_inferior_registers): Don't set current_thread,
15572 pass the thread to do_windows_store_inferior_registers. Use
15573 ptid from regcache instead of inferior_ptid.
15575 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15577 * ser-mingw.c (ser_windows_raw): Remove reference to
15578 struct serial::current_timeout.
15580 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15583 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15584 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15585 (sparc64_fsr_type): Fix %fsr decoding.
15587 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15589 * python/py-record-btrace.c (btpy_insn_data): Change return type
15592 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15594 * spu-linux-nat.c (spu_fetch_inferior_registers,
15595 spu_store_inferior_registers): Use ptid from regcache, set and
15596 restore inferior_ptid.
15597 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15600 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15602 * i386-linux-nat.c (fetch_register, store_register,
15603 i386_linux_fetch_inferior_registers,
15604 i386_linux_store_inferior_registers): Use ptid from regcache.
15605 * ia64-linux-nat.c (ia64_linux_fetch_register,
15606 ia64_linux_store_register): Likewise.
15607 * inf-ptrace.c (inf_ptrace_fetch_register,
15608 inf_ptrace_store_register): Likewise.
15609 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15610 m32r_linux_store_inferior_registers): Likewise.
15611 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15612 m68kbsd_store_inferior_registers): Likewise.
15613 * m68k-linux-nat.c (fetch_register, store_register,
15614 m68k_linux_fetch_inferior_registers,
15615 m68k_linux_store_inferior_registers): Likewise.
15616 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15617 m88kbsd_store_inferior_registers): Likewise.
15618 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15619 mips_fbsd_store_inferior_registers): Likewise.
15620 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15621 mips64_linux_regsets_store_registers): Likewise.
15622 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15623 mipsnbsd_store_inferior_registers): Likewise.
15624 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15625 mips64obsd_store_inferior_registers): Likewise.
15626 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15628 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15629 ppcfbsd_store_inferior_registers): Likewise.
15630 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15631 ppc_linux_store_inferior_registers): Likewise.
15632 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15633 ppcnbsd_store_inferior_registers): Likewise.
15634 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15635 ppcobsd_store_registers): Likewise.
15636 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15638 * ravenscar-thread.c (ravenscar_fetch_registers,
15639 ravenscar_store_registers, ravenscar_prepare_to_store):
15641 * record-btrace.c (record_btrace_fetch_registers,
15642 record_btrace_store_registers, record_btrace_prepare_to_store):
15644 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15645 Lookup inferior using ptid from regcache, instead of
15647 * remote.c (remote_fetch_registers, remote_store_registers): Use
15648 ptid from regcache.
15649 * rs6000-nat.c (fetch_register, store_register): Likewise.
15650 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15651 s390_linux_store_inferior_registers): Likewise.
15652 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15653 shnbsd_store_inferior_registers): Likewise.
15654 * sol-thread.c (sol_thread_fetch_registers,
15655 sol_thread_store_registers): Likewise.
15656 * sparc-nat.c (sparc_fetch_inferior_registers,
15657 sparc_store_inferior_registers): Likewise.
15658 * tilegx-linux-nat.c (fetch_inferior_registers,
15659 store_inferior_registers): Likewise.
15660 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15661 vaxbsd_store_inferior_registers): Likewise.
15662 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15663 store_xtregs): Likewise.
15665 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15668 * NEWS: Mention support for rvalue references in GDB and python.
15669 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15670 supports both lvalue and rvalue references.
15672 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15675 * gdbtypes.c (rank_one_type): Implement overloading
15676 resolution rules regarding rvalue references.
15678 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15681 * aarch64-tdep.c (aarch64_type_align)
15682 (aarch64_extract_return_value, aarch64_store_return_value): Change
15683 lvalue reference type checks to general reference type checks.
15684 * amd64-tdep.c (amd64_classify): Likewise.
15685 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15687 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15688 (arm_store_return_value): Likewise.
15689 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15690 * c-typeprint.c (c_print_type): Likewise.
15691 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15692 (cplus_number_of_children, cplus_describe_child): Likewise.
15693 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15694 * completer.c (expression_completer): Likewise.
15695 * cp-support.c (make_symbol_overload_list_adl_namespace):
15697 * darwin-nat-info.c (info_mach_region_command): Likewise.
15698 * dwarf2loc.c (entry_data_value_coerce_ref)
15699 (value_of_dwarf_reg_entry): Likewise.
15700 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15701 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15703 * findvar.c (extract_typed_address, store_typed_address):
15705 * gdbtypes.c (rank_one_type): Likewise.
15706 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15707 * infcall.c (value_arg_coerce): Likewise.
15708 * language.c (pointer_type): Likewise.
15709 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15711 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15712 * mn10300-tdep.c (mn10300_type_align): Likewise.
15713 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15714 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15715 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15717 * printcmd.c (print_formatted, x_command): Likewise.
15718 * python/py-type.c (typy_get_composite, typy_template_argument):
15720 * python/py-value.c (valpy_referenced_value)
15721 (valpy_get_dynamic_type, value_has_field): Likewise.
15722 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15723 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15724 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15725 * spu-tdep.c (spu_scalar_value_p): Likewise.
15726 * symtab.c (lookup_symbol_aux): Likewise.
15727 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15728 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15730 * valops.c (value_cast_pointers, value_cast)
15731 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15732 (value_struct_elt, value_struct_elt_bitpos)
15733 (value_find_oload_method_list, find_overload_match)
15734 (value_rtti_indirect_type): Likewise.
15735 * valprint.c (val_print_scalar_type_p, generic_val_print):
15737 * value.c (value_actual_type, value_as_address, unpack_long)
15738 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15739 (coerce_ref): Likewise.
15740 * varobj.c (varobj_get_value_type): Likewise.
15742 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15745 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15746 table of constants.
15747 * python/lib/gdb/command/explore.py: Support exploring values
15748 of rvalue reference types.
15749 * python/lib/gdb/types.py: Implement get_basic_type() for
15750 rvalue reference types.
15751 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15753 * python/py-value.c (valpy_getitem): Add an rvalue reference
15755 (valpy_reference_value): Add new parameter "refcode".
15756 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15757 New wrappers for valpy_reference_value().
15758 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15759 (gdbpy_invoke_xmethod): Likewise.
15761 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15764 * dwarf2read.c (process_die, read_type_die_1): Handle the
15765 DW_TAG_rvalue_reference_type DIE.
15766 (read_tag_reference_type): Add new parameter "refcode".
15768 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15771 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15772 (c_type_print_modifier, c_type_print_varspec_suffix)
15773 (c_type_print_base): Support printing rvalue reference types.
15774 * c-valprint.c (c_val_print, c_value_print): Support printing
15775 rvalue reference values.
15777 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15780 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15782 * cp-support.c (replace_typedefs): Handle
15783 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15784 * python/py-type.c (typy_lookup_type): Likewise.
15786 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15789 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15790 * parse.c (insert_type): Change assert statement.
15791 (follow_types): Handle rvalue reference types.
15792 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15795 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15798 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15799 value_ref() interface.
15800 * c-valprint.c (c_value_print): Likewise.
15801 * infcall.c (value_arg_coerce): Likewise.
15802 * python/py-value.c (valpy_reference_value): Likewise.
15803 * valops.c (value_cast, value_reinterpret_cast)
15804 (value_dynamic_cast, typecmp): Likewise.
15805 (value_ref): Parameterize by kind of return value reference type.
15806 * value.h (value_ref): Add new parameter "refcode".
15808 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15811 * dwarf2read.c (read_tag_reference_type): Use
15812 lookup_lvalue_reference_type() instead of lookup_reference_type().
15813 * eval.c (evaluate_subexp_standard): Likewise.
15814 * f-exp.y: Likewise.
15815 * gdbtypes.c (make_reference_type, lookup_reference_type):
15816 Generalize with rvalue reference types.
15817 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15818 convenience wrappers for lookup_reference_type().
15819 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15820 reference kind parameter.
15821 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15822 wrappers for lookup_reference_type().
15823 * guile/scm-type.c (gdbscm_type_reference): Use
15824 lookup_lvalue_reference_type() instead of lookup_reference_type().
15825 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15826 * parse.c (follow_types): Likewise.
15827 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15828 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15830 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15831 (gdbpy_invoke_xmethod): Likewise.
15832 * stabsread.c: Provide extra argument to make_reference_type()
15834 * valops.c (value_ref, value_rtti_indirect_type): Use
15835 lookup_lvalue_reference_type() instead of lookup_reference_type().
15837 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15840 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15841 (TYPE_IS_REFERENCE): New macro.
15842 (struct type): Add rvalue_reference_type field.
15843 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15845 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15847 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15848 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15849 New function definition.
15850 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15851 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15852 New function declaration.
15853 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15854 * mi/mi-interp.h: New file.
15855 * solib.c (info_sharedlibrary_command): Replace for loop with
15857 * solib.h (update_solib_list): New function declaration.
15858 (so_list_head): Move macro.
15859 * solist.h (ALL_SO_LIBS): New macro.
15861 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15863 * infcmd.c (post_create_inferior): Remove unused argument in
15865 * remote.c (remote_start_remote): Likewise.
15866 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15867 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15868 (enable_break): Likewise.
15869 * solib.c (update_solib_list): Remove unused target argument
15870 and its documentation.
15871 (solib_add): Remove unused target argument. Remove unused
15872 argument in call to update_solib_list.
15873 (info_sharedlibrary_command): Remove unused argument in call
15874 to update_solib_list.
15875 (sharedlibrary_command): Remove unused argument in call to
15877 (handle_solib_event): Likewise.
15878 (reload_shared_libraries): Likewise.
15879 * solib.h (solib_add): Remove unused target argument.
15881 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15883 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15884 (s390_displaced_step_fixup): Cover relative branches with the
15885 default fixup handling. This fixes lack of support for some
15886 relative branch instructions.
15888 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15890 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15891 ptid from regcache.
15893 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15895 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15896 i386_darwin_store_inferior_registers): Use ptid from regcache.
15898 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15900 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15901 i386bsd_store_inferior_registers): Use ptid from regcache.
15903 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15905 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15906 hppaobsd_store_registers): Use ptid from regcache.
15908 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15910 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15911 hppanbsd_store_registers): Use ptid from regcache.
15913 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15915 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
15916 from regcache. Use get_ptrace_pid.
15918 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15920 * corelow.c (get_core_register_section): Use ptid from regcache,
15923 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15925 * bsd-uthread.c (bsd_uthread_fetch_registers,
15926 bsd_uthread_store_registers): Use ptid from regcache, set and
15927 restore inferior_ptid.
15929 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15931 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
15932 fetch_fp_regs, store_register, store_regs, store_fp_register,
15933 store_fp_regs): Use ptid from regcache.
15935 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15937 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
15938 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
15939 store_vfp_regs): Use ptid from regcache.
15941 2017-03-17 Pedro Alves <palves@redhat.com>
15944 * ser-base.c (ser_base_wait_for): Add comment.
15945 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
15947 * ser-unix.c (hardwire_raw): Remove reference to
15948 scb->current_timeout.
15949 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
15950 (hardwire_ops): Install ser_base_readchar instead of
15952 * serial.h (struct serial) <current_timeout, timeout_remaining>:
15955 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
15958 * python/lib/gdb/printer/bound_registers.py: Add support for
15961 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
15963 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
15964 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
15965 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
15966 byte_offset to subobj_byte_offset. Fix the handling of
15967 DWARF_VALUE_STACK on big-endian targets when coming via an
15969 (dwarf2_evaluate_loc_desc): Adjust call to
15970 dwarf2_evaluate_loc_desc_full.
15971 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
15972 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
15974 2017-03-16 Yao Qi <yao.qi@linaro.org>
15976 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
15977 and REVSH instructions.
15979 2017-03-16 Yao Qi <yao.qi@linaro.org>
15981 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
15982 (arm_record_test): Declare.
15983 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
15984 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
15985 align with the manual.
15986 (thumb_record_misc): Adjust the code order to align with the
15988 (thumb2_record_decode_insn_handler): Fix instruction matching.
15989 (instruction_reader_thumb): New class.
15990 (arm_record_test): New function.
15992 2017-03-16 Yao Qi <yao.qi@linaro.org>
15994 * arm-tdep.c (abstract_memory_reader): New class.
15995 (instruction_reader): New class.
15996 (extract_arm_insn): Add argument 'reader'. Callers updated.
15997 (decode_insn): Likewise.
15999 2017-03-16 Doug Evans <dje@google.com>
16001 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
16002 member. Change type of TYPE member to SCM. All uses updated.
16003 (lsscm_make_lazy_string_smob): Add assert.
16004 (lsscm_make_lazy_string): Flag bad length values.
16005 (lsscm_elt_type): New function.
16006 (gdbscm_lazy_string_to_value): Rewrite to use
16007 lsscm_safe_lazy_string_to_value.
16008 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
16009 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
16010 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
16012 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
16013 * guile/scm-type.c (tyscm_scm_to_type): New function.
16015 2017-03-15 Doug Evans <dje@google.com>
16017 PR python/17728, python/18439, python/18779
16018 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
16019 member. Change type of TYPE member to PyObject *. All uses updated.
16020 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
16021 (gdbpy_create_lazy_string_object): Flag bad length values.
16022 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
16023 Handle typedefs in incoming type.
16024 (stpy_lazy_string_elt_type): New function.
16025 (gdbpy_extract_lazy_string): Call it.
16026 * python/py-value.c (valpy_lazy_string): Flag bad length values.
16027 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
16028 typedefs in incoming type.
16030 2017-03-16 Doug Evans <dje@google.com>
16032 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
16033 * guile/scm-type.c (tyscm_scm_to_type): New function.
16035 2017-03-16 Jiong Wang <jiong.wang@arm.com>
16037 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
16038 "ULONGEST" for "skip".
16040 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
16043 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
16044 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
16045 (inf_ptrace_peek_poke): ...here. New function. Now also loop
16046 over ptrace peek/poke until end of buffer or error.
16048 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
16050 * parse.c (length_of_subexp): Make static.
16051 * parser-defs.h (length_of_subexp): Remove.
16053 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
16055 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
16058 2017-03-14 Pedro Alves <palves@redhat.com>
16060 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
16061 (main): Use std::unique_ptr. Remove calls to
16062 cp_demangled_name_parse_free.
16064 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16066 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
16067 alphabsd_store_inferior_registers): Use regcache->ptid instead
16070 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16072 * aix-thread.c (aix_thread_fetch_registers,
16073 aix_thread_store_registers): Use regcache->ptid instead of
16076 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16078 * aarch64-linux-nat.c (fetch_gregs_from_thread,
16079 store_gregs_to_thread, fetch_fpregs_from_thread,
16080 store_fpregs_to_thread): Use regcache->ptid instead of
16083 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16085 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
16086 amd64_linux_fetch_inferior_registers): Use regcache->ptid
16087 instead of inferior_ptid.
16089 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16091 * target.c (target_fetch_registers, target_store_registers): Add
16094 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16096 * regcache.h (regcache_get_ptid): New function.
16097 * regcache.c (regcache_get_ptid): New function.
16099 2017-03-13 Mark Wielaard <mark@klomp.org>
16101 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
16103 2017-03-10 Keith Seitz <keiths@redhat.com>
16106 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
16108 2017-03-08 Pedro Alves <palves@redhat.com>
16111 * infrun.c (start_step_over, do_target_resume, resume)
16112 (restart_threads): Assert we're not resuming a thread that is
16113 meant to be stopped.
16114 (infrun_thread_stop_requested_callback): Delete.
16115 (infrun_thread_stop_requested): If the thread is internally
16116 stopped, queue a pending stop event and clear the thread's
16117 inline-frame state.
16118 (handle_stop_requested): New function.
16119 (handle_syscall_event, handle_inferior_event_1): Use
16120 handle_stop_requested.
16121 (handle_stop_requested): New function.
16122 (handle_signal_stop): Set the thread's stop_signal here instead of
16124 (finish_step_over): Clear step over info unconditionally.
16125 (handle_signal_stop): If the user had interrupted the event
16126 thread, consider the stop a random signal.
16127 (handle_signal_stop) <signal arrived while stepping over
16128 breakpoint>: Don't restart threads here.
16129 (stop_waiting): Don't clear step-over info here.
16131 2017-03-08 Pedro Alves <palves@redhat.com>
16134 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
16135 goes to argument 2, not 1.
16137 2017-03-08 Pedro Alves <palves@redhat.com>
16140 * top.c (gdb_readline_wrapper): Avoid passing NULL to
16141 display_gdb_prompt.
16142 (command_line_input): Add comment.
16144 2017-03-08 Pedro Alves <palves@redhat.com>
16147 * tui/tui-file.c (tui_file::write): New.
16148 * tui/tui-file.h (tui_file): Override "write".
16149 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
16150 factored out from ...
16151 (tui_puts): ... here.
16152 (tui_putc): Use them.
16153 (tui_write): New function.
16154 * tui/tui-io.h (tui_write): Declare.
16156 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
16158 * Makefile.in (SFILES): Replace "environ.c" with
16159 "common/environ.c".
16160 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
16161 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
16163 * common/environ.c: ... here.
16164 * environ.h: Moved to...
16165 * common/environ.h: ... here.
16167 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16169 * gdbarch.sh (pstring_ptr): New static function.
16170 (gdbarch_disassembler_options): Use it.
16171 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
16172 not valid_disassembler_option->name.
16173 * gdbarch.c: Regenerate.
16175 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16177 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
16179 2017-03-07 Pedro Alves <palves@redhat.com>
16181 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
16183 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
16185 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
16186 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
16187 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
16188 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
16190 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
16192 * xtensa-linux-nat.c (fetch_gregs): Remove const.
16194 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
16196 * remote.c (remote_add_target_side_commands): Use range-based
16199 2017-03-03 Yao Qi <yao.qi@linaro.org>
16202 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
16204 * valprint.c (common_val_print): Likewise.
16206 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
16208 * NEWS: Mention new set/show disassembler-options commands.
16209 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
16210 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
16211 (prospective_options): New static variable.
16212 (gdb_disassembler::gdb_disassembler): Initialize
16213 m_di.disassembler_options.
16214 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
16215 (get_disassembler_options): New function.
16216 (set_disassembler_options): Likewise.
16217 (set_disassembler_options_sfunc): Likewise.
16218 (show_disassembler_options_sfunc): Likewise.
16219 (disassembler_options_completer): Likewise.
16220 (_initialize_disasm): Likewise.
16221 * disasm.h (get_disassembler_options): New prototype.
16222 (set_disassembler_options): Likewise.
16223 * gdbarch.sh (gdbarch_disassembler_options): New variable.
16224 (gdbarch_verify_disassembler_options): Likewise.
16225 * gdbarch.c: Regenerate.
16226 * gdbarch.h: Likewise.
16227 * arm-tdep.c (num_disassembly_options): Delete.
16228 (set_disassembly_style): Likewise.
16229 (arm_disassembler_options): New static variable.
16230 (set_disassembly_style_sfunc): Convert short style name into long
16231 option name. Call set_disassembler_options.
16232 (show_disassembly_style_sfunc): New function.
16233 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
16234 set_gdbarch_verify_disassembler_options.
16235 (_initialize_arm_tdep): Delete regnames variable and update callers.
16236 (arm_disassembler_options): Initialize.
16237 (disasm_options): New variable.
16238 (num_disassembly_options): Rename from this...
16239 (num_disassembly_styles): ...to this. Compute by scanning through
16241 (valid_disassembly_styles): Initialize using disasm_options.
16242 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
16243 set_arm_regname_option.
16244 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
16245 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
16246 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
16247 set_gdbarch_verify_disassembler_options.
16248 * s390-tdep.c (s390_disassembler_options): New static variable.
16249 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
16250 set_gdbarch_verify_disassembler_options.
16252 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16254 * remote.c (remote_add_target_side_condition): Remove "struct"
16255 keyword from range-based for loop.
16257 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16259 * remote.c (remote_add_target_side_condition): Use range-based
16260 for loop. Update comment.
16262 2017-02-27 Yao Qi <yao.qi@linaro.org>
16264 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
16266 2017-02-26 Alan Hayward <alan.hayward@arm.com>
16268 * regcache.c (regcache_raw_update): New function.
16269 (regcache_raw_read): Move code to regcache_raw_update.
16270 * regcache.h (regcache_raw_update): New declaration.
16271 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
16273 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
16275 * dwarf2read.c (create_debug_type_hash_table): Initialize
16276 header.signature and header.type_offset_in_tu.
16278 2017-02-24 Pedro Alves <palves@redhat.com>
16280 * symtab.c (make_file_symbol_completion_list_1): Use
16281 add_symtab_completions.
16283 2017-02-24 Alan Hayward <alan.hayward@arm.com>
16285 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
16287 2017-02-24 Alan Hayward <alan.hayward@arm.com>
16289 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
16290 I386_MAX_REGISTER_SIZE.
16291 (i386_pseudo_register_write): Likewise.
16292 (i386_process_record): Likewise.
16293 * i387-tdep.c (i387_supply_xsave): Likewise.
16294 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
16295 (store_register): Likewise.
16297 2017-02-23 Pedro Alves <palves@redhat.com>
16299 * ada-lang.c: Include "common/function-view.h".
16300 (ada_iterate_over_symbols): Adjust to use function_view as
16302 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
16303 (ada_make_symbol_completion_list): Use a lambda.
16304 (ada_exc_search_name_matches): Delete.
16305 (name_matches_regex): New.
16306 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
16307 * compile/compile-c-support.c: Include "common/function-view.h".
16308 (print_one_macro): Change prototype to accept a ui_file pointer.
16309 (write_macro_definitions): Use a lambda.
16310 * dwarf2read.c: Include "common/function-view.h".
16311 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
16312 (dw2_expand_symtabs_matching): Adjust to use function_view as
16314 * language.h: Include "common/function-view.h".
16315 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
16316 function_view as callback type.
16317 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
16318 * linespec.c: Include "common/function-view.h".
16319 (collect_info::add_symbol): New method.
16320 (struct symbol_and_data_callback, iterate_inline_only, struct
16321 symbol_matcher_data, iterate_name_matcher): Delete.
16322 (iterate_over_all_matching_symtabs): Adjust to use function_view
16323 as callback type and lambdas.
16324 (iterate_over_file_blocks): Adjust to use function_view as
16326 (decode_compound_collector): Now a class with private fields.
16327 (decode_compound_collector::release_symbols): New method.
16328 (collect_one_symbol): Rename to...
16329 (decode_compound_collector::operator()): ... this and adjust.
16330 (lookup_prefix_sym): decode_compound_collector construction bits
16331 move to decode_compound_collector ctor. Pass the
16332 decode_compound_collector object directly as callback. Remove
16333 cleanups and use decode_compound_collector::release_symbols
16335 (symtab_collector): Now a class with private fields.
16336 (symtab_collector::release_symtabs): New method.
16337 (add_symtabs_to_list): Rename to...
16338 (symtab_collector::operator()): ... this and adjust.
16339 (collect_symtabs_from_filename): symtab_collector construction
16340 bits move to symtab_collector ctor. Pass the symtab_collector
16341 object directly as callback. Remove cleanups and use
16342 symtab_collector::release_symtabs instead.
16343 (collect_symbols): Delete.
16344 (add_matching_symbols_to_info): Use lambdas.
16345 * macrocmd.c (print_macro_callback): Delete.
16346 (info_macro_command): Use a lambda.
16347 (info_macros_command): Pass print_macro_definition as callable
16349 (print_one_macro): Remove 'ignore' parameter.
16350 (macro_list_command): Adjust.
16351 * macrotab.c (macro_for_each_data::fn): Now a function_view.
16352 (macro_for_each_data::user_data): Delete field.
16353 (foreach_macro): Adjust to call the function_view.
16354 (macro_for_each): Adjust to use function_view as callback type.
16355 (foreach_macro_in_scope): Adjust to call the function_view.
16356 (macro_for_each_in_scope): Adjust to use function_view as callback
16358 * macrotab.h: Include "common/function-view.h".
16359 (macro_callback_fn): Declare a prototype instead of a pointer.
16360 Remove "user_data" parameter.
16361 (macro_for_each, macro_for_each_in_scope): Adjust to use
16362 function_view as callback type.
16363 * psymtab.c (partial_map_expand_apply)
16364 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
16365 Adjust to use function_view as callback type and to return bool.
16366 (psym_expand_symtabs_matching): Adjust to use function_view as
16368 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
16369 to use function_view as callback type and to return bool.
16370 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
16372 * symfile.c (expand_symtabs_matching): Adjust to use function_view
16374 * symfile.h: Include "common/function-view.h".
16375 (expand_symtabs_file_matcher_ftype)
16376 (expand_symtabs_symbol_matcher_ftype)
16377 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
16379 (quick_symbol_functions::map_symtabs_matching_filename)
16380 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
16381 function_view as callback type and return bool.
16382 (expand_symtabs_matching): Adjust to use function_view as callback
16384 (maintenance_expand_name_matcher)
16385 (maintenance_expand_file_matcher): Delete.
16386 (maintenance_expand_symtabs): Use lambdas.
16387 * symtab.c (iterate_over_some_symtabs): Adjust to use
16388 function_view as callback types and return bool.
16389 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
16391 (lookup_symtab_callback): Delete.
16392 (lookup_symtab): Use a lambda.
16393 (iterate_over_symbols): Adjust to use function_view as callback
16395 (struct search_symbols_data, search_symbols_file_matches)
16396 (search_symbols_name_matches): Delete.
16397 (search_symbols): Use a pair of lambdas.
16398 (struct add_name_data, add_macro_name, symbol_completion_matcher)
16399 (symtab_expansion_callback): Delete.
16400 (default_make_symbol_completion_list_break_on_1): Use lambdas.
16401 * symtab.h: Include "common/function-view.h".
16402 (iterate_over_some_symtabs): Adjust to use function_view as
16403 callback type and return bool.
16404 (iterate_over_symtabs): Adjust to use function_view as callback
16406 (symbol_found_callback_ftype): Remove 'data' parameter and return
16408 (iterate_over_symbols): Adjust to use function_view as callback
16411 2017-02-23 Pedro Alves <palves@redhat.com>
16413 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
16414 (%.o) <unittests/%.c>: New pattern.
16415 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
16416 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
16417 * common/function-view.h: New file.
16418 * unittests/function-view-selftests.c: New file.
16419 * configure: Regenerate.
16421 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
16423 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
16425 * go32-nat.c (go32_thread_alive): Likewise.
16427 2017-02-23 Yao Qi <yao.qi@linaro.org>
16429 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
16432 2017-02-23 Yao Qi <yao.qi@linaro.org>
16434 * varobj.c (varobj_clear_saved_item): Use delete instead of
16436 (update_dynamic_varobj_children): Likewise.
16438 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16440 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
16442 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
16444 * common/enum-flags.h (enum_flags::enum_flags): Initialize
16445 m_enum_value to 0 in default constructor.
16447 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
16449 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
16450 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
16451 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
16452 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
16453 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
16454 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
16455 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
16456 IS_STORE_CONDITIONAL_INSN.
16458 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16460 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
16462 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16464 * NEWS (Changes since GDB 7.12): Add DWARF-5.
16466 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16468 * dwarf2read.c (skip_one_die, read_attribute_value)
16469 (dwarf2_const_value_attr, dump_die_shallow)
16470 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
16471 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
16473 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16475 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
16476 (dwarf_parse_macro_header): Accept DWARF version 5.
16477 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
16479 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16481 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
16483 * common/common-exceptions.h (enum errors): Likewise.
16484 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
16485 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
16486 (dwarf_expr_context::execute_stack_op): Likewise.
16487 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
16489 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
16490 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
16491 (show_entry_values_debug, call_site_to_target_addr)
16492 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
16493 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
16494 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
16495 (value_of_dwarf_block_entry, indirect_pieced_value)
16496 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
16497 (disassemble_dwarf_expression): Likewise.
16498 * dwarf2read.c (process_die, inherit_abstract_dies)
16499 (read_call_site_scope): Likewise.
16500 * gdbtypes.h (struct func_type, struct call_site_parameter)
16501 (struct call_site): Likewise.
16502 * stack.c (read_frame_arg): Likewise.
16503 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
16505 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16507 * defs.h (read_unsigned_leb128): New declaration.
16508 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
16509 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
16510 (dwarf2_find_location_expression): Call also
16511 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
16512 * dwarf2loc.h (dwarf2_version): New declaration.
16513 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
16515 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
16517 (struct dwop_section_names): Add loclists_dwo.
16518 (dwop_section_names): Add .debug_loclists.dwo.
16519 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
16520 (struct dwarf2_per_cu_data): Add dwarf_version.
16521 (struct dwo_sections): Add loclists.
16522 (struct attr_abbrev): Add implicit_const.
16523 (read_indirect_line_string): New declaration.
16524 (read_unsigned_leb128): Delete declaration.
16525 (rcuh_kind): New definition.
16526 (read_and_check_comp_unit_head): Change parameter
16527 is_debug_types_section to section_kind.
16528 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
16529 (read_comp_unit_head): Change parameter abfd to section, add parameter
16530 section_kind. Handle DWARF-5.
16531 (error_check_comp_unit_head): Accept also DWARF version 5.
16532 (read_and_check_comp_unit_head): Change parameter
16533 is_debug_types_section to section_kind.
16534 (read_and_check_type_unit_head): Delete function.
16535 (read_abbrev_offset): Handle DWARF-5.
16536 (create_debug_type_hash_table): Add parameter section_kind. Process
16537 only DW_UT_type. Use signature and type_offset_in_tu from struct
16539 (create_debug_types_hash_table): Update create_debug_type_hash_table
16541 (create_all_type_units): Call create_debug_type_hash_table.
16542 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
16543 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
16545 (skip_one_die): Handle DW_FORM_implicit_const.
16546 (dwarf2_rnglists_process): New function.
16547 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
16548 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
16549 (read_attribute_value): Handle DW_FORM_implicit_const,
16551 (read_attribute): Handle DW_FORM_implicit_const.
16552 (read_indirect_string_at_offset_from): New function from
16553 read_indirect_string_at_offset.
16554 (read_indirect_string_at_offset): Call
16555 read_indirect_string_at_offset_from.
16556 (read_indirect_line_string_at_offset): New function.
16557 (read_indirect_string): New function comment.
16558 (read_indirect_line_string): New function.
16559 (read_unsigned_leb128): Make it global.
16560 (dwarf2_string_attr): Handle DWARF-5.
16561 (add_include_dir_stub, read_formatted_entries): New functions.
16562 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
16564 (per_cu_header_read_in): Update read_comp_unit_head caller.
16565 (dwarf2_version): New function.
16566 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
16568 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16571 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16573 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16575 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16577 * dwarf2read.c (dwarf2_ranges_process): New function from
16578 dwarf2_ranges_read.
16579 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16580 dwarf2_ranges_process.
16582 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16584 * dwarf2read.c (create_debug_type_hash_table): New function from
16585 create_debug_types_hash_table.
16586 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16587 (create_all_type_units, open_and_init_dwo_file): Update
16588 create_debug_types_hash_table callers.
16590 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16593 * fork-child.c (trace_start_error): Fix thinko. va_end should
16594 refer to 'ap', not 'args'.
16596 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16597 Pedro Alves <palves@redhat.com>
16600 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16602 * fork-child.c (trace_start_error): New function.
16603 (trace_start_error_with_name): Likewise.
16604 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16605 * inf-ptrace.c (inf_ptrace_me): Likewise.
16606 * inferior.h (trace_start_error): New prototype.
16607 (trace_start_error_with_name): Likewise.
16609 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16612 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16613 NULL before using it.
16614 * symmisc.c (maintenance_print_symbols): Likewise.
16615 (maintenance_print_msymbols): Likewise.
16617 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16619 * NEWS: Add record Python bindings entry.
16621 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16623 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16625 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16626 * python/py-record-btrace.c, python/py-record-btrace.h,
16627 python/py-record-full.c, python/py-record-full.h: New file.
16628 * python/py-record.c: Add include for py-record-btrace.h and
16630 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16631 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16632 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16633 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16635 (gdbpy_initialize_btrace): New export.
16636 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16638 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16640 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16641 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16642 * python/py-record.c: New file.
16643 * python/python-internal.h (gdbpy_start_recording,
16644 gdbpy_current_recording, gdpy_stop_recording,
16645 gdbpy_initialize_record): New export.
16646 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16647 (python_GdbMethods): Add gdbpy_start_recording,
16648 gdbpy_current_recording and gdbpy_stop_recording.
16650 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16652 * record-btrace.c (record_btrace_record_method): New function.
16653 (init_record_btrace_ops): Initialize to_record_method.
16654 * record-full.c (record_full_record_method): New function.
16655 (init_record_full_ops, init_record_full_core_ops): Add
16656 record_full_record_method.
16657 * record.h (enum record_method): New enum.
16658 * target-debug.h (target_debug_print_enum_record_method: New define.
16659 * target-delegates.c: Regenerate.
16660 * target.c (target_record_method): New function.
16661 * target.h: Include record.h.
16662 (struct target_ops) <to_record_method>: New field.
16663 (target_record_method): New export.
16665 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16667 * record.h (record_start, record_stop): New export.
16668 * record.c (record_start, record_stop): New function.
16670 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16672 * btrace.c (btrace_fetch): Copy function call segments pointer
16674 (btrace_clear): Clear the vector.
16675 (btrace_find_insn_by_number): Use binary search to find the correct
16676 function call segment.
16677 * btrace.h (brace_fun_p): New typedef.
16678 (struct btrace_thread_info) <functions>: New field.
16680 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16682 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16683 * btrace.c (btrace_decode_error): ... here. New function.
16684 * btrace.h (btrace_decode_error): New export.
16686 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16688 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16689 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16690 btrace_find_insn_by_number): Remove special case for gaps.
16691 * btrace.h (btrace_insn_get_error): New export.
16692 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16693 * record-btrace.c (btrace_insn_history): Print number for gaps.
16694 (record_btrace_info, record_btrace_goto): Handle gaps.
16696 2017-02-14 Tom Tromey <tom@tromey.com>
16699 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16701 * python/py-evts.c (gdbpy_initialize_py_events): Add
16702 before_prompt registry.
16703 * python/py-events.h (events_object) <before_prompt>: New field.
16705 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16707 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16709 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
16711 * symfile (_initialize_symfile): Add usage text to the load command's
16714 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16716 * utils.c (defaulted_query): Don't query on secondary UIs.
16718 2017-02-10 Tom Tromey <tom@tromey.com>
16720 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16722 2017-02-10 Tom Tromey <tom@tromey.com>
16724 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16726 * python/py-type.c (typy_legacy_template_argument): Remove
16727 unnecessary "cleanup" local.
16729 2017-02-10 Tom Tromey <tom@tromey.com>
16731 * python/python.c (do_start_initialization): New function, from
16732 _initialize_python.
16733 (_initialize_python): Call do_start_initialization.
16734 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16737 2017-02-10 Tom Tromey <tom@tromey.com>
16739 * python/py-prettyprint.c (pretty_print_one_value): Use
16742 2017-02-10 Tom Tromey <tom@tromey.com>
16744 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16745 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16747 * python/py-type.c (field_new): Use gdbpy_ref.
16748 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16750 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16751 (py_free_pspace): Likewise.
16752 (pspace_to_pspace_object): Likewise.
16753 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16754 (py_free_objfile): Likewise.
16755 (objfile_to_objfile_object): Likewise.
16756 * python/py-inferior.c (delete_thread_object): Use
16758 (infpy_read_memory): Likewise.
16759 (py_free_inferior): Likewise.
16760 * python/py-evtregistry.c (create_eventregistry_object): Use
16762 * python/py-event.c (create_event_object): Use gdbpy_ref.
16764 2017-02-10 Tom Tromey <tom@tromey.com>
16766 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16767 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16769 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16770 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16771 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16772 python/py-framefilter.c, python/py-function.c,
16773 python/py-inferior.c, python/py-infevents.c,
16774 python/py-linetable.c, python/py-newobjfileevent.c,
16775 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16776 python/py-signalevent.c, python/py-stopevent.c,
16777 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16778 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16779 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16780 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16782 2017-02-10 Tom Tromey <tom@tromey.com>
16784 * ui-out.h (ui_out_emit_type): New class.
16785 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16786 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16787 and ui_out_emit_tuple.
16788 (enumerate_locals): Likewise.
16789 (py_mi_print_variables, py_print_locals, py_print_args): Use
16791 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16793 * common/gdb_optional.h: New file.
16795 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
16797 * MAINTAINERS (Write After Approval): Update my e-mail address.
16799 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
16802 * breakpoint.c (_initialize_breakpoint): Update the help description
16803 of the 'commands' command to indicate that it takes a list argument.
16805 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16807 * interps.c (current_interp_set_logging): Remove "return".
16809 2017-02-09 Gary Benson <gbenson@redhat.com>
16811 * symtab.c (add_symtab_completions): Prevent NULL pointer
16814 2017-02-08 Pedro Alves <palves@redhat.com>
16816 * interps.c (interp::interp): Remove reference to quiet_p.
16817 (interp_set): Make static. Remove dead "Switching to" output
16819 (interp_quiet_p, interp_set_quiet): Delete.
16820 (interpreter_exec_cmd): Don't set the interpreter quiet.
16821 * interps.h (interp_quiet_p): Make static.
16822 (class interp) <quiet_p>: Remove field
16824 2017-02-08 Jerome Guitton <guitton@adacore.com>
16826 * cli/cli-decode.c (find_command_name_length): Make it extern.
16827 * cli/cli-decode.h (find_command_name_length): Declare.
16828 * cli/cli-script.c (command_name_equals, line_first_arg):
16830 (process_next_line): Use cli-decode to parse command names.
16831 (build_command_line): Make args a constant pointer.
16833 2017-02-08 Jerome Guitton <guitton@adacore.com>
16835 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16836 Remove case-insensitive search.
16838 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16840 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16841 at the end of the line. Avoids an ARI warning.
16843 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
16845 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16846 rdseed instructions.
16847 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16849 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16852 Provide and use sparc32 and sparc64 target description XML files.
16853 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16854 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16855 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16856 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16857 * features/sparc/sparc32-solaris.xml: New file.
16858 * features/sparc/sparc64-solaris.xml: New file.
16859 * features/sparc/sparc32-solaris.c: Generated.
16860 * features/sparc/sparc64-solaris.c: Generated.
16861 * sparc-tdep.h: Account for differences in target descriptions.
16862 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16863 (sparc32_register_type): Use target provided registers.
16864 (validate_tdesc_registers): New function.
16865 (sparc32_gdbarch_init): Use tdesc_has_registers.
16866 Set pseudoregister functions.
16867 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16868 (sparc64_register_type): Use target provided registers.
16869 (sparc64_init_abi): Set pseudoregister functions.
16871 2017-02-03 Tom Tromey <tom@tromey.com>
16874 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16875 with a single member.
16877 2017-02-03 Pedro Alves <palves@redhat.com>
16879 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16880 (cli_interp_base::~cli_interp_base): New.
16881 (cli_interp): New struct.
16882 (as_cli_interp): Cast the interp itself to cli_interp.
16883 (cli_interpreter_pre_command_loop): Rename to ...
16884 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16886 (cli_interpreter_init): Rename to ...
16887 (cli_interp::init): ... this. Remove 'self' parameter. Use
16888 boolean. Make extern.
16889 (cli_interpreter_resume): Rename to ...
16890 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16892 (cli_interpreter_suspend): Rename to ...
16893 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16895 (cli_interpreter_exec): Rename to ...
16896 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16898 (cli_interpreter_supports_command_editing): Rename to ...
16899 (cli_interp_base::supports_command_editing): ... this. Remove
16900 'interp' parameter. Make extern.
16901 (cli_ui_out): Rename to ...
16902 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16904 (cli_set_logging): Rename to ...
16905 (cli_interp_base::set_logging): ... this. Remove 'interp'
16906 parameter. Make extern.
16907 (cli_interp_procs): Delete.
16908 (cli_interp_factory): Adjust to use "new".
16909 * cli/cli-interp.h: Include "interps.h".
16910 (struct cli_interp_base): New struct.
16911 * interps.c (struct interp): Delete. Fields moved to interps.h.
16912 (interp_new): Delete.
16913 (interp::interp, interp::~interp): New.
16914 (interp_set): Use bool, and return void. Assume the interpreter
16915 has suspend, init and resume methods, and that the all return
16917 (set_top_level_interpreter): interp_set returns void.
16918 (interp_ui_out): Adapt.
16919 (current_interp_set_logging): Adapt.
16920 (interp_data): Delete.
16921 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
16922 (interp_exec): Adapt.
16923 (top_level_interpreter_data): Delete.
16924 * interps.h (interp_init_ftype, interp_resume_ftype)
16925 (interp_suspend_ftype, interp_exec_ftype)
16926 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
16927 (class interp): New.
16928 (interp_new): Delete.
16929 (interp_set): Now returns void. Use bool.
16930 (interp_data, top_level_interpreter_data): Delete.
16931 * mi/mi-common.h: Include interps.h.
16932 (class mi_interp): Inherit from interp. Define a ctor. Declare
16933 init, resume, suspect, exec, interp_ui_out, set_logging and
16934 pre_command_loop methods.
16935 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
16936 (mi_interpreter_init): Rename to ...
16937 (mi_interp::init): ... this. Remove the 'interp' parameter, use
16938 bool, return void and make extern. Adjust.
16939 (mi_interpreter_resume): ... Rename to ...
16940 (mi_interp::resume): ... this. Remove the 'data' parameter,
16941 return void and make extern. Adjust.
16942 (mi_interpreter_suspend): ... Rename to ...
16943 (mi_interp::suspend): ... this. Remove the 'data' parameter,
16944 return void and make extern. Adjust.
16945 (mi_interpreter_exec): ... Rename to ...
16946 (mi_interp::exec): ... this. Remove the 'data' parameter and make
16948 (mi_interpreter_pre_command_loop): ... Rename to ...
16949 (mi_interp::pre_command_loop): ... this. Remove the 'self'
16950 parameter and make extern.
16951 (mi_on_normal_stop_1): Adjust.
16952 (mi_ui_out): Rename to ...
16953 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
16954 parameter and make extern. Adjust.
16955 (mi_set_logging): Rename to ...
16956 (mi_interp::set_logging): ... this. Remove the 'interp'
16957 parameter and make extern. Adjust.
16958 (mi_interp_procs): Delete.
16959 (mi_interp_factory): Adjust to use 'new'.
16960 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
16961 (mi_print_exception, mi_execute_command, mi_load_progress):
16963 * tui/tui-interp.c (tui_interp): New class.
16964 (as_tui_interp): Return a tui_interp pointer.
16965 (tui_on_normal_stop, tui_on_signal_received)
16966 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
16967 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
16968 to use interp::interp_ui_out.
16969 (tui_init): Rename to ...
16970 (tui_interp::init): ... this. Remove the 'self' parameter, use
16971 bool, return void and make extern. Adjust.
16972 (tui_resume): Rename to ...
16973 (tui_interp::resume): ... this. Remove the 'data' parameter,
16974 return void and make extern. Adjust.
16975 (tui_suspend): Rename to ...
16976 (tui_interp::suspend): ... this. Remove the 'data' parameter,
16977 return void and make extern. Adjust.
16978 (tui_ui_out): Rename to ...
16979 (tui_interp::interp_ui_out): ... this. Remove the 'self'
16980 parameter, and make extern. Adjust.
16981 (tui_exec): Rename to ...
16982 (tui_interp::exec): ... this. Remove the 'data' parameter and
16984 (tui_interp_procs): Delete.
16985 (tui_interp_factory): Use "new".
16987 2017-02-02 Tom Tromey <tom@tromey.com>
16989 * rust-exp.y (ends_raw_string, space_then_number)
16990 (rust_identifier_start_p): Return bool.
16991 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
16992 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
16993 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
16994 (rust_chartype_p): Return bool.
16995 (val_print_struct, rust_print_struct_def, rust_print_type):
16997 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
17000 2017-02-02 Tom Tromey <tom@tromey.com>
17002 * rust-lang.c: Reindent.
17004 2017-02-02 Tom Tromey <tom@tromey.com>
17006 * rust-lang.h (rust_crate_for_block): Update.
17007 * rust-lang.c (rust_crate_for_block): Return std::string.
17008 (rust_get_disr_info): Use std:;string, not
17009 gdb::unique_xmalloc_ptr.
17010 * rust-exp.y (crate_name): Update.
17012 2017-02-02 Pedro Alves <palves@redhat.com>
17014 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
17015 field out of gdb_disassembler_test and make it static.
17017 2017-02-02 Pedro Alves <palves@redhat.com>
17019 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
17020 mi1_interp and mi_interp fields.
17022 2017-02-02 Pedro Alves <palves@redhat.com>
17024 * cli/cli-interp.c (struct saved_output_files, saved_output):
17025 Moved from cli/cli-logging.c.
17026 (cli_set_logging): New function.
17027 (cli_interp_procs): Install cli_set_logging.
17028 * cli/cli-interp.h (make_logging_output, cli_set_logging):
17030 * cli/cli-logging.c (struct saved_output_files, saved_output):
17031 Moved to cli/cli-interp.c.
17032 (pop_output_files): Don't save outputs here.
17033 (make_logging_output): New function.
17034 (handle_redirections): Don't build tee nor save previous outputs
17036 * interps.c (current_interp_set_logging): Change prototype.
17037 Assume there's always a set_logging_proc method installed.
17038 * interps.h (interp_set_logging_ftype): Change prototype.
17039 (current_interp_set_logging): Change prototype and adjust comment.
17040 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
17041 use make_logging_output.
17042 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
17043 2017-02-02 Pedro Alves <palves@redhat.com>
17045 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
17047 (set_logging_overwrite): ... here.
17048 (logging_no_redirect_file): Delete.
17049 (set_logging_redirect): Don't handle redirection on the fly.
17050 Instead warn that "logging off" / "logging on" is necessary.
17051 (pop_output_files): Delete references to logging_no_redirect_file.
17052 (show_logging_command): Always speak in terms of what will happen
17053 once logging is reenabled.
17055 2017-02-02 Pedro Alves <palves@redhat.com>
17057 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
17059 2017-02-02 Pedro Alves <palves@redhat.com>
17061 * disasm.c (gdb_pretty_print_insn): Rename to ...
17062 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
17063 Remove gdbarch parameter. Adapt to clear the object's buffers
17064 instead of allocating new buffers, and to print using the object's
17065 gdb_disassembler instead of calling gdb_print_insn.
17066 (dump_insns): Use gdb_pretty_print_disassembler.
17067 * disasm.h (gdb_pretty_print_insn): Delete declaration.
17068 (gdb_pretty_print_disassembler): New class.
17069 * record-btrace.c (btrace_insn_history): Use
17070 gdb_pretty_print_disassembler.
17072 2017-02-02 Pedro Alves <palves@redhat.com>
17074 * ada-lang.c (type_as_string): Use string_file.
17075 * ada-valprint.c (ada_print_floating): Use string_file.
17076 * ada-varobj.c (ada_varobj_scalar_image)
17077 (ada_varobj_get_value_image): Use string_file.
17078 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
17079 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
17080 * breakpoint.c (update_inserted_breakpoint_locations)
17081 (insert_breakpoint_locations, reattach_breakpoints)
17082 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
17083 (print_it_watchpoint): Use string_file.
17084 (save_breakpoints): Use stdio_file.
17085 * c-exp.y (oper): Use string_file.
17086 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
17088 (pop_output_files): Use delete.
17089 (handle_redirections): Use stdio_file and tee_file.
17090 * cli/cli-setshow.c (do_show_command): Use string_file.
17091 * compile/compile-c-support.c (c_compute_program): Use
17093 * compile/compile-c-symbols.c (generate_vla_size): Take a
17094 'string_file &' instead of a 'ui_file *'.
17095 (generate_c_for_for_one_variable): Take a 'string_file &' instead
17096 of a 'ui_file *'. Use string_file.
17097 (generate_c_for_variable_locations): Take a 'string_file &'
17098 instead of a 'ui_file *'.
17099 * compile/compile-internal.h (generate_c_for_for_one_variable):
17100 Take a 'string_file &' instead of a 'ui_file *'.
17101 * compile/compile-loc2c.c (push, pushf, unary, binary)
17102 (print_label, pushf_register_address, pushf_register)
17103 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
17104 'ui_file *'. Adjust.
17105 * compile/compile.c (compile_to_object): Use string_file.
17106 * compile/compile.h (compile_dwarf_expr_to_c)
17107 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
17109 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
17110 (replace_typedefs_qualified_name): Use string_file and
17112 * disasm.c (gdb_pretty_print_insn): Use string_file.
17113 (gdb_disassembly): Adjust reference the null_stream global.
17114 (do_ui_file_delete): Delete.
17115 (gdb_insn_length): Use null_stream.
17116 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
17117 * dwarf2loc.c (dwarf2_compile_property_to_c)
17118 (locexpr_generate_c_location, loclist_generate_c_location): Take a
17119 'string_file &' instead of a 'ui_file *'.
17120 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
17121 * dwarf2read.c (do_ui_file_peek_last): Delete.
17122 (dwarf2_compute_name): Use string_file.
17123 * event-top.c (gdb_setup_readline): Use stdio_file.
17124 * gdbarch.sh (verify_gdbarch): Use string_file.
17125 * gdbtypes.c (safe_parse_type): Use null_stream.
17126 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
17128 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
17129 'string_file *' instead of a 'ui_file *'.
17130 (gdbscm_arch_disassemble): Use string_file.
17131 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
17132 * guile/scm-ports.c (class ioscm_file_port): Now a class that
17133 inherits from ui_file.
17134 (ioscm_file_port_delete, ioscm_file_port_rewind)
17135 (ioscm_file_port_put): Delete.
17136 (ioscm_file_port_write): Rename to ...
17137 (ioscm_file_port::write): ... this. Remove file_port_magic
17139 (ioscm_file_port_new): Delete.
17140 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
17142 * guile/scm-type.c (tyscm_type_name): Use string_file.
17143 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
17145 * infcmd.c (print_return_value_1): Use string_file.
17146 * infrun.c (print_target_wait_results): Use string_file.
17147 * language.c (add_language): Use string_file.
17148 * location.c (explicit_to_string_internal): Use string_file.
17149 * main.c (captured_main_1): Use null_file.
17150 * maint.c (maintenance_print_architecture): Use stdio_file.
17151 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
17152 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
17153 event_channel>: Change type to mi_console_file pointer.
17154 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
17155 (mi_console_file_delete): Delete.
17156 (struct mi_console_file): Delete.
17157 (mi_console_file_magic): Delete.
17158 (mi_console_file_new): Delete.
17159 (mi_console_file::mi_console_file): New.
17160 (mi_console_file_delete): Delete.
17161 (mi_console_file_fputs): Delete.
17162 (mi_console_file::write): New.
17163 (mi_console_raw_packet): Delete.
17164 (mi_console_file::flush): New.
17165 (mi_console_file_flush): Delete.
17166 (mi_console_set_raw): Rename to ...
17167 (mi_console_file::set_raw): ... this.
17168 * mi/mi-console.h (class mi_console_file): New class.
17169 (mi_console_file_new, mi_console_set_raw): Delete.
17170 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
17171 (mi_set_logging): Use delete and tee_file. Adjust.
17172 * mi/mi-main.c (output_register): Use string_file.
17173 (mi_cmd_data_evaluate_expression): Use string_file.
17174 (mi_cmd_data_read_memory): Use string_file.
17175 (mi_cmd_execute, print_variable_or_computed): Use string_file.
17176 * mi/mi-out.c (mi_ui_out::main_stream): New.
17177 (mi_ui_out::rewind): Use main_stream and
17179 (mi_ui_out::put): Use main_stream and string_file.
17180 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17181 Allocate a 'string_file' instead.
17182 (mi_out_new): Don't allocate a mem_fileopen stream here.
17183 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17184 (mi_ui_out::main_stream): Declare method.
17185 * printcmd.c (eval_command): Use string_file.
17186 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
17187 * python/py-arch.c (archpy_disassemble): Use string_file.
17188 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
17189 * python/py-frame.c (frapy_str): Use string_file.
17190 * python/py-framefilter.c (py_print_type, py_print_single_arg):
17192 * python/py-type.c (typy_str): Use string_file.
17193 * python/py-unwind.c (unwind_infopy_str): Use string_file.
17194 * python/py-value.c (valpy_str): Use string_file.
17195 * record-btrace.c (btrace_insn_history): Use string_file.
17196 * regcache.c (regcache_print): Use stdio_file.
17197 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
17198 * remote.c (escape_buffer): Use string_file.
17199 * rust-lang.c (rust_get_disr_info): Use string_file.
17200 * serial.c (serial_open_ops_1): Use stdio_file.
17201 (do_serial_close): Use delete.
17202 * stack.c (print_frame_arg): Use string_file.
17203 (print_frame_args): Remove local mem_fileopen stream, not used.
17204 (print_frame): Use string_file.
17205 * symmisc.c (maintenance_print_symbols): Use stdio_file.
17206 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
17207 Take a 'string_file *' instead of a 'ui_file *'.
17208 * top.c (new_ui): Use stdio_file and stderr_file.
17209 (free_ui): Use delete.
17210 (execute_command_to_string): Use string_file.
17211 (quit_confirm): Use string_file.
17212 * tracepoint.c (collection_list::append_exp): Use string_file.
17213 * tui/tui-disasm.c (tui_disassemble): Use string_file.
17214 * tui/tui-file.c: Don't include "ui-file.h".
17215 (enum streamtype, struct tui_stream): Delete.
17216 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
17217 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
17218 (tui_file::tui_file): New method.
17219 (tui_file_fputs): Delete.
17220 (tui_file_get_strbuf): Delete.
17221 (tui_file::puts): New method.
17222 (tui_file_adjust_strbuf): Delete.
17223 (tui_file_flush): Delete.
17224 (tui_file::flush): New method.
17225 * tui/tui-file.h: Tweak intro comment.
17227 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
17228 (tui_file_adjust_strbuf): Delete declarations.
17229 (class tui_file): New class.
17230 * tui/tui-io.c (tui_initialize_io): Use tui_file.
17231 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
17232 (tui_register_format): Use string_stream.
17233 * tui/tui-stack.c (tui_make_status_line): Use string_file.
17234 (tui_get_function_from_frame): Use string_file.
17235 * typeprint.c (type_to_string): Use string_file.
17236 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
17237 (null_stream): New global.
17238 (ui_file_delete): Delete.
17239 (ui_file::ui_file): New.
17240 (null_file_isatty): Delete.
17241 (ui_file::~ui_file): New.
17242 (null_file_rewind): Delete.
17243 (ui_file::printf): New.
17244 (null_file_put): Delete.
17245 (null_file_flush): Delete.
17246 (ui_file::putstr): New.
17247 (null_file_write): Delete.
17248 (ui_file::putstrn): New.
17249 (null_file_read): Delete.
17250 (ui_file::putc): New.
17251 (null_file_fputs): Delete.
17252 (null_file_write_async_safe): Delete.
17253 (ui_file::vprintf): New.
17254 (null_file_delete): Delete.
17255 (null_file::write): New.
17256 (null_file_fseek): Delete.
17257 (null_file::puts): New.
17258 (ui_file_data): Delete.
17259 (null_file::write_async_safe): New.
17260 (gdb_flush, ui_file_isatty): Adjust.
17261 (ui_file_put, ui_file_rewind): Delete.
17262 (ui_file_write): Adjust.
17263 (ui_file_write_for_put): Delete.
17264 (ui_file_write_async_safe, ui_file_read): Adjust.
17265 (ui_file_fseek): Delete.
17266 (fputs_unfiltered): Adjust.
17267 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
17268 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
17269 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
17270 (set_ui_file_data): Delete.
17271 (string_file::~string_file, string_file::write)
17272 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
17273 (do_ui_file_as_string, ui_file_as_string): Delete.
17274 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
17275 (struct mem_file): Delete.
17276 (mem_file_new): Delete.
17277 (stdio_file::stdio_file): New.
17278 (mem_file_delete): Delete.
17279 (stdio_file::stdio_file): New.
17280 (mem_fileopen): Delete.
17281 (stdio_file::~stdio_file): New.
17282 (mem_file_rewind): Delete.
17283 (stdio_file::set_stream): New.
17284 (mem_file_put): Delete.
17285 (stdio_file::open): New.
17286 (mem_file_write): Delete.
17287 (stdio_file_magic, struct stdio_file): Delete.
17288 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
17289 (stdio_file::flush): New.
17290 (stdio_file_read): Rename to ...
17291 (stdio_file::read): ... this. Adjust.
17292 (stdio_file_write): Rename to ...
17293 (stdio_file::write): ... this. Adjust.
17294 (stdio_file_write_async_safe): Rename to ...
17295 (stdio_file::write_async_safe) ... this. Adjust.
17296 (stdio_file_fputs): Rename to ...
17297 (stdio_file::puts) ... this. Adjust.
17298 (stdio_file_isatty): Delete.
17299 (stdio_file_fseek): Delete.
17300 (stdio_file::isatty): New.
17301 (stderr_file_write): Rename to ...
17302 (stderr_file::write) ... this. Adjust.
17303 (stderr_file_fputs): Rename to ...
17304 (stderr_file::puts) ... this. Adjust.
17305 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
17306 (stderr_file::stderr_file): New.
17307 (tee_file_magic): Delete.
17308 (struct tee_file): Delete.
17309 (tee_file::tee_file): New.
17310 (tee_file_new): Delete.
17311 (tee_file::~tee_file): New.
17312 (tee_file_delete): Delete.
17313 (tee_file_flush): Rename to ...
17314 (tee_file::flush): ... this. Adjust.
17315 (tee_file_write): Rename to ...
17316 (tee_file::write): ... this. Adjust.
17317 (tee_file::write_async_safe): New.
17318 (tee_file_fputs): Rename to ...
17319 (tee_file::puts): ... this. Adjust.
17320 (tee_file_isatty): Rename to ...
17321 (tee_file::isatty): ... this. Adjust.
17322 * ui-file.h (struct obstack, struct ui_file): Don't
17324 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
17325 (ui_file_write_ftype)
17326 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
17327 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
17328 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
17329 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
17330 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
17331 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
17332 (set_ui_file_fseek): Delete.
17333 (ui_file_data, ui_file_delete, ui_file_rewind)
17334 (struct ui_file): New.
17336 (class null_file): New.
17337 (null_stream): Declare.
17338 (ui_file_write_for_put, ui_file_put): Delete.
17339 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
17341 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
17342 (gdb_fopen, tee_file_new): Delete.
17343 (struct string_file): New.
17344 (struct stdio_file): New.
17345 (stdio_file_up): New.
17346 (struct stderr_file): New.
17347 (class tee_file): New.
17348 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
17349 of a 'ui_file *'. Adjust.
17350 * ui-out.h (class ui_out) <field_stream>: Likewise.
17351 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
17352 (null_stream): Delete.
17353 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
17355 * utils.h (struct ui_file): Delete forward declaration..
17356 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
17357 (error_stream): Take a 'string_file &' instead of a
17359 * varobj.c (varobj_value_get_print_value): Use string_file.
17360 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
17361 * gdbarch.c: Regenerate.
17363 2017-02-02 Pedro Alves <palves@redhat.com>
17365 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
17366 (gdb_pretty_print_insn): ... this. Now a free function. Add back
17367 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
17368 Adjust to call gdb_print_insn instead of
17369 gdb_disassembler::print_insn.
17370 (dump_insns, do_mixed_source_and_assembly_deprecated)
17371 (do_mixed_source_and_assembly, do_assembly_only): Add back a
17372 'gdbarch' parameter. Remove gdb_disassembler parameter.
17373 (gdb_disassembly): Don't allocate a gdb_disassembler here.
17374 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
17376 (gdb_pretty_print_insn): Re-add declaration.
17377 * record-btrace.c (btrace_insn_history): Don't allocate a
17378 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
17380 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
17382 * disasm.h (gdb_disassembly): Remove file_string parameter.
17383 * disasm.c (gdb_disassembly): Likewise.
17384 * cli/cli-cmds.c (print_disassembly): Adapt.
17385 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
17386 * stack.c (do_gdb_disassembly): Likewise.
17388 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
17390 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
17391 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
17392 targets. And if the implicit value is longer than needed, extract
17393 the first bytes instead of the "least significant" ones.
17395 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17397 * btrace.c (btrace_enable): Do not call btrace_add_pc for
17398 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
17399 (btrace_fetch): Assert can_access_registers_ptid.
17400 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
17401 validate_registers_access.
17403 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17405 * gdbthread.h (can_access_registers_ptid): New.
17406 * thread.c (can_access_registers_ptid): New.
17408 2017-02-01 Pedro Alves <palves@redhat.com>
17410 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
17412 2017-01-31 Pedro Alves <palves@redhat.com>
17414 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
17417 2017-01-31 Pedro Alves <palves@redhat.com>
17419 * stack.c (print_frame_args): Remove local mem_fileopen stream,
17422 2017-01-31 Pedro Alves <palves@redhat.com>
17424 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
17426 2017-01-31 Pedro Alves <palves@redhat.com>
17428 * common/scoped_restore.h
17429 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
17430 change the value's parameter type to T2.
17431 (make_scoped_restore): Likewise.
17433 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17434 Richard Henderson <rth@redhat.com>
17436 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
17437 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
17438 GS_BASE for older kernels.
17439 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
17440 GS_BASE for older kernels.
17441 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
17442 and GS_BASE to the offset table.
17443 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
17444 system register group.
17445 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
17447 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
17449 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
17450 AMD64_GSBASE_REGNUM.
17451 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
17452 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
17453 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
17454 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
17455 i386/64bit-segments.xml in those rules.
17456 * features/i386/64bit-segments.xml: New file.
17457 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
17458 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
17459 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
17460 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
17461 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
17462 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
17463 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
17464 * features/i386/amd64-avx-linux.c: Regenerated.
17465 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
17466 * features/i386/amd64-avx-mpx.c: Regenerated.
17467 * features/i386/amd64-avx512-linux.c: Regenerated.
17468 * features/i386/amd64-linux.c: Regenerated.
17469 * features/i386/amd64-mpx-linux.c: Regenerated.
17470 * features/i386/i386-avx-mpx-linux.c: Regenerated.
17471 * features/i386/i386-avx-mpx.c: Regenerated.
17472 * features/i386/x32-avx-linux.c: Regenerated.
17473 * features/i386/x32-avx512-linux.c: Regenerated.
17474 * regformats/i386/amd64-avx-linux.dat: Regenerated.
17475 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
17476 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
17477 * regformats/i386/amd64-linux.dat: Regenerated.
17478 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
17479 * regformats/i386/x32-avx-linux.dat: Regenerated.
17480 * regformats/i386/x32-avx512-linux.dat: Regenerated.
17481 * regformats/i386/x32-linux.dat: Regenerated.
17483 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17485 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
17486 Set to AMD64_NUM_REGS.
17488 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17490 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
17491 that checks validity of a register number.
17493 2017-01-27 Kees Cook <keescook@google.com>
17495 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
17496 fetch_fpregs if target has fpa registers.
17497 (arm_linux_store_inferior_registers): Call store_fpregs if target
17500 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
17502 * cris-tdep.c (cris_gdbarch_init): Remove check for
17503 info.byte_order and force it to BFD_ENDIAN_LITTLE.
17505 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
17507 * corelow.c (get_core_register_section): Check for regset
17508 existence before checking for REGSET_VARIABLE_SIZE.
17510 2017-01-26 Yao Qi <yao.qi@linaro.org>
17511 Pedro Alves <palves@redhat.com>
17514 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
17515 call memory_error, save memaddr instead.
17516 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
17517 negative, cal memory_error.
17518 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
17520 2017-01-26 Yao Qi <yao.qi@linaro.org>
17522 * disasm-selftests.c (memory_error_test): New function.
17523 (_initialize_disasm_selftests): Register memory_error_test.
17525 2017-01-26 Yao Qi <yao.qi@linaro.org>
17527 * Makefile.in (SFILES): Add disasm-selftests.c and
17529 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
17530 * disasm-selftests.c: New file.
17531 * selftest-arch.c: New file.
17532 * selftest-arch.h: New file.
17534 2017-01-26 Yao Qi <yao.qi@linaro.org>
17536 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
17537 to bfd_arch_mep. Don't return 0 if section is not
17538 found. Call print_insn_mep.
17540 2017-01-26 Pedro Alves <palves@redhat.com>
17541 Yao Qi <yao.qi@linaro.org>
17543 * arm-tdep.c: Include "disasm.h".
17544 (gdb_print_insn_arm): Update code to get gdbarch.
17545 * disasm.c (dis_asm_read_memory): Change it to
17546 gdb_disassembler::dis_asm_read_memory.
17547 (dis_asm_memory_error): Likewise.
17548 (dis_asm_print_address): Likewise.
17549 (gdb_pretty_print_insn): Change it to
17550 gdb_disassembler::pretty_print_insn.
17551 (dump_insns): Add one argument gdb_disassemlber. All
17553 (do_mixed_source_and_assembly_deprecated): Likewise.
17554 (do_mixed_source_and_assembly): Likewise.
17555 (do_assembly_only): Likewise.
17556 (gdb_disassembler::gdb_disassembler): New.
17557 (gdb_disassembler::print_insn): New.
17558 * disasm.h (class gdb_disassembler): New.
17559 (gdb_pretty_print_insn): Remove declaration.
17560 (gdb_disassemble_info): Likewise.
17561 * guile/scm-disasm.c (class gdbscm_disassembler): New.
17562 (gdbscm_disasm_read_memory_worker): Update.
17563 (gdbscm_disasm_read_memory): Update.
17564 (gdbscm_disasm_memory_error): Remove.
17565 (gdbscm_disasm_print_address): Remove.
17566 (gdbscm_disassembler::gdbscm_disassembler): New.
17567 (gdbscm_print_insn_from_port): Update.
17568 * mips-tdep.c: Include disasm.h.
17569 (gdb_print_insn_mips): Update code to get gdbarch.
17570 * record-btrace.c (btrace_insn_history): Update.
17571 * spu-tdep.c: Include disasm.h.
17572 (struct spu_dis_asm_data): Remove.
17573 (struct spu_dis_asm_info): New.
17574 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17576 (gdb_print_insn_spu): Cast disassemble_info to
17579 2017-01-26 Yao Qi <yao.qi@linaro.org>
17581 * disasm.c (do_ui_file_delete): Delete.
17582 (gdb_insn_length): Move code creating stream to ...
17583 * utils.c (null_stream): ... here. New function.
17584 * utils.h (null_stream): Declare.
17586 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17588 * python/py-inferior.c (find_thread_object): Return directly
17589 from the loop. Remove "found" variable.
17591 2017-01-21 Joel Brobecker <brobecker@adacore.com>
17593 GDB 7.12.1 released.
17595 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17597 * python/py-function.c (fnpy_call): Reorder declarations to have
17598 the gdbpy_enter object declared first.
17599 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17601 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17604 * python/python-internal.h (PyMem_RawMalloc): Define for
17606 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17607 PyMem_RawMalloc instead of PyMem_Malloc.
17609 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17610 Luis Machado <lgustavo@codesourcery.com>
17612 * NEWS (New commands): Mention flash-erase.
17613 (New MI commands): Mention target-flash-erase.
17614 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17616 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17617 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17618 * target.c (flash_erase_command): New function.
17619 (initialize_targets): Add new flash-erase command.
17620 * target.h (flash_erase_command): New declaration.
17622 2017-01-20 Joel Brobecker <brobecker@adacore.com>
17624 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17625 HAVE_SYS_PROCFS_H is defined.
17627 2017-01-18 Alan Hayward <alan.hayward@arm.com>
17629 * remote.c (struct cached_reg): Change data into a pointer.
17630 * (stop_reply_dtr): Free data pointers before deleting vector.
17631 (process_stop_reply): Likewise.
17632 (remote_parse_stop_reply): Allocate space for data
17634 2017-01-18 Alan Hayward <alan.hayward@arm.com>
17636 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17638 (amd64_pseudo_register_read_value): Likewise.
17639 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17640 (store_register_using_P): Likewise.
17641 * regcache.c (regcache_xfer_part): Likewise.
17643 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17645 Split real and pseudo registers.
17646 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17647 (sparc32_pseudo_regnum): New enum.
17648 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17649 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17650 (SPARC32_CP0_REGISTERS): New macro.
17651 (sparc32_pseudo_register_name): New function.
17652 (sparc32_register_name): Use sparc32_pseudo_register_name.
17653 (sparc32_pseudo_register_type): New function.
17654 (sparc32_register_type): Use sparc32_pseudo_register_type.
17655 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17656 pseudo register numbers.
17657 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17658 (SPARC64_CP0_REGISTERS): New macro.
17659 (sparc64_pseudo_register_name): New function.
17660 (sparc64_register_name): Use sparc64_pseudo_register_name.
17661 (sparc64_pseudo_register_type): New function.
17662 (sparc64_register_type): Use sparc64_pseudo_register_type.
17663 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17664 pseudo register numbers.
17665 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17666 sparc64_store_arguments): Handle pseudo register numbers.
17668 2017-01-13 Yao Qi <yao.qi@linaro.org>
17670 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17671 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17673 (getpkt_or_notif_sane_1): Likewise.
17675 2017-01-13 Yao Qi <yao.qi@linaro.org>
17677 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17678 of CC. Pass "-x c++-header" instead of "-x c".
17680 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17682 * remote.c (remote_can_async_p): Update comment.
17684 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17686 * linux-nat.c (linux_nat_can_async_p): Update comment.
17688 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17690 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17692 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17694 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17696 2017-01-10 Tom Tromey <tom@tromey.com>
17698 * python/py-type.c (typy_legacy_template_argument): Update.
17699 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17700 ~demangle_parse_info): Declare new members.
17701 (cp_demangled_name_to_comp): Return unique_ptr.
17702 (cp_demangled_name_parse_free)
17703 (make_cleanup_cp_demangled_name_parse_free)
17704 (cp_new_demangle_parse_info): Remove.
17705 * cp-support.c (do_demangled_name_parse_free_cleanup)
17706 (make_cleanup_cp_demangled_name_parse_free): Remove.
17707 (inspect_type, cp_canonicalize_string_full)
17708 (cp_canonicalize_string): Update.
17709 (mangled_name_to_comp): Change return type.
17710 (cp_class_name_from_physname, method_name_from_physname)
17711 (cp_func_name, cp_remove_params): Update.
17712 * cp-name-parser.y (demangle_parse_info): New constructor, from
17713 cp_new_demangle_parse_info.
17714 (~demangle_parse_info): New destructor, from
17715 cp_demangled_name_parse_free.
17716 (cp_merge_demangle_parse_infos): Update.
17717 (cp_demangled_name_to_comp): Change return type.
17719 2017-01-10 Tom Tromey <tom@tromey.com>
17721 * top.c (prevent_dont_repeat): Change return type.
17722 * python/python.c (execute_gdb_command): Use std::string.
17724 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17725 * command.h (prevent_dont_repeat): Change return type.
17726 * breakpoint.c (bpstat_do_actions_1): Update.
17728 2017-01-10 Tom Tromey <tom@tromey.com>
17730 * value.h (scoped_value_mark::~scoped_value_mark): Call
17732 (scoped_value_mark::free_to_mark): New method.
17733 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17736 2017-01-10 Tom Tromey <tom@tromey.com>
17738 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17739 (valpy_reference_value, valpy_const_value, valpy_get_address)
17740 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17741 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17742 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17743 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17745 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17746 * value.h (scoped_value_mark): New class.
17748 2017-01-10 Tom Tromey <tom@tromey.com>
17750 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17751 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17752 * psymtab.c (discard_psymtabs_upto): Remove.
17753 (make_cleanup_discard_psymtabs): Remove.
17754 (struct psymtab_state): Remove.
17756 2017-01-10 Tom Tromey <tom@tromey.com>
17758 * record-full.c (record_full_save_cleanups): Remove.
17759 (record_full_save): Use gdb::unlinker.
17760 * gcore.c (do_bfd_delete_cleanup): Remove.
17761 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17763 * dwarf2read.c (unlink_if_set): Remove.
17764 (write_psymtabs_to_index): Use gdb::unlinker.
17765 * common/gdb_unlinker.h: New file.
17767 2017-01-10 Tom Tromey <tom@tromey.com>
17769 * windows-tdep.c (windows_xfer_shared_library): Update.
17770 * windows-nat.c (windows_make_so): Update.
17771 * utils.h (make_cleanup_bfd_unref): Remove.
17772 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17773 * symfile.h (symfile_bfd_open)
17774 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17775 * symfile.c (read_symbols, symbol_file_add)
17776 (separate_debug_file_exists): Update.
17777 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17778 (generic_load, reread_symbols): Update.
17779 * symfile-mem.c (symbol_file_add_from_memory): Update.
17780 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17781 (spu_symbol_file_add_from_memory): Update.
17782 * solist.h (struct target_so_ops) <bfd_open>: Return
17784 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17785 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17787 (solib_map_sections, reload_shared_libraries_1): Update.
17788 * solib-svr4.c (enable_break): Update.
17789 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17790 * solib-frv.c (enable_break2): Update.
17791 * solib-dsbt.c (enable_break): Update.
17792 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17794 (darwin_solib_get_all_image_info_addr_at_init): Update.
17795 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17796 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17797 * record-full.c (record_full_save): Update.
17798 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17799 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17800 * minidebug.c (find_separate_debug_file_in_section): Return
17802 * machoread.c (macho_add_oso_symfile): Change abfd to
17804 (macho_symfile_read_all_oso): Update.
17805 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17806 (macho_symfile_read): Update.
17807 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17808 (jit_bfd_try_read_symtab): Update.
17809 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17810 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17811 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17813 (gdb_bfd_ref_policy): New struct.
17814 (gdb_bfd_ref_ptr): New typedef.
17815 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17816 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17817 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17819 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17820 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17821 (gcore_command): Update.
17822 * exec.c (exec_file_attach): Update.
17823 * elfread.c (elf_symfile_read): Update.
17824 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17825 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17826 (open_and_init_dwo_file): Update.
17827 (open_dwp_file): Return gdb_bfd_ref_ptr.
17828 (open_and_init_dwp_file): Update.
17829 * corelow.c (core_open): Update.
17830 * compile/compile-object-load.c (compile_object_load): Update.
17831 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17832 * coffread.c (coff_symfile_read): Update.
17833 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17834 gdb_bfd_ref_ptr. Rename.
17835 (dump_bfd_file, restore_command): Update.
17836 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17837 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17838 (find_separate_debug_file_by_buildid): Update.
17840 2017-01-10 Tom Tromey <tom@tromey.com>
17842 * common/gdb_ref_ptr.h: New file.
17843 * python/py-ref.h (struct gdbpy_ref_policy): New.
17844 (gdbpy_ref): Now a typedef.
17846 2017-01-10 Tom Tromey <tom@tromey.com>
17848 * utils.h (make_cleanup_htab_delete): Don't declare.
17849 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17851 * linespec.c (decode_compound_collector): Add constructor,
17853 (lookup_prefix_sym): Remove cleanup.
17854 (symtab_collector): Add constructor, destructor.
17855 (collect_symtabs_from_filename): Remove cleanup.
17856 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17857 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17859 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17860 * dwarf2read.c (dw2_expand_symtabs_matching)
17861 (dw2_map_symbol_filenames, dwarf_decode_macros)
17862 (write_psymtabs_to_index): Use htab_up.
17863 * dwarf2loc.c (func_verify_no_selftailcall)
17864 (call_site_find_chain_1, func_verify_no_selftailcall)
17865 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17866 std::vector, gdb::unique_xmalloc_ptr.
17867 (call_sitep): Remove typedef.
17868 (dwarf2_locexpr_baton_eval): Remove unused variable.
17870 2017-01-10 Tom Tromey <tom@tromey.com>
17872 * python/python-internal.h (make_cleanup_py_decref)
17873 (make_cleanup_py_xdecref): Don't declare.
17874 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17875 (py_xdecref, make_cleanup_py_xdecref): Remove.
17877 2017-01-10 Tom Tromey <tom@tromey.com>
17879 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17880 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17882 2017-01-10 Tom Tromey <tom@tromey.com>
17884 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17886 2017-01-10 Tom Tromey <tom@tromey.com>
17888 * python/py-utils.c (unicode_to_encoded_string)
17889 (python_string_to_target_string)
17890 (python_string_to_target_python_string)
17891 (python_string_to_host_string, gdbpy_obj_to_string)
17892 (get_addr_from_python): Use gdbpy_ref.
17894 2017-01-10 Tom Tromey <tom@tromey.com>
17896 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17899 2017-01-10 Tom Tromey <tom@tromey.com>
17901 * python/python.c (eval_python_command, gdbpy_decode_line)
17902 (gdbpy_run_events, gdbpy_start_type_printers)
17903 (gdbpy_apply_type_printers): Use gdbpy_ref.
17905 2017-01-10 Tom Tromey <tom@tromey.com>
17907 * python/py-param.c (get_doc_string, compute_enum_values): Use
17910 2017-01-10 Tom Tromey <tom@tromey.com>
17912 * python/py-inferior.c (find_thread_object, build_inferior_list):
17915 2017-01-10 Tom Tromey <tom@tromey.com>
17917 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17919 2017-01-10 Tom Tromey <tom@tromey.com>
17921 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
17924 2017-01-10 Tom Tromey <tom@tromey.com>
17926 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
17928 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
17931 2017-01-10 Tom Tromey <tom@tromey.com>
17933 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17936 2017-01-10 Tom Tromey <tom@tromey.com>
17938 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
17939 decref results of PyArg_ParseTupleAndKeywords.
17941 2017-01-10 Tom Tromey <tom@tromey.com>
17943 * python/python.c (python_run_simple_file): Use
17944 unique_xmalloc_ptr, gdbpy_ref.
17946 2017-01-10 Tom Tromey <tom@tromey.com>
17948 * python/py-prettyprint.c (print_stack_unless_memory_error)
17949 (print_string_repr, print_children): Use gdbpy_ref.
17950 (dummy_python_frame): New class.
17951 (dummy_python_frame::dummy_python_frame): Rename from
17952 push_dummy_python_frame.
17953 (py_restore_tstate): Remove.
17955 2017-01-10 Tom Tromey <tom@tromey.com>
17957 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17959 2017-01-10 Tom Tromey <tom@tromey.com>
17961 * python/python.c (ensure_python_env, restore_python_env):
17963 * python/python-internal.h (ensure_python_env): Don't declare.
17964 * varobj.h (varobj_ensure_python_env): Don't declare.
17965 * varobj.c (varobj_ensure_python_env): Remove.
17967 2017-01-10 Tom Tromey <tom@tromey.com>
17969 * varobj.c (varobj_value_get_print_value): Use
17970 gdbpy_enter_varobj.
17972 2017-01-10 Tom Tromey <tom@tromey.com>
17974 * python/py-prettyprint.c (print_string_repr, print_children):
17976 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
17978 * varobj.c (varobj_value_get_print_value): Update.
17979 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
17981 2017-01-10 Tom Tromey <tom@tromey.com>
17983 * varobj.c (varobj_get_display_hint)
17984 (dynamic_varobj_has_child_method, install_new_value_visualizer)
17985 (varobj_set_visualizer, free_variable): Use
17986 gdbpy_enter_varobj.
17988 2017-01-10 Tom Tromey <tom@tromey.com>
17990 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
17991 (do_finish_initialization): New function. Use gdbpy_ref.
17992 (gdbpy_finish_initialization): Use gdbpy_enter. Call
17993 do_finish_initialization.
17995 2017-01-10 Tom Tromey <tom@tromey.com>
17997 * python/py-param.c (get_set_value, get_show_value): Use
17998 gdbpy_enter, gdbpy_ref.
18000 2017-01-10 Tom Tromey <tom@tromey.com>
18002 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
18004 2017-01-10 Tom Tromey <tom@tromey.com>
18006 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
18008 2017-01-10 Tom Tromey <tom@tromey.com>
18010 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
18011 Use gdbpy_enter_varobj.
18013 2017-01-10 Tom Tromey <tom@tromey.com>
18015 * varobj.c (gdbpy_enter_varobj): New constructor.
18016 * python/python-internal.h (gdbpy_enter_varobj): New class.
18017 * python/py-varobj.c (py_varobj_get_iterator): Use
18018 gdbpy_enter_varobj.
18020 2017-01-10 Tom Tromey <tom@tromey.com>
18022 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
18023 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
18024 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
18025 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
18026 unique_xmalloc_ptr.
18027 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
18029 2017-01-10 Tom Tromey <tom@tromey.com>
18031 * python/py-xmethods.c (invoke_match_method): Use
18034 2017-01-10 Tom Tromey <tom@tromey.com>
18036 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
18037 gdbpy_enter, gdbpy_ref.
18039 2017-01-10 Tom Tromey <tom@tromey.com>
18041 * python/python.c (python_interactive_command): Use gdbpy_enter.
18043 2017-01-10 Tom Tromey <tom@tromey.com>
18045 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
18048 2017-01-10 Tom Tromey <tom@tromey.com>
18050 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
18051 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
18053 2017-01-10 Tom Tromey <tom@tromey.com>
18055 * utils.h (htab_deleter): New struct.
18056 (htab_up): New typedef.
18057 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
18058 gdbpy_enter, gdbpy_ref, htab_up.
18060 2017-01-10 Tom Tromey <tom@tromey.com>
18062 * python/py-unwind.c (pending_frame_invalidate): Remove.
18063 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
18065 2017-01-10 Tom Tromey <tom@tromey.com>
18067 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
18068 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
18070 2017-01-10 Tom Tromey <tom@tromey.com>
18072 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
18074 2017-01-10 Tom Tromey <tom@tromey.com>
18076 * python/python.c (gdbpy_eval_from_control_command)
18077 (gdbpy_source_script, gdbpy_run_events)
18078 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
18079 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
18082 2017-01-10 Tom Tromey <tom@tromey.com>
18084 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
18086 2017-01-10 Tom Tromey <tom@tromey.com>
18088 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
18090 2017-01-10 Tom Tromey <tom@tromey.com>
18092 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
18093 (python_on_inferior_call_pre, python_on_inferior_call_post)
18094 (python_on_memory_change, python_on_register_change)
18095 (python_inferior_exit, python_new_objfile, add_thread_object)
18096 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
18098 2017-01-10 Tom Tromey <tom@tromey.com>
18100 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
18101 (bpfinishpy_handle_exit): Use gdbpy_enter.
18103 2017-01-10 Tom Tromey <tom@tromey.com>
18105 * python/py-cmd.c (cmdpy_destroyer)
18106 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
18109 2017-01-10 Tom Tromey <tom@tromey.com>
18111 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
18113 (gdbpy_breakpoint_has_cond): Likewise.
18115 2017-01-10 Tom Tromey <tom@tromey.com>
18117 * python/python.c (gdbpy_enter): New constructor.
18118 (~gdbpy_enter): New destructor.
18119 (restore_python_env, ensure_python_env): Rewrite.
18120 * python/python-internal.h (gdbpy_enter): New class.
18122 2017-01-10 Tom Tromey <tom@tromey.com>
18124 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
18126 2017-01-10 Tom Tromey <tom@tromey.com>
18128 * python/py-value.c (value_has_field, get_field_flag)
18129 (get_field_type, valpy_getitem, convert_value_from_python): Use
18132 2017-01-10 Tom Tromey <tom@tromey.com>
18134 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
18137 2017-01-10 Tom Tromey <tom@tromey.com>
18139 * python/py-prettyprint.c (search_pp_list)
18140 (find_pretty_printer_from_objfiles)
18141 (find_pretty_printer_from_progspace)
18142 (find_pretty_printer_from_gdb, find_pretty_printer)
18143 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
18146 2017-01-10 Tom Tromey <tom@tromey.com>
18148 * python/py-param.c (call_doc_function): Use gdbpy_ref.
18150 2017-01-10 Tom Tromey <tom@tromey.com>
18152 * python/py-linetable.c (build_line_table_tuple_from_pcs)
18153 (ltpy_get_all_source_lines): Use gdbpy_ref.
18155 2017-01-10 Tom Tromey <tom@tromey.com>
18157 * python/py-framefilter.c (extract_sym, extract_value)
18158 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
18161 2017-01-10 Tom Tromey <tom@tromey.com>
18163 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
18165 2017-01-10 Tom Tromey <tom@tromey.com>
18167 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
18169 2017-01-10 Tom Tromey <tom@tromey.com>
18171 * python/py-function.c (convert_values_to_python, fnpy_init): Use
18174 2017-01-10 Tom Tromey <tom@tromey.com>
18176 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
18178 2017-01-10 Tom Tromey <tom@tromey.com>
18180 * python/py-type.c (convert_field, make_fielditem, typy_fields)
18181 (typy_range): Use gdbpy_ref.
18183 2017-01-10 Tom Tromey <tom@tromey.com>
18185 * python/py-threadevent.c (create_thread_event_object): Use
18187 * python/py-stopevent.c (create_stop_event_object): Simplify.
18188 (emit_stop_event): Use gdbpy_ref.
18189 * python/py-signalevent.c (create_signal_event_object): Use
18191 * python/py-newobjfileevent.c (create_new_objfile_event_object)
18192 (emit_new_objfile_event, create_clear_objfiles_event_object)
18193 (emit_clear_objfiles_event): Use gdbpy_ref.
18194 * python/py-infevents.c (create_inferior_call_event_object)
18195 (create_register_changed_event_object)
18196 (create_memory_changed_event_object, emit_inferior_call_event)
18197 (emit_memory_changed_event, emit_register_changed_event): Use
18199 * python/py-exitedevent.c (create_exited_event_object)
18200 (emit_exited_event): Use gdbpy_ref.
18201 * python/py-event.h (evpy_emit_event): Remove
18202 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
18203 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
18204 * python/py-continueevent.c (emit_continue_event): Use
18206 * python/py-breakpoint.c (gdbpy_breakpoint_created)
18207 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
18209 * python/py-bpevent.c (create_breakpoint_event_object): Use
18212 2017-01-10 Tom Tromey <tom@tromey.com>
18214 * python/py-ref.h: New file.
18216 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18218 * cli-out.c (cli_ui_out::do_redirect): Change return type to
18220 * cli-out.h (cli_ui_out::do_redirect): Likewise.
18221 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
18222 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
18223 * ui-out.c (ui_out::redirect): Likewise.
18224 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
18225 * cli/cli-logging.c (set_logging_redirect): Update call site of
18227 (handle_redirections): Likewise.
18228 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
18229 * top.c (execute_command_to_string): Likewise.
18230 * utils.c (do_ui_out_redirect_pop): Likewise.
18232 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18234 * stack.c (_initialize_stack): Update "frame" command help message.
18236 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
18238 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
18240 2017-01-06 Yao Qi <yao.qi@linaro.org>
18242 * x86-linux-nat.h: Include gdb_proc_service.h.
18244 2017-01-06 Yao Qi <yao.qi@linaro.org>
18246 * ser-base.h: Include serial.h.
18248 2017-01-06 Yao Qi <yao.qi@linaro.org>
18250 * ppc-linux-tdep.h: Include ppc-tdep.h.
18252 2017-01-06 Yao Qi <yao.qi@linaro.org>
18254 * nat/amd64-linux-siginfo.h: Include signal.h.
18256 2017-01-06 Yao Qi <yao.qi@linaro.org>
18258 * nat/aarch64-linux-hw-point.h: Include break-common.h.
18260 2017-01-06 Yao Qi <yao.qi@linaro.org>
18262 * mi/mi-parse.h: Include mi-cmds.h.
18264 2017-01-06 Yao Qi <yao.qi@linaro.org>
18266 * inf-loop.c: Don't include "target.h".
18267 * inf-loop.h: Include it here.
18269 2017-01-06 Yao Qi <yao.qi@linaro.org>
18271 * dfp.h: Include "dboulest.h" and "expression.h".
18273 2017-01-06 Yao Qi <yao.qi@linaro.org>
18275 * ax-gdb.h: Include "ax.h".
18277 2017-01-06 Yao Qi <yao.qi@linaro.org>
18279 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
18280 with nat/gdb_ptrace.h.
18282 2017-01-05 Yao Qi <yao.qi@linaro.org>
18284 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
18286 (mips64_fbsd_sigframe_init): Likewise.
18288 2017-01-04 John Baldwin <jhb@FreeBSD.org>
18290 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
18291 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
18293 2017-01-04 John Baldwin <jhb@FreeBSD.org>
18295 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
18296 * NEWS: Mention new FreeBSD/mips native configuration.
18297 * config/mips/fbsd.mh: New file.
18298 * configure.host: Add mips*-*-freebsd*.
18299 * mips-fbsd-nat.c: New file.
18301 2017-01-04 John Baldwin <jhb@FreeBSD.org>
18303 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
18304 (ALLDEPFILES): Add mips-fbsd-tdep.c.
18305 * NEWS: Mention new FreeBSD/mips target.
18306 * configure.tgt: Add mips*-*-freebsd*.
18307 * mips-fbsd-tdep.c: New file.
18308 * mips-fbsd-tdep.h: New file.
18310 2017-01-04 Yao Qi <yao.qi@linaro.org>
18312 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
18313 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
18315 2017-01-01 Joel Brobecker <brobecker@adacore.com>
18317 Update copyright year range in all GDB files.
18319 2017-01-01 Joel Brobecker <brobecker@adacore.com>
18321 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
18323 For older changes see ChangeLog-2016.
18329 version-control: never