Ada: unable to compare strings (Attempt to compare array with non-array)
[binutils-gdb.git] / gdb / ChangeLog
1 2017-12-14 Joel Brobecker <brobecker@adacore.com>
2
3 * ada-lang.c (ada_value_equal): Add handling of typedef types
4 when comparing array objects.
5
6 2017-12-14 Joel Brobecker <brobecker@adacore.com>
7
8 * ada-tasks.c (read_atcb): Properly set task_info->ptid
9 when !target_has_execution as well.
10 (task_command): Remove error when !target_has_execution.
11
12 2017-12-13 Simon Marchi <simon.marchi@ericsson.com>
13
14 * location.h (string_to_event_location): Add match_type
15 parameter.
16 * location.c (string_to_event_location): Likewise.
17 * python/py-breakpoint.c (bppy_init): Handle qualified
18 parameter.
19
20 2017-12-13 Pedro Alves <palves@redhat.com>
21
22 * completer.c (completion_tracker::maybe_add_completion): New
23 'text' and 'word' parameters. Use make_completion_match_str.
24 (completion_tracker::add_completion): New 'text' and 'word'
25 parameters. Pass down.
26 (completion_tracker::recompute_lowest_common_denominator): Change
27 parameter type to gdb::unique_xmalloc_ptr rval ref. Adjust.
28 * completer.h (completion_tracker::add_completion): New 'text' and
29 'word' parameters.
30 (completion_tracker::recompute_lowest_common_denominator): Change
31 parameter type to gdb::unique_xmalloc_ptr rval ref.
32 (completion_tracker::recompute_lowest_common_denominator): Change
33 parameter type to gdb::unique_xmalloc_ptr rval ref.
34 * symtab.c (completion_list_add_name): Pass down 'text' and 'word'
35 as well.
36
37 2017-12-13 Pedro Alves <palves@redhat.com>
38
39 * cli/cli-decode.c (complete_on_cmdlist, complete_on_enum): Use
40 make_completion_match_str.
41 * completer.c: Use gdb::unique_xmalloc_ptr and
42 make_completion_match_str.
43 (make_completion_match_str_1): New.
44 (make_completion_match_str(const char *, const char *,
45 const char *)): New.
46 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
47 const char *, const char *)): New.
48 * completer.h (make_completion_match_str(const char *,
49 const char *, const char *)): New.
50 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
51 const char *, const char *)): New.
52 * interps.c (interpreter_completer): Use make_completion_match_str.
53 * symtab.c (completion_list_add_name, add_filename_to_list): Use
54 make_completion_match_str.
55
56 2017-12-13 Stafford Horne <shorne@gmail.com>
57
58 * or1k-tdep.c (or1k_analyse_inst): Use _() wrapper for message
59 strings.
60 (or1k_unwind_pc): Use paddress() instead of %p.
61 (or1k_unwind_sp): Likewise.
62 (or1k_frame_cache): Use host_address_to_string()/paddress()
63 instead of %p and use _() wrapper for message strings.
64
65 2017-12-13 Simon Marchi <simon.marchi@ericsson.com>
66
67 * contrib/ari/gdb_ari.sh: Fix typo in help.
68
69 2017-12-13 Joel Brobecker <brobecker@adacore.com>
70
71 * event-top.c (handle_line_of_input): Set server_command.
72
73 2017-12-12 Stafford Horne <shorne@gmail.com>
74 Stefan Wallentowitz <stefan@wallentowitz.de>
75 Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
76 Franck Jullien <franck.jullien@gmail.com>
77 Jeremy Bennett <jeremy.bennett@embecosm.com>
78
79 * configure.tgt: Add targets for or1k and or1knd.
80 * or1k-tdep.c: New file.
81 * or1k-tdep.h: New file.
82 * features/Makefile: Add or1k.xml to build.
83 * features/or1k.xml: New file.
84 * features/or1k-core.xml: New file.
85 * features/or1k.c: Generated.
86
87 2017-12-12 Alan Modra <amodra@gmail.com>
88
89 PR tdep/22576
90 * ppc64-tdep.c (ppc64_plt_entry_point): Rewrite to take TOC-relative
91 PLT offset, and retrieve r2 from stack when executing in reverse.
92 (ppc64_standard_linkage1_target): Drop pc param. Calculate offset
93 rather than PLT address.
94 (ppc64_standard_linkage2_target): Likewise.
95 (ppc64_standard_linkage3_target): Likewise.
96 (ppc64_standard_linkage4_target): Likewise.
97 (ppc64_skip_trampoline_code_1): Adjust to suit.
98
99 2017-12-11 Simon Marchi <simon.marchi@ericsson.com>
100
101 PR gdb/22556
102 * remote.c (remote_thread_name): Return NULL if name is empty.
103 (remote_threads_extra_info): Return NULL if extra info is empty.
104
105 2017-12-11 Pedro Alves <palves@redhat.com>
106
107 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index)
108 (elf_sym_fns_debug_names): Move to elfread.c.
109 * dwarf2read.c (dwarf2_initialize_objfile): Return a boolean
110 instead of a sym_fns and add 'index_kind' output parameter. Fill
111 the latter in with the index variant kind if using an index.
112 (enum dw_index_kind): Moved to symfile.h.
113 * elfread.c (elf_sym_fns_gdb_index, elf_sym_fns_debug_names)
114 (elf_sym_fns_lazy_psyms): Move from defs.h.
115 (elf_symfile_read): Adjust to new dwarf2_initialize_objfile
116 interface.
117 * symfile.h (enum class dw_index_kind): New, moved from
118 dwarf2read.c.
119 (dwarf2_initialize_objfile): Change prototype.
120
121 2017-12-11 Ulrich Weigand <uweigand@de.ibm.com>
122
123 * target-float.c (mpfr_float_ops::from_target): Use mpfr_set_ui
124 instead of mpfr_set_si to convert mantissa bits.
125
126 2017-12-11 Xavier Roirand <roirand@adacore.com>
127 Joel Brobecker <brobecker@adacore.com>
128
129 * ada-lang.c (ada_tag_value_at_base_address): Change the way
130 tagged type base address is computed.
131 (enum ada_primitive_types) <ada_primitive_type_storage_offset>:
132 New enumerate.
133 (ada_language_arch_info): Set the ada_primitive_type_storage_offset
134 element of lai->primitive_type_vector.
135
136 2017-12-08 Pedro Alves <palves@redhat.com>
137
138 * dwarf2read.c (mock_mapped_index): Reimplement as an extension of
139 mapped_index_base.
140 (check_match): Adjust to use mock_index directly.
141 (check_find_bounds_finds)
142 (test_mapped_index_find_name_component_bounds): Adjust to work
143 with a mapped_index_base.
144
145 2017-12-08 Pedro Alves <palves@redhat.com>
146
147 * dwarf2read.c (struct mapped_index_base): New, partially factored
148 out from ...
149 (struct mapped_index): ... this. Inherit mapped_index_base.
150 (mapped_index::symbol_name_slot_invalid):
151 (mapped_index::symbol_name_at): Add override marker.
152 (mapped_index::symbol_name_count): New.
153 (struct mapped_debug_names): Inherit mapped_index_base.
154 (mapped_debug_names::symbol_name_at): New.
155 (mapped_debug_names::symbol_name_count): New.
156 (mapped_index::find_name_components_bounds): Rename to ...
157 (mapped_index_base::find_name_components_bounds): ... this.
158 (mapped_index::build_name_components): Rename to ...
159 (mapped_index_base::build_name_components): ... this. Adjust to
160 use mapped_index_base::symbol_name_count and
161 mapped_index_base::symbol_name_slot_invalid.
162 (dw2_expand_symtabs_matching_symbol): Take a mapped_index_base
163 instead of a mapped_index. Use
164 dw2_expand_symtabs_matching_symbol.
165
166 2017-12-08 Pedro Alves <palves@redhat.com>
167
168 * dwarf2read.c (mapped_index::symbol_table_slot): New.
169 (mapped_index::address_table): Now a gdb::array_view of const
170 gdb_byte.
171 (mapped_index::symbol_table): Now a gdb::array_view of
172 symbol_table_slot.
173 (mapped_index::address_table_size)
174 (mapped_index::symbol_table_slots): Delete.
175 (create_addrmap_from_index): Adjust.
176 (find_slot_in_mapped_hash): Adjust.
177 (read_index_from_section): Adjust.
178 (dwarf2_read_index): Adjust.
179
180 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
181 Pedro Alves <palves@redhat.com>
182
183 * defs.h (elf_sym_fns_debug_names): New declaration.
184 * dwarf2read.c: Include "hash_enum.h".
185 (mapped_debug_names): New.
186 (struct dwarf2_per_objfile): Add debug_names, debug_aranges and
187 debug_names_table.
188 (dwarf2_elf_names): Add ".debug_names" and ".debug_aranges".
189 (struct dwz_file): Add debug_names.
190 (dwarf2_per_objfile::locate_sections): Handle debug_names and
191 debug_aranges.
192 (locate_dwz_sections): Handle debug_names.
193 (create_signatured_type_table_from_debug_names)
194 (create_addrmap_from_aranges): New.
195 (dwarf2_read_index): Update function comment.
196 (dwarf5_augmentation): Moved up.
197 (read_debug_names_from_section, create_cus_from_debug_names_list)
198 (create_cus_from_debug_names, dwarf2_read_debug_names): New.
199 (dwarf5_djb_hash): Moved up.
200 (dw2_debug_names_iterator): New.
201 (read_indirect_string_at_offset): New declaration.
202 (mapped_debug_names::namei_to_name)
203 (dw2_debug_names_iterator::find_vec_in_debug_names)
204 (dw2_debug_names_iterator::next, dw2_debug_names_lookup_symbol)
205 (dw2_debug_names_dump, dw2_debug_names_expand_symtabs_for_function)
206 (dw2_debug_names_expand_symtabs_matching, dwarf2_debug_names_functions):
207 New.
208 (dwarf2_initialize_objfile): Return also elf_sym_fns_debug_names.
209 (debug_names::djb_hash): Rename it to dwarf5_djb_hash.
210 (debug_names::build): Update djb_hash caller.
211 (write_debug_names): Move out and rename augmentation to
212 dwarf5_augmentation.
213 * elfread.c (elf_sym_fns_debug_names): New.
214 * psymtab.h (dwarf2_debug_names_functions): New declaration.
215 * symfile.h (struct dwarf2_debug_sections): Add debug_names and
216 debug_aranges.
217 * xcoffread.c (dwarf2_xcoff_names): Add debug_names and debug_aranges.
218
219 2017-12-08 Pedro Alves <palves@redhat.com>
220
221 * common/hash_enum.h: New file.
222
223 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
224
225 * dwarf2read.c (create_cu_from_index_list): New from ...
226 (create_cus_from_index_list): ... this function, use it.
227 (dw_expand_symtabs_matching_file_matcher)
228 (dw2_expand_symtabs_matching_one): New from ...
229 (dw2_expand_symtabs_matching): ... this function, use them.
230
231 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
232
233 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move here
234 declarations from elfread.c.
235 (dwarf2_initialize_objfile): Change return value.
236 * elfread.c (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move these
237 declarations to defs.h.
238 (elf_symfile_read): Adjust dwarf2_initialize_objfile caller.
239 * symfile.h (dwarf2_initialize_objfile): Change return type.
240
241 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
242 Pedro Alves <palves@redhat.com>
243
244 * contrib/gdb-add-index.sh (index): Rename to ...
245 (index4): ... here.
246 (index5, debugstr, debugstrmerge, debugstrerr): New variables.
247 Support also .debug_names and .debug_str.
248 * dwarf2read.c: Include cmath, set, list.
249 (INDEX_SUFFIX): Rename to ...
250 (INDEX4_SUFFIX): ... here.
251 (INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
252 (file_write(FILE *, const void *, size_t)): New.
253 (file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
254 (data_buf::append_unsigned_leb128, data_buf::empty): New.
255 (data_buf::file_write): Use ::file_write.
256 (data_buf::c_str, dwarf5_djb_hash, debug_names)
257 (check_dwarf64_offsets): New.
258 (psyms_seen_size, write_gdbindex): New from
259 write_psymtabs_to_index code.
260 (dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
261 (enum dw_index_kind): New.
262 (write_psymtabs_to_index): New parameter index_kind. Support
263 filename_str and out_file_str. Move code to write_gdbindex,
264 possibly call write_debug_names.
265 (save_gdb_index_command): New parameter -dwarf-5.
266 (_initialize_dwarf2_read): Document the new parameter -dwarf-5.
267
268 2017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
269 Pedro Alves <palves@redhat.com>
270
271 * contrib/cc-with-tweaks.sh: Change interpreter to bash, incl. initial
272 comment.
273 (GDB_ADD_INDEX): New variable.
274 <$want_index>: Call $GDB_ADD_INDEX.
275
276 2017-12-08 Sergio Durigan Junior <sergiodj@redhat.com>
277
278 * dtrace-probe.c (dtrace_process_dof_probe): Do not declare a new
279 "expression_up" inside the TRY block.
280
281 2017-12-08 Yao Qi <yao.qi@linaro.org>
282
283 * breakpoint.c (update_watchpoint): Call
284 address_significant.
285
286 2017-12-08 Yao Qi <yao.qi@linaro.org>
287
288 * breakpoint.c (adjust_breakpoint_address): Call
289 address_significant.
290
291 2017-12-08 Yao Qi <yao.qi@linaro.org>
292
293 * aarch64-tdep.c (aarch64_gdbarch_init): Install gdbarch
294 significant_addr_bit.
295 * gdbarch.sh (significant_addr_bit): New.
296 * gdbarch.c, gdbarch.h: Re-generated.
297 * target.c (memory_xfer_partial): Call address_significant.
298 * utils.c (address_significant): New function.
299 * utils.h (address_significant): Declare.
300
301 2017-12-08 Tom Tromey <tom@tromey.com>
302
303 * printcmd.c (ui_printf): Update. Use std::vector.
304 * common/format.h (struct format_piece): Add constructor.
305 <string>: Now const.
306 (class format_pieces): New class.
307 (parse_format_string, free_format_pieces)
308 (free_format_pieces_cleanup): Remove.
309 * common/format.c (format_pieces::format_pieces): Rename from
310 parse_format_string. Update.
311 (free_format_pieces, free_format_pieces_cleanup): Remove.
312 * breakpoint.c (parse_cmd_to_aexpr): Update. Use std::vector.
313 * ax-gdb.h (gen_printf): Remove argument.
314 * ax-gdb.c (gen_printf): Remove "frags" argument.
315 (maint_agent_printf_command): Update. Use std::vector.
316
317 2017-12-08 Yao Qi <yao.qi@linaro.org>
318
319 PR breakpionts/22567
320 * linespec.c (minsym_found): Set sal.section.
321
322 2017-12-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
323
324 * configure.tgt (s390*-*-linux*): Add symfile-mem.o.
325
326 2017-12-07 Keith Seitz <keiths@redhat.com>
327
328 PR breakpoints/22569
329 * location.c (string_to_explicit_location): When terminating
330 parsing early, break out of enclosing loop instead of returning.
331
332 2017-12-07 Keith Seitz <keiths@redhat.com>
333
334 * NEWS (New commands): Mention set/show print type nested-type-limit.
335 * c-typeprint.c (c_type_print_base): Print out nested types.
336 * dwarf2read.c (struct typedef_field_list): Rename to ...
337 (struct decl_field_list): ... this. Change all uses.
338 (struct field_info) <nested_types_list, nested_types_list_count>:
339 New fields.
340 (add_partial_symbol): Look for nested type definitions in C++, too.
341 (dwarf2_add_typedef): Rename to ...
342 (dwarf2_add_type_defn): ... this.
343 (type_can_define_types): New function.
344 Update assertion to use type_can_define_types.
345 Permit NULL for a field's name.
346 (process_structure_scope): Handle child DIEs of types that can
347 define types.
348 Copy the list of nested types into the type struct.
349 * gdbtypes.h (struct typedef_field): Rename to ...
350 (struct decl_field): ... this. Change all uses.
351 [is_protected, is_private]: New fields.
352 (struct cplus_struct_type) <nested_types, nested_types_count>: New
353 fields.
354 (TYPE_NESTED_TYPES_ARRAY, TYPE_NESTED_TYPES_FIELD)
355 (TYPE_NESTED_TYPES_FIELD_NAME, TYPE_NESTED_TYPES_FIELD_TYPE)
356 (TYPE_NESTED_TYPES_COUNT, TYPE_NESTED_TYPES_FIELD_PROTECTED)
357 (TYPE_NESTED_TYPES_FIELD_PRIVATE): New macros.
358 * typeprint.c (type_print_raw_options, default_ptype_flags): Add
359 default value for print_nested_type_limit.
360 (print_nested_type_limit): New static variable.
361 (set_print_type_nested_types, show_print_type_nested_types): New
362 functions.
363 (_initialize_typeprint): Register new commands for set/show
364 `print-nested-type-limit'.
365 * typeprint.h (struct type_print_options) [print_nested_type_limit]:
366 New field.
367
368 2017-12-07 Tom Tromey <tom@tromey.com>
369
370 PR breakpoints/22511:
371 * breakpoint.c (commands_command_1): Don't throw an exception when
372 no commands have been read.
373
374 2017-12-07 Adam Stylinski <adam.stylinski@etegent.com>
375
376 PR c++/21222
377 * target-descriptions.c (print_c_tdesc::visit_pre): Change type of
378 range-for variable.
379
380 2017-12-07 Simon Marchi <simon.marchi@ericsson.com>
381
382 * common/selftest.h (struct selftest): Add virtual destructor.
383
384 2017-12-07 Phil Muldoon <pmuldoon@redhat.com>
385
386 * python/py-breakpoint.c (bppy_init): Use string_to_event_location
387 over basic location code. Implement explicit location keywords.
388 (bppy_init_validate_args): New function.
389 * NEWS: Document Python explicit breakpoint locations.
390
391 2017-12-07 Joel Brobecker <brobecker@adacore.com>
392
393 * MAINTAINERS: Restore target entries for m68hc11-elf,
394 score-elf and xstormy16-elf, incorrectly removed in a previous
395 patch meant to only update the list of active maintainers.
396
397 2017-12-06 Pedro Alves <palves@redhat.com>
398
399 * break-catch-syscall.c (insert_catch_syscall)
400 (remove_catch_syscall): Adjust to pass reference to
401 inf_data->syscalls_counts directly via gdb::array_view.
402 * fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
403 and gdb::array_view.
404 * linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
405 * remote.c (remote_set_syscall_catchpoint): Likewise.
406 * target-debug.h (target_debug_print_bool): New.
407 (define target_debug_print_gdb_array_view_const_int): New.
408 * target-delegates.c: Regenerate.
409 * target.h (target_ops) <to_set_syscall_catchpoint>: Use
410 gdb::array_view and bool.
411 (target_set_syscall_catchpoint): Likewise.
412
413 2017-12-06 Simon Marchi <simon.marchi@ericsson.com>
414
415 * break-catch-syscall.c (catch_syscall_completer): Get pointers
416 to syscall group strings after building the string vector.
417
418 2017-12-06 Pedro Alves <palves@redhat.com>
419
420 * remote.c (remote_query_supported): Don't send "xmlRegisters=" if
421 "qXfer:features:read"" is disabled.
422 (remote_write_qxfer, remote_read_qxfer, remote_search_memory):
423 Check packet_config_support instead of packet->support directly.
424
425 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
426
427 * target-descriptions.c (struct tdesc_feature) <registers>: Use
428 tdesc_reg_up typedef.
429 (struct target_desc) <features>: Use tdesc_feature_up typedef.
430
431 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
432
433 * target-descriptions.c (struct tdesc_type): Use default
434 destructor.
435 <u>: Remove.
436 <accept>: Remove.
437 (struct tdesc_type_builtin): New.
438 (struct tdesc_type_vector): New.
439 (struct tdesc_type_with_fields): New.
440 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
441 (tdesc_gdb_type): Remove.
442 (tdesc_register_type): Adjust.
443 (tdesc_create_vector): Create tdesc_type_vector.
444 (tdesc_create_struct): Create tdesc_type_with_fields.
445 (tdesc_set_struct_size): Change parameter type.
446 (tdesc_create_union): Create tdesc_type_with_fields.
447 (tdesc_create_flags): Likewise.
448 (tdesc_create_enum): Likewise.
449 (tdesc_add_field): Change parameter type.
450 (tdesc_add_typed_bitfield): Likewise.
451 (tdesc_add_bitfield): Likewise.
452 (tdesc_add_flag): Likewise.
453 (tdesc_add_enum_value): Likewise.
454 (print_c_tdesc) <visit>: Remove overload with tdesc_type
455 parameter, add overloads for tdesc_type_builtin,
456 tdesc_type_with_fields and tdesc_type_vector.
457 <m_printed_type>: Remove.
458 <m_printed_element_type, m_printed_type_with_fields>: Add.
459 * target-descriptions.h (tdesc_create_enum): Change return type.
460 (tdesc_add_typed_bitfield): Change parameter type.
461 (tdesc_add_enum_value): Change parameter type.
462 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
463 type to tdesc_type_with_fields.
464 (tdesc_start_struct): Adjust.
465 (tdesc_start_flags): Adjust.
466 (tdesc_start_enum): Adjust.
467 (tdesc_start_field): Adjust.
468 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
469 (struct tdesc_type_vector): Forward-declare.
470 (struct tdesc_type_with_fields): Forward-declare.
471 (tdesc_create_struct): Change return type.
472 (tdesc_create_union): Likewise.
473 (tdesc_create_flags): Likewise.
474 (tdesc_add_field): Change parameter type.
475 (tdesc_set_struct_size): Likewise.
476 (tdesc_add_bitfield): Likewise.
477 (tdesc_add_flag): Likewise.
478 * features: Re-generate C files.
479
480 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
481
482 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
483 (struct tdesc_arch_reg): Add constructor.
484 (DEF_VEC_O (tdesc_arch_reg)): Remove.
485 (struct tdesc_arch_data): Initialize fields.
486 <arch_regs>: Change type to std::vector.
487 (target_find_description): Adjust.
488 (tdesc_find_type): Adjust.
489 (tdesc_data_init): Call tdesc_arch_data constructor.
490 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
491 (tdesc_data_cleanup): Free data with delete.
492 (tdesc_numbered_register): Adjust.
493 (tdesc_find_arch_register): Adjust.
494 (tdesc_use_registers): Adjust.
495
496 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
497
498 * target-descriptions.c (tdesc_type_field): Remove typedef.
499 (DEF_VEC_O (tdesc_type_field)): Remove.
500 (struct tdesc_type_field): Add constructor.
501 <name>: Change type to std::string.
502 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
503 kind uses it.
504 <~tdesc_type>: Destroy vector if the type kind uses it.
505 <u::u::fields>: Change type to std::vector.
506 (tdesc_gdb_type): Adjust.
507 (tdesc_add_field): Adjust.
508 (tdesc_add_typed_bitfield): Adjust.
509 (tdesc_add_field): Adjust.
510 (tdesc_add_enum_value): Adjust.
511 (class print_c_tdesc) <visit>: Adjust.
512
513 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
514
515 * target-descriptions.c (struct tdesc_type) <name>: Change type
516 to std::string.
517 <~tdesc_type>: Don't manually free name.
518 <operator==>: Adjust.
519 (tdesc_named_type): Adjust.
520 (tdesc_find_type): Adjust.
521 (tdesc_gdb_type): Adjust.
522 (class print_c_tdesc) <visit>: Adjust.
523
524 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
525
526 * target-descriptions.c (tdesc_type_p): Remove typedef.
527 (DEF_VEC_P (tdesc_type_p)): Remove.
528 (struct tdesc_feature) <types>: Change type to std::vector.
529 <~tdesc_feature>: Replace with default implementation.
530 <accept>: Adjust.
531 (tdesc_named_type): Adjust.
532 (tdesc_create_vector): Adjust.
533 (tdesc_create_struct): Adjust.
534 (tdesc_create_union): Adjust.
535 (tdesc_create_flags): Adjust.
536 (tdesc_create_enum): Adjust.
537
538 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
539
540 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
541 type of name_ parameter, adjust to std::string change.
542 <name, group, type>: Change type to std::string.
543 <~tdesc_reg>: Replace with default implementation.
544 <operator==>: Adjust.
545 (tdesc_find_register_early): Adjust.
546 (tdesc_register_name): Adjust.
547 (tdesc_register_type): Adjust.
548 (tdesc_register_in_reggroup_p): Adjust.
549 (class print_c_tdesc) <visit>: Adjust.
550 (class print_c_feature) <visit>: Adjust.
551 * features/arc-arcompact.c: Re-generate.
552 * features/arc-v2.c: Re-generate.
553
554 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
555
556 * target-descriptions.c (tdesc_reg_p): Remove typedef.
557 (DEF_VEC_P (tdesc_reg_p)): Remove.
558 (struct tdesc_feature) <registers>: Change type to std::vector.
559 <~tdesc_feature>: Don't manually free registers.
560 <accept>: Adjust.
561 <operator==>: Adjust.
562 (tdesc_has_registers): Adjust.
563 (tdesc_find_register_early): Adjust.
564 (tdesc_use_registers): Adjust.
565 (tdesc_create_reg): Adjust.
566
567 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
568
569 * target-descriptions.c (tdesc_feature) <name>: Change type to
570 std::string.
571 <~tdesc_feature>: Don't manually free name.
572 <operator==>: Adjust.
573 (tdesc_find_feature): Adjust.
574 (tdesc_feature_name): Adjust.
575 (class print_c_tdesc) <visit_pre>: Adjust.
576 (class print_c_feature) <visit_pre>: Adjust.
577
578 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
579
580 * target-descriptions.c (tdesc_feature_p): Remove typedef.
581 (DEF_VEC_P (tdesc_feature_p)): Remove.
582 (struct target_desc) <features>: Change type to std::vector.
583 <~target_desc>: Replace with default implementation.
584 <accept>: Adjust.
585 <operator==>: Adjust.
586 (tdesc_has_registers): Adjust.
587 (tdesc_find_feature): Adjust.
588 (tdesc_use_registers): Adjust.
589 (tdesc_create_feature): Adjust.
590
591 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
592
593 * target-descriptions.c (arch_p): Remove typedef.
594 (DEF_VEC_P (arch_p)): Remove.
595 (struct target_desc) <compatible>: Change type to std::vector.
596 <~target_desc>: Don't manually free compatible.
597 (tdesc_compatible_p): Adjust.
598 (tdesc_add_compatible): Adjust.
599 (class print_c_tdesc) <visit_pre>: Adjust.
600
601 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
602
603 * target-descriptions.c (property_s): Remove typedef.
604 (DEF_VEC_O (property_s)): Remove.
605 (struct target_desc) <properties>: Make an std::vector.
606 <~target_desc>: Don't manually free properties.
607 (tdesc_property): Adjust.
608 (set_tdesc_property): Adjust.
609 (class print_c_tdesc) <visit_pre>: Adjust.
610
611 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
612
613 * common/gdb_assert.h (gdb_static_assert): Redefine using
614 static_assert.
615
616 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
617
618 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
619 unused variables.
620 (ada_is_redundant_range_encoding): Likewise.
621 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
622 Likewise.
623 * alpha-tdep.c (alpha_software_single_step): Likewise.
624 * arm-tdep.c (_initialize_arm_tdep): Likewise.
625 * auto-load.c (info_auto_load_cmd): Likewise.
626 * break-catch-syscall.c (insert_catch_syscall): Likewise.
627 (remove_catch_syscall): Likewise.
628 * breakpoint.c (condition_completer): Likewise.
629 (clear_command): Likewise.
630 (update_breakpoint_locations): Likewise.
631 * btrace.c (btrace_disable): Likewise.
632 (btrace_teardown): Likewise.
633 (btrace_maint_update_pt_packets): Likewise.
634 (maint_btrace_clear_cmd): Likewise.
635 * cli/cli-decode.c (lookup_cmd_1): Likewise.
636 (lookup_cmd_composition): Likewise.
637 * cli/cli-dump.c (scan_filename): Likewise.
638 (restore_command): Likewise.
639 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
640 * compile/compile-object-load.c (compile_object_load): Likewise.
641 * compile/compile-object-run.c (compile_object_run): Likewise.
642 * compile/compile.c (compile_to_object): Likewise.
643 * completer.c (filename_completer): Likewise.
644 (complete_files_symbols): Likewise.
645 (complete_expression): Likewise.
646 * corelow.c (core_open): Likewise.
647 * ctf.c (ctf_start): Likewise.
648 (ctf_write_status): Likewise.
649 (ctf_write_uploaded_tsv): Likewise.
650 (ctf_write_definition_end): Likewise.
651 (ctf_open_dir): Likewise.
652 (ctf_xfer_partial): Likewise.
653 (ctf_trace_find): Likewise.
654 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
655 Likewise.
656 * dwarf2loc.c (allocate_piece_closure): Likewise.
657 (indirect_pieced_value): Likewise.
658 (dwarf2_evaluate_loc_desc_full): Likewise.
659 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
660 (dw2_expand_symtabs_matching): Likewise.
661 (dw2_map_symbol_filenames): Likewise.
662 (read_and_check_comp_unit_head): Likewise.
663 (read_cutu_die_from_dwo): Likewise.
664 (lookup_dwo_unit): Likewise.
665 (read_comp_units_from_section): Likewise.
666 (dwarf2_compute_name): Likewise.
667 (handle_DW_AT_stmt_list): Likewise.
668 (create_cus_hash_table): Likewise.
669 (create_dwp_v2_section): Likewise.
670 (dwarf2_rnglists_process): Likewise.
671 (dwarf2_ranges_process): Likewise.
672 (dwarf2_record_block_ranges): Likewise.
673 (is_vtable_name): Likewise.
674 (read_formatted_entries): Likewise.
675 (skip_form_bytes): Likewise.
676 * elfread.c (elf_symtab_read): Likewise.
677 * exec.c (exec_file_command): Likewise.
678 * f-valprint.c (f_val_print): Likewise.
679 (info_common_command_for_block): Likewise.
680 * guile/guile.c (initialize_scheme_side): Likewise.
681 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
682 * guile/scm-cmd.c (cmdscm_completer): Likewise.
683 (gdbscm_register_command_x): Likewise.
684 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
685 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
686 * guile/scm-ports.c (file_port_magic): Likewise.
687 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
688 (ppscm_pretty_print_one_value): Likewise.
689 (ppscm_print_children): Likewise.
690 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
691 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
692 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
693 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
694 * i386-tdep.c (i386_register_reggroup_p): Likewise.
695 * infcmd.c (run_command_1): Likewise.
696 (until_next_fsm_clean_up): Likewise.
697 * linespec.c (linespec_complete): Likewise.
698 (find_label_symbols): Likewise.
699 * m2-valprint.c (m2_val_print): Likewise.
700 * memattr.c (require_user_regions): Likewise.
701 (lookup_mem_region): Likewise.
702 (disable_mem_command): Likewise.
703 (mem_delete): Likewise.
704 * mep-tdep.c (mep_register_name): Likewise.
705 (mep_analyze_prologue): Likewise.
706 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
707 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
708 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
709 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
710 * minidebug.c (lzma_open): Likewise.
711 * minsyms.c (lookup_minimal_symbol): Likewise.
712 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
713 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
714 (mips_o64_return_value): Likewise.
715 (mips_single_step_through_delay): Likewise.
716 (_initialize_mips_tdep): Likewise.
717 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
718 (nios2_software_single_step): Likewise.
719 * parse.c (find_minsym_type_and_address): Likewise.
720 * psymtab.c (psym_relocate): Likewise.
721 * python/py-breakpoint.c (bppy_get_commands): Likewise.
722 (gdbpy_breakpoint_modified): Likewise.
723 * python/py-infevents.c (create_inferior_call_event_object):
724 Likewise.
725 * python/py-record-btrace.c (btpy_list_item): Likewise.
726 * python/py-type.c (typy_str): Likewise.
727 * python/py-value.c (valpy_call): Likewise.
728 * python/python.c (do_start_initialization): Likewise.
729 * record-btrace.c (record_btrace_insn_history_range): Likewise.
730 (record_btrace_call_history_range): Likewise.
731 (record_btrace_record_method): Likewise.
732 (record_btrace_xfer_partial): Likewise.
733 (btrace_get_frame_function): Likewise.
734 * record-full.c (record_full_open): Likewise.
735 * record.c (get_context_size): Likewise.
736 * registry.h (DEFINE_REGISTRY): Likewise.
737 * remote-fileio.c (remote_fileio_request): Likewise.
738 * remote.c (remote_update_thread_list): Likewise.
739 (remote_check_symbols): Likewise.
740 (remote_commit_resume): Likewise.
741 (remote_interrupt): Likewise.
742 (remote_insert_breakpoint): Likewise.
743 (compare_sections_command): Likewise.
744 * rust-exp.y (super_name): Likewise.
745 (lex_string): Likewise.
746 (convert_ast_to_type): Likewise.
747 (convert_ast_to_expression): Likewise.
748 * rust-lang.c (rust_print_struct_def): Likewise.
749 (rust_print_type): Likewise.
750 (rust_evaluate_subexp): Likewise.
751 * rx-tdep.c (rx_register_type): Likewise.
752 * ser-event.c (serial_event_clear): Likewise.
753 * serial.c (serial_open): Likewise.
754 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
755 * symfile.c (section_is_overlay): Likewise.
756 (overlay_unmapped_address): Likewise.
757 (overlay_mapped_address): Likewise.
758 (simple_overlay_update_1): Likewise.
759 (simple_overlay_update): Likewise.
760 * symtab.c (symbol_find_demangled_name): Likewise.
761 (search_symbols): Likewise.
762 * target-descriptions.c (tdesc_predefined_type): Likewise.
763 * target.c (target_commit_resume): Likewise.
764 * thread.c (print_selected_thread_frame): Likewise.
765 * top.c (new_ui_command): Likewise.
766 (gdb_readline_no_editing): Likewise.
767 * tracefile-tfile.c (tfile_open): Likewise.
768 * tracepoint.c (create_tsv_from_upload): Likewise.
769 * utils.c (quit): Likewise.
770 (defaulted_query): Likewise.
771 * valarith.c (value_concat): Likewise.
772 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
773 * xml-tdesc.c (target_fetch_description_xml): Likewise.
774 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
775 (xtensa_pseudo_register_write): Likewise.
776
777 2017-12-04 Tom Tromey <tom@tromey.com>
778
779 * NEWS: Mention Rust trait object inspection.
780
781 2017-12-04 Pedro Alves <palves@redhat.com>
782
783 PR gdb/22499
784 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
785 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
786 (vex2_prefix_p, vex3_prefix_p): New functions.
787 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
788 VEX3 prefixes.
789 (fixup_riprel): Set VEX3.!B.
790
791 2017-12-03 Simon Marchi <simon.marchi@ericsson.com>
792
793 * target.h (mem_region_vector): Remove.
794 (struct target_ops) <to_memory_map>: Change return type to
795 std::vector<mem_region>.
796 * target-debug.h (target_debug_print_mem_region_vector): Rename
797 to ...
798 (target_debug_print_std_vector_mem_region): ... this.
799 * target-delegates.c: Re-generate.
800
801 2017-12-03 Pedro Alves <palves@redhat.com>
802
803 * make-target-delegates (munge_type): Also munge '<', '>', and
804 ':'. Avoid double underscores in identifiers, and trailing
805 underscores.
806 * target-debug.h
807 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
808 ...
809 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
810 * target-delegates.c: Regenerate.
811
812 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
813
814 * common/poison.h (XDELETE): Fix typo.
815
816 2017-12-01 Andrew Cagney <cagney@redhat.com>
817 Joel Brobecker <brobecker@adacore.com>
818 Sergio Durigan Junior <sergiodj@redhat.com>
819
820 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
821 feature.
822 * coffread.c (coff_symfile_read): Do not map over sections with
823 'coff_locate_sections' if readnever is on.
824 * dwarf2read.c (dwarf2_has_info): Return 0 if
825 readnever is on.
826 * elfread.c (elf_symfile_read): Do not map over sections with
827 'elf_locate_sections' if readnever is on.
828 * main.c (validate_readnow_readnever): New function.
829 (captured_main_1): Add support for --readnever.
830 (print_gdb_help): Document --readnever.
831 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
832 flag.
833 * symfile.c (readnever_symbol_files): New global.
834 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
835 'READNEVER_SYMBOL_FILES' is set.
836 (validate_readnow_readnever): New function.
837 (symbol_file_command): Handle '-readnever' option.
838 Call 'validate_readnow_readnever'.
839 (add_symbol_file_command): Handle '-readnever' option.
840 Call 'validate_readnow_readnever'.
841 (_initialize_symfile): Document new '-readnever' option for
842 both 'symbol-file' and 'add-symbol-file' commands.
843 * top.h (readnever_symbol_files): New extern global.
844 * xcoffread.c (xcoff_initial_scan): Do not read debug
845 information if readnever is on.
846
847 2017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
848
849 * symfile.c (symbol_file_command): Call
850 'symbol_file_add_main_1' only after processing all command
851 line options.
852 (add_symbol_file_command): Modify logic to make arguments
853 position-independent.
854
855 2017-12-01 Joel Brobecker <brobecker@adacore.com>
856
857 * ada-lang.c (symbol_list_obstack): Delete.
858 (resolve_subexp): Make sure "candidates" gets xfree'ed.
859 (ada_lookup_symbol_list_worker): Remove the limitation that
860 the result is only good until the next call, now making it
861 the responsibility of the caller to free the result when no
862 longer needed. Adjust the function's intro comment accordingly.
863 (ada_lookup_symbol_list): Adjust the function's intro comment.
864 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
865 (ada_lookup_encoded_symbol, get_var_value): Likewise.
866 (_initialize_ada_language): Remove symbol_list_obstack
867 initialization.
868 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
869 (write_var_or_type, write_name_assoc): Likewise.
870
871 2017-12-01 Tom Tromey <tom@tromey.com>
872
873 * Makefile.in (all_deps_files): New variable.
874 Include .Po files using all_deps_files.
875
876 2017-12-01 Joel Brobecker <brobecker@adacore.com>
877
878 * MAINTAINERS: Update list of maintainers, moving those who
879 stepped down or became inactive to the "Past Maintainers"
880 section.
881
882 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
883
884 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
885 sys/proc.h.
886 (NEW_PROC_API): Remove.
887 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
888 Likewise.
889 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
890 * configure: Regenerate.
891 * config.in: Regenerate.
892 * gdbserver/configure: Regenerate.
893 * gdbserver/config.in: Regenerate.
894
895 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
896 NEW_PROC_API test.
897 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
898
899 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
900
901 * proc-api.c: Remove !NEW_PROC_API support.
902 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
903 Remove tests for macros always defined on Solaris.
904 * proc-events.c: Remove !NEW_PROC_API support.
905 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
906 HAVE_SYS_USER_H tests.
907 (init_syscall_table): Remove non-Solaris syscalls.
908 Remove tests for syscalls present on all Solaris versions.
909 Add missing Solaris 10+ syscalls.
910 (signal_table): Remove non-Solaris signals.
911 Remove tests for signals present on all Solaris versions.
912 (fault_table): Remove non-Solaris faults.
913 Remove tests for faults present on all Solaris versions.
914 * proc-flags.c: Remove !NEW_PROC_API support.
915 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
916 Remove non-Solaris flags.
917 * proc-why.c: Remove !NEW_PROC_API support.
918 (pr_why_table): Remove meaningless comments.
919 Remove tests for reasons present on all Solaris versions.
920 Remove OSF/1 cases.
921 (proc_prettyfprint_why): Likewise.
922
923 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
924 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
925 Remove WA_READ test, IRIX watchpoint support.
926 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
927 types. Change users.
928 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
929 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
930 Change callers.
931 Remove CTL_PROC_NAME_FMT tests.
932 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
933 users.
934 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
935 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
936 (proc_modify_flag): Replace GDBRESET by PCUNSET.
937 Remove PR_ASYNC, PR_KLC tests.
938 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
939 (proc_parent_pid): Remove PCWATCH etc. tests.
940 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
941 Remove PCAGENT test.
942 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
943 Remove SYS_lwpcreate || SYS_lwp_create test.
944 (proc_get_current_thread): Likewise.
945 [PIOCNTHR && PIOCTLIST]: Remove.
946 [PIOCLSTATUS]: Remove.
947 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
948 [PRFS_STOPEXEC]: Remove.
949 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
950 (syscall_is_exit): Likewise.
951 (syscall_is_exec): Likewise.
952 (syscall_is_lwp_create): Likewise.
953 Remove SYS_syssgi support.
954 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
955 [SYS_syssgi]: Remove.
956 Remove non-Solaris cases, conditionals.
957 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
958 Remove.
959 (procfs_init_inferior) [SYS_syssgi]: Remove.
960 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
961 (procfs_inferior_created) [SYS_syssgi]: Remove.
962 (procfs_set_watchpoint): Remove !AIX5 test.
963 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
964 case.
965 (mappingflags) [MA_PHYS]: Remove.
966 (info_mappings_callback): Remove PCAGENT test.
967 Remove PIOCOPENLWP || PCAGENT test.
968
969 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
970
971 * sol-thread.c (info_solthreads): Constify args.
972 Cast args to void *.
973
974 2017-11-29 John Baldwin <jhb@FreeBSD.org>
975
976 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
977
978 2017-11-29 Joel Brobecker <brobecker@adacore.com>
979
980 * ada-lang.c (to_fixed_range_type): Make sure that the size
981 of the range type being returned is the same as the size
982 of the range type being fixed.
983
984 2017-11-29 Pedro Alves <palves@redhat.com>
985
986 PR c++/19436
987 * NEWS: Mention setting breakpoints on functions with C++ ABI
988 tags.
989 * completer.h (completion_match_for_lcd) <match,
990 mark_ignored_range>: New methods.
991 <finish>: Consider ignored ranges.
992 <clear>: Clear ignored ranges.
993 <m_ignored_ranges, m_finished_storage>: New fields.
994 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
995 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
996 completion_match_for_lcd pointer to strncmp_iw_with_mode.
997 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
998 * language.c (default_symbol_name_matcher): Pass the
999 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1000 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1001 * utils.c (skip_abi_tag): New function.
1002 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1003 Handle ABI tags.
1004 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1005 parameter.
1006
1007 2017-11-29 Pedro Alves <palves@redhat.com>
1008
1009 PR c++/19436
1010 * NEWS: Mention setting breakpoints on functions with C++ ABI
1011 tags.
1012 * completer.h (completion_match_for_lcd) <match,
1013 mark_ignored_range>: New methods.
1014 <finish>: Consider ignored ranges.
1015 <clear>: Clear ignored ranges.
1016 <m_ignored_ranges, m_finished_storage>: New fields.
1017 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1018 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1019 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1020 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1021 * language.c (default_symbol_name_matcher): Pass the
1022 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1023 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1024 * utils.c (skip_abi_tag): New function.
1025 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1026 Handle ABI tags.
1027 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1028 parameter.
1029
1030 2017-11-29 Pedro Alves <palves@redhat.com>
1031
1032 * NEWS: Mention that breakpoints on C++ functions are now set on
1033 on all namespaces/classes by default, and mention "break
1034 -qualified".
1035 * ax-gdb.c (agent_command_1): Adjust to pass a
1036 symbol_name_match_type to new_linespec_location.
1037 * breakpoint.c (parse_breakpoint_sals): Adjust to
1038 get_linespec_location's return type change.
1039 (strace_marker_create_sals_from_location): Adjust to pass a
1040 symbol_name_match_type to new_linespec_location.
1041 (strace_marker_decode_location): Adjust to get_linespec_location's
1042 return type change.
1043 (strace_command): Adjust to pass a symbol_name_match_type to
1044 new_linespec_location.
1045 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
1046 mention "-qualified".
1047 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
1048 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
1049 enumerator.
1050 (complete_address_and_linespec_locations): New parameter
1051 'match_type'. Pass it down.
1052 (explicit_options): Add "-qualified".
1053 (collect_explicit_location_matches): Pass the requested match type
1054 to the linespec completers. Handle MATCH_QUALIFIED.
1055 (location_completer): Handle "-qualified" combined with linespecs.
1056 * cp-support.c (cp_search_name_hash): New.
1057 (cp_symbol_name_matches_1): Implement wild matching for C++.
1058 (cp_fq_symbol_name_matches): Reimplement.
1059 (cp_get_symbol_name_matcher): Return different matchers depending
1060 on the lookup name's match type.
1061 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
1062 * cp-support.h (cp_search_name_hash): New declaration.
1063 * dwarf2read.c
1064 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
1065 symbols.
1066 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
1067 tests.
1068 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
1069 pass a symbol_name_match_type to new_linespec_location.
1070 * linespec.c (linespec_parse_basic): Lookup function symbols using
1071 the parser's symbol name match type.
1072 (convert_explicit_location_to_linespec): New
1073 symbol_name_match_type parameter. Pass it down to
1074 find_linespec_symbols.
1075 (convert_explicit_location_to_sals): Pass the location's name
1076 match type to convert_explicit_location_to_linespec.
1077 (parse_linespec): New match_type parameter. Save it in the
1078 parser.
1079 (linespec_parser_new): Default to symbol_name_match_type::WILD.
1080 (linespec_complete_function): New symbol_name_match_type
1081 parameter. Use it.
1082 (complete_linespec_component): Pass down the parser's recorded
1083 name match type.
1084 (linespec_complete_label): New symbol_name_match_type parameter.
1085 Use it.
1086 (linespec_complete): New symbol_name_match_type parameter. Save
1087 it in the parser and pass it down. Adjust to
1088 get_linespec_location's prototype change.
1089 (find_function_symbols, find_linespec_symbols): New
1090 symbol_name_match_type parameter. Pass it down instead of
1091 assuming symbol_name_match_type::WILD.
1092 * linespec.h (linespec_complete, linespec_complete_function)
1093 (linespec_complete_label): New symbol_name_match_type parameter.
1094 * location.c (event_location::linespec_location): Now a struct
1095 linespec_location.
1096 (EL_LINESPEC): Adjust.
1097 (initialize_explicit_location): Default to
1098 symbol_name_match_type::WILD.
1099 (new_linespec_location): New symbol_name_match_type parameter.
1100 Record it in the location.
1101 (get_linespec_location): Now returns a struct linespec_location.
1102 (new_explicit_location): Also copy func_name_match_type.
1103 (explicit_to_string_internal)
1104 (string_to_explicit_location): Handle "-qualified".
1105 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
1106 Copy symbol_name_match_type fields.
1107 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
1108 type change.
1109 (event_location_to_string): Adjust to LINESPEC_LOCATION type
1110 change. Handle "-qualfied".
1111 (string_to_explicit_location): Handle "-qualified".
1112 (string_to_event_location_basic): New symbol_name_match_type
1113 parameter. Pass it down.
1114 (string_to_event_location): Handle "-qualified".
1115 * location.h (struct linespec_location): New.
1116 (explicit_location::func_name_match_type): New field.
1117 (new_linespec_location): Now returns a const linespec_location *.
1118 (string_to_event_location_basic): New symbol_name_match_type
1119 parameter.
1120 (explicit_completion_info::saw_explicit_location_option): New
1121 field.
1122 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
1123 symbol_name_match_type to new_linespec_location.
1124 * python/py-breakpoint.c (bppy_init): Likewise.
1125 * python/python.c (gdbpy_decode_line): Likewise.
1126
1127 2017-11-29 Pedro Alves <palves@redhat.com>
1128
1129 * ada-lang.c (ada_lookup_name_info::matches): Change type of
1130 parameter from completion_match to completion_match_result.
1131 Adjust.
1132 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
1133 * completer.c (completion_tracker::maybe_add_completion): Add
1134 match_for_lcd parameter and use it.
1135 (completion_tracker::add_completion): Likewise.
1136 * completer.h (class completion_match_for_lcd): New class.
1137 (completion_match_result::match_for_lcd): New field.
1138 (completion_match_result::set_match): New method.
1139 (completion_tracker): Add comments.
1140 (completion_tracker::add_completion): Add match_for_lcd parameter.
1141 (completion_tracker::reset_completion_match_result): Reset
1142 match_for_lcd too.
1143 (completion_tracker::maybe_add_completion): Add match_for_lcd
1144 parameter.
1145 (completion_tracker::m_lowest_common_denominator_unique): Extend
1146 comments.
1147 * cp-support.c (cp_symbol_name_matches_1)
1148 (cp_fq_symbol_name_matches): Change type of parameter from
1149 completion_match to completion_match_result. Adjust.
1150 * language.c (default_symbol_name_matcher): Change type of
1151 parameter from completion_match to completion_match_result.
1152 Adjust.
1153 * language.h (completion_match_for_lcd): Forward declare.
1154 (default_symbol_name_matcher): Change type of parameter from
1155 completion_match to completion_match_result.
1156 * symtab.c (compare_symbol_name): Adjust.
1157 (completion_list_add_name): Pass the match_for_lcd to the tracker.
1158 * symtab.h (ada_lookup_name_info::matches): Change type of
1159 parameter from completion_match to completion_match_result.
1160 (symbol_name_matcher_ftype): Likewise, and update comments.
1161
1162 2017-11-29 Pedro Alves <palves@redhat.com>
1163
1164 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
1165 * minsyms.c (msymbol_is_text): Delete.
1166 (msymbol_is_function): New function.
1167 * minsyms.h (msymbol_is_text): Delete.
1168 (msymbol_is_function): New declaration.
1169 * symtab.c (find_function_alias_target): Use msymbol_is_function.
1170
1171 2017-11-29 Tom Tromey <tom@tromey.com>
1172
1173 * Makefile.in (distclean): Handle the case where rmdir fails.
1174
1175 2017-11-29 Tom Tromey <tom@tromey.com>
1176
1177 * symfile.c (_initialize_symfile): Update usage text for
1178 add-symbol-file, symbol-file, load.
1179
1180 2017-11-29 Tom Tromey <tom@tromey.com>
1181
1182 * symfile.c (add_symbol_file_command): Error if some arguments to
1183 -s are missing. Change unrecognized-argument error message.
1184 (_initialize_symfile): Fix usage text for add-symbol-file.
1185
1186 2017-11-27 Tom Tromey <tom@tromey.com>
1187
1188 * Makefile.in (REMOTE_OBS): Remove.
1189 (SFILES): Remove remote sources.
1190 (COMMON_SFILES): Add remote sources.
1191 (ALLDEPFILES): Remove dcache.c.
1192
1193 2017-11-27 Tom Tromey <tom@tromey.com>
1194
1195 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
1196 variables.
1197 (SFILES): Use SUBDIR_TARGET_SRCS.
1198 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
1199 (CONFIG_SRC_SUBDIR): Add target.
1200 (%.o): Remove target rule.
1201
1202 2017-11-27 Tom Tromey <tom@tromey.com>
1203
1204 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
1205 registry.o, thread-fsm.o, debug.o.
1206 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
1207 thread-fsm.c, debug.c.
1208
1209 2017-11-27 Tom Tromey <tom@tromey.com>
1210
1211 * Makefile.in (COMMON_SFILES): New.
1212 (SFILES): Move some entries to COMMON_SFILES.
1213 (COMMON_OBS): Use COMMON_SFILES.
1214
1215 2017-11-27 Tom Tromey <tom@tromey.com>
1216
1217 * Makefile.in (YYFILES): Update comment.
1218 (YYOBJ): Redefine.
1219
1220 2017-11-27 Tom Tromey <tom@tromey.com>
1221
1222 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
1223 (CONFIG_SRC_SUBDIR): Add python.
1224 (%.o): Remove python rule.
1225 (python/%.o): New rule.
1226 * configure: Rebuild.
1227 * configure.ac (CONFIG_OBS): Refer to python/python.o
1228
1229 2017-11-27 Tom Tromey <tom@tromey.com>
1230
1231 * configure: Rebuild.
1232 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
1233 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
1234 (CONFIG_SRC_SUBDIR): Add guile.
1235 (%.o): Remove guile rule.
1236
1237 2017-11-27 Tom Tromey <tom@tromey.com>
1238
1239 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
1240 (%.o): Remove unittests rule.
1241 (CONFIG_SRC_SUBDIR): Add unittests.
1242
1243 2017-11-27 Tom Tromey <tom@tromey.com>
1244
1245 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
1246 (CONFIG_SRC_SUBDIR): Add tui.
1247 (%.o): Remove tui rule.
1248
1249 2017-11-27 Tom Tromey <tom@tromey.com>
1250
1251 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
1252 (%.o): Remove compile rule.
1253 (CONFIG_SRC_SUBDIR): Add compile.
1254
1255 2017-11-27 Tom Tromey <tom@tromey.com>
1256
1257 * Makefile.in (SUBDIR_MI_OBS): Redefine.
1258 (%.o): Remove mi rule.
1259 (CONFIG_SRC_SUBDIR): Add mi.
1260 (COMMON_OBS): Use mi/mi-common.o
1261
1262 2017-11-27 Tom Tromey <tom@tromey.com>
1263
1264 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
1265 (%.o): Remove cli rule.
1266 (CONFIG_SRC_SUBDIR): Add cli.
1267
1268 2017-11-27 Tom Tromey <tom@tromey.com>
1269
1270 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
1271 * configure: Rebuild.
1272 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
1273 (CONFIG_DEP_SUBDIR): New variable.
1274 (%.o): Add order-only dependency.
1275 ($(CONFIG_DEP_SUBDIR)): New target.
1276
1277 2017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
1278
1279 PR gdb/21945
1280 * findcmd.c (_initialize_mem_search): Update find command help
1281 text.
1282
1283 2017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
1284
1285 * python/python.c (do_start_initialization): Change progname
1286 type to gdb::unique_xmalloc_ptr. Release the pointer when using
1287 Python 2.
1288
1289 2017-11-26 Tom Tromey <tom@tromey.com>
1290
1291 * common/format.h: Add include guards.
1292
1293 2017-11-26 Tom Tromey <tom@tromey.com>
1294
1295 * nat/linux-personality.h (class
1296 maybe_disable_address_space_randomization): New class.
1297 (maybe_disable_address_space_randomization): Don't declare
1298 function.
1299 * nat/linux-personality.c (restore_personality)
1300 (make_disable_asr_cleanup): Remove.
1301 (maybe_disable_address_space_randomization): Now a constructor.
1302 (~maybe_disable_address_space_randomization): New destructor.
1303 * linux-nat.c (linux_nat_create_inferior): Update.
1304
1305 2017-11-26 Tom Tromey <tom@tromey.com>
1306
1307 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
1308
1309 2017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
1310
1311 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
1312 "cooked" register. Access only first four bytes of branch target
1313 registers.
1314
1315 2017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
1316
1317 PR gdb/22491
1318 * stap-probe.c (relocate_address): New function.
1319 (stap_probe::get_relocated_address): Use 'relocate_address'.
1320 (stap_probe::set_semaphore): Use 'relocate_address' and pass
1321 'm_sem_addr'.
1322 (stap_probe::clear_semaphore): Likewise.
1323
1324 2017-11-25 Pedro Alves <palves@redhat.com>
1325
1326 * dictionary.c: Include "safe-ctype.h".
1327 * minsyms.c: Include "safe-ctype.h".
1328 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
1329
1330 2017-11-25 Pedro Alves <palves@redhat.com>
1331
1332 * completer.c (complete_line_internal_1): Skip spaces until the
1333 start of the command.
1334
1335 2017-11-24 Pedro Alves <palves@redhat.com>
1336
1337 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
1338 cp_fq_symbol_name_matches. Pass language_cplus to
1339 strncmp_with_mode.
1340 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
1341 (selftests::test_cp_symbol_name_cmp): New.
1342 (_initialize_cp_support): Register "cp_symbol_name_matches"
1343 selftests.
1344 * language.c (default_symbol_name_matcher): Pass language_minimal
1345 to strncmp_iw_with_mode.
1346 * utils.c: Include "cp-support.h" and <algorithm>.
1347 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
1348 (cp_is_operator): New functions.
1349 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
1350 skip whitespace in the symbol name when the lookup name doesn't
1351 have spaces, and vice versa.
1352 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
1353 * utils.h (strncmp_iw_with_mode): Add language parameter.
1354
1355 2017-11-24 Joel Brobecker <brobecker@adacore.com>
1356
1357 * ada-lang.c (ada_exception_message_1, ada_exception_message):
1358 New functions.
1359 (print_it_exception): If available, display the exception
1360 message as well.
1361 * NEWS: Document new feature.
1362
1363 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1364
1365 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
1366
1367 2017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
1368
1369 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
1370 (dtrace_probe::is_enabled, dtrace_probe::enable)
1371 (dtrace_probe::disable): Remove keyword 'struct' at for-range
1372 variable
1373 * probe.c (gen_ui_out_table_header_info)
1374 (print_ui_out_not_applicables): Remove keyword 'struct' at
1375 for-range variable
1376
1377 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1378
1379 * configure.tgt: Add arch/aarch64.o
1380
1381 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1382
1383 * common/common-utils.h: Include poison.h.
1384 (xfree): Remove declaration, add definition with static_assert.
1385 * common/common-utils.c (xfree): Remove.
1386 * common/poison.h (IsMallocatable): Define.
1387 (IsFreeable): Define.
1388 (free): Delete for non-freeable types.
1389 (xnew): New.
1390 (XNEW): Undef and redefine.
1391 (xcnew): New.
1392 (XCNEW): Undef and redefine.
1393 (xdelete): New.
1394 (XDELETE): Undef and redefine.
1395 (xnewvec): New.
1396 (XNEWVEC): Undef and redefine.
1397 (xcnewvec): New.
1398 (XCNEWVEC): Undef and redefine.
1399 (xresizevec): New.
1400 (XRESIZEVEC): Undef and redefine.
1401 (xdeletevec): New.
1402 (XDELETEVEC): Undef and redefine.
1403 (xnewvar): New.
1404 (XNEWVAR): Undef and redefine.
1405 (xcnewvar): New.
1406 (XCNEWVAR): Undef and redefine.
1407 (xresizevar): New.
1408 (XRESIZEVAR): Undef and redefine.
1409
1410 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1411
1412 * gdbthread.h (private_thread_info): Define structure type, add
1413 virtual pure destructor.
1414 (thread_info) <priv>: Change type to unique_ptr.
1415 <private_dtor>: Remove.
1416 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
1417 (private_thread_info::~private_thread_info): Provide default
1418 implementation.
1419 (thread_info::~thread_info): Don't call private_dtor nor
1420 manually free priv.
1421 * aix-thread.c (private_thread_info): Rename to ...
1422 (aix_thread_info): ... this.
1423 (get_aix_thread_info): New.
1424 (sync_threadlists): Adjust.
1425 (iter_tid): Adjust.
1426 (aix_thread_resume): Adjust.
1427 (aix_thread_fetch_registers): Adjust.
1428 (aix_thread_store_registers): Adjust.
1429 (aix_thread_extra_thread_info): Adjust.
1430 * darwin-nat.h (private_thread_info): Rename to ...
1431 (darwin_thread_info): ... this.
1432 (get_darwin_thread_info): New.
1433 * darwin-nat.c (darwin_init_thread_list): Adjust.
1434 (darwin_check_new_threads): Adjust.
1435 (thread_info_from_private_thread_info): Adjust.
1436 * linux-thread-db.c (private_thread_info): Rename to ...
1437 (thread_db_thread_info): ... this, initialize fields.
1438 (get_thread_db_thread_info): New.
1439 <dying>: Change type to bool.
1440 (update_thread_state): Adjust to type rename.
1441 (record_thread): Adjust to type rename an use of unique_ptr.
1442 (thread_db_pid_to_str): Likewise.
1443 (thread_db_extra_thread_info): Likewise.
1444 (thread_db_thread_handle_to_thread_info): Likewise.
1445 (thread_db_get_thread_local_address): Likewise.
1446 * nto-tdep.h (private_thread_info): Rename to ...
1447 (nto_thread_info): ... this, initialize fields.
1448 (get_nto_thread_info): New.
1449 <name>: Change type to std::string.
1450 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1451 use of unique_ptr.
1452 * nto-procfs.c (update_thread_private_data_name): Adjust to
1453 std::string change, allocate nto_private_thread_info with new.
1454 (update_thread_private_data): Adjust to unique_ptr.
1455 * remote.c (private_thread_info): Rename to ...
1456 (remote_thread_info): ... this, initialize data members with
1457 default values.
1458 <extra, name>: Change type to std::string.
1459 <thread_handle>: Change type to non-pointer.
1460 (free_private_thread_info): Remove.
1461 (get_private_info_thread): Rename to...
1462 (get_remote_thread_info): ... this, change return type, adjust to
1463 use of unique_ptr, use remote_thread_info constructor.
1464 (remote_add_thread): Adjust.
1465 (get_private_info_ptid): Rename to...
1466 (get_remote_thread_info): ...this, change return type.
1467 (remote_thread_name): Use get_remote_thread_info, adjust to
1468 change to std::string.
1469 (struct thread_item) <~thread_item>: Remove.
1470 <thread_handle>: Make non pointer.
1471 (start_thread): Adjust to thread_item::thread_handle type
1472 change.
1473 (remote_update_thread_list): Adjust to type name change, move
1474 strings from temporary to long-lived object instead of
1475 duplicating.
1476 (remote_threads_extra_info): Use get_remote_thread_info.
1477 (process_initial_stop_replies): Likewise.
1478 (resume_clear_thread_private_info): Likewise.
1479 (remote_resume): Adjust to type name change.
1480 (remote_commit_resume): Use get_remote_thread_info.
1481 (process_stop_reply): Adjust to type name change.
1482 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1483 (remote_stopped_by_hw_breakpoint): Likewise.
1484 (remote_stopped_by_watchpoint): Likewise.
1485 (remote_stopped_data_address): Likewise.
1486 (remote_core_of_thread): Likewise.
1487 (remote_thread_handle_to_thread_info): Use
1488 get_private_info_thread, adjust to thread_handle field type
1489 change.
1490
1491 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1492
1493 * remote.c (struct thread_item): Add constructor, disable copy
1494 construction and copy assignment, define default move
1495 construction and move assignment.
1496 <extra, name>: Change type to std::string.
1497 <core>: Initialize.
1498 <thread_handle>: Make non-pointer.
1499 (thread_item_t): Remove typedef.
1500 (DEF_VEC_O(thread_item_t)): Remove.
1501 (threads_listing_context) <contains_thread>: New method.
1502 <remove_thread>: New method.
1503 <items>: Change type to std::vector.
1504 (clear_threads_listing_context): Remove.
1505 (threads_listing_context_remove): Remove.
1506 (remote_newthread_step): Use thread_item constructor, adjust to
1507 change to std::vector.
1508 (start_thread): Use thread_item constructor, adjust to change to
1509 std::vector.
1510 (end_thread): Adjust to change to std::vector and std::string.
1511 (remote_get_threads_with_qthreadinfo): Use thread_item
1512 constructor, adjust to std::vector.
1513 (remote_update_thread_list): Adjust to change to std::vector and
1514 std::string, use threads_listing_context methods.
1515 (remove_child_of_pending_fork): Adjust.
1516 (remove_new_fork_children): Adjust.
1517 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1518 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1519 * unittests/rsp-low-selftests.c: New file.
1520 * common/rsp-low.h: Include common/byte-vector.h.
1521 (hex2bin): New overload.
1522 * common/rsp-low.c (hex2bin): New overload.
1523
1524 2017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1525
1526 * inferior.h (private_inferior): Define structure type, add
1527 virtual pure destructor.
1528 (inferior) <priv>: Change type to unique_ptr.
1529 * inferior.c (private_inferior::~private_inferior): Provide
1530 default implementation.
1531 (inferior::~inferior): Don't free priv field.
1532 (exit_inferior_1): Likewise.
1533 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1534 (darwin_exception_info): Remove typedef.
1535 (DEF_VEC_O (darwin_thread_t)); Remove.
1536 (private_inferior): Rename to ...
1537 (darwin_private_inferior): ... this, extend private_inferior.
1538 (get_darwin_inferior): New.
1539 <threads>: Change type to std::vector of darwin_thread_t pointers.
1540 * darwin-nat.c (darwin_check_new_threads): Adjust.
1541 (find_inferior_task_it): Adjust.
1542 (darwin_find_thread); Adjust.
1543 (darwin_suspend_inferior): Adjust.
1544 (darwin_resume_inferior): Adjust.
1545 (darwin_find_new_inferior): Adjust.
1546 (darwin_decode_notify_message): Adjust.
1547 (darwin_send_reply): Adjust.
1548 (darwin_resume_inferior_threads): Adjust.
1549 (darwin_suspend_inferior_threads): Adjust.
1550 (darwin_decode_message): Adjust.
1551 (darwin_wait): Adjust.
1552 (darwin_interrupt): Adjust.
1553 (darwin_deallocate_threads): Adjust.
1554 (darwin_mourn_inferior): Adjust, don't free private data.
1555 (darwin_reply_to_all_pending_messages): Adjust.
1556 (darwin_stop_inferior): Adjust.
1557 (darwin_setup_exceptions): Adjust.
1558 (darwin_kill_inferior): Adjust.
1559 (darwin_setup_request_notification): Adjust.
1560 (darwin_attach_pid): Adjust.
1561 (darwin_init_thread_list): Adjust.
1562 (darwin_setup_fake_stop_event): Adjust.
1563 (darwin_attach): Adjust.
1564 (darwin_detach): Adjust.
1565 (darwin_xfer_partial): Adjust.
1566 (set_enable_mach_exceptions): Adjust.
1567 (darwin_pid_to_exec_file): Adjust.
1568 (darwin_get_ada_task_ptid): Adjust.
1569 * darwin-nat-info.c (get_task_from_args): Adjust.
1570 (info_mach_ports_command): Adjust.
1571 (info_mach_region_command): Adjust.
1572 (info_mach_exceptions_command): Adjust.
1573 * remote.c (private_inferior): Rename to ...
1574 (remote_private_inferior): ... this, initialize fields.
1575 (get_remote_inferior); New.
1576 (remote_commit_resume): Use get_remote_inferior.
1577 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1578
1579 2017-11-24 Pedro Alves <palves@redhat.com>
1580
1581 * NEWS: Mention linespecs and explicit locations, and completion
1582 improvements.
1583
1584 2017-11-24 Yao Qi <yao.qi@linaro.org>
1585
1586 * regcache.c (regcache::dump): Remove footnote_register_size.
1587
1588 2017-11-24 Yao Qi <yao.qi@linaro.org>
1589
1590 * regcache.c (cooked_read_test): Add more test for readonly
1591 regcache.
1592
1593 2017-11-24 Yao Qi <yao.qi@linaro.org>
1594
1595 * gdbarch-selftests.c (test_target_has_registers): Move it to
1596 target.c.
1597 (test_target_has_stack): Likewise.
1598 (test_target_has_memory): Likewise.
1599 (test_target_prepare_to_store): Likewise.
1600 (test_target_store_registers): Likewise.
1601 (test_target_ops): Likewise.
1602 * regcache.c: Include selftest-arch.h and gdbthread.h.
1603 (target_ops_no_register): New class.
1604 (test_target_fetch_registers): New.
1605 (test_target_store_registers): New.
1606 (test_target_xfer_partial): New.
1607 (readwrite_regcache): New.
1608 (cooked_read_test): New.
1609 (_initialize_regcache): Register the test.
1610 * target.c: (test_target_has_registers): Moved from
1611 gdbarch-selftests.c.
1612 (test_target_has_stack): Likewise.
1613 (test_target_has_memory): Likewise.
1614 (test_target_prepare_to_store): Likewise.
1615 (test_target_store_registers): Likewise.
1616 * target.h (test_target_ops): New class.
1617
1618 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1619
1620 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1621 selftest.
1622
1623 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1624
1625 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1626 * arch/aarch64.c (aarch64_create_target_description): Create
1627 new target description.
1628 * features/Makefile: Add new files.
1629 * features/aarch64.c: Remove file.
1630 * features/aarch64-core.c: New autogenerated file.
1631 * features/aarch64-fpu.c: New autogenerated file.
1632 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
1633
1634 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1635
1636 * Makefile.in: Add new files.
1637 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1638 aarch64_read_description.
1639 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1640 Call aarch64_read_description.
1641 * aarch64-tdep.c (aarch64_read_description): New function.
1642 (aarch64_gdbarch_init): Call aarch64_read_description.
1643 * aarch64-tdep.h (aarch64_read_description): New function.
1644 * arch/aarch64.c: New file.
1645 * configure.tgt: Add new files.
1646
1647 2017-11-24 Yao Qi <yao.qi@linaro.org>
1648
1649 * mi/mi-main.c (register_changed_p): Update.
1650 * value.c (value_contents_bits_eq): Change return type.
1651 (value_contents_eq): Likewise.
1652 * value.h: Update comments.
1653
1654 2017-11-24 Yao Qi <yao.qi@linaro.org>
1655
1656 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1657 local 'changed'. Remove error.
1658 (register_changed_p): Change return type to bool.
1659
1660 2017-11-24 Yao Qi <yao.qi@linaro.org>
1661
1662 * arch/tic6x.c: New file.
1663 * arch/tic6x.h: New file.
1664 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1665 tic6x-core.xml and tic6x-gp.xml.
1666 * features/tic6x-c6xp.c: Generated.
1667 * features/tic6x-core.c: Generated.
1668 * features/tic6x-gp.c: Generated.
1669 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1670 "tic6x-".
1671
1672 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1673
1674 * mi/mi-main.c (list_available_thread_groups): Change map value
1675 type to std::vector.
1676
1677 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1678
1679 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1680
1681 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1682
1683 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1684 back to...
1685 <children_requested>: ... this.
1686 (varobj_get_num_children, varobj_update): Adjust.
1687
1688 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1689
1690 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1691 (ada_value_has_mutated): Likewise.
1692 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1693 (c_is_path_expr_parent): Likewise.
1694 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1695 (mi_cmd_var_set_frozen): Likewise.
1696 (mi_cmd_var_update_iter): Likewise.
1697 (mi_cmd_var_update): Likewise.
1698 * varobj.c (pretty_printing): Likewise.
1699 (varobj_enable_pretty_printing): Likewise.
1700 (struct varobj_root) <floating, is_valid>: Likewise.
1701 (struct varobj_dynamic) <children_requested>: Likewise.
1702 (delete_variable): Likewise.
1703 (delete_variable_1): Likewise.
1704 (install_variable): Likewise.
1705 (update_type_if_necessary): Likewise.
1706 (install_new_value): Likewise.
1707 (value_of_root): Likewise.
1708 (is_root_p): Likewise.
1709 (varobj_create): Likewise.
1710 (varobj_delete): Likewise.
1711 (varobj_has_more): Likewise.
1712 (varobj_set_frozen): Likewise.
1713 (varobj_get_frozen): Likewise.
1714 (install_dynamic_child): Likewise.
1715 (dynamic_varobj_has_child_method): Likewise.
1716 (update_dynamic_varobj_children): Likewise.
1717 (varobj_get_num_children): Likewise.
1718 (varobj_list_children): Likewise.
1719 (is_path_expr_parent): Likewise.
1720 (varobj_default_is_path_expr_parent): Likewise.
1721 (varobj_is_dynamic_p): Likewise.
1722 (varobj_set_value): Likewise.
1723 (varobj_value_has_mutated): Likewise.
1724 (varobj_update): Likewise.
1725 (check_scope): Likewise.
1726 (value_of_root_1): Likewise.
1727 (varobj_value_get_print_value): Likewise.
1728 (varobj_editable_p): Likewise.
1729 (varobj_value_is_changeable_p): Likewise.
1730 (varobj_floating_p): Likewise.
1731 (varobj_default_value_is_changeable_p): Likewise.
1732 (varobj_invalidate_iter): Likewise.
1733 * varobj.h (struct varobj_update_result) <type_changed,
1734 children_changed, changed, value_installed>: Likewise.
1735 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1736 (struct lang_varobj_ops) <value_is_changeable_p,
1737 value_has_mutated, is_path_expr_parent>: Likewise.
1738 (varobj_delete): Likewise.
1739 (varobj_set_frozen): Likewise.
1740 (varobj_get_frozen): Likewise.
1741 (varobj_set_value): Likewise.
1742 (varobj_update): Likewise.
1743 (varobj_editable_p): Likewise.
1744 (varobj_floating_p): Likewise.
1745 (varobj_has_more): Likewise.
1746 (varobj_is_dynamic_p): Likewise.
1747 (varobj_default_value_is_changeable_p): Likewise.
1748 (varobj_value_is_changeable_p): Likewise.
1749 (varobj_is_anonymous_child): Likewise.
1750 (varobj_default_is_path_expr_parent): Likewise.
1751
1752 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1753
1754 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1755 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1756 <type_str>: Convert to 'std::string'.
1757 <expr>: Convert to 'expression_up'.
1758 (dtrace_probe_arg_s): Delete type and VEC.
1759 (dtrace_probe_enabler_s): Likewise.
1760 (struct dtrace_probe): Replace by...
1761 (class dtrace_static_probe_ops): ...this and...
1762 (class dtrace_probe): ...this.
1763 (dtrace_probe_is_linespec): Rename to...
1764 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1765 to reflect change.
1766 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1767 Adjust code. Create new instance of 'dtrace_probe'.
1768 (dtrace_build_arg_exprs): Rename to...
1769 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1770 reflect change.
1771 (dtrace_get_probes): Rename to...
1772 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1773 to reflect change.
1774 (dtrace_get_arg): Rename to...
1775 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1776 reflect change.
1777 (dtrace_probe_is_enabled): Rename to...
1778 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
1779 change.
1780 (dtrace_get_probe_address): Rename to...
1781 (dtrace_probe::get_relocated_address): ...this. Adjust code
1782 to reflect change.
1783 (dtrace_get_probe_argument_count): Rename to...
1784 (dtrace_probe::get_argument_count): ...this. Adjust code to
1785 reflect change.
1786 (dtrace_can_evaluate_probe_arguments): Rename to...
1787 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
1788 to reflect change.
1789 (dtrace_evaluate_probe_argument): Rename to...
1790 (dtrace_probe::evaluate_argument): ...this. Adjust code to
1791 reflect change.
1792 (dtrace_compile_to_ax): Rename to...
1793 (dtrace_probe::compile_to_ax): ...this. Adjust code to
1794 reflect change.
1795 (dtrace_probe_destroy): Delete.
1796 (dtrace_type_name): Rename to...
1797 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
1798 reflect change.
1799 (dtrace_probe::get_static_ops): New method.
1800 (dtrace_gen_info_probes_table_header): Rename to...
1801 (dtrace_static_probe_ops::gen_info_probes_table_header):
1802 ...this. Adjust code to reflect change.
1803 (dtrace_gen_info_probes_table_values): Rename to...
1804 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
1805 code to reflect change.
1806 (dtrace_enable_probe): Rename to...
1807 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
1808 change.
1809 (dtrace_disable_probe): Rename to...
1810 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
1811 change.
1812 (struct probe_ops dtrace_probe_ops): Delete.
1813 (info_probes_dtrace_command): Call 'info_probes_for_spops'
1814 instead of 'info_probes_for_ops'.
1815 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
1816 of 'all_probe_ops'.
1817
1818 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1819 Simon Marchi <simark@simark.ca>
1820
1821 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
1822 variable.
1823 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
1824 <aexpr>: Change type to 'expression_up'.
1825 (stap_probe_arg_s): Delete type and VEC.
1826 (struct stap_probe): Delete. Replace by...
1827 (class stap_static_probe_ops): ...this and...
1828 (class stap_probe): ...this. Rename variables to add 'm_'
1829 prefix. Do not use 'union' for arguments anymore.
1830 (stap_get_expected_argument_type): Receive probe name instead
1831 of 'struct stap_probe'. Adjust code.
1832 (stap_parse_probe_arguments): Rename to...
1833 (stap_probe::parse_arguments): ...this. Adjust code to
1834 reflect change.
1835 (stap_get_probe_address): Rename to...
1836 (stap_probe::get_relocated_address): ...this. Adjust code
1837 to reflect change.
1838 (stap_get_probe_argument_count): Rename to...
1839 (stap_probe::get_argument_count): ...this. Adjust code
1840 to reflect change.
1841 (stap_get_arg): Rename to...
1842 (stap_probe::get_arg_by_number'): ...this. Adjust code to
1843 reflect change.
1844 (can_evaluate_probe_arguments): Rename to...
1845 (stap_probe::can_evaluate_arguments): ...this. Adjust code
1846 to reflect change.
1847 (stap_evaluate_probe_argument): Rename to...
1848 (stap_probe::evaluate_argument): ...this. Adjust code
1849 to reflect change.
1850 (stap_compile_to_ax): Rename to...
1851 (stap_probe::compile_to_ax): ...this. Adjust code to
1852 reflect change.
1853 (stap_probe_destroy): Delete.
1854 (stap_modify_semaphore): Adjust comment.
1855 (stap_set_semaphore): Rename to...
1856 (stap_probe::set_semaphore): ...this. Adjust code to reflect
1857 change.
1858 (stap_clear_semaphore): Rename to...
1859 (stap_probe::clear_semaphore): ...this. Adjust code to
1860 reflect change.
1861 (stap_probe::get_static_ops): New method.
1862 (handle_stap_probe): Adjust code to create instance of
1863 'stap_probe'.
1864 (stap_get_probes): Rename to...
1865 (stap_static_probe_ops::get_probes): ...this. Adjust code to
1866 reflect change.
1867 (stap_probe_is_linespec): Rename to...
1868 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
1869 reflect change.
1870 (stap_type_name): Rename to...
1871 (stap_static_probe_ops::type_name): ...this. Adjust code to
1872 reflect change.
1873 (stap_gen_info_probes_table_header): Rename to...
1874 (stap_static_probe_ops::gen_info_probes_table_header):
1875 ...this. Adjust code to reflect change.
1876 (stap_gen_info_probes_table_values): Rename to...
1877 (stap_probe::gen_info_probes_table_values): ...this. Adjust
1878 code to reflect change.
1879 (struct probe_ops stap_probe_ops): Delete.
1880 (info_probes_stap_command): Use 'info_probes_for_spops'
1881 instead of 'info_probes_for_ops'.
1882 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
1883 of 'all_probe_ops'.
1884
1885 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1886
1887 * break-catch-throw.c (fetch_probe_arguments): Use
1888 'probe.prob' instead of 'probe.probe'.
1889 * breakpoint.c (create_longjmp_master_breakpoint): Call
1890 'can_evaluate_arguments' and 'get_relocated_address' methods
1891 from probe.
1892 (create_exception_master_breakpoint): Likewise.
1893 (add_location_to_breakpoint): Use 'sal->prob' instead of
1894 'sal->probe'.
1895 (bkpt_probe_insert_location): Call 'set_semaphore' method from
1896 probe.
1897 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
1898 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
1899 of 'probe_ops'.
1900 (probe_key_free): Call 'delete' on probe.
1901 (check_exception_resume): Use 'probe.prob' instead of
1902 'probe.probe'.
1903 * location.c (string_to_event_location_basic): Call
1904 'probe_linespec_to_static_ops'.
1905 * probe.c (class any_static_probe_ops): New class.
1906 (any_static_probe_ops any_static_probe_ops): New variable.
1907 (parse_probes_in_pspace): Receive 'static_probe_ops' as
1908 argument. Adjust code to reflect change.
1909 (parse_probes): Use 'static_probe_ops' instead of
1910 'probe_ops'. Adjust code to reflect change.
1911 (find_probes_in_objfile): Call methods to get name and
1912 provider from probe.
1913 (find_probe_by_pc): Use 'result.prob' instead of
1914 'result.probe'. Call 'get_relocated_address' method from
1915 probe.
1916 (collect_probes): Adjust comment and argument list to receive
1917 'static_probe_ops' instead of 'probe_ops'. Adjust code to
1918 reflect change. Call necessary methods from probe.
1919 (compare_probes): Call methods to get name and provider from
1920 probes.
1921 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
1922 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
1923 adjust code accordingly.
1924 (print_ui_out_not_applicables): Likewise.
1925 (info_probes_for_ops): Rename to...
1926 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
1927 as argument instead of 'probe_ops'. Adjust code. Call
1928 necessary methods from probe.
1929 (info_probes_command): Use 'info_probes_for_spops'.
1930 (enable_probes_command): Pass correct argument to
1931 'collect_probes'. Call methods from probe.
1932 (disable_probes_command): Likewise.
1933 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
1934 (get_probe_argument_count): Move to
1935 'any_static_probe_ops::get_argument_count'.
1936 (can_evaluate_probe_arguments): Move to
1937 'any_static_probe_ops::can_evaluate_arguments'.
1938 (evaluate_probe_argument): Move to
1939 'any_static_probe_ops::evaluate_argument'.
1940 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
1941 'probe.probe'.
1942 (probe_linespec_to_ops): Rename to...
1943 (probe_linespec_to_static_ops): ...this. Adjust code.
1944 (probe_any_is_linespec): Rename to...
1945 (any_static_probe_ops::is_linespec): ...this.
1946 (probe_any_get_probes): Rename to...
1947 (any_static_probe_ops::get_probes): ...this.
1948 (any_static_probe_ops::type_name): New method.
1949 (any_static_probe_ops::gen_info_probes_table_header): New
1950 method.
1951 (compute_probe_arg): Use 'pc_probe.prob' instead of
1952 'pc_probe.probe'. Call methods from probe.
1953 (compile_probe_arg): Likewise.
1954 (std::vector<const probe_ops *> all_probe_ops): Delete.
1955 (std::vector<const static_probe_ops *> all_static_probe_ops):
1956 New variable.
1957 (_initialize_probe): Use 'all_static_probe_ops' instead of
1958 'all_probe_ops'.
1959 * probe.h (struct info_probe_column) <field_name>: Delete
1960 extraneous newline
1961 (info_probe_column_s): Delete type and VEC.
1962 (struct probe_ops): Delete. Replace with...
1963 (class static_probe_ops): ...this and...
1964 (clas probe): ...this.
1965 (struct bound_probe) <bound_probe>: Delete extraneous
1966 newline. Adjust constructor to receive 'probe' instead of
1967 'struct probe'.
1968 <probe>: Rename to...
1969 <prob>: ...this. Delete extraneous newline.
1970 <objfile>: Delete extraneous newline.
1971 (register_probe_ops): Delete unused prototype.
1972 (info_probes_for_ops): Rename to...
1973 (info_probes_for_spops): ...this. Adjust comment.
1974 (get_probe_address): Move to 'probe::get_address'.
1975 (get_probe_argument_count): Move to
1976 'probe::get_argument_count'.
1977 (can_evaluate_probe_arguments): Move to
1978 'probe::can_evaluate_arguments'.
1979 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
1980 * solib-svr4.c (struct svr4_info): Adjust comment.
1981 (struct probe_and_action) <probe>: Rename to...
1982 <prob>: ...this.
1983 (register_solib_event_probe): Receive 'probe' instead of
1984 'struct probe' as argument. Use 'prob' instead of 'probe'
1985 when applicable.
1986 (solib_event_probe_action): Call 'get_argument_count' method
1987 from probe. Adjust comment.
1988 (svr4_handle_solib_event): Adjust comment. Call
1989 'evaluate_argument' method from probe.
1990 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
1991 from probe.
1992 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
1993 'struct probe'. Call 'can_evaluate_arguments' from probe.
1994 * symfile.h: Forward declare 'class probe' instead of 'struct
1995 probe'.
1996 * symtab.h: Likewise.
1997 (struct symtab_and_line) <probe>: Rename to...
1998 <prob>: ...this.
1999 * tracepoint.c (start_tracing): Use 'prob' when applicable.
2000 Call probe methods.
2001 (stop_tracing): Likewise.
2002
2003 2017-11-22 Joel Brobecker <brobecker@adacore.com>
2004
2005 * ravenscar-thread.c (ravenscar_inferior_created): Remove
2006 trailing newline at end of string in call to warning.
2007
2008 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2009
2010 * osdata.h: Include vector isntead of vec.h.
2011 (osdata_column_s): Remove typedef.
2012 (struct osdata_column): Add constructor.
2013 <name, value>: Change type to std::string.
2014 (DEF_VEC_O (osdata_column_s)): Remove.
2015 (osdata_item_s): Remove typedef.
2016 (struct osdata_item) <columns>: Change type to std::vector.
2017 (DEF_VEC_O (osdata_item_s)): Remove.
2018 (struct osdata): Add constructor.
2019 <type>: Change type to std::string.
2020 <items>: Change type to std::vector.
2021 (osdata_p): Remove typedef.
2022 (DEF_VEC_P (osdata_p)): Remove.
2023 (osdata_parse): Return a unique_ptr.
2024 (osdata_free): Remove.
2025 (make_cleanup_osdata_free): Remove.
2026 (get_osdata): Return a unique_ptr.
2027 (get_osdata_column): Return pointer to std::string, take a
2028 reference to osdata_item as parameter.
2029 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
2030 unique_ptr.
2031 <property_name>: Change type to std::string.
2032 (osdata_start_osdata): Allocate osdata with new and adjust.
2033 (osdata_start_item): Adjust.
2034 (osdata_start_column): Adjust.
2035 (osdata_end_column): Adjust.
2036 (clear_parsing_data): Remove.
2037 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
2038 (osdata_item_clear): Remove.
2039 (get_osdata): return a unique_ptr and adjust.
2040 (get_osdata_column): Return a pointer to std::string and adjust.
2041 (info_osdata): Adjust.
2042 * mi/mi-main.c: Include <map>.
2043 (free_vector_of_osdata_items): Remove.
2044 (list_available_thread_groups): Adjust, use std::map instead of
2045 splay tree.
2046
2047 2017-11-22 Simon Marchi <simon.marchi@ericsson.com>
2048
2049 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
2050 case in switch.
2051
2052 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2053
2054 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
2055
2056 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2057
2058 * varobj.h (struct varobj_update_result): Add constructor, add
2059 move constructor, disable copy and assign, initialize fields.
2060 <newobj>: Change type to std::vector.
2061 (varobj_update): Return std::vector.
2062 * varobj.c (install_dynamic_child): Change VEC parameters to
2063 std::vector and adjust.
2064 (update_dynamic_varobj_children): Likewise.
2065 (varobj_update): Return std::vector and adjust.
2066 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
2067
2068 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2069
2070 * varobj.h (struct varobj) <parent>: Remove const.
2071 <children>: Change type to std::vector.
2072 (varobj_list_children): Return std::vector const reference.
2073 (varobj_restrict_range): Change parameter type to std::vector
2074 const reference.
2075 * varobj.c (varobj_has_more): Adjust.
2076 (varobj_restrict_range): Change parameter type to std::vector
2077 const reference and adjust.
2078 (install_dynamic_child): Adjust.
2079 (update_dynamic_varobj_children): Adjust.
2080 (varobj_list_children): Return std::vector const reference and
2081 adjust.
2082 (varobj_add_child): Adjust.
2083 (update_type_if_necessary): Adjust.
2084 (varobj_update): Adjust.
2085 (delete_variable_1): Adjust.
2086 * ada-varobj.c (ada_value_has_mutated): Adjust.
2087 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
2088
2089 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2090
2091 * varobj.h (struct varobj): Add constructor and destructor,
2092 initialize fields.
2093 * varobj.c (struct varobj_root): Initialize fields.
2094 (struct varobj_dynamic): Initialize fields.
2095 (varobj_create): Use unique_ptr instead of cleanup. Create
2096 varobj with new instead of new_root_variable.
2097 (delete_variable_1): Free variable with delete instead of
2098 free_variable.
2099 (create_child_with_value): Create variable with new instead of
2100 new_variable.
2101 (varobj::varobj): New.
2102 (varobj::~varobj): New (body mostly coming from free_variable).
2103 (new_variable): Remove.
2104 (free_variable): Remove.
2105 (do_free_variable_cleanup): Remove.
2106 (make_cleanup_free_variable): Remove.
2107
2108 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2109
2110 * core-regset.c: Remove file.
2111 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
2112
2113 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2114
2115 * NEWS: Document use of GNU MPFR.
2116 * README: Likewise.
2117
2118 * Makefile.in (LIBMPFR): Add define.
2119 (CLIBS): Add $(LIBMPFR).
2120 * configure.ac: Add --with-mpfr configure option.
2121 * configure: Regenerate.
2122 * config.in: Regenerate.
2123
2124 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
2125 (class mpfr_float_ops): New type.
2126 (mpfr_float_ops::from_target): Two new overloaded functions.
2127 (mpfr_float_ops::to_target): Likewise.
2128 (mpfr_float_ops::to_string): New function.
2129 (mpfr_float_ops::from_string): Likewise.
2130 (mpfr_float_ops::to_longest): Likewise.
2131 (mpfr_float_ops::from_longest): Likewise.
2132 (mpfr_float_ops::from_ulongest): Likewise.
2133 (mpfr_float_ops::to_host_double): Likewise.
2134 (mpfr_float_ops::from_host_double): Likewise.
2135 (mpfr_float_ops::convert): Likewise.
2136 (mpfr_float_ops::binop): Likewise.
2137 (mpfr_float_ops::compare): Likewise.
2138 (get_target_float_ops): Use mpfr_float_ops if available.
2139
2140 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2141
2142 * target-float.c: Do not include <math.h>.
2143 Include <cmath> and <limits>.
2144 (DOUBLEST): Do not define.
2145 (class target_float_ops): New type.
2146 (class host_float_ops): New templated type.
2147 (class decimal_float_ops): New type.
2148
2149 (floatformat_to_doublest): Rename to ...
2150 (host_float_ops<T>::from_target): ... this. Use template type T
2151 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2152 (host_float_ops<T>::from_target): New overload using a type argument.
2153 (floatformat_from_doublest): Rename to ...
2154 (host_float_ops<T>::to_target): ... this. Use template type T
2155 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2156 (host_float_ops<T>::to_target): New overload using a type argument.
2157 (floatformat_printf_format): New function.
2158 (struct printf_length_modifier): New templated type.
2159 (floatformat_to_string): Rename to ...
2160 (host_float_ops<T>::to_string): ... this. Use type instead of
2161 floatformat argument. Use floatformat_printf_format and
2162 printf_length_modifier. Remove special handling of invalid numbers,
2163 infinities and NaN (moved to target_float_to_string).
2164 (struct scanf_length_modifier): New templated type.
2165 (floatformat_from_string): Rename to ...
2166 (host_float_ops<T>::from_string): ... this. Use type instead of
2167 floatformat argument. Use scanf_length_modifier.
2168 (floatformat_to_longest): Rename to ...
2169 (host_float_ops<T>::to_longest): ... this. Use type instead of
2170 floatformat argument. Handle out-of-range values deterministically.
2171 (floatformat_from_longest): Rename to ...
2172 (host_float_ops<T>::from_longest): ... this. Use type instead of
2173 floatformat argument.
2174 (floatformat_from_ulongest): Rename to ...
2175 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
2176 floatformat argument.
2177 (floatformat_to_host_double): Rename to ...
2178 (host_float_ops<T>::to_host_double): ... this. Use type instead of
2179 floatformat argument.
2180 (floatformat_from_host_double): Rename to ...
2181 (host_float_ops<T>::from_host_double): ... this. Use type instead of
2182 floatformat argument.
2183 (floatformat_convert): Rename to ...
2184 (host_float_ops<T>::convert): ... this. Use type instead of
2185 floatformat arguments. Remove handling of no-op conversions.
2186 (floatformat_binop): Rename to ...
2187 (host_float_ops<T>::binop): ... this. Use type instead of
2188 floatformat arguments.
2189 (floatformat_compare): Rename to ...
2190 (host_float_ops<T>::compare): ... this. Use type instead of
2191 floatformat arguments.
2192
2193 (match_endianness): Use type instead of length/byte_order arguments.
2194 (set_decnumber_context): Likewise.
2195 (decimal_from_number): Likewise. Update calls.
2196 (decimal_to_number): Likewise.
2197 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
2198 (decimal_float_ops::to_host_double): New dummy function.
2199 (decimal_float_ops::from_host_double): Likewise.
2200 (decimal_to_string): Rename to ...
2201 (decimal_float_ops::to_string): ... this. Use type instead of
2202 length/byte_order arguments. Update calls.
2203 (decimal_from_string): Rename to ...
2204 (decimal_float_ops::from_string): ... this. Use type instead of
2205 length/byte_order arguments. Update calls.
2206 (decimal_from_longest): Rename to ...
2207 (decimal_float_ops::from_longest): ... this. Use type instead of
2208 length/byte_order arguments. Update calls.
2209 (decimal_from_ulongest): Rename to ...
2210 (decimal_float_ops::from_ulongest): ... this. Use type instead of
2211 length/byte_order arguments. Update calls.
2212 (decimal_to_longest): Rename to ...
2213 (decimal_float_ops::to_longest): ... this. Use type instead of
2214 length/byte_order arguments. Update calls.
2215 (decimal_binop): Rename to ...
2216 (decimal_float_ops::binop): ... this. Use type instead of
2217 length/byte_order arguments. Update calls.
2218 (decimal_compare): Rename to ...
2219 (decimal_float_ops::compare): ... this. Use type instead of
2220 length/byte_order arguments. Update calls.
2221 (decimal_convert): Rename to ...
2222 (decimal_float_ops::convert): ... this. Use type instead of
2223 length/byte_order arguments. Update calls.
2224
2225 (target_float_same_category_p): New function.
2226 (target_float_same_format_p): Likewise.
2227 (target_float_format_length): Likewise.
2228 (enum target_float_ops_kind): New type.
2229 (get_target_float_ops_kind): New function.
2230 (get_target_float_ops): Three new overloaded functions.
2231
2232 (target_float_is_zero): Update call.
2233 (target_float_to_string): Add special handling of invalid numbers,
2234 infinities and NaN (moved from floatformat_to_string). Use
2235 target_float_ops callback.
2236 (target_float_from_string): Use target_float_ops callback.
2237 (target_float_to_longest): Likewise.
2238 (target_float_from_longest): Likewise.
2239 (target_float_from_ulongest): Likewise.
2240 (target_float_to_host_double): Likewise.
2241 (target_float_from_host_double): Likewise.
2242 (target_float_convert): Add special case for no-op conversions.
2243 Use target_float_ops callback.
2244 (target_float_binop): Use target_float_ops callback.
2245 (target_float_compare): Likewise.
2246
2247 2017-11-22 Yao Qi <yao.qi@linaro.org>
2248
2249 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
2250
2251 2017-11-22 Yao Qi <yao.qi@linaro.org>
2252
2253 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
2254 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
2255
2256 2017-11-21 Jerome Guitton <guitton@adacore.com>
2257
2258 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
2259 with event ptid from the lower layer before doing the
2260 ravenscar-specific update.
2261
2262 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2263
2264 * ravenscar-thread.c (is_ravenscar_task): Also verify that
2265 the ptid's TID is nonzero.
2266
2267 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2268
2269 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
2270 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
2271 Make non-static. Change return type to char *. Adjust code
2272 accordingly. Rewrite the function's documentation.
2273 (read_atcb): Adjust call to get_tcb_types_info accordingly.
2274 * ravenscar-thread.c (ravenscar_inferior_created): Check that
2275 we have enough debugging information in the runtime to support
2276 Ada task debugging before we enable the ravenscar-thread layer.
2277
2278 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2279
2280 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
2281 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
2282 * ravenscar-thread.c: Add into comment.
2283 (base_magic_null_ptid): Delete.
2284 (base_ptid): Change documentation.
2285 (ravenscar_active_task): Renames ravenscar_running_thread.
2286 All callers updated throughout.
2287 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
2288 (ravenscar_task_is_currently_active): Likewise.
2289 (get_base_thread_from_ravenscar_task): Ditto.
2290 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
2291 (ravenscar_runtime_initialized): Likewise.
2292 (get_running_thread_id): Add new parameter "cpu". Adjust
2293 implementation to handle this new parameter.
2294 (ravenscar_fetch_registers): Small adjustment to use
2295 is_ravenscar_task and ravenscar_task_is_currently_active in
2296 order to decide whether to use the target beneath or this
2297 module's arch_ops.
2298 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
2299 (ravenscar_stopped_by_sw_breakpoint): Use
2300 get_base_thread_from_ravenscar_task to get the underlying
2301 thread, rather than using base_ptid.
2302 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2303 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2304 Likewise.
2305 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
2306
2307 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2308
2309 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
2310 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
2311 (get_tcb_types_info): Set fieldnos.base_cpu.
2312 (read_atcb): Set task_info->base_cpu.
2313 (info_task): Print "Base CPU" info if set by runtime.
2314
2315 2017-11-21 Joel Brobecker <brobecker@adacore.com>
2316
2317 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
2318 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2319 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2320 New functions.
2321 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
2322 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
2323 to_stopped_data_address and to_core_of_thread fields of
2324 ravenscar_ops.
2325
2326 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
2327
2328 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
2329 (struct gdbarch_tdep): New member long_double_abi.
2330 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
2331 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
2332 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
2333 format depending on long_double_abi tdep member.
2334 (ppc_floatformat_for_type): Handle __ibm128 type.
2335
2336 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
2337
2338 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
2339
2340 2017-11-21 Pedro Alves <palves@redhat.com>
2341
2342 * dwarf2read.c (mapped_index::find_name_components_bounds)
2343 <completion mode, upper bound>: Use std::lower_bound instead of
2344 std::upper_bound.
2345 (test_mapped_index_find_name_component_bounds): Remove incorrect
2346 "t1_fund" from expected symbols.
2347
2348 2017-11-21 Pedro Alves <palves@redhat.com>
2349
2350 * dwarf2read.c (mapped_index::name_components_casing): New field.
2351 (mapped_index) <build_name_components,
2352 find_name_components_bounds): Declare new methods.
2353 (mapped_index::find_name_components_bounds)
2354 (mapped_index::build_name_components): New methods, factored out
2355 from dw2_expand_symtabs_matching_symbol.
2356 (check_find_bounds_finds)
2357 (test_mapped_index_find_name_component_bounds): New.
2358 (run_test): Rename to ...
2359 (test_dw2_expand_symtabs_matching_symbol): ... this.
2360 (run_test): Reimplement.
2361
2362 2017-11-21 Pedro Alves <palves@redhat.com>
2363
2364 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
2365 (symbol_end): Use cp_ident_is_alnum.
2366 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
2367 * dwarf2read.c (make_sort_after_prefix_name): New function.
2368 (dw2_expand_symtabs_matching_symbol): Use it.
2369 (test_symbols): Add more symbols.
2370 (run_test): Add tests.
2371
2372 2017-11-17 Tom Tromey <tom@tromey.com>
2373
2374 * symtab.h (enum symbol_subclass_kind): New.
2375 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
2376 Remove.
2377 <subclass>: New member.
2378 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
2379 * rust-lang.c (rust_get_trait_object_pointer): Update.
2380 * dwarf2read.c (read_func_scope): Update.
2381 (read_variable): Update.
2382
2383 2017-11-17 Tom Tromey <tom@tromey.com>
2384
2385 * dwarf2read.c (read_func_scope): Update.
2386 * symtab.h (struct template_symbol): Derive from symbol.
2387 <base>: Remove.
2388
2389 2017-11-17 Tom Tromey <tom@tromey.com>
2390
2391 * symtab.h (struct symbol) <is_rust_vtable>: New member.
2392 (struct rust_vtable_symbol): New.
2393 (find_symbol_at_address): Declare.
2394 * symtab.c (find_symbol_at_address): New function.
2395 * symfile.h (struct quick_symbol_functions)
2396 <find_compunit_symtab_by_address>: New member.
2397 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
2398 function.
2399 (debug_sym_quick_functions): Link to
2400 debug_qf_find_compunit_symtab_by_address.
2401 * rust-lang.c (rust_get_trait_object_pointer): New function.
2402 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
2403 rust_get_trait_object_pointer.
2404 * psymtab.c (psym_relocate): Clear psymbol_map.
2405 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
2406 functions.
2407 (psym_functions): Link to psym_find_compunit_symtab_by_address.
2408 * objfiles.h (struct objfile) <psymbol_map>: New member.
2409 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
2410 (process_die) <DW_TAG_variable>: New case. Call read_variable.
2411 (rust_containing_type, read_variable): New functions.
2412
2413 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2414
2415 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
2416
2417 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2418
2419 * common/filestuff.c: Include <algorithm>.
2420 (open_fds): Change type to std::vector<int>.
2421 (do_mark_open_fd): Adjust.
2422 (unmark_fd_no_cloexec): Adjust.
2423 (do_close): Adjust.
2424
2425 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2426
2427 * breakpoint.c (output_thread_groups): Take an std::vector.
2428 (print_one_breakpoint_location): Adjust.
2429
2430 2017-11-17 Joel Brobecker <brobecker@adacore.com>
2431
2432 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2433 (ada_evaluate_subexp_for_cast): New function.
2434 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2435 ada_evaluate_subexp_for_cast.
2436 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2437 eval_skip_value.
2438 * eval.c (evaluate_var_value): Make non-static.
2439 (evaluate_var_msym_value, eval_skip_value): Likewise.
2440 * value.h (evaluate_var_value, evaluate_var_msym_value)
2441 (eval_skip_value): Declare.
2442
2443 2017-11-16 Joel Brobecker <brobecker@adacore.com>
2444
2445 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2446 Update all callers.
2447
2448 2017-11-16 Pedro Alves <palves@redhat.com>
2449
2450 * python/py-unwind.c (pyuw_sniffer): Translate
2451 PyExc_KeyboardInterrupt to a GDB Quit exception.
2452
2453 2017-11-16 Pedro Alves <palves@redhat.com>
2454
2455 * infrun.c (resume_cleanups): Delete.
2456 (resume): No longer install a resume_cleanups cleanup nor call
2457 QUIT.
2458 (proceed): Pass the terminal to the inferior.
2459 (keep_going_pass_signal): No longer install a resume_cleanups
2460 cleanup.
2461
2462 2017-11-16 Pedro Alves <palves@redhat.com>
2463
2464 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2465 if the prompt is blocked.
2466
2467 2017-11-16 Pedro Alves <palves@redhat.com>
2468
2469 * breakpoint.c (insert_bp_location): Replace bp_err and
2470 bp_err_message locals by a gdb_exception local.
2471
2472 2017-11-16 Pedro Alves <palves@redhat.com>
2473
2474 * inflow.c (scoped_ignore_sigttou): New class.
2475 (child_terminal_ours_1, new_tty): Use it.
2476
2477 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2478
2479 * target-float.c (decimal_from_number): Add byte_order argument and
2480 call match_endianness. Error if unknown floating-point type.
2481 (decimal_to_number): Add byte_order argument and call match_endianness.
2482 (decimal_from_longest): Update call. Do not call match_endianness.
2483 (decimal_from_ulongest): Likewise.
2484 (decimal_binop): Likewise.
2485 (decimal_is_zero): Likewise.
2486 (decimal_compare): Likewise.
2487 (decimal_convert): Likewise.
2488
2489 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2490
2491 * python/python.c (gdbpy_rbreak): New function.
2492 * NEWS: Document Python rbreak feature.
2493
2494 2017-11-16 Yao Qi <yao.qi@linaro.org>
2495
2496 * features/tic6x-c62x.xml: Remove.
2497 * features/tic6x-c64x.xml: Remove.
2498 * features/tic6x-c64xp.xml: Remove.
2499
2500 2017-11-15 John Baldwin <jhb@FreeBSD.org>
2501
2502 * symtab.h: Include <array>.
2503
2504 2017-11-15 John Baldwin <jhb@FreeBSD.org>
2505
2506 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2507 (bsd_kvm_proc_cmd): Likewise.
2508
2509 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2510
2511 * tui/tui-win.c (window_name_completer): Replace VEC with
2512 std::vector.
2513
2514 2017-11-15 Andrew Cagney <cagney@gnu.org>
2515
2516 * MAINTAINERS: Remove no-longer applicable entries.
2517
2518 2017-11-15 Andrew Cagney <cagney@gnu.org>
2519
2520 * MAINTAINERS: Move self to Past Maintainers.
2521
2522 2017-11-15 Yao Qi <yao.qi@linaro.org>
2523
2524 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2525 * features/nios2-linux.c: Remove.
2526 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2527 initialize_tdesc_nios2_linux.
2528
2529 2017-11-15 Yao Qi <yao.qi@linaro.org>
2530
2531 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2532 M68HC11_LAST_HARD_REG + 1.
2533
2534 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2535
2536 PR gdb/22388
2537 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2538 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2539 Return TARGET_XFER_EOF if size of returned data is 0.
2540
2541 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2542
2543 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2544 memory-map-selftests.c.
2545 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2546 * memory-map.c (memory_map_start_memory): Fix computation of hi
2547 address.
2548 * unittests/memory-map-selftests.c: New file.
2549
2550 2017-11-09 Joel Brobecker <brobecker@adacore.com>
2551
2552 * ada-lang.c: Fix some typos in the general command documenting
2553 how Ada expressions are being evaluated and how their result
2554 is printed.
2555
2556 2017-11-09 Tom Tromey <tom@tromey.com>
2557
2558 * psymtab.c (psymbol_hash): Do not hash string contents.
2559 (psymbol_compare): Add comment.
2560
2561 2017-11-09 Tom Tromey <tom@tromey.com>
2562
2563 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2564
2565 2017-11-08 Joel Brobecker <brobecker@adacore.com>
2566
2567 * ada-exp.y (write_var_from_sym): Remove parameter
2568 "orig_left_context". Update all callers.
2569
2570 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2571
2572 * tracepoint.h (class collection_list) <stringify>: Return
2573 std::vector<std::string>.
2574 (encode_actions_rsp): Change parameters to
2575 std::vector<std::string> *.
2576 * tracepoint.c (collection_list::stringify): Return
2577 std::vector<std::string> and adjust accordingly.
2578 (encode_actions_rsp): Changee parameters to
2579 std::vector<std::string> and adjust accordingly.
2580 * remote.c (free_actions_list),
2581 free_actions_list_cleanup_wrapper): Remove.
2582 (remote_download_tracepoint): Adjust to std::vector.
2583
2584 2017-11-08 Tom Tromey <tom@tromey.com>
2585
2586 * dwarf2read.c (symbolp): Remove typedef.
2587 (read_func_scope): Use std::vector.
2588 (process_structure_scope): Use std::vector.
2589
2590 2017-11-08 Pedro Alves <palves@redhat.com>
2591
2592 * ada-lang.c (ada_make_symbol_completion_list): Use
2593 completion_skip_symbol.
2594 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2595 (symbol_is_function_or_method(symbol*)): New.
2596 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2597 completion_skip_symbol.
2598 (default_collect_symbol_completion_matches_break_on): Use
2599 completion_skip_symbol. Pass down mode.
2600 (collect_file_symbol_completion_matches): Pass down mode.
2601 * symtab.h (symbol_is_function_or_method): New declarations.
2602 (completion_skip_symbol): New template function.
2603
2604 2017-11-08 Pedro Alves <palves@redhat.com>
2605
2606 * linespec.c (iterate_over_all_matching_symtabs): Add
2607 search_domain parameter. Pass it down to expand_symtabs_matching.
2608 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2609 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2610 search_domain.
2611 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2612 Pass it down.
2613 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2614 symbols.
2615 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2616 it down.
2617
2618 2017-11-08 Pedro Alves <palves@redhat.com>
2619
2620 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2621 text_len locals and don't pass them down.
2622 * symtab.c (completion_list_add_name): Remove
2623 sym_text/sym_text_len parameters and adjust.
2624 (completion_list_add_symbol, completion_list_add_msymbol)
2625 (completion_list_objc_symbol, completion_list_add_fields)
2626 (add_symtab_completions): Likewise.
2627 (default_collect_symbol_completion_matches_break_on)
2628 (collect_file_symbol_completion_matches): Remove sym_text_len
2629 local and don't pass it down.
2630 * symtab.h (completion_list_add_name): Remove
2631 sym_text/sym_text_len parameters.
2632
2633 2017-11-08 Pedro Alves <palves@redhat.com>
2634
2635 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2636 unittests/lookup_name_info-selftests.c.
2637 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2638 * cp-support.c: Include "selftest.h".
2639 (cp_remove_params_1): Rename from cp_remove_params. Add
2640 'require_param' parameter, and handle it.
2641 (cp_remove_params): Reimplement.
2642 (cp_remove_params_if_any): New.
2643 (selftests::quote): New.
2644 (selftests::check_remove_params): New.
2645 (selftests::test_cp_remove_params): New.
2646 (_initialize_cp_support): Install
2647 selftests::test_cp_remove_params.
2648 * cp-support.h (cp_remove_params_if_any): Declare.
2649 * dwarf2read.c :Include "selftest.h".
2650 (dw2_expand_symtabs_matching_symbol): Use
2651 lookup_name_info::make_ignore_params.
2652 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2653 (selftests::dw2_expand_symtabs_matching::string_or_null)
2654 (selftests::dw2_expand_symtabs_matching::check_match)
2655 (selftests::dw2_expand_symtabs_matching::test_symbols)
2656 (selftests::dw2_expand_symtabs_matching::run_test): New.
2657 (_initialize_dwarf2_read): Register
2658 selftests::dw2_expand_symtabs_matching::run_test.
2659 * psymtab.c (psym_expand_symtabs_matching): Use
2660 lookup_name_info::make_ignore_params.
2661 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2662 If the lookup name wants to ignore parameters, strip them.
2663 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2664 code handling '('.
2665 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2666 (default_collect_symbol_completion_matches_break_on): Don't try to
2667 strip parameters.
2668 * symtab.h (lookup_name_info::lookup_name_info): Add
2669 'ignore_parameters' parameter.
2670 (lookup_name_info::ignore_parameters)
2671 (lookup_name_info::make_ignore_params): New methods.
2672 (lookup_name_info::m_ignore_parameters): New field.
2673 * unittests/lookup_name_info-selftests.c: New file.
2674
2675 2017-11-08 Pedro Alves <palves@redhat.com>
2676
2677 * dwarf2read.c (dw2_expand_marked_cus)
2678 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2679 (dw2_expand_symtabs_matching): Move further below.
2680 (dw2_expand_marked_cus): Reindent.
2681
2682 2017-11-08 Pedro Alves <palves@redhat.com>
2683
2684 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2685 (struct name_component): New.
2686 (mapped_index::name_components): New field.
2687 (mapped_index::symbol_name_at): New method.
2688 (dwarf2_read_index): Call mapped_index ctor.
2689 (dw2_map_matching_symbols): Add comment about name_components
2690 table.
2691 (dw2_expand_symtabs_matching): Factor part to...
2692 (dw2_expand_symtabs_matching_symbol): ... this new function.
2693 Build name components table, and lookup symbols in it before
2694 calling the name matcher.
2695 (dw2_expand_marked_cus): New, factored out from
2696 dw2_expand_symtabs_matching.
2697 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2698
2699 2017-11-08 Pedro Alves <palves@redhat.com>
2700
2701 * ada-lang.c (ada_encode): Rename to ..
2702 (ada_encode_1): ... this. Add throw_errors parameter and handle
2703 it.
2704 (ada_encode): Reimplement.
2705 (match_name): Delete, folded into full_name.
2706 (resolve_subexp): No longer pass the encoded name to
2707 ada_lookup_symbol_list.
2708 (should_use_wild_match): Delete.
2709 (name_match_type_from_name): New.
2710 (ada_lookup_simple_minsym): Use lookup_name_info and the
2711 language's symbol_name_matcher_ftype.
2712 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2713 (ada_add_block_renamings): Adjust to use lookup_name_info.
2714 (ada_lookup_name): New.
2715 (add_nonlocal_symbols, ada_add_all_symbols)
2716 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2717 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2718 (ada_name_for_lookup): Delete.
2719 (ada_lookup_encoded_symbol): Construct a verbatim name.
2720 (wild_match): Reverse sense of return type. Use bool.
2721 (full_match): Reverse sense of return type. Inline bits of old
2722 match_name here.
2723 (ada_add_block_symbols): Adjust to use lookup_name_info.
2724 (symbol_completion_match): Delete, folded into...
2725 (ada_lookup_name_info::matches): ... .this new method.
2726 (symbol_completion_add): Delete.
2727 (ada_collect_symbol_completion_matches): Add name_match_type
2728 parameter. Adjust to use lookup_name_info and
2729 completion_list_add_name.
2730 (get_var_value, ada_add_global_exceptions): Adjust to use
2731 lookup_name_info.
2732 (ada_get_symbol_name_cmp): Delete.
2733 (do_wild_match, do_full_match): New functions.
2734 (ada_lookup_name_info::ada_lookup_name_info): New method.
2735 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2736 functions.
2737 (ada_language_defn): Install ada_get_symbol_name_matcher.
2738 * ada-lex.l (processId): If name starts with '<', copy it
2739 verbatim.
2740 * block.c (block_iter_match_step, block_iter_match_first)
2741 (block_iter_match_next, block_lookup_symbol)
2742 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2743 lookup_name_info.
2744 * block.h (block_iter_match_first, block_iter_match_next)
2745 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2746 * c-lang.c (c_language_defn, cplus_language_defn)
2747 (asm_language_defn, minimal_language_defn): Adjust comments to
2748 refer to la_get_symbol_name_matcher.
2749 * completer.c (complete_files_symbols)
2750 (collect_explicit_location_matches, symbol_completer): Pass a
2751 symbol_name_match_type down.
2752 * completer.h (class completion_match, completion_match_result):
2753 New classes.
2754 (completion_tracker::reset_completion_match_result): New method.
2755 (completion_tracker::m_completion_match_result): New field.
2756 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2757 lookup_name_info.
2758 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2759 functions.
2760 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2761 * d-lang.c: Adjust comments to refer to
2762 la_get_symbol_name_matcher.
2763 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2764 Adjust to use lookup_name_info.
2765 (dict_iter_match_first, dict_iter_match_next)
2766 (iter_match_first_hashed, iter_match_next_hashed)
2767 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2768 with a lookup_name_info.
2769 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2770 Likewise.
2771 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2772 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2773 (gdb_index_symbol_name_matcher): New class.
2774 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2775 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2776 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2777 with a symbol_name_match_type.
2778 (f_language_defn): Adjust comments to refer to
2779 la_get_symbol_name_matcher.
2780 * go-lang.c (go_language_defn): Adjust comments to refer to
2781 la_get_symbol_name_matcher.
2782 * language.c (default_symbol_name_matcher)
2783 (language_get_symbol_name_matcher): New functions.
2784 (unknown_language_defn, auto_language_defn): Adjust comments to
2785 refer to la_get_symbol_name_matcher.
2786 * language.h (symbol_name_cmp_ftype): Delete.
2787 (language_defn) <la_collect_symbol_completion_matches>: Add match
2788 type parameter.
2789 <la_get_symbol_name_cmp>: Delete field.
2790 <la_get_symbol_name_matcher>: New field.
2791 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
2792 (default_symbol_name_matcher, language_get_symbol_name_matcher):
2793 Declare.
2794 * linespec.c (iterate_over_all_matching_symtabs)
2795 (iterate_over_file_blocks): Adjust to use lookup_name_info.
2796 (find_methods): Add language parameter, and use lookup_name_info
2797 and the language's symbol_name_matcher_ftype.
2798 (linespec_complete_function): Adjust.
2799 (lookup_prefix_sym): Use lookup_name_info.
2800 (add_all_symbol_names_from_pspace): Adjust.
2801 (find_superclass_methods): Add language parameter and pass it
2802 down.
2803 (find_method): Pass symbol language down.
2804 (find_linespec_symbols): Don't demangle or Ada encode here.
2805 (search_minsyms_for_name): Add lookup_name_info parameter.
2806 (add_matching_symbols_to_info): Add name_match_type parameter.
2807 Use lookup_name_info.
2808 * m2-lang.c (m2_language_defn): Adjust comments to refer to
2809 la_get_symbol_name_matcher.
2810 * minsyms.c: Include <algorithm>.
2811 (add_minsym_to_demangled_hash_table): Remove table parameter and
2812 add objfile parameter. Use search_name_hash, and add language to
2813 demangled languages vector.
2814 (struct found_minimal_symbols): New struct.
2815 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
2816 New functions.
2817 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
2818 input names here. Use lookup_name_info instead. Lookup up
2819 demangled names once for each language in the demangled names
2820 vector.
2821 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
2822 demangled names once for each language in the demangled names
2823 vector.
2824 (build_minimal_symbol_hash_tables): Adjust.
2825 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
2826 lookup_name_info.
2827 * objc-lang.c (objc_language_defn): Adjust comment to refer to
2828 la_get_symbol_name_matcher.
2829 * objfiles.h: Include <vector>.
2830 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
2831 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
2832 la_get_symbol_name_matcher.
2833 * p-lang.c (pascal_language_defn): Adjust comment to refer to
2834 la_get_symbol_name_matcher.
2835 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
2836 (match_partial_symbol): Use symbol_name_match_type,
2837 lookup_name_info and psymbol_name_matches.
2838 (lookup_partial_symbol): Use lookup_name_info.
2839 (map_block): Use symbol_name_match_type and lookup_name_info.
2840 (psym_map_matching_symbols): Use symbol_name_match_type.
2841 (psymbol_name_matches): New.
2842 (recursively_search_psymtabs): Use lookup_name_info and
2843 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
2844 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
2845 'kind' parameter to 'domain'.
2846 * rust-lang.c (rust_language_defn): Adjust comment to refer to
2847 la_get_symbol_name_matcher.
2848 * symfile-debug.c (debug_qf_map_matching_symbols)
2849 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
2850 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
2851 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
2852 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
2853 Adjust to use symbol_name_match_type.
2854 <expand_symtabs_matching>: Adjust to use lookup_name_info.
2855 (expand_symtabs_matching): Adjust to use lookup_name_info.
2856 * symmisc.c (maintenance_expand_symtabs): Use
2857 lookup_name_info::match_any ().
2858 * symtab.c (symbol_matches_search_name): New.
2859 (eq_symbol_entry): Adjust to use lookup_name_info and the
2860 language's matcher.
2861 (demangle_for_lookup_info::demangle_for_lookup_info): New.
2862 (lookup_name_info::match_any): New.
2863 (iterate_over_symbols, search_symbols): Use lookup_name_info.
2864 (compare_symbol_name): Add language, lookup_name_info and
2865 completion_match_result parameters, and use them.
2866 (completion_list_add_name): Make extern. Add language and
2867 lookup_name_info parameters. Use them.
2868 (completion_list_add_symbol, completion_list_add_msymbol)
2869 (completion_list_objc_symbol): Add lookup_name_info parameters and
2870 adjust. Pass down language.
2871 (completion_list_add_fields): Add lookup_name_info parameters and
2872 adjust. Pass down language.
2873 (add_symtab_completions): Add lookup_name_info parameters and
2874 adjust.
2875 (default_collect_symbol_completion_matches_break_on): Add
2876 name_match_type parameter, and use it. Use lookup_name_info.
2877 (default_collect_symbol_completion_matches)
2878 (collect_symbol_completion_matches): Add name_match_type
2879 parameter, and pass it down.
2880 (collect_symbol_completion_matches_type): Adjust.
2881 (collect_file_symbol_completion_matches): Add name_match_type
2882 parameter, and use lookup_name_info.
2883 * symtab.h: Include <string> and "common/gdb_optional.h".
2884 (enum class symbol_name_match_type): New.
2885 (class ada_lookup_name_info): New.
2886 (struct demangle_for_lookup_info): New.
2887 (class lookup_name_info): New.
2888 (symbol_name_matcher_ftype): New.
2889 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
2890 (symbol_matches_search_name): Declare.
2891 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
2892 (default_collect_symbol_completion_matches)
2893 (collect_symbol_completion_matches)
2894 (collect_file_symbol_completion_matches): Add name_match_type
2895 parameter.
2896 (iterate_over_symbols): Use lookup_name_info.
2897 (completion_list_add_name): Declare.
2898 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
2899 (strncmp_iw_with_mode): Now extern.
2900 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
2901 (strncmp_iw_with_mode): Declare.
2902
2903 2017-11-08 Keith Seitz <keiths@redhat.com>
2904 Pedro Alves <palves@redhat.com>
2905
2906 * ada-lang.c (ada_language_defn): Install
2907 default_search_name_hash.
2908 * buildsym.c (struct buildsym_compunit): <language>: New field.
2909 (finish_block_internal): Pass language when creating dictionaries.
2910 (start_buildsym_compunit, start_symtab): New language parameters.
2911 Use them.
2912 (restart_symtab): Pass down compilation unit's language.
2913 * buildsym.h (enum language): Forward declare.
2914 (start_symtab): New 'language' parameter.
2915 * c-lang.c (c_language_defn, cplus_language_defn)
2916 (asm_language_defn, minimal_language_defn): Install
2917 default_search_name_hash.
2918 * coffread.c (coff_start_symtab): Adjust.
2919 * d-lang.c (d_language_defn): Install default_search_name_hash.
2920 * dbxread.c (struct symloc): Add 'pst_language' field.
2921 (PST_LANGUAGE): Define.
2922 (start_psymtab, read_ofile_symtab): Use it.
2923 (process_one_symbol): New 'language' parameter. Pass it down.
2924 * dictionary.c (struct dictionary) <language>: New field.
2925 (DICT_LANGUAGE): Define.
2926 (dict_create_hashed, dict_create_hashed_expandable)
2927 (dict_create_linear, dict_create_linear_expandable): New parameter
2928 'language'. Set the dictionary's language.
2929 (iter_match_first_hashed): Adjust to rename.
2930 (insert_symbol_hashed): Assert we don't see mismatching
2931 languages. Adjust to rename.
2932 (dict_hash): Rename to ...
2933 (default_search_name_hash): ... this and make extern.
2934 * dictionary.h (struct language_defn): Forward declare.
2935 (dict_create_hashed): New parameter 'language'.
2936 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
2937 * f-lang.c (f_language_defn): Install default_search_name_hash.
2938 * go-lang.c (go_language_defn): Install default_search_name_hash.
2939 * jit.c (finalize_symtab): Pass compunit's language to dictionary
2940 creation.
2941 * language.c (unknown_language_defn, auto_language_defn):
2942 * language.h (language_defn::la_search_name_hash): New field.
2943 (default_search_name_hash): Declare.
2944 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
2945 * mdebugread.c (new_block): New parameter 'language'.
2946 * mdebugread.c (parse_symbol): Pass symbol language to block
2947 allocation.
2948 (psymtab_to_symtab_1): Pass down language.
2949 (new_symtab): Pass compunit's language to block allocation.
2950 * objc-lang.c (objc_language_defn): Install
2951 default_search_name_hash.
2952 * opencl-lang.c (opencl_language_defn):
2953 * p-lang.c (pascal_language_defn): Install
2954 default_search_name_hash.
2955 * rust-lang.c (rust_language_defn): Install
2956 default_search_name_hash.
2957 * stabsread.h (enum language): Forward declare.
2958 (process_one_symbol): Add 'language' parameter.
2959 * symtab.c (search_name_hash): New function.
2960 * symtab.h (search_name_hash): Declare.
2961 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
2962
2963 2017-11-08 Pedro Alves <palves@redhat.com>
2964
2965 * cp-name-parser.y (main): Don't initialize extra_chars.
2966
2967 2017-11-07 Tom Tromey <tom@tromey.com>
2968
2969 * event-top.h (command_handler): Constify.
2970 * record-full.c (cmd_record_full_start): Update.
2971 * thread.c (thread_apply_all_command): Update.
2972 * printcmd.c (eval_command): Update.
2973 * mi/mi-main.c (mi_execute_cli_command): Update.
2974 (mi_execute_async_cli_command): Update.
2975 * tui/tui-stack.c (tui_update_command): Update.
2976 * cli/cli-interp.c (safe_execute_command): Constify.
2977 * record.c (record_start): Update.
2978 (record_start, record_stop, cmd_record_start): Update.
2979 * record-btrace.c (cmd_record_btrace_bts_start): Update.
2980 (cmd_record_btrace_pt_start): Update.
2981 (cmd_record_btrace_start): Update.
2982 (cmd_record_btrace_start): Update.
2983 * reverse.c (exec_reverse_once): Update.
2984 * python/python.c (execute_gdb_command): Don't copy the command.
2985 * event-top.c (command_line_handler): Update.
2986 (command_handler): Constify.
2987 * defs.h (deprecated_call_command_hook): Constify.
2988 * cli/cli-script.h (execute_user_command): Constify.
2989 * cli/cli-script.c (execute_user_command): Constify.
2990 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
2991 (enum command_control_type): Update.
2992 * main.c (catch_command_errors): Remove non-const overload.
2993 (catch_command_errors_ftype): Remove.
2994 * python/py-cmd.c (cmdpy_function): Constify.
2995 * guile/scm-cmd.c (cmdscm_function): Constify.
2996 * cli/cli-dump.c (call_dump_func): Constify.
2997 * cli/cli-decode.c (do_const_cfunc): Constify.
2998 (do_sfunc): Constify.
2999 (cmd_func): Constify.
3000 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
3001 * top.h (execute_command): Constify.
3002 * top.c (execute_command): Constify.
3003 (execute_command_to_string): Constify.
3004 (deprecated_call_command_hook): Constify.
3005 * command.h (cmd_func): Constify.
3006 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
3007
3008 2017-11-07 Tom Tromey <tom@tromey.com>
3009
3010 * ada-lang.c (catch_ada_exception_command): Constify.
3011 (catch_assert_command): Constify.
3012 * break-catch-throw.c (catch_catch_command, catch_throw_command)
3013 (catch_rethrow_command): Constify.
3014 (catch_exception_command_1): Constify.
3015 * breakpoint.h (add_catch_command): Constify.
3016 * break-catch-syscall.c (catch_syscall_command_1): Constify.
3017 (catch_syscall_split_args): Constify.
3018 * break-catch-sig.c (catch_signal_command): Constify.
3019 (catch_signal_split_args): Constify.
3020 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
3021 cmd_const_sfunc_ftype.
3022 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
3023 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3024 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3025 (add_setshow_string_cmd, struct cmd_list_element)
3026 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3027 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3028 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
3029 Constify.
3030 (set_cmd_sfunc): Constify.
3031 (empty_sfunc): Constify.
3032 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3033 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3034 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
3035 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3036 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3037 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
3038 Constify.
3039 (set_cmd_sfunc): Constify.
3040 (cmd_sfunc_ftype): Remove.
3041 * compile/compile.c (set_compile_args): Constify.
3042 * infrun.c (set_disable_randomization): Constify.
3043 * infcmd.c (set_args_command, set_cwd_command): Constify.
3044 * breakpoint.c (set_condition_evaluation_mode): Constify.
3045 (add_catch_command): Constify.
3046 (catch_fork_command_1, catch_exec_command_1)
3047 (catch_load_command_1, catch_unload_command_1): Constify.
3048 (catch_load_or_unload): Constify.
3049 * guile/scm-param.c (pascm_set_func): Constify.
3050 (add_setshow_generic): Constify.
3051 * python/py-param.c (get_set_value): Constify.
3052 * top.h (set_verbose): Constify.
3053 * tui/tui-win.c (tui_set_var_cmd): Constify.
3054 * mi/mi-main.c (set_mi_async_command): Constify.
3055 * cli/cli-logging.c (set_logging_overwrite)
3056 (set_logging_redirect): Constify.
3057 * value.c (set_max_value_size): Constify.
3058 * valprint.c (set_input_radix, set_output_radix): Constify.
3059 * utils.c (set_width_command, set_height_command): Constify.
3060 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
3061 * tracepoint.c (set_disconnected_tracing)
3062 (set_circular_trace_buffer, set_trace_buffer_size)
3063 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
3064 * top.c (set_history_size_command, set_verbose, set_editing)
3065 (set_gdb_datadir, set_history_filename): Constify.
3066 * target.c (set_targetdebug, maint_set_target_async_command)
3067 (maint_set_target_non_stop_command, set_target_permissions)
3068 (set_write_memory_permission): Constify.
3069 (open_target): Constify.
3070 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
3071 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
3072 * symtab.c (set_symbol_cache_size_handler): Constify.
3073 * symfile.c (set_ext_lang_command): Constify.
3074 * symfile-debug.c (set_debug_symfile): Constify.
3075 * source.c (set_directories_command): Constify.
3076 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
3077 * serial.c (set_parity): Constify.
3078 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
3079 * remote.c (set_remote_exec_file, set_remotebreak)
3080 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
3081 * record.c (set_record_insn_history_size)
3082 (set_record_call_history_size): Constify.
3083 * record-full.c (set_record_full_insn_max_num): Constify.
3084 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
3085 * osabi.c (set_osabi): Constify.
3086 * mips-tdep.c (set_mips64_transfers_32bit_regs)
3087 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
3088 * maint.c (maintenance_set_profile_cmd): Constify.
3089 * linux-thread-db.c (set_libthread_db_search_path): Constify.
3090 * language.c (set_language_command, set_range_command)
3091 (set_case_command): Constify.
3092 * infrun.c (set_non_stop, set_observer_mode)
3093 (set_stop_on_solib_events, set_schedlock_func)
3094 (set_exec_direction_func): Constify.
3095 * infcmd.c (set_inferior_tty_command): Constify.
3096 * disasm.c (set_disassembler_options_sfunc): Constify.
3097 * demangle.c (set_demangling_command): Constify.
3098 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
3099 * cris-tdep.c (set_cris_version, set_cris_mode)
3100 (set_cris_dwarf2_cfi): Constify.
3101 * corefile.c (set_gnutarget_command): Constify.
3102 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
3103 (set_target_wide_charset_sfunc): Constify.
3104 * breakpoint.c (update_dprintf_commands): Constify.
3105 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
3106 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
3107 (set_disassembly_style_sfunc): Constify.
3108 * arch-utils.c (set_endian, set_architecture): Constify.
3109 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
3110 * agent.c (set_can_use_agent): Constify.
3111
3112 2017-11-07 Tom Tromey <tom@tromey.com>
3113
3114 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
3115 (go32_pde, go32_pte, go32_pte_for_address): Constify.
3116 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
3117 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
3118 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
3119 (parse_int_arg, show_thread_default_detach_sc_cmd)
3120 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
3121 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
3122 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
3123 (show_task_pause_cmd, set_task_detach_sc_cmd)
3124 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
3125 (set_noninvasive_cmd, set_thread_pause_cmd)
3126 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
3127 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
3128 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
3129 * windows-nat.c (display_selectors): Constify.
3130 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
3131 non-const "cfunc".
3132 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
3133 (cmd_cfunc_eq): Likewise.
3134 (struct cmd_list_element): Likewise.
3135 (do_cfunc): Remove.
3136 (cli_user_command_p): Update.
3137 * command.h (add_cmd): Remove non-const overload.
3138 (cmd_cfunc_ftype): Remove typedef.
3139 (cmd_cfunc_eq): Remove non-const overload.
3140 * value.c (show_values): Constify.
3141 * thread.c (thread_apply_all_command): Constify.
3142 * symfile.c (load_command): Constify.
3143 * source.c (directory_command): Constify.
3144 * maint.c (maintenance_internal_error)
3145 (maintenance_demangler_warning, maintenance_space_display)
3146 (maintenance_print_architecture, maintenance_translate_address)
3147 (maintenance_info_selftests, maintenance_internal_warning):
3148 Constify.
3149 * breakpoint.c (disable_trace_command, enable_trace_command):
3150 Constify.
3151 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
3152 Constify.
3153 (add_auto_load_safe_path): Constify.
3154 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
3155 * top.h (show_commands): Constify.
3156 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
3157 * sparc64-tdep.c (adi_examine_command): Constify.
3158 (adi_assign_command): Constify.
3159
3160 2017-11-07 Tom Tromey <tom@tromey.com>
3161
3162 * frame.h (info_locals_command, info_args_command): Constify.
3163 * auto-load.h (auto_load_info_scripts): Constify.
3164 * inferior.h (registers_info): Constify.
3165 * copying.c: Rebuild.
3166 * copying.awk: Constify generated commands.
3167 * auto-load.c (auto_load_info_scripts)
3168 (info_auto_load_gdb_scripts): Constify.
3169 * cli/cli-decode.c (struct cmd_list_element): Take a
3170 cmd_const_cfunc_ftype.
3171 * command.h (add_info): Take a cmd_const_cfunc_ftype.
3172 * tui/tui-win.c (tui_all_windows_info): Constify.
3173 * python/py-auto-load.c (info_auto_load_python_scripts):
3174 Constify.
3175 * cli/cli-cmds.c (show_command): Remove non-const overload.
3176 * tracepoint.c (info_tvariables_command, info_scope_command):
3177 Constify.
3178 (info_static_tracepoint_markers_command): Constify.
3179 * thread.c (info_threads_command): Constify.
3180 (print_thread_info_1): Constify.
3181 * target.c (info_target_command): Constify.
3182 * symtab.c (info_sources_command, info_functions_command)
3183 (info_types_command): Constify.
3184 (info_variables_command): Remove non-const overload.
3185 * symfile.c (info_ext_lang_command): Constify.
3186 * stack.c (info_frame_command, info_locals_command)
3187 (info_args_command): Constify.
3188 (backtrace_command): Remove non-const overload.
3189 * source.c (info_source_command, info_line_command): Constify.
3190 * solib.c (info_sharedlibrary_command): Constify.
3191 * skip.c (info_skip_command): Constify.
3192 * ser-go32.c (info_serial_command): Constify.
3193 * reverse.c (info_bookmarks_command): Constify.
3194 * printcmd.c (info_symbol_command, info_address_command)
3195 (info_display_command): Constify.
3196 * osdata.c (info_osdata_command): Constify.
3197 * objc-lang.c (info_selectors_command, info_classes_command):
3198 Constify.
3199 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
3200 * memattr.c (info_mem_command): Constify.
3201 * macrocmd.c (info_macro_command, info_macros_command): Constify.
3202 * linux-fork.c (info_checkpoints_command): Constify.
3203 * infrun.c (info_signals_command): Constify.
3204 * inflow.c (info_terminal_command): Constify.
3205 * inferior.c (info_inferiors_command): Constify.
3206 (print_inferior): Constify.
3207 * infcmd.c (info_program_command, info_all_registers_command)
3208 (info_registers_command, info_vector_command)
3209 (info_float_command): Constify.
3210 (registers_info): Constify.
3211 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
3212 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
3213 Constify.
3214 * f-valprint.c (info_common_command): Constify.
3215 * dcache.c (info_dcache_command): Constify.
3216 (dcache_info_1): Constify.
3217 * darwin-nat-info.c (info_mach_tasks_command)
3218 (info_mach_task_command, info_mach_ports_command)
3219 (info_mach_port_command, info_mach_threads_command)
3220 (info_mach_thread_command, info_mach_regions_command)
3221 (info_mach_regions_recurse_command, info_mach_region_command)
3222 (info_mach_exceptions_command): Constify.
3223 (get_task_from_args): Constify.
3224 * cp-support.c (info_vtbl_command): Constify.
3225 * breakpoint.c (info_watchpoints_command)
3226 (info_tracepoints_command): Constify.
3227 (info_breakpoints_command): Remove non-const overload.
3228 * avr-tdep.c (avr_io_reg_read_command): Constify.
3229 * auxv.c (info_auxv_command): Constify.
3230 * ada-tasks.c (info_tasks_command): Constify.
3231 (info_task): Constify.
3232 * ada-lang.c (info_exceptions_command): Constify.
3233
3234 2017-11-07 Tom Tromey <tom@tromey.com>
3235
3236 * solib.h (no_shared_libraries): Constify.
3237 * frame.h (return_command): Constify.
3238 * cli/cli-cmds.h (quit_command): Constify.
3239 * top.h (quit_command, execute_command): Constify.
3240 * target.h (flash_erase_command): Constify.
3241 * inferior.h (set_inferior_args, attach_command): Constify.
3242 * tracepoint.h (start_tracing, stop_tracing): Constify.
3243 * breakpoint.h (break_command, tbreak_command)
3244 (hbreak_command_wrapper, thbreak_command_wrapper)
3245 (rbreak_command_wrapper, watch_command_wrapper)
3246 (awatch_command_wrapper, rwatch_command_wrapper)
3247 (get_tracepoint_by_number): Constify.
3248 * symtab.c (info_variables_command, rbreak_command)
3249 (symtab_symbol_info): Constify.
3250 (info_variables_command): Add non-const overload.
3251 * top.c (dont_repeat_command): Constify.
3252 * breakpoint.c (ignore_command, commands_command)
3253 (condition_command, tbreak_command, hbreak_command)
3254 (thbreak_command, clear_command, break_command)
3255 (info_breakpoints_command, watch_command, rwatch_command)
3256 (awatch_command, trace_command, ftrace_command, strace_command)
3257 (trace_pass_command, break_range_command, dprintf_command)
3258 (agent_printf_command, get_tracepoint_by_number)
3259 (watch_maybe_just_location, trace_pass_command): Constify.
3260 (info_breakpoints_command): Add non-const overload.
3261 * tracefile.c (tsave_command): Constify.
3262 * infcmd.c (attach_command, disconnect_command, signal_command)
3263 (queue_signal_command, stepi_command, nexti_command)
3264 (finish_command, next_command, step_command, until_command)
3265 (advance_command, jump_command, continue_command, run_command)
3266 (start_command, starti_command, interrupt_command)
3267 (run_command_1, set_inferior_args, step_1): Constify.
3268 * inferior.c (add_inferior_command, remove_inferior_command)
3269 (clone_inferior_command): Constify.
3270 * linux-fork.c (checkpoint_command, restart_command): Constify.
3271 * windows-nat.c (signal_event_command): Constify.
3272 * guile/guile.c (guile_repl_command, guile_command): Constify.
3273 * printcmd.c (x_command, display_command, printf_command)
3274 (output_command, set_command, call_command, print_command)
3275 (eval_command): Constify.
3276 (non_const_set_command): Remove.
3277 (_initialize_printcmd): Update.
3278 * source.c (forward_search_command, reverse_search_command):
3279 Constify.
3280 * jit.c (jit_reader_load_command, jit_reader_unload_command):
3281 Constify.
3282 * infrun.c (handle_command): Constify.
3283 * memattr.c (mem_command): Constify.
3284 * stack.c (return_command, up_command, up_silently_command)
3285 (down_command, down_silently_command, frame_command)
3286 (backtrace_command, func_command, backtrace_command_1): Constify.
3287 (backtrace_command): Add non-const overload.
3288 * remote-sim.c (simulator_command): Constify.
3289 * exec.c (set_section_command): Constify.
3290 * tracepoint.c (tdump_command, trace_variable_command)
3291 (tstatus_command, tstop_command, tstart_command)
3292 (end_actions_pseudocommand, while_stepping_pseudocommand)
3293 (collect_pseudocommand, teval_pseudocommand, actions_command)
3294 (start_tracing, stop_tracing): Constify.
3295 * value.c (init_if_undefined_command): Constify.
3296 * tui/tui-stack.c (tui_update_command): Constify.
3297 * tui/tui-win.c (tui_refresh_all_command)
3298 (tui_set_tab_width_command, tui_set_win_height_command)
3299 (tui_set_focus_command, tui_scroll_forward_command)
3300 (tui_scroll_backward_command, tui_scroll_left_command)
3301 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
3302 (tui_set_win_height): Constify.
3303 * tui/tui-layout.c (tui_layout_command): Constify.
3304 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
3305 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
3306 (proc_untrace_sysexit_cmd): Constify.
3307 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
3308 (threadset_test_cmd, threadlist_update_test_cmd)
3309 (threadalive_test): Constify.
3310 * objc-lang.c (print_object_command): Constify.
3311 * command.h (add_com): Constify.
3312 * cli/cli-dump.c (restore_command): Constify.
3313 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
3314 (help_command, complete_command, shell_command, edit_command)
3315 (list_command, disassemble_command, make_command)
3316 (apropos_command, alias_command): Constify.
3317 * cli/cli-script.c (document_command, define_command)
3318 (while_command, if_command, validate_comname): Constify.
3319 * cli/cli-decode.c (struct cmd_list_element): Change type of
3320 "fun".
3321 * target.c (do_monitor_command, flash_erase_command): Constify.
3322 * regcache.c (reg_flush_command): Constify.
3323 * reverse.c (reverse_step, reverse_next, reverse_stepi)
3324 (reverse_nexti, reverse_continue, reverse_finish)
3325 (save_bookmark_command, goto_bookmark_command)
3326 (exec_reverse_once): Constify.
3327 * python/python.c (python_interactive_command, python_command):
3328 Constify.
3329 * typeprint.c (ptype_command, whatis_command, whatis_exp):
3330 Constify.
3331 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
3332 * gcore.c (gcore_command): Constify.
3333
3334 2017-11-07 Tom Tromey <tom@tromey.com>
3335
3336 * printcmd.c (x_command): Call set_repeat_arguments.
3337 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
3338 * top.c (repeat_arguments): New global.
3339 (set_repeat_arguments): New function.
3340 (execute_command): Handle repeat_arguments.
3341 (show_commands): Calls set_repeat_arguments.
3342 * command.h (set_repeat_arguments): Declare.
3343
3344 2017-11-07 Tom Tromey <tom@tromey.com>
3345
3346 * stack.c (backtrace_command): Use std::string.
3347 (backtrace_command_1): Make "count_exp" const.
3348
3349 2017-11-07 Tom Tromey <tom@tromey.com>
3350
3351 * source.c (directory_switch, mod_path, add_path): Constify.
3352 * defs.h (add_path, mod_path, directory_switch): Constify.
3353 * mi/mi-cmd-env.c (env_mod_path): Constify.
3354
3355 2017-11-07 Tom Tromey <tom@tromey.com>
3356
3357 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
3358 (run_command_1, continue_command, step_1, jump_command)
3359 (signal_command, until_command, advance_command, finish_command)
3360 (attach_command): Update.
3361
3362 2017-11-07 Tom Tromey <tom@tromey.com>
3363
3364 * command.h (set_cmd_cfunc): Don't declare.
3365 * cli/cli-decode.c (set_cmd_cfunc): Now static.
3366
3367 2017-11-07 Tom Tromey <tom@tromey.com>
3368
3369 * stack.c (select_frame_command): Constify.
3370 * cli/cli-decode.c (add_com_suppress_notification): Constify.
3371 * command.h (add_com_suppress_notification): Constify.
3372
3373 2017-11-07 Tom Tromey <tom@tromey.com>
3374
3375 * breakpoint.c (stop_command): Constify.
3376 * cli/cli-decode.c (struct cmd_list_element): Constify.
3377 * command.h (add_abbrev_prefix_cmd): Constify.
3378
3379 2017-11-07 Pedro Alves <palves@redhat.com>
3380
3381 * breakpoint.c (extract_bp_kind): New enum.
3382 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
3383 factored out from ...
3384 (extract_bp_number_and_location): ... here.
3385 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
3386
3387 2017-11-07 Pedro Alves <palves@redhat.com>
3388
3389 * breakpoint.c (extract_bp_number_and_location): Change return
3390 type to void. Throw error instead of warning.
3391 (enable_disable_command): Adjust.
3392
3393 2017-11-07 Xavier Roirand <roirand@adacore.com>
3394 Pedro Alves <palves@redhat.com>
3395
3396 * breakpoint.c (map_breakpoint_number_range): New, factored out
3397 from ...
3398 (map_breakpoint_numbers): ... here.
3399 (find_location_by_number): Change parameters from string to
3400 breakpoint number and location.
3401 (extract_bp_number_and_location): New function.
3402 (enable_disable_bp_num_loc)
3403 (enable_disable_breakpoint_location_range)
3404 (enable_disable_command): New functions, factored out ...
3405 (enable_command, disable_command): ... these functions, and
3406 adjusted to support ranges.
3407 * NEWS: Document enable/disable breakpoint location range feature.
3408
3409 2017-11-06 Luis Machado <luis.machado@linaro.org>
3410
3411 * MAINTAINERS (Write After Approval): Update my e-mail address.
3412
3413 2017-11-06 Pedro Alves <palves@redhat.com>
3414
3415 * gnu-nat.c (gnu_terminal_init): Delete.
3416 (gnu_target): Don't install gnu_terminal_init.
3417 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
3418 (child_terminal_init): ... this function.
3419
3420 2017-11-06 Pedro Alves <palves@redhat.com>
3421
3422 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
3423 sgtty.h.
3424 * config.in, configure: Regenerate.
3425
3426 2017-11-06 Pedro Alves <palves@redhat.com>
3427
3428 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
3429 (async_init_signals): Adjust.
3430 (handle_stop_sig): Rename to ...
3431 (handle_sigtstp): ... this.
3432 (async_stop_sig): Rename to ...
3433 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3434 SIGTSTP path.
3435 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3436 instead of STOP_SIGNAL thoughout.
3437 (handle_stop_sig): Rename to ...
3438 (handle_sigtstp): ... this.
3439 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3440
3441 2017-11-06 Pedro Alves <palves@redhat.com>
3442
3443 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3444 longer set flags twice in row.
3445
3446 2017-11-06 Pedro Alves <palves@redhat.com>
3447
3448 * Makefile.in (SER_HARDWIRE): Update comment.
3449 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3450 * common/gdb_termios.h: Delete file.
3451 * common/job-control.c: Include termios.h and unistd.h instead of
3452 gdb_termios.h.
3453 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3454 check.
3455 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3456 Remove sgtty code.
3457 * configure.ac: No longer check for termio.h and sgtty.h.
3458 * configure: Regenerate.
3459 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3460 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3461 Replace PROCESS_GROUP_TYPE references with pid_t references
3462 throughout.
3463 (gdb_getpgrp): Delete.
3464 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3465 (child_terminal_inferior): Remove comment. Remove sgtty code.
3466 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3467 gdb_getpgrp. Use serial_set_tty_state instead aof
3468 serial_noflush_set_tty_state. Remove sgtty code.
3469 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3470 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3471 (inferior_process_group): Now returns pid_t.
3472 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3473 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3474 * ser-event.c (serial_event_ops): Update.
3475 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3476 (dos_ops): Update.
3477 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3478 * ser-pipe.c (pipe_ops): Update.
3479 * ser-tcp.c (tcp_ops): Update.
3480 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3481 HAVE_TERMIOS checks.
3482 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3483 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3484 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3485 assume termios.
3486 (hardwire_noflush_set_tty_state): Delete.
3487 (hardwire_print_tty_state, hardwire_drain_output)
3488 (hardwire_flush_output, hardwire_flush_input)
3489 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3490 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3491 code, and assume termios.
3492 (hardwire_ops): Update.
3493 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3494 * serial.c (serial_noflush_set_tty_state): Delete.
3495 * serial.h (serial_noflush_set_tty_state): Delete.
3496 (serial_ops::noflush_set_tty_state): Delete.
3497
3498 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3499
3500 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3501 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3502 (COMMON_OBS): Remove doublest.o and dfp.o.
3503 Do not build target-float.c (instead of doublest.c)
3504 with -Wformat-nonliteral.
3505
3506 * doublest.c: Remove file.
3507 * doublest.h: Remove file.
3508 * dfp.c: Remove file.
3509 * dfp.h: Remove file.
3510
3511 * target-float.c: Do not include "doublest.h" and "dfp.h".
3512 (DOUBLEST): Move here from doublest.h.
3513 (enum float_kind): Likewise.
3514 (FLOATFORMAT_CHAR_BIT): Likewise.
3515 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3516 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3517 (floatformat_precision): Likewise.
3518 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3519 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3520 Likewise.
3521 (host_float_format, host_double_format, host_long_double_format):
3522 Likewise.
3523 (floatformat_to_string, floatformat_from_string): Likewise.
3524 (floatformat_to_doublest): Likewise. Also, inline the original
3525 convert_floatformat_to_doublest.
3526 (floatformat_from_doublest): Likewise. Also, inline the original
3527 convert_floatformat_from_doublest.
3528
3529 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3530 (MAX_DECIMAL_STRING): Move here from dfp.c.
3531 (match_endianness): Likewise.
3532 (set_decnumber_context, decimal_check_errors): Likewise.
3533 (decimal_from_number, decimal_to_number): Likewise.
3534 (decimal_to_string, decimal_from_string): Likewise. Make static.
3535 (decimal_from_longest, decimal_from_ulongest): Likewise.
3536 (decimal_to_longest): Likewise.
3537 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3538 (decimal_convert): Likewise.
3539
3540 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3541
3542 * doublest.c: Do not include "gdbtypes.h".
3543 (extract_typed_floating): Remove.
3544 (store_typed_floating): Remove.
3545 (convert_typed_floating): Remove.
3546 * doublest.h (struct type): Remove.
3547 (DOUBLEST_PRINT_FORMAT): Remove.
3548 (DOUBLEST_SCAN_FORMAT): Remove.
3549 (extract_typed_floating): Remove.
3550 (store_typed_floating): Remove.
3551 (convert_typed_floating): Remove.
3552
3553 * dfp.c (decimal_from_doublest): Remove.
3554 (decimal_to_doublest): Remove.
3555 * dfp.h: Do not include "doublest.h".
3556 (decimal_from_doublest): Remove.
3557 (decimal_to_doublest): Remove.
3558
3559 * value.c: Do not include "doublest.h" and "dfp.h".
3560 (value_as_double): Remove.
3561 (unpack_double): Remove.
3562 (value_from_double): Remove.
3563 (value_from_decfloat): Remove.
3564 * value.h: Do not include "doublest.h".
3565 (value_as_double): Remove.
3566 (unpack_double): Remove.
3567 (value_from_double): Remove.
3568 (value_from_decfloat): Remove.
3569
3570 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3571
3572 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3573 (i386_extract_return_value): Use target_float_convert.
3574 (i386_store_return_value): Likewise.
3575 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3576 (i387_value_to_register): Likewise.
3577 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3578 (ia64_register_to_value): Use target_float_convert.
3579 (ia64_value_to_register): Likewise.
3580 (ia64_extract_return_value): Likewise.
3581 (ia64_store_return_value): Likewise.
3582 (ia64_push_dummy_call): Likewise.
3583 * m68k-tdep.c: Include "target-float.h".
3584 (m68k_register_to_value): Use target_float_convert.
3585 (m68k_value_to_register): Likewise.
3586 (m68k_svr4_extract_return_value): Likewise.
3587 (m68k_svr4_store_return_value): Likewise.
3588 * ppc-sysv-tdep.c: Include "target-float.h".
3589 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3590 (do_ppc_sysv_return_value): Likewise.
3591 (ppc64_sysv_abi_push_freg): Likewise.
3592 (ppc64_sysv_abi_return_value_base): Likewise.
3593 * rs6000-aix-tdep.c: Include "target-float.h".
3594 (rs6000_push_dummy_call): Use target_float_convert.
3595 (rs6000_return_value): Likewise.
3596 * rs6000-lynx178-tdep.c: Include "target-float.h".
3597 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3598 (rs6000_lynx178_return_value): Likewise.
3599 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3600 (rs6000_register_to_value): Use target_float_convert.
3601 (rs6000_value_to_register): Likewise.
3602 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3603 (arm_extract_return_value): Use target_float_convert.
3604 (arm_store_return_value): Likewise.
3605 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3606 (sh_register_convert_to_virtual): Use target_float_convert.
3607 (sh_register_convert_to_raw): Likewise.
3608 * sh64-tdep.c: Include "target-float.h".
3609 (sh64_extract_return_value): Use target_float_convert.
3610 (sh64_register_convert_to_virtual): Likewise.
3611 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3612
3613 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3614
3615 * target-float.c (floatformat_to_host_double): New function.
3616 (floatformat_from_host_double): Likewise.
3617 (target_float_to_host_double): Likewise.
3618 (target_float_from_host_double): Likewise.
3619 * target-float.h (target_float_to_host_double): Add prototype.
3620 (target_float_from_host_double): Likewise.
3621
3622 * guile/scm-value.c: Include "target-float.h".
3623 (gdbscm_value_to_real): Use target_float_to_host_double.
3624 Handle integer source values via value_as_long.
3625 * guile/scm-math.c: Include "target-float.h". Do not include
3626 "doublest.h", "dfp.h", and "expression.h".
3627 (vlscm_convert_typed_number): Use target_float_from_host_double.
3628 (vlscm_convert_number): Likewise.
3629
3630 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3631 (convert_value_from_python): Use target_float_from_host_double.
3632
3633 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3634
3635 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3636 (cast_from_fixed): Likewise.
3637 (ada_scaling_type): New function.
3638 (ada_delta): Return value instead of DOUBLEST. Perform target
3639 arithmetic instead of host arithmetic.
3640 (scaling_factor): Rename to ...
3641 (ada_scaling_factor) ... this. Make non-static. Return value instead
3642 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3643 (ada_fixed_to_float): Remove.
3644 (ada_float_to_fixed): Remove.
3645 * ada-lang.h (ada_fixed_to_float): Remove.
3646 (ada_float_to_fixed): Remove.
3647 (ada_delta): Return value instead of DOUBLEST.
3648 (ada_scaling_factor): Add prototype.
3649
3650 * ada-typeprint.c: Include "target-float.h".
3651 (print_fixed_point_type): Perform target arithmetic instead of
3652 host arithmetic.
3653 * ada-valprint.c: Include "target-float.h".
3654 (ada_val_print_num): Perform target arithmetic instead of
3655 host arithmetic for fixed-point types.
3656
3657 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3658
3659 * target-float.c: Include <math.h>.
3660 (floatformat_binop): New function.
3661 (floatformat_compare): Likewise.
3662 (target_float_binop): Likewise.
3663 (target_float_compare): Likewise.
3664 * target-float.h: Include "expression.h".
3665 (target_float_binop): Add prototype.
3666 (target_float_compare): Likewise.
3667
3668 * valarith.c: Do not include "doublest.h" and "dfp.h".
3669 Include "common/byte-vector.h".
3670 (value_args_as_decimal): Remove, replace by ...
3671 (value_args_as_target_float): ... this function. Handle both
3672 binary and decimal target floating-point formats.
3673 (scalar_binop): Handle both binary and decimal FP using
3674 value_args_as_target_float and target_float_binop.
3675 (value_equal): Handle both binary and decimal FP using
3676 value_args_as_target_float and target_float_compare.
3677 (value_less): Likewise.
3678 (value_pos): Handle all scalar types as simple copy.
3679 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3680 * dfp.c (decimal_binop): Throw error instead of internal_error
3681 when called with an unsupported operation code.
3682
3683 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3684
3685 * target-float.c (target_float_to_string): New function.
3686 (target_float_from_string): New function.
3687 * target-float.h (target_float_to_string): Add prototype.
3688 (target_float_from_string): Add prototype.
3689
3690 * valprint.c: Include "target-float.h". Do not include
3691 "doublest.h" and "dfp.h".
3692 (print_floating): Use target_float_to_string.
3693 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3694 (printf_floating): Use target_float_to_string.
3695 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3696 (print_i387_value): Use target_float_to_string.
3697 * mips-tdep.c: Include "target-float.h".
3698 (mips_print_fp_register): Use target_float_to_string.
3699 * sh64-tdep.c: Include "target-float.h".
3700 (sh64_do_fp_register): Use target_float_to_string.
3701
3702 * parse.c: Include "target-float.h". Do not include
3703 "doublest.h" and "dfp.h".
3704 (parse_float): Use target_float_from_string.
3705 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3706 (define_symbol): Use target_float_from_string.
3707 * gdbarch-selftests.c: Include "target-float.h".
3708 (register_to_value_test): Use target_float_from_string.
3709
3710 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3711
3712 * Makefile.c (SFILES): Add target-float.c.
3713 (HFILES_NO_SRCDIR): Add target-float.h.
3714 (COMMON_OBS): Add target-float.o.
3715 * target-float.h: New file.
3716 * target-float.c: New file.
3717
3718 * doublest.c (floatformat_classify): Fix detection of float_zero.
3719
3720 * gdbtypes.c (is_floating_type): New function.
3721 * gdbtypes.h (is_floating_type): Add prototype.
3722
3723 * value.c: Do not include "floatformat.h".
3724 (unpack_double): Use target_float_is_valid.
3725 (is_floating_value): New function.
3726 * value.h (is_floating_value): Add prototype-
3727
3728 * valarith.c: Include "target-float.h".
3729 (value_logical_not): Use target_float_is_zero.
3730
3731 * python/py-value.c: Include "target-float.h".
3732 (valpy_nonzero): Use target_float_is_zero.
3733
3734 2017-11-04 Tom Tromey <tom@tromey.com>
3735
3736 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3737
3738 2017-11-04 Tom Tromey <tom@tromey.com>
3739
3740 * breakpoint.c (set_momentary_breakpoint): Return
3741 breakpoint_up.
3742 (until_break_command): Update.
3743 (new_until_break_fsm): Change argument types to
3744 breakpoint_up.
3745 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3746 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3747 Remove.
3748 * infcmd.c (finish_forward): Update.
3749 * breakpoint.h (set_momentary_breakpoint)
3750 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3751 (make_cleanup_delete_breakpoint): Remove.
3752 (struct breakpoint_deleter): New.
3753 (breakpoint_up): New typedef.
3754 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3755 (insert_exception_resume_breakpoint): Update.
3756 (insert_exception_resume_from_probe): Update.
3757 (insert_longjmp_resume_breakpoint): Update.
3758 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3759 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3760 * infcall.c (call_function_by_hand_dummy): Update
3761
3762 2017-11-04 Tom Tromey <tom@tromey.com>
3763
3764 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3765
3766 2017-11-04 Tom Tromey <tom@tromey.com>
3767
3768 * linux-tdep.c (linux_core_info_proc_mappings): Use
3769 gdb::def_vector.
3770 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3771 "size" argument.
3772 (linux_corefile_thread): Update.
3773 (linux_make_corefile_notes): Remove unused variable.
3774
3775 2017-11-04 Tom Tromey <tom@tromey.com>
3776
3777 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
3778 gdb::byte_vector.
3779
3780 2017-11-04 Tom Tromey <tom@tromey.com>
3781
3782 * objfiles.c (do_free_objfile_cleanup): Remove.
3783 * compile/compile-object-load.c (compile_object_load): Update.
3784 * objfiles.h (make_cleanup_free_objfile): Remove.
3785
3786 2017-11-04 Tom Tromey <tom@tromey.com>
3787
3788 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
3789 (adi_read_versions): Change "tags" to "gdb_byte *".
3790 (adi_print_versions): Likewise.
3791
3792 2017-11-04 Tom Tromey <tom@tromey.com>
3793
3794 * breakpoint.c
3795 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
3796 from start_rbreak_breakpoints.
3797 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
3798 * breakpoint.h (class scoped_rbreak_breakpoints): New.
3799 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
3800 * symtab.c (do_end_rbreak_breakpoints): Remove.
3801 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
3802
3803 2017-11-04 Tom Tromey <tom@tromey.com>
3804
3805 * cp-namespace.c (reset_directive_searched): Remove.
3806 (cp_lookup_symbol_via_imports): Use scoped_restore.
3807 * cp-support.c (reset_directive_searched): Remove.
3808 (make_symbol_overload_list_using): Use scoped_restore.
3809 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
3810 (reset_directive_searched): Remove.
3811
3812 2017-11-04 Tom Tromey <tom@tromey.com>
3813
3814 * symfile.c (find_separate_debug_file_by_debuglink): Use
3815 unique_xmalloc_ptr.
3816
3817 2017-11-04 Tom Tromey <tom@tromey.com>
3818
3819 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
3820 type of "info".
3821 (compute_stack_depth): Likewise.
3822 (do_compile_dwarf_expr_to_c): Use std::vector.
3823
3824 2017-11-04 Tom Tromey <tom@tromey.com>
3825
3826 * compile/compile-object-load.c (link_callbacks_einfo): Use
3827 std::string.
3828
3829 2017-11-04 Tom Tromey <tom@tromey.com>
3830
3831 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3832 Use scoped_free_pendings.
3833 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
3834 scoped_free_pendings.
3835 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
3836 (xcoff_initial_scan): Likewise.
3837 * buildsym.c (reset_symtab_globals): Update comment.
3838 (scoped_free_pendings): Rename from really_free_pendings.
3839 (prepare_for_building): Update comment.
3840 (buildsym_init): Likewise.
3841 * buildsym.h (class scoped_free_pendings): New class.
3842 (really_free_pendings): Don't declare.
3843
3844 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
3845
3846 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
3847 output when converting a zero value to a special byteorder format.
3848
3849 2017-11-02 Yao Qi <yao.qi@linaro.org>
3850
3851 * frame.c (do_frame_register_read): Remove aspace.
3852 * jit.c (jit_frame_sniffer): Likwise.
3853 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3854 * regcache.c (regcache::regcache): Pass nullptr.
3855 (regcache_print): Caller updated.
3856 * regcache.h (regcache::regcache): Remove one constructor
3857 parameter aspace.
3858
3859 2017-11-02 Yao Qi <yao.qi@linaro.org>
3860
3861 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
3862
3863 2017-11-02 Yao Qi <yao.qi@linaro.org>
3864
3865 * breakpoint.c (insert_single_step_breakpoints): Update.
3866 * frame.c (struct frame_info) <aspace>: Add const.
3867 (frame_save_as_regcache): Add const.
3868 (get_frame_address_space): Return const address_space *.
3869 * frame.h (get_frame_address_space): Update declaration.
3870 * infrun.c (struct step_over_info) <aspace>: Add const.
3871 (set_step_over_info): Make aspace const.
3872 (displaced_step_prepare_throw): Change variable const.
3873 (resume): Likewise.
3874 (proceed): Likewise.
3875 (adjust_pc_after_break): Likewise.
3876 (save_waitstatus): Likewise.
3877 (handle_signal_stop): Likewise.
3878 (keep_going_pass_signal): Likewise.
3879 * jit.c (jit_frame_sniffer): Add const.
3880 * mips-tdep.c (mips_single_step_through_delay): Likewise.
3881 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3882 * record-full.c (record_full_wait_1): Likewise.
3883 * regcache.c (regcache::regcache): Change parameter to const.
3884 * regcache.h (regcache::regcache): Likewise.
3885 (regcache::aspace): Return const address_space *.
3886 (regcache) <m_aspace>: Add const.
3887
3888 2017-11-02 Yao Qi <yao.qi@linaro.org>
3889
3890 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
3891 * frame.c (create_sentinel_frame): Likewise.
3892 * infrun.c (displaced_step_prepare_throw): Likewise.
3893 (resume): Likewise.
3894 (thread_still_needs_step_over_bp): Likewise.
3895 (proceed): Likewise.
3896 (do_target_wait): Likewise.
3897 (adjust_pc_after_break): Likewise.
3898 (handle_syscall_event): Likewise.
3899 (save_waitstatus): Likewise.
3900 (handle_inferior_event_1): Likewise.
3901 (handle_signal_stop): Likewise.
3902 (keep_going_pass_signal): Likewise.
3903 * linux-nat.c (status_callback): Likewise.
3904 (save_stop_reason): Likewise.
3905 (resume_stopped_resumed_lwps): Likewise.
3906 * record-full.c (record_full_exec_insn): Likewise.
3907 (record_full_wait_1): Likewise.
3908 * regcache.c (get_regcache_aspace): Remove.
3909 * regcache.h (get_regcache_aspace): Remove.
3910
3911 2017-11-02 Yao Qi <yao.qi@linaro.org>
3912
3913 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
3914 (init_regcache_descr): Use gdbarch_num_regs.
3915 (regcache::regcache): Likewise.
3916 (regcache::get_register_status): Likewise.
3917 (regcache::assert_raw_regnum): Likewise.
3918 (regcache::cooked_read): Likewise.
3919 (regcache::cooked_read_value): Likewise.
3920 (regcache::cooked_write): Likewise.
3921 (regcache::dump): Likewise.
3922 (regcache::num_raw_registers): New method.
3923 * regcache.h (class regcache) <num_raw_registers>: New.
3924
3925 2017-11-02 Yao Qi <yao.qi@linaro.org>
3926
3927 * regcache.c (regcache::assert_regnum): New method.
3928 (regcache::invalidate): Call assert_regnum.
3929 (regcache::raw_update): Likewise.
3930 (regcache::raw_write): Likewise.
3931 (regcache::raw_read_part): Likewise.
3932 (regcache::raw_write_part): Likewise.
3933 (regcache::raw_supply): Likewise.
3934 (regcache::raw_supply_integer): Likewise.
3935 (regcache::raw_supply_zeroed): Likewise.
3936 (regcache::raw_collect): Likewise.
3937 (regcache::raw_collect_integer): Likewise.
3938 * regcache.h (regcache::assert_regnum): Declare.
3939
3940 2017-11-02 Yao Qi <yao.qi@linaro.org>
3941
3942 * regcache.c (regcache::dump): Remove code.
3943
3944 2017-11-02 Yao Qi <yao.qi@linaro.org>
3945
3946 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
3947 Remove.
3948 <sizeof_cooked_register_status>: Remove.
3949 (init_regcache_descr): Update.
3950 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
3951 (regcache::save): Likewise.
3952 (regcache::dump): Likewise.
3953
3954 2017-11-01 James Bowman <james.bowman@ftdichip.com>
3955
3956 * ft32-tdep.c (ft32_fetch_instruction): New function.
3957 (ft32_analyze_prologue): Use ft32_fetch_instruction().
3958
3959 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
3960
3961 * cli/cli-script.c (execute_control_command): Rename to ...
3962 (execute_control_command_1): ... this.
3963 (execute_control_command): New function.
3964
3965 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
3966
3967 * tracepoint.c (tfind_command): Remove const_cast.
3968
3969 2017-10-30 Mike Gulick <mgulick@mathworks.com>
3970
3971 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
3972
3973 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
3974
3975 * common/common-utils.h (in_inclusive_range): New function.
3976 * arm-tdep.c (arm_record_extension_space): Use
3977 in_inclusive_range.
3978 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
3979 * cris-tdep.c (cris_spec_reg_applicable): Use
3980 in_inclusive_range.
3981
3982 2017-10-30 Pedro Alves <palves@redhat.com>
3983 Simon Marchi <simon.marchi@ericsson.com>
3984
3985 * remote.c (remote_set_syscall_catchpoint): Build a std::string
3986 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
3987
3988 2017-10-30 Pedro Alves <palves@redhat.com>
3989
3990 * common/common-utils.c (string_appendf, string_vappendf): New
3991 functions.
3992 * common/common-utils.h (string_appendf, string_vappendf): New
3993 declarations.
3994 * unittests/common-utils-selftests.c (string_appendf_func)
3995 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
3996 (string_vappendf_tests): New functions.
3997 (_initialize_common_utils_selftests): Register "string_appendf" and
3998 "string_vappendf tests".
3999
4000 2017-10-30 Pedro Alves <palves@redhat.com>
4001
4002 * unittests/common-utils-selftests.c (format_func): New typedef.
4003 (string_printf_tests, string_vprintf_tests): Tests factored out
4004 and merged to ...
4005 (test_format_func): ... this new function.
4006 (string_printf_tests, string_vprintf_tests): Reimplement on top of
4007 test_format_func.
4008
4009 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4010
4011 * darwin-nat.c: Remove include of gdb.h.
4012
4013 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4014
4015 * xtensa-xtregs.c: Fix formatting issues.
4016
4017 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4018
4019 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
4020
4021 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
4022
4023 PR python/21213
4024 * python/py-infthread.c (thpy_get_inferior): Increment reference
4025 of inferior before returning it.
4026
4027 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4028
4029 * unittests/common-utils-selftests.c (format): Add
4030 ATTRIBUTE_PRINTF.
4031
4032 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4033
4034 * xml-syscall.c (struct syscall_desc): Add constructor.
4035 <name>: Change type to std::string.
4036 (syscall_desc_up): New typedef.
4037 (syscall_desc_p): Remove typeder.
4038 (DEF_VEC_P(syscall_desc_p)): Remove.
4039 (struct syscall_group_desc): Add constructor.
4040 <name>: Change type to std::string.
4041 <syscalls>: Change type to std::vector.
4042 (syscall_group_desc_up): New typedef.
4043 (syscall_group_desc_p): Remove typedef.
4044 (DEF_VEC_P(syscall_group_desc_p)): Remove.
4045 (struct syscalls_info) <syscalls>: Change type to std::vector of
4046 unique_ptr.
4047 <groups>: Likewise.
4048 <my_gdb_datadir>: Change type to std::string.
4049 (syscalls_info_up): New typedef.
4050 (allocate_syscalls_info): Remove.
4051 (syscalls_info_free_syscalls_desc): Remove.
4052 (syscalls_info_free_syscall_group_desc): Remove.
4053 (free_syscalls_info): Remove.
4054 (make_cleanup_free_syscalls_info): Remove.
4055 (syscall_group_create_syscall_group_desc): Adjust.
4056 (syscall_group_add_syscall): Adjust.
4057 (syscall_create_syscall_desc): Adjust.
4058 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
4059 (init_syscalls_info): Adjust.
4060 (syscall_group_get_group_by_name): Adjust.
4061 (xml_get_syscall_number): Adjust.
4062 (xml_get_syscall_name): Adjust.
4063 (xml_list_of_syscalls): Adjust.
4064 (xml_list_syscalls_by_group): Adjust.
4065 (xml_list_of_groups): Adjust.
4066
4067 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4068
4069 * probe.h: Don't include gdb_vecs.h.
4070 (DEF_VEC_P (probe_p)): Remove.
4071 (find_probes_in_objfile): Return an std::vector.
4072 * probe.c (find_probes_in_objfile): Likewise.
4073 * breakpoint.c (breakpoint_objfile_data)
4074 <longjmp_probes>: Change type to std::vector.
4075 <exception_probes>: Likewise.
4076 (free_breakpoint_probes): Don't manually free vectors.
4077 (create_longjmp_master_breakpoint): Adjust.
4078 (create_exception_master_breakpoint): Adjust.
4079 * solib-svr4.c (svr4_create_probe_breakpoints): Change
4080 parameter type, adjust.
4081 (svr4_create_solib_event_breakpoints): Adjust.
4082
4083 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4084
4085 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
4086 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
4087 with new.
4088 (free_breakpoint_probes): Rename to ...
4089 (free_breakpoint_objfile_data): ... this, and call delete on
4090 bp_objfile_data..
4091
4092 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4093
4094 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
4095 (loaded_script_ptr): Remove typedef.
4096 (DEF_VEC_P (loaded_script_ptr)): Remove.
4097 (struct collect_matching_scripts_data): Add constructor.
4098 <scripts_p>: Change type to (pointer to) std::vector.
4099 (collect_matching_scripts_data): Adjust.
4100 (sort_scripts_by_name): Make suitable for std::sort.
4101 (print_scripts): Don't sort vector, adjust to std::vector.
4102 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
4103
4104 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4105
4106 * symfile.c (filename_language): Make struct, not typedef. Add
4107 constructor.
4108 <ext>: Change type to std::string.
4109 (DEF_VEC_O (filename_language)): Remove.
4110 (filename_language_table): Change type to std::vector.
4111 (add_filename_language): Adjust.
4112 (set_ext_lang_command): Adjust.
4113 (info_ext_lang_command): Adjust.
4114 (deduce_language_from_filename): Adjust.
4115 (class scoped_restore_filename_language_table): Remove.
4116 (test_filename_language): Use scoped_restore.
4117 (test_set_ext_lang_command): Use scoped_restore, adjust to
4118 std::vector change.
4119
4120 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4121
4122 * symfile.c: Include selftest.h.
4123 (class scoped_restore_filename_language_table): New.
4124 (test_filename_language): New test.
4125 (test_set_ext_lang_command): New test.
4126 (_initialize_symfile): Register tests.
4127
4128 2017-10-27 Keith Seitz <keiths@redhat.com>
4129
4130 * breakpoint.c (print_breakpoint_location): Use the symbol saved
4131 in the bp_location, falling back to find_pc_sect_function when
4132 needed.
4133 (add_location_to_breakpoint): Save sal->symbol.
4134 * breakpoint.h (struct bp_location) <symbol>: New field.
4135 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
4136 * symtab.h (struct symtab_and_line) <symbol>: New field.
4137
4138 2017-10-26 Patrick Frants <osscontribute@gmail.com>
4139
4140 PR gdb/13669
4141 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
4142 to rewind obstack.
4143
4144 2017-10-26 Pedro Alves <palves@redhat.com>
4145
4146 * remote.c (remote_async_terminal_ours_p): Delete.
4147 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
4148 Remove references to 'remote_async_terminal_ours_p'.
4149
4150 2017-10-26 Yao Qi <yao.qi@linaro.org>
4151
4152 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
4153
4154 2017-10-26 Yao Qi <yao.qi@linaro.org>
4155
4156 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
4157 aspace const.
4158 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
4159 Likewise.
4160 * breakpoint.c (bpstat_check_location): Remove cast.
4161 (breakpoint_hit_catch_fork): Make aspce const.
4162 (breakpoint_hit_catch_solib): Likewise.
4163 (breakpoint_hit_catch_exec): Likewise.
4164 (breakpoint_hit_ranged_breakpoint): Likewise.
4165 (breakpoint_hit_watchpoint): Likewise.
4166 (base_breakpoint_breakpoint_hit): Likewise.
4167 (bkpt_breakpoint_hit): Likewise.
4168 (dprintf_breakpoint_hit): Likewise.
4169 (tracepoint_breakpoint_hit): Likewise.
4170 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
4171
4172 2017-10-26 Yao Qi <yao.qi@linaro.org>
4173
4174 * breakpoint.c (breakpoint_location_address_match): Change
4175 "struct address_space *" to "const address_space".
4176 (breakpoint_location_address_range_overlap): Likewise.
4177 (breakpoint_here_p): Likewise.
4178 (breakpoint_in_range_p): Likewise.
4179 (moribund_breakpoint_here_p): Likewise.
4180 (bp_location_inserted_here_p): Likewise.
4181 (software_breakpoint_inserted_here_p): Likewise.
4182 (hardware_breakpoint_inserted_here_p): Likewise.
4183 (hardware_watchpoint_inserted_in_range): Likewise.
4184 (bpstat_check_location): Likewise.
4185 (bpstat_stop_status): Likewise.
4186 (breakpoint_address_match): Likewise.
4187 (breakpoint_address_match_range): Likewise.
4188 (breakpoint_location_address_match): Likewise.
4189 (breakpoint_location_address_range_overlap): Likewise.
4190 (insert_single_step_breakpoint): Likewise.
4191 (breakpoint_has_location_inserted_here): Likewise.
4192 (single_step_breakpoint_inserted_here_p): Likewise.
4193 (pc_at_non_inline_function): Likewise.
4194 * breakpoint.h (bpstat_stop_status): Update declaration.
4195 (breakpoint_here_p): Likewise.
4196 (breakpoint_in_range_p): Likewise.
4197 (moribund_breakpoint_here_p): Likewise.
4198 (breakpoint_inserted_here_p): Likewise.
4199 (software_breakpoint_inserted_here_p): Likewise.
4200 (hardware_breakpoint_inserted_here_p): Likewise.
4201 (breakpoint_has_location_inserted_here): Likewise.
4202 (single_step_breakpoint_inserted_here_p): Likewise.
4203 (hardware_watchpoint_inserted_in_range): Likewise.
4204 (breakpoint_address_match): Likewise.
4205 (insert_single_step_breakpoint): Likewise.
4206 (pc_at_non_inline_function): Likewise.
4207 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
4208 * record.c (record_check_stopped_by_breakpoint): Likewise.
4209 * record.h (record_check_stopped_by_breakpoint): Likewise.
4210 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
4211
4212 2017-10-25 Yao Qi <yao.qi@linaro.org>
4213
4214 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
4215 regcache->arch () instead get_regcache_arch.
4216 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
4217 Likewise.
4218 (aarch64_fbsd_store_inferior_registers): Likewise.
4219 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
4220 (store_gregs_to_thread): Likewise.
4221 (fetch_fpregs_from_thread): Likewise.
4222 (store_fpregs_to_thread): Likewise.
4223 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
4224 (aarch64_store_return_value): Likewise.
4225 (aarch64_software_single_step): Likewise.
4226 * aix-thread.c (aix_thread_wait): Likewise.
4227 (supply_reg32): Likewise.
4228 (supply_sprs64): Likewise.
4229 (supply_sprs32): Likewise.
4230 (fill_gprs64): Likewise.
4231 (fill_gprs32): Likewise.
4232 (fill_sprs64): Likewise.
4233 (fill_sprs32): Likewise.
4234 (store_regs_user_thread): Likewise.
4235 (store_regs_kernel_thread): Likewise.
4236 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
4237 (alphabsd_store_inferior_registers): Likewise.
4238 * alpha-tdep.c (alpha_extract_return_value): Likewise.
4239 (alpha_store_return_value): Likewise.
4240 (alpha_deal_with_atomic_sequence): Likewise.
4241 (alpha_next_pc): Likewise.
4242 (alpha_software_single_step): Likewise.
4243 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
4244 (amd64bsd_store_inferior_registers): Likewise.
4245 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
4246 Likewise.
4247 (amd64_linux_store_inferior_registers): Likewise.
4248 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
4249 (amd64_collect_native_gregset): Likewise.
4250 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
4251 (amd64obsd_collect_uthread): Likewise.
4252 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
4253 (amd64_collect_fpregset): Likewise.
4254 (amd64_supply_fxsave): Likewise.
4255 (amd64_supply_xsave): Likewise.
4256 (amd64_collect_fxsave): Likewise.
4257 (amd64_collect_xsave): Likewise.
4258 * arc-tdep.c (arc_write_pc): Likewise.
4259 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
4260 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
4261 (arm_fbsd_store_inferior_registers): Likewise.
4262 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
4263 (store_vfp_regs): Likewise.
4264 (arm_linux_fetch_inferior_registers): Likewise.
4265 (arm_linux_store_inferior_registers): Likewise.
4266 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
4267 (arm_linux_sigreturn_next_pc): Likewise.
4268 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
4269 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
4270 (fetch_register): Likewise.
4271 (store_register): Likewise.
4272 * arm-tdep.c (arm_is_thumb): Likewise.
4273 (displaced_in_arm_mode): Likewise.
4274 (bx_write_pc): Likewise.
4275 (arm_get_next_pcs_addr_bits_remove): Likewise.
4276 (arm_software_single_step): Likewise.
4277 (arm_extract_return_value): Likewise.
4278 (arm_store_return_value): Likewise.
4279 (arm_write_pc): Likewise.
4280 * bfin-tdep.c (bfin_extract_return_value): Likewise.
4281 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
4282 (bsd_uthread_store_registers): Likewise.
4283 * core-regset.c (fetch_core_registers): Likewise.
4284 * corelow.c (get_core_registers): Likewise.
4285 * cris-tdep.c (cris_store_return_value): Likewise.
4286 (cris_extract_return_value): Likewise.
4287 (find_step_target): Likewise.
4288 (find_step_target): Likewise.
4289 (cris_software_single_step): Likewise.
4290 * ctf.c (ctf_fetch_registers): Likewise.
4291 * darwin-nat.c (cancel_breakpoint): Likewise.
4292 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
4293 * frv-tdep.c (frv_extract_return_value): Likewise.
4294 * ft32-tdep.c (ft32_store_return_value): Likewise.
4295 (ft32_extract_return_value): Likewise.
4296 * go32-nat.c (fetch_register): Likewise.
4297 (go32_fetch_registers): Likewise.
4298 (go32_store_registers): Likewise.
4299 (store_register): Likewise.
4300 * h8300-tdep.c (h8300_extract_return_value): Likewise.
4301 (h8300_store_return_value): Likewise.
4302 * hppa-linux-nat.c (fetch_register): Likewise.
4303 (store_register): Likewise.
4304 (hppa_linux_fetch_inferior_registers): Likewise.
4305 (hppa_linux_store_inferior_registers): Likewise.
4306 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
4307 (i386_darwin_store_inferior_registers): Likewise.
4308 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
4309 (gnu_store_registers): Likewise.
4310 * i386-linux-nat.c (fetch_register): Likewise.
4311 (store_register): Likewise.
4312 (supply_gregset): Likewise.
4313 (fill_gregset): Likewise.
4314 (i386_linux_fetch_inferior_registers): Likewise.
4315 (i386_linux_store_inferior_registers): Likewise.
4316 (i386_linux_resume): Likewise.
4317 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
4318 Likewise.
4319 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
4320 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
4321 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
4322 (i386obsd_collect_uthread): Likewise.
4323 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4324 (i386_supply_gregset): Likewise.
4325 (i386_collect_gregset): Likewise.
4326 (i386_supply_fpregset): Likewise.
4327 (i386_collect_fpregset): Likewise.
4328 (i386_mpx_bd_base): Likewise.
4329 * i386-v4-nat.c (supply_fpregset): Likewise.
4330 (fill_fpregset): Likewise.
4331 * i387-tdep.c (i387_supply_fsave): Likewise.
4332 (i387_collect_fsave): Likewise.
4333 (i387_supply_fxsave): Likewise.
4334 (i387_collect_fxsave): Likewise.
4335 (i387_supply_xsave): Likewise.
4336 (i387_collect_xsave): Likewise.
4337 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
4338 (ia64_linux_store_registers): Likewise.
4339 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
4340 (ia64_extract_return_value): Likewise.
4341 (ia64_store_return_value): Likewise.
4342 (find_func_descr): Likewise.
4343 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
4344 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
4345 (inf_ptrace_store_registers): Likewise.
4346 * infrun.c (use_displaced_stepping): Likewise.
4347 (displaced_step_prepare_throw): Likewise.
4348 (resume): Likewise.
4349 (proceed): Likewise.
4350 (do_target_wait): Likewise.
4351 (adjust_pc_after_break): Likewise.
4352 (handle_inferior_event_1): Likewise.
4353 (handle_signal_stop): Likewise.
4354 (save_infcall_suspend_state): Likewise.
4355 (restore_infcall_suspend_state): Likewise.
4356 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
4357 * jit.c (jit_frame_prev_register): Likewise.
4358 * linux-nat.c (save_stop_reason): Likewise.
4359 (linux_nat_wait_1): Likewise.
4360 (resume_stopped_resumed_lwps): Likewise.
4361 * linux-record.c (record_linux_sockaddr): Likewise.
4362 (record_linux_msghdr): Likewise.
4363 (record_linux_system_call): Likewise.
4364 * linux-tdep.c (linux_collect_thread_registers): Likewise.
4365 * lm32-tdep.c (lm32_extract_return_value): Likewise.
4366 (lm32_store_return_value): Likewise.
4367 * m32c-tdep.c (m32c_read_flg): Likewise.
4368 (m32c_pseudo_register_read): Likewise.
4369 (m32c_pseudo_register_write): Likewise.
4370 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
4371 (m32r_linux_collect_gregset): Likewise.
4372 * m32r-tdep.c (m32r_store_return_value): Likewise.
4373 (m32r_extract_return_value): Likewise.
4374 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
4375 (m68kbsd_collect_fpregset): Likewise.
4376 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
4377 * m68k-linux-nat.c (fetch_register): Likewise.
4378 (old_fetch_inferior_registers): Likewise.
4379 (old_store_inferior_registers): Likewise.
4380 (store_regs): Likewise.
4381 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
4382 (m68k_svr4_store_return_value): Likewise.
4383 * m88k-tdep.c (m88k_store_arguments): Likewise.
4384 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
4385 (mi_cmd_data_write_register_values): Likewise.
4386 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
4387 (mips_fbsd_store_inferior_registers): Likewise.
4388 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
4389 (mips_fbsd_supply_gregs): Likewise.
4390 (mips_fbsd_collect_fpregs): Likewise.
4391 (mips_fbsd_collect_gregs): Likewise.
4392 (mips_fbsd_supply_fpregset): Likewise.
4393 (mips_fbsd_collect_fpregset): Likewise.
4394 (mips_fbsd_supply_gregset): Likewise.
4395 (mips_fbsd_collect_gregset): Likewise.
4396 * mips-linux-nat.c (supply_gregset): Likewise.
4397 (fill_gregset): Likewise.
4398 (supply_fpregset): Likewise.
4399 (fill_fpregset): Likewise.
4400 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
4401 (mips_fill_gregset): Likewise.
4402 (mips_supply_fpregset): Likewise.
4403 (mips_fill_fpregset): Likewise.
4404 (mips64_supply_gregset): Likewise.
4405 (micromips_linux_sigframe_validate): Likewise.
4406 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
4407 (mipsnbsd_fetch_inferior_registers): Likewise.
4408 (mipsnbsd_store_inferior_registers): Likewise.
4409 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
4410 (mipsnbsd_supply_gregset): Likewise.
4411 (mipsnbsd_iterate_over_regset_sections): Likewise.
4412 (mipsnbsd_supply_reg): Likewise.
4413 (mipsnbsd_supply_fpreg): Likewise.
4414 * mips-tdep.c (mips_in_frame_stub): Likewise.
4415 (mips_dummy_id): Likewise.
4416 (is_octeon_bbit_op): Likewise.
4417 (micromips_bc1_pc): Likewise.
4418 (extended_mips16_next_pc): Likewise.
4419 (mips16_next_pc): Likewise.
4420 (deal_with_atomic_sequence): Likewise.
4421 * moxie-tdep.c (moxie_process_readu): Likewise.
4422 * nios2-tdep.c (nios2_get_next_pc): Likewise.
4423 * nto-procfs.c (procfs_store_registers): Likewise.
4424 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
4425 (ppcfbsd_store_inferior_registers): Likewise.
4426 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
4427 (fetch_altivec_register): Likewise.
4428 (get_spe_registers): Likewise.
4429 (fetch_spe_register): Likewise.
4430 (fetch_altivec_registers): Likewise.
4431 (fetch_all_gp_regs): Likewise.
4432 (fetch_all_fp_regs): Likewise.
4433 (store_vsx_register): Likewise.
4434 (store_altivec_register): Likewise.
4435 (set_spe_registers): Likewise.
4436 (store_spe_register): Likewise.
4437 (store_altivec_registers): Likewise.
4438 (store_all_gp_regs): Likewise.
4439 (store_all_fp_regs): Likewise.
4440 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4441 (ppc_linux_collect_gregset): Likewise.
4442 (ppc_canonicalize_syscall): Likewise.
4443 (ppc_linux_record_signal): Likewise.
4444 (ppu2spu_prev_register): Likewise.
4445 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4446 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4447 (ppcobsd_store_registers): Likewise.
4448 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4449 Likewise.
4450 (ppc_ravenscar_generic_store_registers): Likewise.
4451 * procfs.c (procfs_fetch_registers): Likewise.
4452 (procfs_store_registers): Likewise.
4453 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4454 (ravenscar_store_registers): Likewise.
4455 (ravenscar_prepare_to_store): Likewise.
4456 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4457 * record-full.c (record_full_wait_1): Likewise.
4458 (record_full_registers_change): Likewise.
4459 (record_full_store_registers): Likewise.
4460 (record_full_core_fetch_registers): Likewise.
4461 (record_full_save): Likewise.
4462 (record_full_goto_insn): Likewise.
4463 * regcache.c (regcache_register_size): Likewise.
4464 (get_regcache_arch): Remove.
4465 (regcache_read_pc): Likewise.
4466 * regcache.h (get_regcache_arch): Remove.
4467 * remote-sim.c (gdbsim_fetch_register): Likewise.
4468 (gdbsim_store_register): Likewise.
4469 * remote.c (fetch_register_using_p): Likewise.
4470 (send_g_packet): Likewise.
4471 (remote_prepare_to_store): Likewise.
4472 (store_registers_using_G): Likewise.
4473 * reverse.c (save_bookmark_command): Likewise.
4474 (goto_bookmark_command): Likewise.
4475 * rs6000-aix-tdep.c (branch_dest): Likewise.
4476 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4477 (fetch_register): Likewise.
4478 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4479 (ppc_collect_reg): Likewise.
4480 (ppc_collect_gregset): Likewise.
4481 (ppc_collect_fpregset): Likewise.
4482 (ppc_collect_vsxregset): Likewise.
4483 (ppc_collect_vrregset): Likewise.
4484 (ppc_displaced_step_hw_singlestep): Likewise.
4485 (rs6000_pseudo_register_read): Likewise.
4486 (rs6000_pseudo_register_write): Likewise.
4487 * s390-linux-nat.c (supply_gregset): Likewise.
4488 (fill_gregset): Likewise.
4489 (s390_linux_fetch_inferior_registers): Likewise.
4490 * s390-linux-tdep.c (s390_write_pc): Likewise.
4491 (s390_software_single_step): Likewise.
4492 (s390_all_but_pc_registers_record): Likewise.
4493 (s390_linux_syscall_record): Likewise.
4494 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4495 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4496 (shnbsd_store_inferior_registers): Likewise.
4497 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4498 (sh_extract_return_value_fpu): Likewise.
4499 (sh_store_return_value_nofpu): Likewise.
4500 (sh_corefile_supply_regset): Likewise.
4501 (sh_corefile_collect_regset): Likewise.
4502 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4503 (sh64_store_return_value): Likewise.
4504 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4505 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4506 (sparc_store_inferior_registers): Likewise.
4507 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4508 (sparc_ravenscar_prepare_to_store): Likewise.
4509 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4510 (sparc_analyze_control_transfer): Likewise.
4511 (sparc_step_trap): Likewise.
4512 (sparc_software_single_step): Likewise.
4513 (sparc32_gdbarch_init): Likewise.
4514 (sparc_supply_rwindow): Likewise.
4515 (sparc_collect_rwindow): Likewise.
4516 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4517 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4518 (sparc64nbsd_collect_gregset): Likewise.
4519 (sparc64nbsd_supply_fpregset): Likewise.
4520 (sparc64nbsd_collect_fpregset): Likewise.
4521 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4522 (sparc64_supply_gregset): Likewise.
4523 (sparc64_collect_gregset): Likewise.
4524 (sparc64_supply_fpregset): Likewise.
4525 (sparc64_collect_fpregset): Likewise.
4526 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4527 * spu-tdep.c (spu_unwind_sp): Likewise.
4528 (spu2ppu_prev_register): Likewise.
4529 (spu_memory_remove_breakpoint): Likewise.
4530 * stack.c (return_command): Likewise.
4531 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4532 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4533 * tracefile.c (trace_save_ctf): Likewise.
4534 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4535 (do_windows_store_inferior_registers): Likewise.
4536 (windows_resume): Likewise.
4537 * xtensa-linux-nat.c (fill_gregset): Likewise.
4538 (supply_gregset_reg): Likewise.
4539 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4540 (xtensa_register_read_masked): Likewise.
4541 (xtensa_supply_gregset): Likewise.
4542 (xtensa_extract_return_value): Likewise.
4543 (xtensa_store_return_value): Likewise.
4544
4545 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4546
4547 * doublest.c (floatformat_from_string): New function.
4548 * doublest.h (floatformat_from_string): Add prototype.
4549
4550 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4551 (OP_FLOAT): ... this.
4552 * expression.h: Do not include "doublest.h".
4553 (union exp_element): Replace doubleconst and decfloatconst by
4554 new element floatconst.
4555 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4556 (ada_evaluate_subexp): Likewise.
4557 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4558 OP_DOUBLE and OP_DECFLOAT.
4559 * expprint.c (print_subexp_standard): Likewise.
4560 (dump_subexp_body_standard): Likewise.
4561 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4562
4563 * parse.c: Include "dfp.h".
4564 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4565 (write_exp_elt_floatcst): New function.
4566 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4567 and OP_DECFLOAT.
4568 (operator_check_standard): Likewise.
4569 (parse_float): Do not accept suffix. Take type as input. Return bool.
4570 Return target format buffer instead of host DOUBLEST.
4571 Use floatformat_from_string and decimal_from_string to parse
4572 either binary or decimal floating-point types.
4573 (parse_c_float): Remove.
4574 * parser-defs.h: Do not include "doublest.h".
4575 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4576 (write_exp_elt_floatcst): Add prototype.
4577 (parse_float): Update prototype.
4578 (parse_c_float): Remove.
4579
4580 * c-exp.y: Do not include "dfp.h".
4581 (typed_val_float): Use byte buffer instead of DOUBLEST.
4582 (typed_val_decfloat): Remove.
4583 (DECFLOAT): Remove.
4584 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4585 (parse_number): Update to new parse_float interface.
4586 Parse suffixes and determine type before calling parse_float.
4587 Handle decimal and binary FP types the same way.
4588
4589 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4590 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4591 (parse_number): Update to new parse_float interface.
4592 Parse suffixes and determine type before calling parse_float.
4593
4594 * f-exp.y: Replace dval by typed_val_float.
4595 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4596 (parse_number): Use parse_float instead of atof.
4597
4598 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4599 (parse_go_float): Remove.
4600 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4601 (parse_number): Call parse_float instead of parse_go_float.
4602 Parse suffixes and determine type before calling parse_float.
4603
4604 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4605 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4606 (parse_number): Update to new parse_float interface.
4607 Parse suffixes and determine type before calling parse_float.
4608
4609 * m2-exp.y: Replace dval by byte buffer val.
4610 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4611 (parse_number): Call parse_float instead of atof.
4612
4613 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4614 (lex_number): Call parse_float instead of strtod.
4615 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4616 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4617 Use write_exp_elt_floatcst.
4618 (unit_testing): Remove static variable.
4619 (rust_type): Do not check unit_testing.
4620 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4621
4622 * ada-exp.y (type_float, type_double): Remove.
4623 (typed_val_float): Use byte buffer instead of DOUBLEST.
4624 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4625 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4626
4627 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4628
4629 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4630 * arch/aarch64.h: New file.
4631
4632 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4633
4634 * dfp.h (decimal_from_string): Use const reference for argument.
4635 * dfp.c (decimal_from_string): Likewise.
4636
4637 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4638
4639 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4640 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4641 * mips-tdep.c (mips_print_fp_register): Likewise.
4642
4643 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4644
4645 * common/format.h (enum argclass): Replace decfloat_arg by
4646 dec32float_arg, dec64float_arg, and dec128float_arg.
4647 * common/format.c (parse_format_string): Update to return
4648 new decimal float argument classes.
4649
4650 * printcmd.c (printf_decfloat): Rename to ...
4651 (printf_floating): ... this. Add argclass argument, and use it
4652 instead of parsing the format string again. Add support for
4653 binary floating-point values, using floatformat_to_string.
4654 Convert value to the target format if it doesn't already match.
4655 (ui_printf): Call printf_floating instead of printf_decfloat,
4656 also for double_arg / long_double_arg. Pass argclass.
4657
4658 * dfp.c (decimal_to_string): Add format string argument.
4659 * dfp.h (decimal_to_string): Likewise.
4660
4661 * doublest.c (floatformat_to_string): Add format string argument.
4662 * doublest.h (floatformat_to_string): Likewise.
4663
4664 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4665
4666 * doublest.c (floatformat_precision): New routine.
4667 (floatformat_to_string): Likewise.
4668 * doublest.c (floatformat_to_string): Add prototype.
4669
4670 * printcmd.c (print_scalar_formatted): Only call print_floating
4671 on floating-point types.
4672 * valprint.c: Do not include "floatformat.h".
4673 (generic_val_print_decfloat): Remove.
4674 (generic_val_print): Call generic_val_print_float for both
4675 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4676 (print_floating): Use floatformat_to_string. Handle decimal float.
4677 (print_decimal_floating): Remove, merge into floatformat_to_string.
4678 * value.h (print_decimal_floating): Remove.
4679
4680 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4681
4682 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4683
4684 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4685
4686 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4687
4688 * memattr.h: Don't include vec.h.
4689 (struct mem_attrib): Initialize fields.
4690 <unknown>: New static method.
4691 (struct mem_region): Add constructors, operator<, initialize
4692 fields.
4693 * memattr.c: Include algorithm.
4694 (default_mem_attrib, unknown_mem_attrib): Remove.
4695 (user_mem_region_list): New global.
4696 (target_mem_region_list, mem_region_list): Change type to
4697 std::vector<mem_region>.
4698 (mem_use_target): Now a function.
4699 (target_mem_regions_valid): Change type to bool.
4700 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4701 (require_user_regions): Adjust.
4702 (require_target_regions): Adjust.
4703 (create_mem_region): Adjust.
4704 (lookup_mem_region): Adjust.
4705 (invalidate_target_mem_regions): Adjust.
4706 (mem_clear): Rename to...
4707 (user_mem_clear): ... this, and adjust.
4708 (mem_command): Adjust.
4709 (info_mem_command): Adjust.
4710 (mem_enable, enable_mem_command, mem_disable,
4711 disable_mem_command): Adjust.
4712 (mem_delete): Adjust.
4713 (delete_mem_command): Adjust.
4714 * memory-map.h (parse_memory_map): Return an std::vector.
4715 * memory-map.c (parse_memory_map): Likewise.
4716 (struct memory_map_parsing_data): Add constructor.
4717 <memory_map>: Point to std::vector.
4718 (memory_map_start_memory): Adjust.
4719 (memory_map_end_memory): Adjust.
4720 (memory_map_end_property): Adjust.
4721 (clear_result): Remove.
4722 * remote.c (remote_memory_map): Return an std::vector.
4723 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4724 Remove.
4725 (target_debug_print_mem_region_vector): New.
4726 * target-delegates.c: Regenerate.
4727 * target.h (mem_region_vector): New typedef.
4728 (to_memory_map): Return mem_region_vector.
4729 (target_memory_map): Return an std::vector.
4730 * target.c (target_memory_map): Return an std::vector.
4731 (flash_erase_command): Adjust.
4732
4733 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4734
4735 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4736 Change type to std::string.
4737 (memory_map_start_property): Adjust.
4738 (memory_map_end_property): Adjust.
4739
4740 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4741
4742 * infrun.h: Include common/byte-vector.h.
4743 (struct displaced_step_closure): New struct.
4744 (struct buf_displaced_step_closure): New struct.
4745 * infrun.c (displaced_step_closure::~displaced_step_closure):
4746 Provide default implementation.
4747 (displaced_step_clear): Deallocate step closure with delete.
4748 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4749 (aarch64_displaced_step_closure): ... this, extend
4750 displaced_step_closure.
4751 (aarch64_displaced_step_data) <dsc>: Change type to
4752 aarch64_displaced_step_closure.
4753 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4754 unique_ptr.
4755 (aarch64_displaced_step_fixup): Add cast for displaced step
4756 closure.
4757 * amd64-tdep.c (displaced_step_closure): Rename to ...
4758 (amd64_displaced_step_closure): ... this, extend
4759 displaced_step_closure.
4760 <insn_buf>: Change type to std::vector<gdb_byte>.
4761 <max_len>: Remove.
4762 (fixup_riprel): Change type of DSC parameter, adjust to type
4763 change of insn_buf.
4764 (fixup_displaced_copy): Change type of DSC parameter.
4765 (amd64_displaced_step_copy_insn): Instantiate
4766 amd64_displaced_step_closure.
4767 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4768 to type change of insn_buf.
4769 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4770 parameter DSC.
4771 (arm_linux_copy_svc): Likewise.
4772 (cleanup_kernel_helper_return): Likewise.
4773 (arm_catch_kernel_helper_return): Likewise.
4774 (arm_linux_displaced_step_copy_insn): Instantiate
4775 arm_displaced_step_closure.
4776 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4777 (displaced_read_reg): Change type of parameter DSC.
4778 (branch_write_pc): Likewise.
4779 (load_write_pc): Likewise.
4780 (alu_write_pc): Likewise.
4781 (displaced_write_reg): Likewise.
4782 (arm_copy_unmodified): Likewise.
4783 (thumb_copy_unmodified_32bit): Likewise.
4784 (thumb_copy_unmodified_16bit): Likewise.
4785 (cleanup_preload): Likewise.
4786 (install_preload): Likewise.
4787 (arm_copy_preload): Likewise.
4788 (thumb2_copy_preload): Likewise.
4789 (install_preload_reg): Likewise.
4790 (arm_copy_preload_reg): Likewise.
4791 (cleanup_copro_load_store): Likewise.
4792 (install_copro_load_store): Likewise.
4793 (arm_copy_copro_load_store) Likewise.
4794 (thumb2_copy_copro_load_store): Likewise.
4795 (cleanup_branch): Likewise.
4796 (install_b_bl_blx): Likewise.
4797 (arm_copy_b_bl_blx): Likewise.
4798 (thumb2_copy_b_bl_blx): Likewise.
4799 (thumb_copy_b): Likewise.
4800 (install_bx_blx_reg): Likewise.
4801 (arm_copy_bx_blx_reg): Likewise.
4802 (thumb_copy_bx_blx_reg): Likewise.
4803 (cleanup_alu_imm): Likewise.
4804 (arm_copy_alu_imm): Likewise.
4805 (thumb2_copy_alu_imm): Likewise.
4806 (cleanup_alu_reg): Likewise.
4807 (install_alu_reg): Likewise.
4808 (arm_copy_alu_reg): Likewise.
4809 (thumb_copy_alu_reg): Likewise.
4810 (cleanup_alu_shifted_reg): Likewise.
4811 (install_alu_shifted_reg): Likewise.
4812 (arm_copy_alu_shifted_reg): Likewise.
4813 (cleanup_load): Likewise.
4814 (cleanup_store): Likewise.
4815 (arm_copy_extra_ld_st): Likewise.
4816 (install_load_store): Likewise.
4817 (thumb2_copy_load_literal): Likewise.
4818 (thumb2_copy_load_reg_imm): Likewise.
4819 (arm_copy_ldr_str_ldrb_strb): Likewise.
4820 (cleanup_block_load_all): Likewise.
4821 (cleanup_block_store_pc): Likewise.
4822 (cleanup_block_load_pc): Likewise.
4823 (arm_copy_block_xfer): Likewise.
4824 (thumb2_copy_block_xfer): Likewise.
4825 (cleanup_svc): Likewise.
4826 (install_svc): Likewise.
4827 (arm_copy_svc): Likewise.
4828 (thumb_copy_svc): Likewise.
4829 (arm_copy_undef): Likewise.
4830 (thumb_32bit_copy_undef): Likewise.
4831 (arm_copy_unpred): Likewise.
4832 (arm_decode_misc_memhint_neon): Likewise.
4833 (arm_decode_unconditional): Likewise.
4834 (arm_decode_miscellaneous): Likewise.
4835 (arm_decode_dp_misc): Likewise.
4836 (arm_decode_ld_st_word_ubyte): Likewise.
4837 (arm_decode_media): Likewise.
4838 (arm_decode_b_bl_ldmstm): Likewise.
4839 (arm_decode_ext_reg_ld_st): Likewise.
4840 (thumb2_decode_dp_shift_reg): Likewise.
4841 (thumb2_decode_ext_reg_ld_st): Likewise.
4842 (arm_decode_svc_copro): Likewise.
4843 (thumb2_decode_svc_copro): Likewise.
4844 (install_pc_relative): Likewise.
4845 (thumb_copy_pc_relative_16bit): Likewise.
4846 (thumb_decode_pc_relative_16bit): Likewise.
4847 (thumb_copy_pc_relative_32bit): Likewise.
4848 (thumb_copy_16bit_ldr_literal): Likewise.
4849 (thumb_copy_cbnz_cbz): Likewise.
4850 (thumb2_copy_table_branch): Likewise.
4851 (cleanup_pop_pc_16bit_all): Likewise.
4852 (thumb_copy_pop_pc_16bit): Likewise.
4853 (thumb_process_displaced_16bit_insn): Likewise.
4854 (decode_thumb_32bit_ld_mem_hints): Likewise.
4855 (thumb_process_displaced_32bit_insn): Likewise.
4856 (thumb_process_displaced_insn): Likewise.
4857 (arm_process_displaced_insn): Likewise.
4858 (arm_displaced_init_closure): Likewise.
4859 (arm_displaced_step_fixup): Add cast for closure.
4860 * arm-tdep.h: Include infrun.h.
4861 (displaced_step_closure): Rename to ...
4862 (arm_displaced_step_closure): ... this, extend
4863 displaced_step_closure.
4864 <u::svc::copy_svc_os>: Change type of parameter DSC.
4865 <cleanup>: Likewise.
4866 (arm_process_displaced_insn): Likewise.
4867 (arm_displaced_init_closure): Likewise.
4868 (displaced_read_reg): Likewise.
4869 (displaced_write_reg): Likewise.
4870 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4871 Adjust.
4872 * i386-tdep.h: Include infrun.h.
4873 (i386_displaced_step_closure): New typedef.
4874 * i386-tdep.c (i386_displaced_step_copy_insn): Use
4875 i386_displaced_step_closure.
4876 (i386_displaced_step_fixup): Adjust.
4877 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
4878 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
4879 and unique_ptr.
4880 (ppc_displaced_step_fixup): Adjust.
4881 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
4882 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
4883 and unique_ptr.
4884 (s390_displaced_step_fixup): Adjust.
4885
4886 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4887
4888 * interps.h (interp_resume, interp_suspend, interp_set_temp):
4889 Remove declarations.
4890
4891 2017-10-20 Tom Tromey <tom@tromey.com>
4892
4893 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
4894 std::vector.
4895 (gdb_bfd_record_inclusion): Update.
4896 (bfdp): Remove typedef.
4897
4898 2017-10-20 Tom Tromey <tom@tromey.com>
4899
4900 * gdb_bfd.c (gdb_bfd_ref): Use new.
4901 (struct gdb_bfd_data): Add constructor, destructor, and member
4902 initializers.
4903 (gdb_bfd_unref): Use delete.
4904
4905 2017-10-20 Tom Tromey <tom@tromey.com>
4906
4907 * exec.c (exec_file_attach): Use new_bfd_ref.
4908 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
4909 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4910 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
4911 new_bfd_ref.
4912 * gdb_bfd.h (new_bfd_ref): New function.
4913
4914 2017-10-20 Pedro Alves <palves@redhat.com>
4915
4916 * main.c (captured_command_loop): Add attribute noinline.
4917
4918 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
4919
4920 * interps.c (struct interp_factory): Add constructor.
4921 (interp_factory_p): Remove typedef.
4922 (DEF_VEC_P(interp_factory_p)): Remove.
4923 (interpreter_factories): Change type to std::vector.
4924 (interp_factory_register): Adjust.
4925 (interp_lookup): Adjust.
4926 (interpreter_completer): Adjust.
4927
4928 2017-10-19 Tom Tromey <tom@tromey.com>
4929
4930 * break-catch-syscall.c (catch_syscall_completer): Use
4931 std::string, gdb::unique_xmalloc_ptr.
4932
4933 2017-10-19 Tom Tromey <tom@tromey.com>
4934
4935 * infcall.c (call_function_by_hand_dummy): Use std::string.
4936
4937 2017-10-19 Tom Tromey <tom@tromey.com>
4938
4939 * mi/mi-main.c (mi_cmd_execute): Update.
4940 * top.h (prepare_execute_command): Return scoped_value_mark.
4941 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
4942 Add move constructor.
4943 * top.c (prepare_execute_command): Return scoped_value_mark.
4944 (execute_command): Update.
4945
4946 2017-10-19 Pedro Alves <palves@redhat.com>
4947
4948 * xml-support.c (xml_fetch_content_from_file): Check fread's
4949 return.
4950
4951 2017-10-19 Pedro Alves <palves@redhat.com>
4952
4953 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
4954 async.
4955 (handle_error_fd): New function.
4956 (ser_base_async): Add/delete an event loop file handler for
4957 error_fd.
4958
4959 2017-10-19 Pedro Alves <palves@redhat.com>
4960
4961 * xml-support.c (xml_fetch_content_from_file): Don't read in
4962 chunks. Instead use fseek to determine the file's size, and read
4963 it in one go.
4964
4965 2017-11-18 Keith Seitz <keiths@redhat.com>
4966
4967 * c-exp.y (oper): Canonicalize conversion operators of user-defined
4968 types.
4969 Add whitespace to front of type name.
4970
4971 2017-10-18 Keith Seitz <keiths@redhat.com>
4972
4973 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
4974 DW_AT_accessibility.
4975
4976 2017-10-18 Yao Qi <yao.qi@linaro.org>
4977
4978 * features/tic6x-c62x-linux.c: Remove.
4979
4980 2017-10-17 Tom Tromey <tom@tromey.com>
4981
4982 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
4983 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
4984 (do_mixed_source_and_assembly): Likewise.
4985
4986 2017-10-17 Tom Tromey <tom@tromey.com>
4987
4988 * regcache.c (regcache::xfer_part): Remove assertion.
4989
4990 2017-10-17 Pedro Alves <palves@redhat.com>
4991
4992 * xml-support.c (xml_fetch_content_from_file): Call
4993 unique_ptr::release() instead unique_ptr::get() when passing
4994 through xrealloc.
4995
4996 2017-10-17 Yao Qi <yao.qi@linaro.org>
4997
4998 * regcache.c (regcache::xfer_part): Remove parameters read and
4999 write, add parameter is_raw. All callers are updated.
5000
5001 2017-10-16 Keith Seitz <keiths@redhat.com>
5002
5003 * c-typeprint.c (enum access_specifier): Moved here from
5004 c_type_print_base.
5005 (output_access_specifier): New function.
5006 (c_type_print_base): Consider typedefs when assessing
5007 whether access labels are needed.
5008 Use output_access_specifier as needed.
5009 Output access specifier for typedefs, if needed.
5010 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
5011 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
5012 fields.
5013 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
5014 accessor macros.
5015
5016 2017-10-16 Tom Tromey <tom@tromey.com>
5017
5018 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
5019 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
5020 * target.c (target_fileio_read_stralloc): Update.
5021 * sparc64-tdep.c (adi_is_addr_mapped): Update.
5022 * target.h (target_fileio_read_stralloc): Return
5023 unique_xmalloc_ptr.
5024
5025 2017-10-16 Tom Tromey <tom@tromey.com>
5026
5027 * xml-syscall.c (xml_init_syscalls_info): Update.
5028 * xml-support.c (xinclude_start_include): Update.
5029 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
5030 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
5031 (xml_fetch_content_from_file): Likewise.
5032 * osdata.c (get_osdata): Update.
5033 * target.h (target_read_stralloc, target_get_osdata): Return
5034 unique_xmalloc_ptr.
5035 * solib-aix.c (solib_aix_get_library_list): Update.
5036 * solib-target.c (solib_target_current_sos): Update.
5037 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
5038 * xml-tdesc.c (fetch_available_features_from_target): Update.
5039 (target_fetch_description_xml): Update.
5040 (file_read_description_xml): Update.
5041 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
5042 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
5043 (remote_pid_to_exec_file): Update.
5044 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
5045 (target_get_osdata): Likewise.
5046
5047 2017-10-16 Tom Tromey <tom@tromey.com>
5048
5049 * remote.c (remote_register_number_and_offset): Use std::vector.
5050 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
5051 (putpkt_binary): Use gdb::def_vector.
5052 (compare_sections_command): Use gdb::byte_vector.
5053
5054 2017-10-16 Tom Tromey <tom@tromey.com>
5055
5056 * ppc-linux-nat.c (hwdebug_insert_point): Use
5057 gdb::unique_xmalloc_ptr, XDUP.
5058
5059 2017-10-16 Tom Tromey <tom@tromey.com>
5060
5061 * probe.c (parse_probes): Use std::string.
5062 (info_probes_for_ops, enable_probes_command)
5063 (disable_probes_command): Remove cleanups.
5064
5065 2017-10-16 Tom Tromey <tom@tromey.com>
5066
5067 * buildsym.c (block_compar): Remove.
5068 (end_symtab_get_static_block): Use std::vector.
5069
5070 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
5071
5072 * memrange.h (struct mem_range): Define operator< and operator==.
5073 (mem_range_s): Remove.
5074 (DEF_VEC_O (mem_range_s)): Remove.
5075 (normalize_mem_ranges): Change parameter type to std::vector.
5076 * memrange.c (compare_mem_ranges): Remove.
5077 (normalize_mem_ranges): Change parameter type to std::vector,
5078 adjust to vector change.
5079 * exec.c (section_table_available_memory): Return vector, remove
5080 parameter.
5081 (section_table_read_available_memory): Adjust to std::vector
5082 change.
5083 * remote.c (remote_read_bytes): Adjust to std::vector
5084 change.
5085 * tracepoint.h (traceframe_available_memory): Change parameter
5086 type to std::vector.
5087 * tracepoint.c (traceframe_available_memory): Change parameter
5088 type to std::vector, adjust.
5089 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
5090 std::vector change.
5091 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5092 unittests/memrange-selftests.c.
5093 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
5094 * gdb/unittests/memrange-selftests.c: New file.
5095
5096 2017-10-16 Pedro Alves <palves@redhat.com>
5097
5098 * elfread.c (probe_key_free): Rename range-for variable.
5099 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
5100 (find_probe_by_pc, collect_probes): Rename range-for variable.
5101
5102 2017-10-16 Yao Qi <yao.qi@linaro.org>
5103
5104 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
5105 * features/tic6x-c62x.c: Remove.
5106 * features/tic6x-c64x-linux.c: Remove.
5107 * features/tic6x-c64x.c: Remove.
5108 * features/tic6x-c64xp-linux.c: Remove.
5109 * features/tic6x-c64xp.c: Remove.
5110 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
5111 initialize_tdesc_tic6x_*_linux functions.
5112 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
5113 initialize_tdesc_tic6x_* functions.
5114
5115 2017-10-16 Yao Qi <yao.qi@linaro.org>
5116
5117 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
5118 tic6x-c62x.
5119 * regformats/tic6x-c62x.dat: Remove.
5120 * regformats/tic6x-c64x.dat: Remove.
5121 * regformats/tic6x-c64xp.dat: Remove.
5122
5123 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
5124
5125 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
5126 (the !HAVE_LIBEXPAT version).
5127
5128 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5129
5130 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
5131 const.
5132
5133 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5134
5135 * target.h: Include tracepoint.h.
5136 (enum trace_find_type): Move to tracepoint.h.
5137 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
5138 * tracepoint.h: Don't include target.h
5139 (enum trace_find_type): Move from target.h.
5140 (parse_traceframe_info): Return a unique ptr.
5141 * tracepoint.c (current_traceframe_info): Change type to unique
5142 ptr.
5143 (free_traceframe_info): Remove.
5144 (clear_traceframe_info): Don't manually free
5145 current_traceframe_info.
5146 (free_result): Remove.
5147 (parse_traceframe_info): Return a unique ptr.
5148 (get_traceframe_info): Adjust to unique ptr.
5149 * ctf.c (ctf_traceframe_info): Return a unique ptr.
5150 * remote.c (remote_traceframe_info): Return a unique ptr.
5151 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
5152 ptr.
5153 * target-debug.h (target_debug_print_traceframe_info_up): New
5154 macro.
5155 * target-delegates.c: Regenerate.
5156
5157 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5158
5159 * memrange.h (struct mem_range): Add constructors.
5160 * tracepoint.h (struct traceframe_info) <memory>: Change type to
5161 std::vector<mem_range>.
5162 * tracepoint.c (free_traceframe_info): Don't manually free
5163 vector.
5164 (traceframe_info_start_memory): Adjust to vector change.
5165 (traceframe_available_memory): Likewise.
5166 * tracefile-tfile.c (build_traceframe_info): Likewise.
5167 * ctf.c (ctf_traceframe_info): Likewise.
5168
5169 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5170
5171 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
5172 std::vector<int>.
5173 * tracepoint.c (free_traceframe_info): Deallocate with delete.
5174 (traceframe_info_start_tvar): Adjust to vector change.
5175 (parse_traceframe_info): Allocate with new.
5176 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
5177 vector change.
5178 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
5179 change.
5180 tfile_traceframe_info): Allocate with new.
5181 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
5182 change.
5183
5184 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5185
5186 * tracepoint.c (traceframe_info): Rename to...
5187 (current_traceframe_info): ...this.
5188 (clear_traceframe_info): Adjust.
5189 (get_traceframe_info): Adjust.
5190
5191 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5192
5193 * nat/linux-osdata.c: Include algorithm.
5194 (compare_processes): Remove.
5195 (struct pid_pgid_entry): New struct.
5196 (linux_xfer_osdata_processgroups): Use std::vector instead of
5197 XNEWVEC.
5198
5199 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5200
5201 * objfiles.h: Don't include symfile.h.
5202 (struct partial_symbol): Remove forward-declaration.
5203 (struct objfile) <global_psymbols, static_psymbols>: Change type
5204 to std::vector<partial_symbol *>.
5205 * objfiles.c (objfile::objfile): Don't memset those fields.
5206 (objfile::~objfile): Don't free those fields.
5207 * psympriv.h (struct psymbol_allocation_list): Remove
5208 forward-declaration.
5209 (add_psymbol_to_list): Change psymbol_allocation_list parameter
5210 to std::vector.
5211 (start_psymtab_common): Change parameters to std::vector.
5212 * psymtab.c: Include algorithm.
5213 (require_partial_symbols): Call shrink_to_fit.
5214 (find_pc_sect_psymbol): Adjust to vector change.
5215 (match_partial_symbol): Likewise.
5216 (lookup_partial_symbol): Likewise.
5217 (psym_relocate): Likewise.
5218 (dump_psymtab): Likewise.
5219 (recursively_search_psymtabs): Likewise.
5220 (compare_psymbols): Remove.
5221 (sort_pst_symbols): Adjust to vector change.
5222 (start_psymtab_common): Likewise.
5223 (end_psymtab_common): Likewise.
5224 (psymbol_bcache_full): De-constify return value.
5225 (add_psymbol_to_bcache): Likewise.
5226 (extend_psymbol_list): Remove.
5227 (append_psymbol_to_list): Adjust to vector change.
5228 (add_psymbol_to_list): Likewise.
5229 (init_psymbol_list): Likewise.
5230 (maintenance_info_psymtabs): Likewise.
5231 (maintenance_check_psymtabs): Likewise.
5232 * symfile.h (struct psymbol_allocation_list): Remove.
5233 * symfile.c (reread_symbols): Adjust to vector change.
5234 * dbxread.c (start_psymtab): Change type of parameters.
5235 (dbx_symfile_read): Adjust to vector change.
5236 (read_dbx_symtab): Likewise.
5237 (start_psymtab): Change type of parameters.
5238 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
5239 (create_partial_symtab): Likewise.
5240 (add_partial_symbol): Likewise.
5241 (write_one_signatured_type): Likewise.
5242 (recursively_write_psymbols): Likewise.
5243 * mdebugread.c (parse_partial_symbols): Likewise.
5244 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
5245 (scan_xcoff_symtab): Adjust to vector change.
5246 (xcoff_initial_scan): Likewise.
5247
5248 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
5249
5250 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
5251
5252 2017-10-13 Yao Qi <yao.qi@linaro.org>
5253
5254 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
5255 Remove s390x-*-expedite, add s390x-expedite.
5256
5257 2017-10-13 Yao Qi <yao.qi@linaro.org>
5258
5259 * features/s390-gs-linux64.c: Regenerated.
5260 * features/s390x-gs-linux64.c: Regenerated.
5261
5262 2017-10-13 Tom Tromey <tom@tromey.com>
5263
5264 * compile/compile-object-run.c (do_module_cleanup): Use delete.
5265 * solib.c (update_solib_list, reload_shared_libraries_1): Use
5266 delete.
5267 * symfile.c (symbol_file_add_with_addrs): Use new.
5268 (symbol_file_add_separate): Update comment.
5269 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
5270 * jit.c (jit_object_close_impl): Use new.
5271 (jit_unregister_code): Use delete.
5272 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
5273 (~objfile): Rename from free_objfile.
5274 (free_objfile_separate_debug, do_free_objfile_cleanup)
5275 (free_all_objfiles, objfile_purge_solibs): Use delete.
5276 * objfiles.h (struct objfile): Add constructor and destructor.
5277 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
5278 (allocate_objfile, free_objfile): Don't declare.
5279 (struct objstats): Add initializers.
5280
5281 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5282
5283 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
5284 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
5285 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
5286 * gdbarch.h: Regenerate.
5287 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5288 Adjust comment.
5289 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
5290 (i386_displaced_step_fixup): Adjust comment.
5291 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
5292
5293 2017-10-12 Tom Tromey <tom@tromey.com>
5294
5295 * prologue-value.h (pv_area::store_would_trash): Return bool.
5296 (pv_area::find_reg): Likewise.
5297 * prologue-value.c (pv_area::store_would_trash): Return bool.
5298 (pv_area::find_reg): Likewise.
5299
5300 2017-10-12 Tom Tromey <tom@tromey.com>
5301
5302 * s390-linux-tdep.c (s390_store, s390_load)
5303 (s390_check_for_saved, s390_analyze_prologue): Update.
5304 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
5305 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
5306 * prologue-value.h (class pv_area): Move from prologue-value.c.
5307 Change names of members. Add constructor, destructor, member
5308 functions.
5309 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
5310 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
5311 (pv_area_fetch, pv_area_scan): Don't declare.
5312 * prologue-value.c (struct pv_area::area_entry): Now member of
5313 pv_area.
5314 (struct pv_area): Move to prologue-value.h.
5315 (pv_area::pv_area): Rename from make_pv_area.
5316 (pv_area::~pv_area): Rename from free_pv_area.
5317 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
5318 (clear_entries, find_entry, overlaps, store_would_trash, store)
5319 (fetch, find_reg, scan): Now member of pv_area.
5320 Remove "area" argument. Update.
5321 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
5322 Update.
5323 * mn10300-tdep.c (push_reg, check_for_saved)
5324 (mn10300_analyze_prologue): Update.
5325 * mep-tdep.c (is_arg_spill, check_for_saved)
5326 (mep_analyze_prologue): Update.
5327 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
5328 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
5329 (m32c_is_struct_return, m32c_analyze_prologue): Update.
5330 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
5331 Update.
5332 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
5333 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
5334
5335 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5336
5337 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
5338 * linux-nat.c (linux_nat_delete_thread): New variable.
5339 (lwp_free): Invoke linux_nat_delete_thread if set.
5340 (linux_nat_set_delete_thread): New function.
5341 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
5342 thread delete callback.
5343 * arm-linux-nat.c (arm_linux_delete_thread): New function.
5344 (_initialize_arm_linux_nat): Assign thread delete callback.
5345 * s390-linux-nat.c (s390_delete_thread): New function.
5346 (_initialize_s390_nat): Assign thread delete callback.
5347 * x86-linux-nat.c (x86_linux_add_target): Likewise.
5348 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
5349 function.
5350 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
5351 declaration.
5352 * nat/x86-linux.c (x86_linux_delete_thread): New function.
5353 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
5354
5355 2017-10-09 Tom Tromey <tom@tromey.com>
5356
5357 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
5358 std::string.
5359 * tui/tui-layout.c (enum tui_status): Use std::string.
5360
5361 2017-10-11 Tom Tromey <tom@tromey.com>
5362
5363 * gdbthread.h (thread_command): Constify.
5364 * inferior.h (detach_command): Constify.
5365 * top.h (set_history, show_history): Constify.
5366 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
5367 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
5368 * bsd-kvm.c (bsd_kvm_cmd): Constify.
5369 * printcmd.c (set_command): Constify.
5370 (non_const_set_command): New function.
5371 * dcache.c (set_dcache_command, show_dcache_command): Constify.
5372 * breakpoint.c (enable_command, disable_command, delete_command)
5373 (catch_command, tcatch_command, set_breakpoint_cmd)
5374 (show_breakpoint_cmd): Constify.
5375 * macrocmd.c (macro_command): Constify.
5376 * infcmd.c (unset_command, kill_command, detach_command)
5377 (info_proc_cmd): Constify.
5378 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
5379 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
5380 (info_auto_load_cmd): Constify.
5381 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5382 (unset_tdesc_cmd): Constify.
5383 * ada-lang.c (set_ada_command, show_ada_command)
5384 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
5385 * guile/guile.c (set_guile_command, show_guile_command)
5386 (info_guile_command): Constify.
5387 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
5388 Constify.
5389 * skip.c (skip_command): Constify.
5390 * compile/compile.c (_initialize_compile): Constify.
5391 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
5392 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5393 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5394 (maint_btrace_pt_show_cmd): Constify.
5395 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
5396 Constify.
5397 * python/python.c (user_show_python, user_set_python): Constify.
5398 * mips-tdep.c (set_mips_command, show_mips_command)
5399 (set_mipsfpu_command): Constify.
5400 * record-btrace.c (cmd_record_btrace_start)
5401 (cmd_set_record_btrace, cmd_show_record_btrace)
5402 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
5403 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
5404 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
5405 Constify.
5406 * symfile.c (overlay_command): Constify.
5407 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
5408 * cli/cli-logging.c (set_logging_command, show_logging_command):
5409 Constify.
5410 * cli/cli-dump.c (dump_command, append_command)
5411 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5412 (tekhex_dump_command, binary_dump_command)
5413 (binary_append_command): Constify.
5414 * cli/cli-decode.c (struct cmd_list_element): Change type of
5415 "fun".
5416 * cli/cli-cmds.c (info_command, show_command, set_debug)
5417 (show_debug): Constify.
5418 (show_command): Add non-const overload.
5419 * top.c (set_history, show_history): Constify.
5420 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
5421 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
5422 * target.c (target_command): Constify.
5423 * sparc64-tdep.c (info_adi_command): Constify.
5424 * record-full.c (cmd_record_full_start): Constify.
5425 (set_record_full_command): Constify. Fix typo.
5426 (show_record_full_command): Constify.
5427 * thread.c (thread_command, thread_apply_command): Constify.
5428 * memattr.c (dummy_cmd): Constify.
5429 * value.c (function_command): Constify.
5430 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
5431 * probe.c (info_probes_command): Constify.
5432 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5433 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5434 (show_thread_cmd, set_thread_default_cmd)
5435 (show_thread_default_cmd): Constify.
5436 (check_empty): Constify.
5437 * tracepoint.c (tfind_command): Constify.
5438 * cp-support.c (maint_cplus_command): Constify.
5439 * windows-tdep.c (info_w32_command): Constify.
5440 * record.c (cmd_record_start, set_record_command)
5441 (show_record_command, info_record_command, cmd_record_goto):
5442 Constify.
5443 * ravenscar-thread.c (set_ravenscar_command)
5444 (show_ravenscar_command): Constify.
5445 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5446 Constify.
5447 (add_internal_problem_command): Remove casts.
5448 * arc-tdep.c (maintenance_print_arc_command): Constify.
5449 * valprint.c (set_print, show_print, set_print_raw)
5450 (show_print_raw): Constify.
5451 * maint.c (maintenance_command, maintenance_info_command)
5452 (maintenance_print_command, maintenance_set_cmd)
5453 (maintenance_show_cmd, set_per_command_cmd)
5454 (show_per_command_cmd, maintenance_check_command): Constify.
5455 * language.c (set_check, show_check): Constify.
5456 * typeprint.c (show_print_type, set_print_type): Constify.
5457 * go32-nat.c (go32_info_dos_command): Constify.
5458
5459 2017-10-11 Tom Tromey <tom@tromey.com>
5460
5461 * breakpoint.c (prepare_re_set_context): Remove.
5462 (breakpoint_re_set_one): Update. Don't use cleanups.
5463 (breakpoint_re_set): Use scoped_restore, std::string, and
5464 scoped_restore_current_language.
5465
5466 2017-10-11 Tom Tromey <tom@tromey.com>
5467
5468 * breakpoint.c (commands_command_1): Use std::string.
5469 (cleanup_executing_breakpoints): Remove.
5470 (bpstat_do_actions_1): Use scoped_restore.
5471 (bpstat_check_watchpoint): Use std::string.
5472 (decode_static_tracepoint_spec): Likewise.
5473 (break_range_command): Likewise.
5474 (watch_command_1): Likewise.
5475 (compare_breakpoints): Change argument types.
5476 (clear_command): Use std::vector.
5477 (cleanup_executing_breakpoints): Remove.
5478 (update_global_location_list): Use unique_xmalloc_ptr.
5479 (strace_command): Remove unused declaration.
5480
5481 2017-10-11 John Baldwin <jhb@FreeBSD.org>
5482
5483 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5484 * NEWS: Mention new FreeBSD/arm native configuration.
5485 * configure.host: Add arm*-*-freebsd*.
5486 * configure.nat: Likewise.
5487 * arm-fbsd-nat.c: New file.
5488
5489 2017-10-11 John Baldwin <jhb@FreeBSD.org>
5490
5491 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5492 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5493 * NEWS: Mention new FreeBSD/arm target.
5494 * configure.tgt: Add arm*-*-freebsd*.
5495 * arm-fbsd-tdep.c: New file.
5496 * arm-fbsd-tdep.h: New file.
5497
5498 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5499
5500 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5501 `gdbarch_elfcore_write_linux_prpsinfo'.
5502 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5503 method.
5504 (elf_internal_linux_prpsinfo): Remove declaration.
5505 * gdbarch.h: Regenerate.
5506 * gdbarch.c: Regenerate.
5507
5508 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5509
5510 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5511 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5512
5513 2017-10-11 Pedro Alves <palves@redhat.com>
5514
5515 * breakpoint.c (reattach_breakpoints): Delete.
5516 * breakpoint.h (reattach_breakpoints): Delete.
5517
5518 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5519
5520 * symfile.c (registered_sym_fns): Make struct, not typedef.
5521 (DEF_VEC_O (registered_sym_fns)): Remove.
5522 (symtab_fns): Change type to std::vector.
5523 (add_symtab_fns): Adjust.
5524 (find_sym_fns): Adjust.
5525
5526 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5527
5528 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5529 * arc-tdep.h (arc_arch_is_em): New function.
5530 (arc_arch_is_hs): Likewise.
5531
5532 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5533
5534 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5535 parentheses in the declaration.
5536 (macro_lookup_inclusion): Likewise.
5537 (macro_lookup_definition): Likewise.
5538 * p-lang.h (pascal_builtin_types): Likewise.
5539 * tui/tui-data.c (tui_win_list): Likewise.
5540 * tui/tui-data.h (tui_win_list): Likewise.
5541 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5542
5543 2017-10-11 Mark Rages <markrages@gmail.com>
5544
5545 * target-memory.c (block_boundaries): Fix for block address not
5546 aligned on block size.
5547
5548 2017-10-10 Pedro Alves <palves@redhat.com>
5549 Tom Tromey <tom@tromey.com>
5550
5551 * breakpoint.c (struct captured_breakpoint_query_args)
5552 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5553 (print_breakpoint): New.
5554 * breakpoint.h (print_breakpoint): Declare.
5555 * common/common-exceptions.h (enum return_reason): Remove
5556 references to catch_exceptions.
5557 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5558 Delete.
5559 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5560 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5561 * gdb.h: Delete.
5562 * gdbthread.h (thread_select): Declare.
5563 * mi/mi-cmd-break.c: Don't include gdb.h.
5564 (breakpoint_notify): Use print_breakpoint.
5565 * mi/mi-cmd-catch.c: Don't include gdb.h.
5566 * mi/mi-interp.c: Don't include gdb.h.
5567 (mi_print_breakpoint_for_event): New.
5568 (mi_breakpoint_created, mi_breakpoint_modified): Use
5569 mi_print_breakpoint_for_event.
5570 * mi/mi-main.c: Don't include gdb.h.
5571 (mi_cmd_thread_select): Parse the global thread ID here. Use
5572 thread_select instead of gdb_thread_select.
5573 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5574 of using gdb_list_thread_ids.
5575 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5576 FILEIO_ENOSYS here.
5577 (remote_fileio_request): Use TRY/CATCH instead of
5578 catch_exceptions.
5579 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5580 (symbol_file_add_from_memory_wrapper): Delete.
5581 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5582 * thread.c: Don't include gdb.h.
5583 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5584 (thread_alive): Use thread_select.
5585 (do_captured_thread_select): Delete, parts salvaged as ...
5586 (thread_select): ... this new function.
5587 (gdb_thread_select): Delete.
5588
5589 2017-10-10 Pedro Alves <palves@redhat.com>
5590 Tom Tromey <tom@tromey.com>
5591
5592 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5593 and reverse logic.
5594 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5595 No longer macros. Instead ...
5596 (enum wp_check_result): They're now values of this new
5597 enumeration.
5598 (watchpoint_check): Change return type to wp_check_result and
5599 parameter type to bpstat.
5600 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5601 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5602 catch_errors. Reverse logic of watchpoint_check call.
5603 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5604 pointer as parameter.
5605 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5606 * common/common-exceptions.c (throw_exception_sjlj): Update
5607 comments to avoid mentioning catch_errors.
5608 * exceptions.c (catch_errors): Delete.
5609 * exceptions.h: Update comments to avoid mentioning catch_errors.
5610 (catch_errors_ftype, catch_errors): Delete.
5611 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5612 (hook_stop_stub): Delete.
5613 (restore_selected_frame): Change return type to void, and
5614 parameter type to const frame_id &.
5615 (restore_infcall_control_state): Use TRY/CATCH instead of
5616 catch_errors.
5617 * main.c (captured_command_loop): Return void and remove
5618 parameter. Remove references to catch_errors.
5619 (captured_main): Use TRY/CATCH instead of catch_errors.
5620 * objc-lang.c (objc_submethod_helper_data)
5621 (find_objc_msgcall_submethod_helper): Delete.
5622 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5623 catch_errors.
5624 * record-full.c (record_full_message): Return void.
5625 (record_full_message_args, record_full_message_wrapper): Delete.
5626 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5627 instead of catch_errors.
5628 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5629 parameter type to int.
5630 * solib-darwin.c (open_symbol_file_object): Ditto.
5631 * solib-dsbt.c (open_symbol_file_object): Ditto.
5632 * solib-frv.c (open_symbol_file_object): Ditto.
5633 * solib-svr4.c (open_symbol_file_object): Ditto.
5634 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5635 * solib.c (update_solib_list): Use TRY/CATCH instead of
5636 catch_errors.
5637 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5638 Change type.
5639 * symmisc.c (struct print_symbol_args): Remove.
5640 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5641 (print_symbol): Change type.
5642 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5643 and remove parameters.
5644 (catch_errors): New.
5645 (get_windows_debug_event): Adjust.
5646
5647 2017-10-09 Tom Tromey <tom@tromey.com>
5648
5649 * mi/mi-main.c (free_splay_tree): Remove.
5650 (list_available_thread_groups): Use splay_tree_up.
5651 * common/gdb_splay_tree.h: New file.
5652
5653 2017-10-09 Tom Tromey <tom@tromey.com>
5654
5655 * mi/mi-main.c (do_nothing): Remove.
5656 (list_available_thread_groups): Update.
5657
5658 2017-10-09 Pedro Alves <palves@redhat.com>
5659
5660 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5661 reading registers when switching context.
5662
5663 2017-10-09 John Baldwin <jhb@FreeBSD.org>
5664
5665 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5666 (fbsd_convert_siginfo): Likewise.
5667 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5668
5669 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5670
5671 * configure.ac (try_guile_versions): Remove guile-2.2.
5672 * configure: Regenerate.
5673
5674 2017-10-09 Tom Tromey <tom@tromey.com>
5675
5676 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5677 (COMPILE.pre): Use $(CXX).
5678
5679 2017-10-09 Pedro Alves <palves@redhat.com>
5680
5681 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5682 Use bool.
5683 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5684 * cp-support.h (cp_remove_params): Now returns a
5685 gdb::unique_xmalloc_ptr.
5686 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5687 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5688 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5689 returning a gdb::unique_xmalloc_ptr.
5690 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5691 * stack.c (find_frame_funname): Adjust to cp_remove_params
5692 returning a gdb::unique_xmalloc_ptr.
5693
5694 2017-10-08 Tom Tromey <tom@tromey.com>
5695
5696 * dwarf2read.c (dwarf2_get_dwz_file): Use
5697 gdb::unique_xmalloc_ptr.
5698 (find_slot_in_mapped_hash): Likewise.
5699 (dwarf2_physname): Likewise.
5700 (create_dwo_unit_in_dwp_v1): Use std::string.
5701 (create_dwo_unit_in_dwp_v2): Likewise.
5702 (lookup_dwo_cutu): Likewise.
5703 (inherit_abstract_dies): Use std::vector.
5704 (read_array_type): Likewise.
5705 (dwarf_decode_macros): Remove unused declaration.
5706 (unsigned_int_compar): Remove.
5707 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5708 (psymtabs_addrmap_cleanup): Remove.
5709
5710 2017-10-08 Tom Tromey <tom@tromey.com>
5711
5712 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5713 * frame.h (frame_cleanup_after_sniffer): Declare.
5714 (frame_prepare_for_sniffer): Return void.
5715 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5716 type of argument.
5717 (frame_prepare_for_sniffer): Return void.
5718
5719 2017-10-08 Tom Tromey <tom@tromey.com>
5720
5721 * utils.h (make_cleanup_value_free): Remove.
5722 * utils.c (do_value_free, struct cleanup): Remove.
5723 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5724 Use gdb_value_up.
5725 * value.h (struct value_deleter): New.
5726 (gdb_value_up): New typedef.
5727
5728 2017-10-08 Tom Tromey <tom@tromey.com>
5729
5730 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5731 (make_cleanup_free_search_symbols): Remove.
5732 (search_symbols): Return std::vector.
5733 (symbol_search::compare_search_syms): Now member of
5734 symbol_search. Change arguments.
5735 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5736 (symtab_symbol_info, rbreak_command): Update.
5737 * symtab.h (struct symbol_search) <next>: Remove.
5738 Add constructors.
5739 (symbol_search::operator<): New function.
5740 (symbol_search::operator==): New function.
5741 (search_symbols): Remove std::vector.
5742 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5743 (symbol_search::compare_search_syms): Declare.
5744
5745 2017-10-06 Yao Qi <yao.qi@linaro.org>
5746
5747 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5748 arch/aarch64-insn.o.
5749 Remove one rule.
5750 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5751
5752 2017-10-06 Yao Qi <yao.qi@linaro.org>
5753
5754 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5755 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5756 arch/arm-linux.o respectively.
5757 * configure.tgt: Likewise.
5758
5759 2017-10-06 Yao Qi <yao.qi@linaro.org>
5760
5761 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5762 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5763
5764 2017-10-06 Pedro Alves <palves@redhat.com>
5765
5766 * windows-nat.c: Include <algorithm>.
5767
5768 2017-10-06 Yao Qi <yao.qi@linaro.org>
5769
5770 * configure.tgt (i386_tobjs): New variable.
5771 (amd64_tobjs): New variable.
5772 Set $cpu_obs and $os_obs.
5773
5774 2017-10-06 Yao Qi <yao.qi@linaro.org>
5775
5776 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5777 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
5778 (clean): Remove object files and dependency files.
5779 (distclean): Remove the directory.
5780 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5781 * configure: Re-generated.
5782 * configure.tgt: Replace amd64.o with arch/amd64.o.
5783
5784 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
5785
5786 PR build/22188
5787 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
5788 and SETEND.
5789
5790 2017-10-05 Pedro Alves <palves@redhat.com>
5791
5792 * linux-nat.c (linux_child_follow_fork): When following the parent
5793 and detaching the child, consult the parent thread's architecture
5794 instead of the child's.
5795
5796 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5797
5798 * ax.h: Do not include "doublest.h".
5799 (union agent_val): Remove.
5800
5801 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5802
5803 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
5804 (decimal_to_string): Return std::string object.
5805 (decimal_from_string): Accept std::string object. Return bool.
5806 (decimal_from_integral, decimal_from_doublest): Remove.
5807 (decimal_from_longest): Add prototype.
5808 (decimal_from_ulongest): Likewise.
5809 (decimal_to_longest): Likewise.
5810 (decimal_from_doublest): Likewise.
5811 * dfp.c: Do not include "gdbtypes.h" or "value.h".
5812 (MAX_DECIMAL_STRING): Move here.
5813 (decimal_to_string): Return std::string object.
5814 (decimal_from_string): Accept std::string object. Return bool.
5815 (decimal_from_integral): Remove, replace by ...
5816 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
5817 (decimal_to_longest): New function.
5818 (decimal_from_floating): Remove, replace by ...
5819 (decimal_from_doublest): ... this new function.
5820 (decimal_to_doublest): Update to new decimal_to_string interface.
5821
5822 * value.c (unpack_long): Use decimal_to_longest.
5823 * valops.c (value_cast): Use decimal_from_doublest instead of
5824 decimal_from_floating. Use decimal_from_[u]longest isntead of
5825 decimal_from_integral.
5826 * valarith.c (value_args_as_decimal): Likewise.
5827 * valprint.c (print_decimal_floating): Update to new
5828 decimal_to_string interface.
5829 * printcmd.c (printf_decfloat): Likewise.
5830 * c-exp.y (parse_number): Update to new decimal_from_string interface.
5831
5832 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5833
5834 * doublest.h: Do not include "floatformat.h". Remove stale comments.
5835 * gdbtypes.c: Include "floatformat.h".
5836 * value.c: Likewise.
5837 * m68k-tdep.c: Likewise.
5838
5839 * findvar.c: Do not include "floatformat.h".
5840 * amd64-darwin-tdep.c: Likewise.
5841 * arm-linux-tdep.c: Likewise.
5842 * i386-darwin-tdep.c: Likewise.
5843 * i387-tdep.c: Likewise.
5844 * m68k-linux-tdep.c: Likewise.
5845 * mep-tdep.c: Likewise.
5846 * mips-tdep.c: Likewise.
5847 * nios2-tdep.c: Likewise.
5848 * s390-linux-tdep.c: Likewise.
5849 * sparc-obsd-tdep.c: Likewise.
5850 * sparc-tdep.c: Likewise.
5851 * sparc64-tdep.c: Likewise.
5852 * spu-tdep.c: Likewise.
5853 * tic6x-tdep.c: Likewise.
5854 * tilegx-tdep.c: Likewise.
5855 * vax-tdep.c: Likewise.
5856 * xstormy16-tdep.c: Likewise.
5857 * xtensa-tdep.c: Likewise.
5858
5859 * top.c: Do not include "doublest.h".
5860 * aarch64-tdep.c: Likewise.
5861 * alpha-tdep.c: Likewise.
5862 * arm-linux-tdep.c: Likewise.
5863 * m68k-linux-tdep.c: Likewise.
5864 * tilegx-tdep.c: Likewise.
5865 * xstormy16-tdep.c: Likewise.
5866
5867 2017-10-05 John Baldwin <jhb@FreeBSD.org>
5868
5869 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
5870 (mipsn32_fbsd_sigframe): Define.
5871 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
5872 for FreeBSD/mipsn32.
5873
5874 2017-10-05 John Baldwin <jhb@FreeBSD.org>
5875
5876 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
5877 AT_HWCAP.
5878
5879 2017-10-05 Tristan Gingold <tgingold@free.fr>
5880
5881 * MAINTAINERS (Misc): Update my email address.
5882
5883 2017-10-04 Pedro Alves <palves@redhat.com>
5884
5885 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
5886 it instead of target_gdbarch.
5887 (get_remote_state, get_remote_packet_size): Adjust
5888 get_remote_arch_state calls, passing down target_gdbarch
5889 explicitly.
5890 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
5891 'gdbarch' and use it instead of target_gdbarch.
5892 (get_memory_packet_size): Adjust get_remote_arch_state calls,
5893 passing down target_gdbarch explicitly.
5894 (struct stop_reply) <arch>: New field.
5895 (remote_parse_stop_reply): Use the stopped thread's architecture,
5896 not the current inferior's. Save the architecture in the
5897 stop_reply.
5898 (process_stop_reply): Use the stop reply's architecture.
5899 (process_g_packet, remote_fetch_registers)
5900 (remote_prepare_to_store, store_registers_using_G)
5901 (remote_store_registers): Adjust get_remote_arch_state calls,
5902 using the regcache's architecture.
5903 (remote_get_trace_status): Adjust get_remote_arch_state calls,
5904 passing down target_gdbarch explicitly.
5905 * spu-multiarch.c (spu_thread_architecture): Defer to the target
5906 beneath instead of calling target_gdbarch.
5907 * target.c (default_thread_architecture): Use the specified
5908 inferior's architecture, instead of the current inferior's
5909 architecture (via target_gdbarch).
5910
5911 2017-10-04 Pedro Alves <palves@redhat.com>
5912
5913 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
5914 case.
5915 (regcache_print): Handle !target_has_registers here instead.
5916
5917 2017-10-04 Pedro Alves <palves@redhat.com>
5918
5919 * frame.c (create_test_frame): Delete.
5920 * frame.h (create_test_frame): Delete.
5921 * gdbarch-selftests.c: Include gdbthread.h and target.h.
5922 (class regcache_test): Delete.
5923 (test_target_has_registers, test_target_has_stack)
5924 (test_target_has_memory, test_target_prepare_to_store)
5925 (test_target_store_registers): New functions.
5926 (test_target_ops): New class.
5927 (register_to_value_test): Error out if there's already a
5928 process_stratum (or higher) target pushed. Create a fuller mock
5929 environment, with mock target_ops, inferior, address space, thread
5930 and inferior_ptid.
5931 * progspace.c (struct address_space): Move to ...
5932 * progspace.h (struct address_space): ... here.
5933 * regcache.h (regcache::~regcache, regcache::raw_write)
5934 [GDB_SELF_TEST]: No longer virtual.
5935
5936 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
5937
5938 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
5939
5940 2017-10-04 Pedro Alves <palves@redhat.com>
5941
5942 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
5943 out of 'between TRY and CATCH'.
5944
5945 2017-10-04 Pedro Alves <palves@redhat.com>
5946
5947 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
5948 * common/common-exceptions.h (TRY): Open an outermost scope.
5949 Expand intro comment.
5950 (CATCH): Reindent.
5951 (END_CATCH): Close the outermost scope.
5952 * completer.c (complete_line_internal): Add missing END_CATCH.
5953
5954 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5955
5956 * NEWS (Changes since GDB 8.0): Add entry about new
5957 'set-cwd-on-gdbserver' feature.
5958 (New remote packets): Add entry for QSetWorkingDir.
5959 * common/common-inferior.h (set_inferior_cwd): New prototype.
5960 * infcmd.c (set_inferior_cwd): Remove "static".
5961 (show_cwd_command): Expand text to include remote debugging.
5962 * remote.c: Add PACKET_QSetWorkingDir.
5963 (remote_protocol_features) <QSetWorkingDir>: New entry for
5964 PACKET_QSetWorkingDir.
5965 (extended_remote_set_inferior_cwd): New function.
5966 (extended_remote_create_inferior): Call
5967 "extended_remote_set_inferior_cwd".
5968 (_initialize_remote): Call "add_packet_config_cmd" for
5969 QSetWorkingDir.
5970
5971 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5972
5973 * NEWS (New commands): Mention "set/show cwd".
5974 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
5975 "cd" command's help text.
5976 * common/common-inferior.h (get_inferior_cwd): New prototype.
5977 * infcmd.c (inferior_cwd_scratch): New global variable.
5978 (set_inferior_cwd): New function.
5979 (get_inferior_cwd): Likewise.
5980 (set_cwd_command): Likewise.
5981 (show_cwd_command): Likewise.
5982 (_initialize_infcmd): Add "set/show cwd" commands.
5983 * inferior.h (class inferior) <cwd>: New field.
5984 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
5985 (fork_inferior): Change inferior's cwd before its execution.
5986 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
5987 to CreateProcess.
5988
5989 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5990
5991 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
5992 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
5993 (COMMON_OBS): Add gdb_tilde_expand.o.
5994 * common/gdb_tilde_expand.c: New file.
5995 * common/gdb_tilde_expand.h: Likewise.
5996
5997 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
5998
5999 * gdbarch.sh (objfile): Remove duplicate declaration.
6000 * gdbarch.h: Regenerate.
6001
6002 2017-10-03 Tom Tromey <tom@tromey.com>
6003
6004 * utils.c (internal_vproblem): Use string_vprintf.
6005
6006 2017-10-03 Tom Tromey <tom@tromey.com>
6007
6008 * printcmd.c (info_symbol_command): Use std::string.
6009
6010 2017-10-03 Tom Tromey <tom@tromey.com>
6011
6012 * top.c (gdb_safe_append_history): Use std::string.
6013
6014 2017-10-03 Tom Tromey <tom@tromey.com>
6015
6016 * event-top.c (stdin_event_handler): Update.
6017 * main.c (captured_main_1): Update.
6018 * top.h (make_delete_ui_cleanup): Remove.
6019 (struct ui): Add constructor and destructor.
6020 (new_ui, delete_ui): Remove.
6021 * top.c (make_delete_ui_cleanup): Remove.
6022 (new_ui_command): Use std::unique_ptr.
6023 (delete_ui_cleanup): Remove.
6024 (ui::ui): Rename from new_ui. Update.
6025 (free_ui): Remove.
6026 (ui::~ui): Rename from delete_ui. Update.
6027
6028 2017-10-03 Tom Tromey <tom@tromey.com>
6029
6030 * symfile.c (load_progress): Use gdb::byte_vector.
6031
6032 2017-10-03 Tom Tromey <tom@tromey.com>
6033
6034 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
6035 declaration.
6036 * printcmd.c (x_command): Remove unused declaration.
6037 * symfile.c (symbol_file_command): Remove unused declaration.
6038
6039 2017-10-03 Tom Tromey <tom@tromey.com>
6040
6041 * utils.c (internal_vproblem): Use std::string.
6042 (defaulted_query): Likewise.
6043
6044 2017-10-03 Tom Tromey <tom@tromey.com>
6045
6046 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
6047 * top.c (execute_command_to_string): Update.
6048 * utils.c (make_cleanup_restore_page_info): Remove.
6049 (do_restore_page_info_cleanup): Remove.
6050 (set_batch_flag_and_restore_page_info):
6051 New.
6052 (make_cleanup_restore_page_info): Remove.
6053 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6054 (~set_batch_flag_and_restore_page_info): New
6055 (make_cleanup_restore_uinteger): Remove.
6056 (make_cleanup_restore_integer): Remove.
6057 (struct restore_integer_closure): Remove.
6058 (restore_integer): Remove.
6059 * utils.h (struct set_batch_flag_and_restore_page_info): New
6060 class.
6061 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6062 (make_cleanup_restore_page_info): Remove.
6063 (make_cleanup_restore_uinteger) Remove.
6064 (make_cleanup_restore_integer) Remove.
6065
6066 2017-10-03 Tom Tromey <tom@tromey.com>
6067
6068 * record-full.h (record_full_gdb_operation_disable_set): Return
6069 scoped_restore_tmpl<int>.
6070 * infrun.c (adjust_pc_after_break): Update.
6071 (handle_signal_stop): Update.
6072 * record-full.c (record_full_gdb_operation_disable_set): Return
6073 scoped_restore_tmpl<int>.
6074 (record_full_wait_1, record_full_insert_breakpoint)
6075 (record_full_remove_breakpoint, record_full_save)
6076 (record_full_goto_insn): Update.
6077
6078 2017-10-02 Tom Tromey <tom@tromey.com>
6079
6080 PR rust/22236:
6081 * rust-lang.c (rust_val_print_str): New function.
6082 (val_print_struct): Call it.
6083 (rust_subscript): Preserve name of slice type.
6084
6085 2017-10-02 Tom Tromey <tom@tromey.com>
6086
6087 * rust-lang.c (rust_subscript): Handle slices in
6088 EVAL_AVOID_SIDE_EFFECTS case.
6089
6090 2017-10-02 Tom Tromey <tom@tromey.com>
6091
6092 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
6093
6094 2017-10-02 Tom Tromey <tom@tromey.com>
6095
6096 * rust-lang.h (rust_slice_type): Add "extern".
6097
6098 2017-10-02 Tom Tromey <tom@tromey.com>
6099 Pedro Alves <palves@redhat.com>
6100
6101 * ada-lang.h (ada_exc_info::operator<): Make const.
6102 (ada_exc_info::operator==): Make const.
6103 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
6104 Make const.
6105
6106 2017-09-29 Tom Tromey <tom@tromey.com>
6107
6108 * target.c (read_whatever_is_readable): Change type of "result".
6109 Update.
6110 (free_memory_read_result_vector): Remove.
6111 (read_memory_robust): Change return type. Update.
6112 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
6113 bin2hex, std::string.
6114 * target.h (memory_read_result_s): Remove typedef.
6115 (free_memory_read_result_vector): Remove.
6116 (read_memory_robust): Return std::vector.
6117
6118 2017-09-29 Tom Tromey <tom@tromey.com>
6119
6120 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
6121
6122 2017-09-29 Tom Tromey <tom@tromey.com>
6123
6124 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
6125 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
6126 operator< and operator==.
6127 (ada_exceptions_list): Return a std::vector.
6128 * ada-lang.c (ada_exc_info::operator<): Rename from
6129 compare_ada_exception_info.
6130 (ada_exc_info::operator==): New.
6131 (sort_remove_dups_ada_exceptions_list): Change type of
6132 "exceptions".
6133 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
6134 (ada_add_global_exceptions): Likewise.
6135 (ada_exceptions_list_1): Return a std::vector.
6136 (ada_exceptions_list): Likewise.
6137
6138 2017-09-29 Tom Tromey <tom@tromey.com>
6139
6140 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
6141 'std::set *'.
6142 (print_one_inferior): Update.
6143 (free_vector_of_ints): Remove.
6144 (list_available_thread_groups): Change "ids" to std::set.
6145 (mi_cmd_list_thread_groups): Update.
6146 (struct collect_cores_data) <core>: Now a std::set.
6147 (collect_cores): Update.
6148 (unique): Remove.
6149 (print_one_inferior): Update.
6150
6151 2017-09-29 Tom Tromey <tom@tromey.com>
6152
6153 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
6154 (mi_execute_async_cli_command): Likewise.
6155 (mi_cmd_trace_frame_collected): Use field_fmt.
6156
6157 2017-09-29 Tom Tromey <tom@tromey.com>
6158
6159 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
6160 gdb::byte_vector.
6161
6162 2017-09-29 Tom Tromey <tom@tromey.com>
6163
6164 * mi/mi-parse.c (mi_parse): Remove unused declaration.
6165
6166 2017-09-29 Tom Tromey <tom@tromey.com>
6167
6168 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
6169
6170 2017-09-29 Tom Tromey <tom@tromey.com>
6171
6172 * varobj.h (varobj_gen_name): Return std::string.
6173 * varobj.c (varobj_gen_name): Return std::string.
6174 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
6175 (mi_cmd_var_delete): Don't copy "name".
6176
6177 2017-09-29 Tom Tromey <tom@tromey.com>
6178
6179 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
6180 (mi_cmd_break_insert_1): Update.
6181
6182 2017-09-29 Tom Tromey <tom@tromey.com>
6183
6184 * target.h (make_scoped_defer_target_commit_resume): Update.
6185 * target.c (make_scoped_defer_target_commit_resume): Rename from
6186 make_cleanup_defer_target_commit_resume. Return a
6187 scoped_restore.
6188 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
6189
6190 2017-09-29 Tom Tromey <tom@tromey.com>
6191
6192 * main.c (captured_main_1): Remove unused declaration.
6193 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
6194
6195 2017-09-29 Tom Tromey <tom@tromey.com>
6196
6197 * symtab.c (search_symbols): Remove unused outer cleanup.
6198 (make_source_files_completion_list): Remove unused declaration.
6199
6200 2017-09-29 Tom Tromey <tom@tromey.com>
6201
6202 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
6203
6204 2017-09-29 Tom Tromey <tom@tromey.com>
6205
6206 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
6207 gdb::byte_vector.
6208
6209 2017-09-29 Tom Tromey <tom@tromey.com>
6210
6211 * complaints.c (vcomplaint): Use std::string.
6212
6213 2017-09-29 Tom Tromey <tom@tromey.com>
6214
6215 * tracepoint.c (trace_variable_command): Use std::string.
6216 (encode_actions_1): Remove unused declarations.
6217 (create_tsv_from_upload): Use std::string.
6218
6219 2017-09-29 Tom Tromey <tom@tromey.com>
6220
6221 * cp-support.c (gdb_demangle): Use std::string.
6222
6223 2017-09-29 Tom Tromey <tom@tromey.com>
6224
6225 * stack.c (parse_frame_specification): Use std::string
6226 (info_frame_command): Use gdb::unique_xmalloc_ptr.
6227
6228 2017-09-29 Tom Tromey <tom@tromey.com>
6229
6230 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
6231
6232 2017-09-29 Tom Tromey <tom@tromey.com>
6233
6234 * utils.c (vfprintf_maybe_filtered): Use std::string.
6235 (vfprintf_unfiltered): Likewise.
6236
6237 2017-09-29 Tom Tromey <tom@tromey.com>
6238
6239 * event-top.c (top_level_prompt): Return std::string.
6240 (display_gdb_prompt): Update.
6241
6242 2017-09-29 Tom Tromey <tom@tromey.com>
6243
6244 * unittests/common-utils-selftests.c (format): New function.
6245 (string_vprintf_tests): New function.
6246 (_initialize_common_utils_selftests): Register new tests.
6247 * common/common-utils.c (string_vprintf): New function.
6248 * common/common-utils.h (string_vprintf): Declare.
6249
6250 2017-09-29 Pedro Alves <palves@redhat.com>
6251
6252 * common/rsp-low.c (unpack_varlen_hex): Constify.
6253 * common/rsp-low.h (unpack_varlen_hex): Constify.
6254 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6255 Constify.
6256 * remote.c (remote_set_permissions, read_ptid)
6257 (remote_current_thread, remote_get_threads_with_qthreadinfo)
6258 (remote_static_tracepoint_marker_at)
6259 (remote_static_tracepoint_markers_by_strid)
6260 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
6261 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
6262 (parse_tracepoint_definition, parse_tsv_definition)
6263 (parse_static_tracepoint_marker_definition): Constify.
6264 * tracepoint.h (parse_static_tracepoint_marker_definition)
6265 (parse_trace_status, parse_tracepoint_status)
6266 (parse_tracepoint_definition, parse_tsv_definition): Constify.
6267
6268 2017-09-29 Pedro Alves <palves@redhat.com>
6269
6270 * remote.c (target_buf, target_buf_size): Delete.
6271 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
6272 Use the connection's packet buffer instead.
6273 All callers adjusted.
6274 (_initialize_remote): Remove references to target_buf and
6275 target_buf_size.
6276
6277 2017-09-28 Pedro Alves <palves@redhat.com>
6278
6279 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6280 unittests/common-utils-selftests.c.
6281 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
6282 (COMMON_OBS): Remove utils-selftests.o.
6283 * utils-selftests.c: Move to ...
6284 * unittests/common-utils-selftests.c: ... here and rename self
6285 test to "string_printf".
6286
6287 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
6288
6289 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
6290 having NULL cus or tus.
6291
6292 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6293
6294 * arm-tdep.c: (convert_from_extended): Remove.
6295 (convert_to_extended): Likewise.
6296 (arm_extract_return_value): Use convert_typed_floating.
6297 (arm_store_return_value): Likewise.
6298
6299 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6300 * sh-tdep.c: Do not include "floatformat.h".
6301 (sh_littlebyte_bigword_type): New function.
6302 (sh_register_convert_to_virtual): Use convert_typed_floating.
6303 (sh_register_convert_to_raw): Likewise.
6304 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6305 (sh64_littlebyte_bigword_type): New function.
6306 (sh64_extract_return_value): Use convert_typed_floating.
6307 (sh64_register_convert_to_virtual): Likewise.
6308 (sh64_register_convert_to_raw): Likewise.
6309
6310 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6311
6312 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
6313 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
6314
6315 * gdbtypes.h (union type_specific): Make field floatformat hold
6316 just a single struct floatformat, not an array.
6317 (floatformat_from_type): Move here.
6318 * gdbtypes.c (floatformat_from_type): Move here. Update to
6319 changed TYPE_FLOATFORMAT definition.
6320 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
6321 (recursive_dump_type): Likewise.
6322 (init_float_type): Install correct floatformat for byte order.
6323 (arch_float_type): Likewise.
6324
6325 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6326
6327 * gdbtypes.c (init_type): Change incoming argument from
6328 length-in-bytes to length-in-bits. Assert length is a
6329 multiple of TARGET_CHAR_BITS.
6330 (arch_type, arch_flags_type): Likewise.
6331 (init_integer_type): Update call to init_type.
6332 (init_character_type): Likewise.
6333 (init_boolean_type): Likewise.
6334 (init_float_type): Likewise.
6335 (init_decfloat_type): Likewise.
6336 (init_complex_type): Likewise.
6337 (init_pointer_type): Likewise.
6338 (objfile_type): Likewise.
6339 (arch_integer_type): Update call to arch_type.
6340 (arch_character_type): Likewise.
6341 (arch_boolean_type): Likewise.
6342 (arch_float_type): Likewise.
6343 (arch_decfloat_type): Likewise.
6344 (arch_complex_type): Likewise.
6345 (arch_pointer_type): Likewise.
6346 (gdbtypes_post_init): Likewise.
6347
6348 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
6349 (read_base_type): Likewise.
6350 * mdebugread.c (basic_type): Likewise.
6351 * stabsread.c (dbx_init_float_type): Likewise.
6352 (rs6000_builtin_type): Likewise.
6353 (read_range_type): Likewise. Also, fix call to init_integer_type
6354 with erroneous length argument.
6355
6356 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
6357 * d-lang.c (build_d_types): Likewise.
6358 * f-lang.c (build_fortran_types): Likewise.
6359 * go-lang.c (build_go_types): Likewise.
6360 * opencl-lang.c (build_opencl_types): Likewise.
6361 * jit.c (finalize_symtab): Likewise.
6362 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
6363 (build_std_type_info_type): Likewise.
6364 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
6365 update call to arch_flags_type.
6366
6367 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
6368 arch_type.
6369 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
6370 * windows-tdep.c (windows_get_tlb_type): Likewise.
6371
6372 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
6373 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6374 * m32c-tdep.c (make_types): Likewise.
6375 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
6376 (rl78_psw_type): Update call to arch_flags_type.
6377 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
6378 * rx-tdep.c (rx_psw_type): Likewise.
6379 (rx_fpsw_type): Likewise.
6380 * sparc-tdep.c (sparc_psr_type): Likewise.
6381 (sparc_fsr_type): Likewise.
6382 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
6383 (sparc64_ccr_type): Likewise.
6384 (sparc64_fsr_type): Likewise.
6385 (sparc64_fprs_type): Likewise.
6386
6387 2017-09-27 Tom Tromey <tom@tromey.com>
6388
6389 * findcmd.c (find_command): Constify.
6390
6391 2017-09-27 Tom Tromey <tom@tromey.com>
6392
6393 * ada-tasks.c (task_command_1, task_command): Constify.
6394
6395 2017-09-27 Tom Tromey <tom@tromey.com>
6396
6397 * symtab.c (maintenance_print_symbol_cache)
6398 (maintenance_flush_symbol_cache)
6399 (maintenance_print_symbol_cache_statistics): Constify.
6400
6401 2017-09-27 Tom Tromey <tom@tromey.com>
6402
6403 * inferior.c (detach_inferior_command, kill_inferior_command)
6404 (inferior_command): Constify.
6405
6406 2017-09-27 Tom Tromey <tom@tromey.com>
6407
6408 * regcache.c (regcache_print, maintenance_print_registers)
6409 (maintenance_print_raw_registers)
6410 (maintenance_print_cooked_registers)
6411 (maintenance_print_register_groups)
6412 (maintenance_print_remote_registers): Constify.
6413
6414 2017-09-27 Tom Tromey <tom@tromey.com>
6415
6416 * printcmd.c (map_display_numbers, undisplay_command)
6417 (enable_disable_display_command, enable_display_command)
6418 (disable_display_command): Constify.
6419
6420 2017-09-27 Tom Tromey <tom@tromey.com>
6421
6422 * breakpoint.h (delete_command): Don't declare.
6423 * breakpoint.c (delete_command, enable_once_command)
6424 (enable_count_command, enable_delete_command, breakpoint_1)
6425 (maintenance_info_breakpoints, stopin_command, stopat_command)
6426 (delete_command, delete_trace_command, save_breakpoints)
6427 (save_breakpoints_command, save_tracepoints_command): Constify.
6428
6429 2017-09-27 Tom Tromey <tom@tromey.com>
6430
6431 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6432 (skip_ws, extract_identifier, macro_define_command)
6433 (macro_undef_command, macro_list_command): Constify.
6434
6435 2017-09-27 Tom Tromey <tom@tromey.com>
6436
6437 * infcmd.c (environment_info, set_environment_command)
6438 (unset_environment_command, path_info, info_proc_cmd_1)
6439 (info_proc_cmd_mappings, info_proc_cmd_stat)
6440 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6441 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6442
6443 2017-09-27 Tom Tromey <tom@tromey.com>
6444
6445 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6446 Constify.
6447
6448 2017-09-27 Tom Tromey <tom@tromey.com>
6449
6450 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6451
6452 2017-09-27 Tom Tromey <tom@tromey.com>
6453
6454 * demangle.c (demangle_command): Constify.
6455
6456 2017-09-27 Tom Tromey <tom@tromey.com>
6457
6458 * progspace.c (maintenance_info_program_spaces_command):
6459 Constify.
6460
6461 2017-09-27 Tom Tromey <tom@tromey.com>
6462
6463 * compile/compile.c (check_raw_argument, compile_file_command)
6464 (compile_code_command, compile_print_command): Constify.
6465
6466 2017-09-27 Tom Tromey <tom@tromey.com>
6467
6468 * reggroups.c (maintenance_print_reggroups): Constify.
6469
6470 2017-09-27 Tom Tromey <tom@tromey.com>
6471
6472 * dwarf2read.c (save_gdb_index_command): Constify.
6473
6474 2017-09-27 Tom Tromey <tom@tromey.com>
6475
6476 * stap-probe.c (info_probes_stap_command): Constify.
6477
6478 2017-09-27 Tom Tromey <tom@tromey.com>
6479
6480 * fork-child.c (unset_exec_wrapper_command): Constify.
6481
6482 2017-09-27 Tom Tromey <tom@tromey.com>
6483
6484 * btrace.c (get_uint, get_context_size, no_chunk)
6485 (maint_btrace_packet_history_cmd)
6486 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6487 (maint_info_btrace_cmd): Constify.
6488
6489 2017-09-27 Tom Tromey <tom@tromey.com>
6490
6491 * reverse.c (delete_bookmark_command): Constify.
6492
6493 2017-09-27 Tom Tromey <tom@tromey.com>
6494
6495 * remote.c (set_memory_packet_size)
6496 (set_memory_write_packet_size, show_memory_write_packet_size)
6497 (set_memory_read_packet_size, show_memory_read_packet_size)
6498 (compare_sections_command, packet_command, remote_put_command)
6499 (remote_get_command, remote_delete_command): Constify.
6500
6501 2017-09-27 Tom Tromey <tom@tromey.com>
6502
6503 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6504 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6505 (set_mipsfpu_auto_command): Constify.
6506
6507 2017-09-27 Tom Tromey <tom@tromey.com>
6508
6509 * cli/cli-cmds.h (cd_command): Constify.
6510 * cli/cli-cmds.c (cd_command): Constify.
6511
6512 2017-09-27 Tom Tromey <tom@tromey.com>
6513
6514 * thread.c (thread_name_command, thread_find_command): Constify.
6515
6516 2017-09-27 Tom Tromey <tom@tromey.com>
6517
6518 * probe.c (enable_probes_command, disable_probes_command):
6519 Constify.
6520
6521 2017-09-27 Tom Tromey <tom@tromey.com>
6522
6523 * symfile.c (symbol_file_command): Constify.
6524 * gdbcore.h (deprecated_file_changed_hook): Constify.
6525 * exec.c (deprecated_file_changed_hook, exec_file_command)
6526 (file_command): Constify.
6527 * defs.h (symbol_file_command): Constify.
6528
6529 2017-09-27 Tom Tromey <tom@tromey.com>
6530
6531 * remote-fileio.c (set_system_call_allowed)
6532 (show_system_call_allowed): Constify.
6533
6534 2017-09-27 Tom Tromey <tom@tromey.com>
6535
6536 * tracepoint.c (delete_trace_variable_command)
6537 (tfind_end_command, tfind_start_command, tfind_pc_command)
6538 (tfind_tracepoint_command, tfind_line_command)
6539 (tfind_range_command, tfind_outside_command): Constify.
6540
6541 2017-09-27 Tom Tromey <tom@tromey.com>
6542
6543 * ax-gdb.c (maint_agent_printf_command, agent_command)
6544 (agent_eval_command): Constify.
6545
6546 2017-09-27 Tom Tromey <tom@tromey.com>
6547
6548 * tracepoint.c (info_scope_command): Constify.
6549 * python/python.c (gdbpy_decode_line): Constify.
6550 * python/py-breakpoint.c (bppy_init): Constify.
6551 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6552 * location.h: (new_linespec_location)
6553 (string_to_event_location_basic, string_to_event_location):
6554 Constify.
6555 * location.c (new_linespec_location)
6556 (string_to_event_location_basic, string_to_event_location):
6557 Constify.
6558 * linespec.h (decode_line_with_current_source)
6559 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6560 * linespec.c (linespec_lex_to_end)
6561 (decode_line_with_current_source)
6562 (decode_line_with_last_displayed): Constify.
6563 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6564 Constify.
6565 * cli/cli-cmds.c (edit_command, list_command): Constify.
6566 * breakpoint.h (until_break_command, watch_command_wrapper)
6567 (awatch_command_wrapper, rwatch_command_wrapper)
6568 (init_ada_exception_breakpoint): Constify.
6569 * breakpoint.c (break_command_1, dprintf_command)
6570 (break_range_command, watch_command_wrapper)
6571 (rwatch_command_wrapper, awatch_command_wrapper)
6572 (until_break_command, init_ada_exception_breakpoint)
6573 (strace_marker_create_sals_from_location, trace_command)
6574 (ftrace_command, strace_command, struct tracepoint): Constify.
6575 * ax-gdb.c (agent_command_1): Constify.
6576 * ada-lang.c (ada_exception_sal): Constify.
6577
6578 2017-09-27 Tom Tromey <tom@tromey.com>
6579
6580 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6581 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6582 (get_context_size, no_chunk, get_insn_history_modifiers)
6583 (cmd_record_insn_history, get_call_history_modifiers)
6584 (cmd_record_call_history): Constify.
6585
6586 2017-09-27 Tom Tromey <tom@tromey.com>
6587
6588 * source.c (show_substitute_path_command)
6589 (unset_substitute_path_command, set_substitute_path_command):
6590 Constify.
6591
6592 2017-09-27 Tom Tromey <tom@tromey.com>
6593
6594 * typeprint.c (maintenance_print_type): Constify.
6595 * maint.c (maintenance_dump_me, maintenance_demangle)
6596 (maintenance_time_display, maintenance_info_sections)
6597 (maintenance_print_statistics, maintenance_deprecate)
6598 (maintenance_undeprecate): Constify.
6599 (maintenance_do_deprecate): Constify. Use std::string.
6600 (maintenance_selftest): Constify.
6601 * gdbtypes.h (maintenance_print_type): Constify.
6602
6603 2017-09-27 Tom Tromey <tom@tromey.com>
6604
6605 * hppa-tdep.c (unwind_command): Constify.
6606
6607 2017-09-27 Tom Tromey <tom@tromey.com>
6608
6609 * target-descriptions.c (unset_tdesc_filename_cmd)
6610 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6611 Constify.
6612
6613 2017-09-27 Tom Tromey <tom@tromey.com>
6614
6615 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6616
6617 2017-09-27 Tom Tromey <tom@tromey.com>
6618
6619 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6620
6621 2017-09-27 Tom Tromey <tom@tromey.com>
6622
6623 * tui/tui-regs.c (tui_reg_command): Constify.
6624
6625 2017-09-27 Tom Tromey <tom@tromey.com>
6626
6627 * skip.c (skip_file_command, skip_function_command)
6628 (skip_enable_command, skip_disable_command, skip_delete_command):
6629 Constify.
6630
6631 2017-09-27 Tom Tromey <tom@tromey.com>
6632
6633 * record-btrace.c (cmd_record_btrace_bts_start)
6634 (cmd_record_btrace_pt_start): Constify.
6635
6636 2017-09-27 Tom Tromey <tom@tromey.com>
6637
6638 * symmisc.c (maintenance_print_symbols)
6639 (maintenance_print_msymbols, maintenance_print_objfiles)
6640 (maintenance_info_symtabs, maintenance_check_symtabs)
6641 (maintenance_expand_symtabs, maintenance_info_line_tables):
6642 Constify.
6643
6644 2017-09-27 Tom Tromey <tom@tromey.com>
6645
6646 * top.c (new_ui_command): Constify.
6647
6648 2017-09-27 Tom Tromey <tom@tromey.com>
6649
6650 * symfile.c (add_symbol_file_command)
6651 (remove_symbol_file_command, list_overlays_command)
6652 (map_overlay_command, unmap_overlay_command)
6653 (overlay_auto_command, overlay_manual_command)
6654 (overlay_off_command, overlay_load_command): Constify.
6655
6656 2017-09-27 Tom Tromey <tom@tromey.com>
6657
6658 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6659 (info_spu_mailbox_command, info_spu_dma_command)
6660 (info_spu_proxydma_command): Constify.
6661
6662 2017-09-27 Tom Tromey <tom@tromey.com>
6663
6664 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6665
6666 2017-09-27 Tom Tromey <tom@tromey.com>
6667
6668 * cli/cli-script.c (user_defined_command): Constify.
6669
6670 2017-09-27 Tom Tromey <tom@tromey.com>
6671
6672 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6673 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6674 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6675 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6676 (dump_binary_value, append_binary_memory, append_binary_value):
6677 Constify.
6678 (struct dump_context) <func>: Constify.
6679 (add_dump_command): Update.
6680
6681 2017-09-27 Tom Tromey <tom@tromey.com>
6682
6683 * cli/cli-cmds.c (show_version, show_configuration)
6684 (source_command, show_user): Constify.
6685
6686 2017-09-27 Tom Tromey <tom@tromey.com>
6687
6688 * target.c (maintenance_print_target_stack): Constify.
6689
6690 2017-09-27 Tom Tromey <tom@tromey.com>
6691
6692 * interps.c (interpreter_exec_cmd): Constify.
6693
6694 2017-09-27 Tom Tromey <tom@tromey.com>
6695
6696 * record-full.c (cmd_record_full_restore): Constify.
6697
6698 2017-09-27 Tom Tromey <tom@tromey.com>
6699
6700 * memattr.c (enable_mem_command, disable_mem_command)
6701 (delete_mem_command): Constify.
6702
6703 2017-09-27 Tom Tromey <tom@tromey.com>
6704
6705 * value.c (show_convenience): Constify.
6706
6707 2017-09-27 Tom Tromey <tom@tromey.com>
6708
6709 * gdbcore.h (core_file_command): Update.
6710 * corefile.c (core_file_command): Constify.
6711
6712 2017-09-27 Tom Tromey <tom@tromey.com>
6713
6714 * user-regs.c (maintenance_print_user_registers): Constify.
6715
6716 2017-09-27 Tom Tromey <tom@tromey.com>
6717
6718 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6719
6720 2017-09-27 Tom Tromey <tom@tromey.com>
6721
6722 * cp-support.c (first_component_command): Constify.
6723
6724 2017-09-27 Tom Tromey <tom@tromey.com>
6725
6726 * psymtab.c (maintenance_print_psymbols)
6727 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6728 Constify.
6729
6730 2017-09-27 Tom Tromey <tom@tromey.com>
6731
6732 * windows-tdep.c (display_tib): Constify.
6733
6734 2017-09-27 Tom Tromey <tom@tromey.com>
6735
6736 * linux-fork.c (delete_checkpoint_command)
6737 (detach_checkpoint_command): Constify.
6738
6739 2017-09-27 Tom Tromey <tom@tromey.com>
6740
6741 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6742
6743 2017-09-27 Tom Tromey <tom@tromey.com>
6744
6745 * arc-tdep.c (dump_arc_instruction_command): Constify.
6746
6747 2017-09-27 Tom Tromey <tom@tromey.com>
6748
6749 * valprint.c (set_radix, show_radix): Constify.
6750
6751 2017-09-27 Tom Tromey <tom@tromey.com>
6752
6753 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6754
6755 2017-09-27 Tom Tromey <tom@tromey.com>
6756
6757 * command.h (not_just_help_class_command): Update.
6758 * cli/cli-decode.h (not_just_help_class_command): Update.
6759 * cli/cli-decode.c (not_just_help_class_command): Constify.
6760
6761 2017-09-27 Tom Tromey <tom@tromey.com>
6762
6763 * gdb_bfd.c (maintenance_info_bfds): Constify.
6764
6765 2017-09-27 Tom Tromey <tom@tromey.com>
6766
6767 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6768 overloads.
6769 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6770 (do_const_cfunc): New function.
6771 (cmd_cfunc_eq): New overload.
6772 (cli_user_command_p): Check do_const_cfunc.
6773 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6774 const_cfunc.
6775 * command.h (add_cmd): Add const overload and no-function
6776 overload.
6777 (set_cmd_cfunc): Add const overload.
6778 (cmd_const_cfunc_ftype): Declare.
6779 (cmd_cfunc_eq): Add const overload.
6780 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
6781 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
6782 overload.
6783
6784 2017-09-27 Tom Tromey <tom@tromey.com>
6785
6786 * macroexp.c (get_next_token_for_substitution): New function.
6787 (substitute_args): Call it. Check for __VA_OPT__.
6788
6789 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6790 Pedro Alves <palves@redhat.com>
6791
6792 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
6793 producer_is_icc_lt_14.
6794 (producer_is_icc_lt_14): New function.
6795 (check_producer): Add code for checking version of ICC.
6796 (producer_is_icc): Move to producer.c.
6797 (read_structure_type): Restrict ICC workaround to ICC<14.
6798 * producer.c: Include selftest.h.
6799 (producer_is_icc, producer_parsing_tests, _initialize_producer):
6800 New functions.
6801 * producer.h (producer_is_icc): New declaration.
6802
6803 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6804
6805 * Makefile.in (SFILES): Add producer.c.
6806 (COMMON_OBS): Add producer.o
6807 * amd64-tdep.c (producer.h): Add new include.
6808 * dwarf2read.c (producer.h): Add new include.
6809 * producer.c: New file.
6810 * producer.h: New file.
6811 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
6812 producer.c.
6813 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
6814 producer.h.
6815
6816 2017-09-26 Matthias Klose <doko@ubuntu.com>
6817
6818 * configure.ac: Search ncursesw before ncurses.
6819 Check ncursesw/ncurses.h before ncurses/ncurses.h.
6820 * gdb_curses.h: Include <ncursesw/ncurses.h>
6821 * config.in, configure: Regenerate.
6822
6823 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6824
6825 PR gdb/22185
6826 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
6827 obsolete.
6828 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
6829 Remove i386sol2 support.
6830 * configure.nat <i386sol2>: Remove.
6831 <sol2-64>: Fold into ...
6832 <sol2>: ... this.
6833 Move common settings to default section.
6834 Add sol-thread.o.
6835 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
6836 x86_64-*-solaris2.1[0-9]*>: Rename to ...
6837 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
6838 <i[34567]86-*-solaris*>: Remove.
6839 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
6840
6841 * configure.ac: Remove wctype in libw check.
6842 (_MSE_INT_H): Don't define on Solaris 7-9.
6843 <solaris*>: Remove libthread_db.so.1 check.
6844 * configure: Regenerate.
6845 * config.in: Regenerate.
6846
6847 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
6848 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
6849 (gdb_ps_size_t): Remove.
6850 Use base types in users.
6851 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
6852
6853 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
6854
6855 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6856
6857 PR build/22206
6858 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
6859 (adi_is_addr_mapped): Likewise.
6860 (PSR_ICC): Don't redefine.
6861 (PSR_IMPL): Likewise.
6862
6863 2017-09-25 Tom Tromey <tom@tromey.com>
6864
6865 * regcache.c (regcache::dump): Use string_printf.
6866
6867 2017-09-25 Tom Tromey <tom@tromey.com>
6868
6869 * regcache.c (class regcache_invalidator): New.
6870 (struct register_to_invalidate): Remove.
6871 (make_cleanup_regcache_invalidate): Remove.
6872 (regcache::raw_write): Use regcache_invalidator.
6873
6874 2017-09-25 Tom Tromey <tom@tromey.com>
6875
6876 * spu-tdep.c (spu2ppu_sniffer): Update.
6877 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
6878 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
6879 Remove.
6880 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
6881 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
6882 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
6883 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
6884 (frame_pop): Update.
6885
6886 2017-09-25 Tom Tromey <tom@tromey.com>
6887
6888 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
6889 * regcache.h (regcache_xfree): Don't declare.
6890 * regcache.c (regcache_xfree): Remove.
6891 (do_regcache_xfree): Use delete.
6892 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
6893 * linux-fork.c (free_fork): Use delete.
6894 (fork_save_infrun_state): Likewise.
6895 * jit.c (jit_dealloc_cache): Use delete.
6896 * infrun.c (discard_infcall_suspend_state): Use delete.
6897
6898 2017-09-25 Tom Tromey <tom@tromey.com>
6899
6900 * regcache.h (regcache_xmalloc): Don't declare.
6901 (regcache_raw_set_cached_value): Update comment.
6902 * regcache.c (regcache_xmalloc): Remove.
6903 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
6904 * jit.c (jit_frame_sniffer): Use new.
6905 * frame.c (frame_save_as_regcache): Use new.
6906
6907 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6908
6909 * NEWS: Advertise support for guarded-storage registers on IBM z.
6910
6911 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6912
6913 * s390-linux-nat.c (have_regset_gs): New static variable.
6914 (s390_linux_fetch_inferior_registers): Handle guarded-storage
6915 control block and guarded-storage broadcast control regsets.
6916 (s390_read_description): Detect whether the target has
6917 guarded-storage support, return appropriate tdesc.
6918 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
6919 (features/s390x-gs-linux64.c): Likewise.
6920 (struct gdbarch_tdep) <have_gs>: New field.
6921 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
6922 (s390_gsbc_regset): New variables.
6923 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
6924 and s390_gsbc_regset, if applicable.
6925 (s390_core_read_description): Check whether core file was from a
6926 target with guarded-storage support; include appropriate regsets.
6927 (s390_gdbarch_init): Add registers for guarded-storage support.
6928 (_initialize_s390_tdep): Initialize new target descriptions that
6929 include registers for guarded-storage support.
6930 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
6931 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
6932 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
6933 (S390_NUM_REGS): Adjust macro definition.
6934 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
6935 (tdesc_s390x_gs_linux64): New declarations.
6936
6937 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6938
6939 * features/s390-gs-linux64.xml: New file.
6940 * features/s390-gs.xml: New file.
6941 * features/s390-gsbc.xml: New file.
6942 * features/s390x-gs-linux64.xml: New file.
6943 * features/Makefile (WHICH): Add s390-gs-linux64 and
6944 s390x-gs-linux64.
6945 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
6946 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
6947 * features/s390-gs-linux64.c: New generated file.
6948 * features/s390x-gs-linux64.c: New file.
6949 * regformats/s390-gs-linux64.dat: New file.
6950 * regformats/s390x-gs-linux64.dat: New file.
6951
6952 2017-09-23 Tom Tromey <tom@tromey.com>
6953
6954 * defs.h (make_cleanup_override_quit_handler): Don't declare.
6955
6956 2017-09-22 Tom Tromey <tom@tromey.com>
6957
6958 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
6959 type to scoped_restore_tmpl.
6960 <scoped_input_handler>: Initialize m_quit_handler directly.
6961
6962 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6963
6964 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
6965 (cd_command): Likewise. Free "current_directory" before
6966 assigning to it.
6967 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
6968 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
6969 * top.c (gdb_dirbuf): Remove global declaration.
6970 * top.h (gdb_dirbuf): Likewise.
6971
6972 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6973
6974 * gnulib/aclocal.m4: Regenerate.
6975 * gnulib/config.in: Regenerate.
6976 * gnulib/configure: Regenerate.
6977 * gnulib/import/Makefile.am: Regenerate.
6978 * gnulib/import/Makefile.in: Regenerate.
6979 * gnulib/import/assure.h: New file.
6980 * gnulib/import/at-func.c: Likewise
6981 * gnulib/import/chdir-long.c: New file.
6982 * gnulib/import/chdir-long.h: New file.
6983 * gnulib/import/cloexec.c: New file.
6984 * gnulib/import/cloexec.h: New file.
6985 * gnulib/import/close.c: New file.
6986 * gnulib/import/closedir.c: New file.
6987 * gnulib/import/dirent-private.h: New file.
6988 * gnulib/import/dup-safer.c: New file.
6989 * gnulib/import/dup.c: New file.
6990 * gnulib/import/dup2.c: New file.
6991 * gnulib/import/error.c: New file.
6992 * gnulib/import/error.h: New file.
6993 * gnulib/import/exitfail.c: New file.
6994 * gnulib/import/exitfail.h: New file.
6995 * gnulib/import/fchdir.c: New file.
6996 * gnulib/import/fcntl.c: New file.
6997 * gnulib/import/fcntl.in.h: New file.
6998 * gnulib/import/fd-hook.c: New file.
6999 * gnulib/import/fd-hook.h: New file.
7000 * gnulib/import/fd-safer.c: New file.
7001 * gnulib/import/fdopendir.c: New file.
7002 * gnulib/import/filename.h: New file.
7003 * gnulib/import/filenamecat-lgpl.c: New file.
7004 * gnulib/import/filenamecat.h: New file.
7005 * gnulib/import/fstat.c: New file.
7006 * gnulib/import/fstatat.c: New file.
7007 * gnulib/import/getcwd-lgpl.c: New file.
7008 * gnulib/import/getcwd.c: New file.
7009 * gnulib/import/getdtablesize.c: New file.
7010 * gnulib/import/getlogin_r.c: New file.
7011 * gnulib/import/getprogname.c: New file.
7012 * gnulib/import/getprogname.h: New file.
7013 * gnulib/import/gettext.h: New file.
7014 * gnulib/import/glob-libc.h: New file.
7015 * gnulib/import/glob.c: New file.
7016 * gnulib/import/glob.in.h: New file.
7017 * gnulib/import/intprops.h: New file.
7018 * gnulib/import/m4/chdir-long.m4: New file.
7019 * gnulib/import/m4/close.m4: New file.
7020 * gnulib/import/m4/closedir.m4: New file.
7021 * gnulib/import/m4/d-ino.m4: New file.
7022 * gnulib/import/m4/d-type.m4: New file.
7023 * gnulib/import/m4/dup.m4: New file.
7024 * gnulib/import/m4/dup2.m4: New file.
7025 * gnulib/import/m4/error.m4: New file.
7026 * gnulib/import/m4/fchdir.m4: New file.
7027 * gnulib/import/m4/fcntl.m4: New file.
7028 * gnulib/import/m4/fcntl_h.m4: New file.
7029 * gnulib/import/m4/fdopendir.m4: New file.
7030 * gnulib/import/m4/filenamecat.m4: New file.
7031 * gnulib/import/m4/fstat.m4: New file.
7032 * gnulib/import/m4/fstatat.m4: New file.
7033 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
7034 * gnulib/import/m4/getcwd-path-max.m4: New file.
7035 * gnulib/import/m4/getcwd.m4: New file.
7036 * gnulib/import/m4/getdtablesize.m4: New file.
7037 * gnulib/import/m4/getlogin_r.m4: New file.
7038 * gnulib/import/m4/getprogname.m4: New file.
7039 * gnulib/import/m4/glob.m4: New file.
7040 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7041 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7042 * gnulib/import/m4/mempcpy.m4: New file.
7043 * gnulib/import/m4/memrchr.m4: New file.
7044 * gnulib/import/m4/mode_t.m4: New file.
7045 * gnulib/import/m4/msvc-inval.m4: New file.
7046 * gnulib/import/m4/msvc-nothrow.m4: New file.
7047 * gnulib/import/m4/open.m4: New file.
7048 * gnulib/import/m4/openat.m4: New file.
7049 * gnulib/import/m4/opendir.m4: New file.
7050 * gnulib/import/m4/readdir.m4: New file.
7051 * gnulib/import/m4/realloc.m4: New file.
7052 * gnulib/import/m4/rewinddir.m4: New file.
7053 * gnulib/import/m4/save-cwd.m4: New file.
7054 * gnulib/import/m4/strdup.m4: New file.
7055 * gnulib/import/m4/strerror.m4: New file.
7056 * gnulib/import/m4/unistd-safer.m4: New file.
7057 * gnulib/import/mempcpy.c: New file.
7058 * gnulib/import/memrchr.c: New file.
7059 * gnulib/import/msvc-inval.c: New file.
7060 * gnulib/import/msvc-inval.h: New file.
7061 * gnulib/import/msvc-nothrow.c: New file.
7062 * gnulib/import/msvc-nothrow.h: New file.
7063 * gnulib/import/open.c: New file.
7064 * gnulib/import/openat-die.c: New file.
7065 * gnulib/import/openat-priv.h: New file.
7066 * gnulib/import/openat-proc.c: New file.
7067 * gnulib/import/openat.c: New file.
7068 * gnulib/import/openat.h: New file.
7069 * gnulib/import/opendir.c: New file.
7070 * gnulib/import/pipe-safer.c: New file.
7071 * gnulib/import/readdir.c: New file.
7072 * gnulib/import/realloc.c: New file.
7073 * gnulib/import/rewinddir.c: New file.
7074 * gnulib/import/save-cwd.c: New file.
7075 * gnulib/import/save-cwd.h: New file.
7076 * gnulib/import/strdup.c: New file.
7077 * gnulib/import/strerror-override.c: New file.
7078 * gnulib/import/strerror-override.h: New file.
7079 * gnulib/import/strerror.c: New file.
7080 * gnulib/import/unistd--.h: New file.
7081 * gnulib/import/unistd-safer.h: New file.
7082 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
7083 "getcwd" and "glob".
7084 * ser-tcp.c: Undefine "close" before redefining it.
7085
7086 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7087
7088 * guile/scm-value.c (gdbscm_value_address): Initialize address,
7089 get rid of res_val.
7090
7091 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7092
7093 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
7094 <sol2,sparc>: Likewise.
7095 <sol2-64,i386>: Likewise.
7096
7097 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
7098 -Wdeprecated-declarations on *-*-solaris*.
7099 * configure: Regenerate.
7100
7101 * procfs.c: Include "nat/inferior.h".
7102 (procfs_info_proc): Fix typo.
7103
7104 2017-09-21 Kevin Buettner <kevinb@redhat.com>
7105
7106 * remote.c (vector): Include.
7107 (struct private_thread_info): Add field, thread_handle.
7108 (free_private_thread_info): Deallocate storage associated with
7109 thread handle.
7110 (get_private_info_thread): Initialize `thread_handle' field.
7111 (struct thread_item): Add field, thread_handle.
7112 (clear_threads_listing_context): Deallocate storage associated
7113 with thread handle.
7114 (start_thread): Add support for "handle" attribute.
7115 (thread_attributes): Add "handle".
7116 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
7117 field.
7118 (remote_update_thread_list): Update thread_handle.
7119 (remote_thread_handle_to_thread_info): New function.
7120 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
7121
7122 2017-09-21 Kevin Buettner <kevinb@redhat.com>
7123
7124 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
7125 function.
7126 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
7127 * python/python-internal.h (thread_object_type): Declare.
7128
7129 2017-09-21 Kevin Buettner <kevinb@redhat.com>
7130
7131 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
7132 (target_thread_handle_to_thread_info): Declare.
7133 * target.c (target_thread_handle_to_thread_info): New function.
7134 * target-delegates.c: Regenerate.
7135 * gdbthread.h (find_thread_by_handle): Declare.
7136 * thread.c (find_thread_by_handle): New function.
7137 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
7138 function.
7139 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
7140
7141 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7142
7143 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
7144
7145 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7146
7147 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
7148
7149 2017-09-21 Yao Qi <yao.qi@linaro.org>
7150
7151 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
7152 to gdb_target_obs.
7153
7154 2017-09-20 Tom Tromey <tom@tromey.com>
7155
7156 * breakpoint.c (struct counted_command_line): Remove.
7157 (breakpoint_commands): Update.
7158 (alloc_counted_command_line, incref_counted_command_line)
7159 (decref_counted_command_line, do_cleanup_counted_command_line)
7160 (make_cleanup_decref_counted_command_line): Remove.
7161 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
7162 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
7163 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
7164 (save_breakpoints): Update.
7165 * breakpoint.h (counted_command_line): Now a typedef to
7166 shared_ptr.
7167 (struct breakpoint) <commands>: Now a counted_command_line.
7168 (struct bpstats) <command>: Likewise.
7169
7170 2017-09-20 Tom Tromey <tom@tromey.com>
7171
7172 * breakpoint.c (struct commands_info, do_map_commands_command):
7173 Remove.
7174 (commands_command_1): Update.
7175 (iterate_over_related_breakpoints): Take a function_view.
7176 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
7177 (delete_command): Update.
7178 (map_breakpoint_numbers): Take a function_view.
7179 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
7180 (disable_command): Update.
7181 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
7182 (enable_command): Update.
7183 (struct disp_data, do_enable_breakpoint_disp)
7184 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
7185 (do_map_enable_delete_breakpoint): Remove.
7186 (enable_once_command, enable_count_command, enable_delete_command)
7187 (delete_trace_variable_command): Update.
7188
7189 2017-09-20 Tom Tromey <tom@tromey.com>
7190
7191 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
7192 (bpstat_clear): Use delete.
7193 (bpstats): New constructors.
7194 (bpstat_copy, bpstat_stop_status): Use new.
7195 (dprintf_after_condition_true): Update.
7196 * breakpoint.h (bpstats::bpstats): Add constructors.
7197 (bpstats::~bpstats): Add destructor.
7198
7199 2017-09-20 Pedro Alves <palves@redhat.com>
7200
7201 * eval.c (make_params): Delete, refactored as ...
7202 (class fake_method): ... this new type's ctor.
7203 (fake_method::~fake_method): New.
7204 (evaluate_subexp_standard): Use 'fake_method'.
7205
7206 2017-09-20 Tom Tromey <tom@tromey.com>
7207
7208 * windows-nat.c (get_windows_debug_event, windows_wait)
7209 (do_initial_windows_stuff, windows_attach): Update.
7210 * utils.c (vwarning, internal_vproblem): Update.
7211 (ui_unregister_input_event_handler_cleanup)
7212 (prepare_to_handle_input): Remove.
7213 (class scoped_input_handler): New.
7214 (defaulted_query, prompt_for_continue): Update.
7215 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
7216 Update.
7217 * top.c (undo_terminal_modifications_before_exit): Update.
7218 * target/target.h (target_terminal_init, target_terminal_inferior)
7219 (target_terminal_ours): Don't declare.
7220 (class target_terminal): New.
7221 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
7222 (target_terminal_ours_for_output)
7223 (make_cleanup_restore_target_terminal): Don't declare.
7224 (target_terminal_info): Remove.
7225 * target.c (enum terminal_state, terminal_state): Remove.
7226 (target_terminal::terminal_state): Define.
7227 (target_terminal::init): Rename from target_terminal_init.
7228 (target_terminal::inferior): Rename from
7229 target_terminal_inferior.
7230 (target_terminal::ours): Rename from target_terminal_ours.
7231 (target_terminal::ours_for_output): Rename from
7232 target_terminal_ours_for_output.
7233 (target_terminal::info): New method.
7234 (cleanup_restore_target_terminal)
7235 (make_cleanup_restore_target_terminal): Remove.
7236 * solib.c (handle_solib_event): Update.
7237 * remote.c (remote_serial_quit_handler): Update.
7238 (remote_terminal_inferior, remote_wait_as): Update.
7239 * record-full.c (record_full_wait_1): Update.
7240 * nto-procfs.c (procfs_create_inferior): Update.
7241 * nat/fork-inferior.c (startup_inferior): Update.
7242 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
7243 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
7244 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
7245 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
7246 (mi_breakpoint_created, mi_breakpoint_deleted)
7247 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
7248 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7249 (mi_user_selected_context_changed, report_initial_inferior):
7250 Update.
7251 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
7252 (linux_nat_terminal_inferior): Update.
7253 * infrun.c (follow_fork_inferior)
7254 (handle_vfork_child_exec_or_exit, do_target_resume)
7255 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
7256 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
7257 Update.
7258 * inflow.c (child_terminal_init, info_terminal_command): Update.
7259 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
7260 (attach_command): Update.
7261 * infcall.c (call_thread_fsm_should_stop): Update.
7262 * gnu-nat.c (gnu_attach): Update.
7263 * extension.c (struct active_ext_lang_state)
7264 (restore_active_ext_lang): Update.
7265 * exceptions.c (print_flush): Update.
7266 * event-top.c (async_enable_stdin, default_quit_handler): Update.
7267 (struct quit_handler_cleanup_data, restore_quit_handler)
7268 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
7269 Remove.
7270 * cp-support.c (gdb_demangle): Update.
7271 * breakpoint.c (update_inserted_breakpoint_locations)
7272 (insert_breakpoint_locations, handle_jit_event)
7273 (disable_breakpoints_in_unloaded_shlib): Update.
7274 * annotate.c (annotate_breakpoints_invalid)
7275 (annotate_frames_invalid): Update.
7276
7277 2017-09-20 Tom Tromey <tom@tromey.com>
7278
7279 * main.c (catch_command_errors): Rename from
7280 catch_command_errors_const.
7281 (captured_main_1): Update.
7282
7283 2017-09-20 Pedro Alves <palves@redhat.com>
7284
7285 * cli/cli-cmds.c (list_command): Use print_sal_location.
7286 (print_sal_location): New function.
7287 (ambiguous_line_spec): Use print_sal_location.
7288 * linespec.c (symbol_to_sal): Record the symbol in the sal.
7289 * symtab.c (find_function_start_sal): Likewise.
7290 * symtab.h (symtab_and_line::symbol): New field.
7291
7292 2017-09-20 Pedro Alves <palves@redhat.com>
7293
7294 * linespec.c (minsym_found): Handle non-text minsyms.
7295 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
7296
7297 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7298
7299 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
7300 backslash.
7301
7302 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7303
7304 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
7305 vmovups instead vmovaps.
7306 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
7307
7308 2017-09-19 John Baldwin <jhb@FreeBSD.org>
7309
7310 * NEWS (Changes since GDB 8.0): Add starti.
7311 * infcmd.c (enum run_break): New.
7312 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
7313 case.
7314 (run_command): Use enum run_how.
7315 (start_command): Likewise.
7316 (starti_command): New function.
7317 (RUN_ARGS_HELP): New macro.
7318 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
7319 commands. Add starti command.
7320
7321 2017-09-19 Yao Qi <yao.qi@linaro.org>
7322
7323 * Makefile.in (monitor.o): Remove the rule.
7324
7325 2017-09-19 Yao Qi <yao.qi@linaro.org>
7326
7327 * annotate.h (struct annotate_arg_emitter): Use
7328 DISABLE_COPY_AND_ASSIGN.
7329 * common/refcounted-object.h (refcounted_object): Likewise.
7330 * completer.h (struct completion_result): Likewise.
7331 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
7332 * filename-seen-cache.h (filename_seen_cache): Likewise.
7333 * gdbcore.h (thread_section_name): Likewise.
7334 * gdb_regex.h (compiled_regex): Likewise.
7335 * gdbthread.h (scoped_restore_current_thread): Likewise.
7336 * inferior.h (scoped_restore_current_inferior): Likewise.
7337 * jit.c (jit_reader): Likewise.
7338 * linespec.h (struct linespec_result): Likewise.
7339 * mi/mi-parse.h (struct mi_parse): Likewise.
7340 * nat/fork-inferior.c (execv_argv): Likewise.
7341 * progspace.h (scoped_restore_current_program_space): Likewise.
7342 * python/python-internal.h (class gdbpy_enter): Likewise.
7343 * regcache.h (regcache): Likewise.
7344 * target-descriptions.c (struct tdesc_reg): Likewise.
7345 (struct tdesc_type): Likewise.
7346 (struct tdesc_feature): Likewise.
7347 * ui-out.h (ui_out_emit_type): Likewise.
7348
7349 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
7350
7351 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
7352 label abort_expression.
7353
7354 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7355
7356 * common/buffer.c (buffer_xml_printf): Adjust.
7357 * common/xml-utils.c (xml_escape_text): Change return type to
7358 std::string, update code accordingly.
7359 * common/xml-utils.h (xml_escape_text): Change return type to
7360 std::string.
7361 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
7362 * windows-tdep.c (windows_xfer_shared_library): Adjust.
7363 * unittests/xml-utils-selftests.c (test_xml_escape_text):
7364 Adjust.
7365
7366 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7367
7368 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
7369 (SUBDIR_UNITTESTS_OBS): Add new object file.
7370 * unittests/xml-utils-selftests.c: New file.
7371
7372 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7373
7374 * common/selftest.h (selftest): New struct/interface.
7375 (register_test): Add name parameter, add new overload.
7376 (run_tests): Add filter parameter.
7377 (for_each_selftest_ftype): New typedef.
7378 (for_each_selftest): New declaration.
7379 * common/selftest.c (tests): Change type to
7380 map<string, unique_ptr<selftest>>.
7381 (simple_selftest): New struct.
7382 (register_test): New function.
7383 (register_test): Add name parameter and use it.
7384 (run_tests): Add filter parameter and use it. Add prints.
7385 Adjust to vector -> map change.
7386 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
7387 registering selftests.
7388 * arm-tdep.c (_initialize_arm_tdep): Likewise.
7389 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
7390 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
7391 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
7392 * findvar.c (_initialize_findvar): Likewise.
7393 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
7394 * maint.c (maintenance_selftest): Update call to run_tests.
7395 (maintenance_info_selftests): New function.
7396 (_initialize_maint_cmds): Register "maintenance info selftests"
7397 command. Update "maintenance selftest" doc.
7398 * regcache.c (_initialize_regcache): Add names when registering
7399 selftests.
7400 * rust-exp.y (_initialize_rust_exp): Likewise.
7401 * selftest-arch.c (gdbarch_selftest): New struct.
7402 (gdbarch_tests): Remove.
7403 (register_test_foreach_arch): Add name parameter. Call
7404 register_test.
7405 (tests_with_arch): Remove, move most content to
7406 gdbarch_selftest::operator().
7407 (_initialize_selftests_foreach_arch): Remove.
7408 * selftest-arch.h (register_test_foreach_arch): Add name
7409 parameter.
7410 (run_tests_with_arch): New declaration.
7411 * utils-selftests.c (_initialize_utils_selftests): Add names
7412 when registering selftests.
7413 * utils.c (_initialize_utils): Likewise.
7414 * unittests/array-view-selftests.c
7415 (_initialize_array_view_selftests): Likewise.
7416 * unittests/environ-selftests.c (_initialize_environ_selftests):
7417 Likewise.
7418 * unittests/function-view-selftests.c
7419 (_initialize_function_view_selftests): Likewise.
7420 * unittests/offset-type-selftests.c
7421 (_initialize_offset_type_selftests): Likewise.
7422 * unittests/optional-selftests.c
7423 (_initialize_optional_selftests): Likewise.
7424 * unittests/scoped_restore-selftests.c
7425 (_initialize_scoped_restore_selftests): Likewise.
7426 * NEWS: Document "maintenance selftest" and "maint info
7427 selftests".
7428
7429 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7430
7431 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7432 scoped_restore.
7433
7434 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7435
7436 * mi/mi-main.c (mi_load_progress): Make uiout variable
7437 a unique_ptr.
7438
7439 2017-09-15 Pedro Alves <palves@redhat.com>
7440
7441 * compile/compile-c-types.c (convert_enum, convert_int)
7442 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7443
7444 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7445
7446 * dwarf2read.c (copy_string): Remove.
7447 (parse_macro_definition): Replace copy_string with savestring.
7448
7449 2017-09-15 Yao Qi <yao.qi@linaro.org>
7450
7451 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7452 gdb_target_obs.
7453 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7454 Likewise.
7455 (i[34567]86-*-linux*): Likewise.
7456
7457 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7458
7459 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7460 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7461 <stack>: Change type to std::vector.
7462 <stack_len, stack_allocated>: Remove.
7463 <grow_stack>: Remove.
7464 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7465 (dwarf_expr_context::~dwarf_expr_context): Remove.
7466 (dwarf_expr_context::grow_stack): Remove.
7467 (dwarf_expr_context::push): Adjust.
7468 (dwarf_expr_context::pop): Adjust.
7469 (dwarf_expr_context::fetch): Adjust.
7470 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7471 (dwarf_expr_context::stack_empty_p): Adjust.
7472 (dwarf_expr_context::execute_stack_op): Adjust.
7473
7474 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7475
7476 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7477 return type to bool.
7478 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7479
7480 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7481
7482 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7483 Change type to bool.
7484 (dwarf_stack_value) <in_stack_memory>: Likewise.
7485 (dwarf_expr_context) <push_address>: Change parameter type to
7486 bool.
7487 <fetch_in_stack_memory>: Change return type to bool.
7488 <push>: Change parameter type to bool.
7489 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7490 to bool.
7491 (dwarf_expr_context::push_address): Likewise.
7492 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7493 to bool.
7494 (dwarf_expr_context::execute_stack_op): Adjust.
7495 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7496
7497 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7498
7499 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7500 (struct dwarf_expr_context) <n_pieces>: Remove.
7501 <pieces>: Change type to std::vector.
7502 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7503 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7504 pieces.
7505 (dwarf_expr_context::add_piece): Adjust.
7506 * dwarf2loc.c (struct piece_closure): Initialize fields.
7507 <n_pieces>: Remove.
7508 <pieces>: Change type to std::vector.
7509 (allocate_piece_closure): Adjust, change parameter to
7510 std::vector rvalue and std::move it to piece_closure.
7511 (rw_pieced_value): Adjust.
7512 (check_pieced_synthetic_pointer): Adjust.
7513 (indirect_synthetic_pointer): Adjust.
7514 (coerce_pieced_ref): Adjust.
7515 (free_pieced_value_closure): Adjust. Use delete to free
7516 piece_closure.
7517 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7518 to allocate_piece_closure.
7519 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7520
7521 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7522
7523 * probe.h (probe_ops_cp): Remove typedef.
7524 (DEF_VEC_P (probe_ops_cp)): Remove.
7525 (all_probe_ops): Change type to std::vector.
7526 * probe.c (info_probes_for_ops): Adjust to vector change.
7527 (probe_linespec_to_ops): Likewise.
7528 (all_probe_ops): Change type to std::vector.
7529 (_initialize_probe): Adjust to vector change.
7530 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7531 * elfread.c (elf_get_probes): Likewise.
7532 * stap-probe.c (_initialize_stap_probe): Likewise.
7533
7534 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7535
7536 * probe.h (struct bound_probe): Define constructors.
7537 * probe.c (bound_probe_s): Remove typedef.
7538 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7539 (collect_probes): Change return type to std::vector, remove
7540 cleanup.
7541 (compare_probes): Return bool, change parameter type. Change
7542 semantic to "less than".
7543 (gen_ui_out_table_header_info): Change parameter to std::vector
7544 and update.
7545 (exists_probe_with_pops): Likewise.
7546 (info_probes_for_ops): Update to std::vector change.
7547 (enable_probes_command): Likewise.
7548 (disable_probes_command): Likewise.
7549
7550 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7551
7552 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7553 vec to std::vector.
7554 * probe.c (parse_probes_in_pspace): Update.
7555 (find_probes_in_objfile): Update.
7556 (find_probe_by_pc): Update.
7557 (collect_probes): Update.
7558 (probe_any_get_probes): Update.
7559 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7560 return type to reference to std::vector.
7561 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7562 std::vector and update.
7563 (dtrace_process_dof): Likewise.
7564 (dtrace_get_probes): Likewise.
7565 * elfread.c (elf_get_probes): Change return type to std::vector,
7566 store an std::vector in bfd_data.
7567 (probe_key_free): Update to std::vector.
7568 * stap-probe.c (handle_stap_probe): Change parameter to
7569 std::vector and update.
7570 (stap_get_probes): Likewise.
7571 * symfile-debug.c (debug_sym_get_probes): Change return type to
7572 std::vector and update.
7573
7574 2017-09-11 Tom Tromey <tom@tromey.com>
7575
7576 * breakpoint.c (program_breakpoint_here_p): Update.
7577 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7578 from make_show_memory_breakpoints_cleanup. Return a
7579 scoped_restore_tmpl<int>.
7580 (restore_show_memory_breakpoints): Remove.
7581 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7582 * mem-break.c (memory_validate_breakpoint): Update.
7583 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7584 (ia64_memory_remove_breakpoint): Update.
7585 (ia64_breakpoint_from_pc): Update.
7586 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7587 from make_show_memory_breakpoints_cleanup.
7588
7589 2017-09-11 Tom Tromey <tom@tromey.com>
7590
7591 * d-namespace.c (d_lookup_symbol): Use std::string.
7592 (find_symbol_in_baseclass): Likewise.
7593
7594 2017-09-11 Tom Tromey <tom@tromey.com>
7595
7596 * ctf.c (ctf_start): Use std::string.
7597
7598 2017-09-11 Tom Tromey <tom@tromey.com>
7599
7600 * ada-lang.c (is_known_support_routine): Update.
7601 (ada_unhandled_exception_name_addr_from_raise): Update.
7602 * guile/scm-frame.c (gdbscm_frame_name): Update.
7603 * python/py-frame.c (frapy_name): Update.
7604 (frapy_function): Update.
7605 * stack.h (find_frame_funname): Update.
7606 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7607 (print_frame): Update.
7608
7609 2017-09-11 Tom Tromey <tom@tromey.com>
7610
7611 * findcmd.c (put_bits): Take a gdb::byte_vector.
7612 (parse_find_args): Return gdb::byte_vector. "args" now const.
7613 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7614 cleanups.
7615 (find_command): Update.
7616
7617 2017-09-11 Tom Tromey <tom@tromey.com>
7618
7619 * cli/cli-script.c (class scoped_restore_hook_in): New.
7620 (clear_hook_in_cleanup): Remove.
7621 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7622 scoped_restore_hook_in.
7623
7624 2017-09-11 Tom Tromey <tom@tromey.com>
7625
7626 * cli/cli-script.c (restore_interp): Remove.
7627 (read_command_lines): Use scoped_restore_interp.
7628 * interps.c (scoped_restore_interp::set_temp): Rename from
7629 interp_set_temp.
7630 * interps.h (class scoped_restore_interp): New.
7631 (interp_set_temp): Remove.
7632
7633 2017-09-11 Tom Tromey <tom@tromey.com>
7634
7635 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7636 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7637 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7638 scoped_restore.
7639 (mi_cmd_break_insert_1): Update.
7640 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7641 scoped_restore.
7642
7643 2017-09-11 Tom Tromey <tom@tromey.com>
7644
7645 * demangle.c (demangle_command): Update.
7646 * breakpoint.c (disable_command): Update.
7647 (enable_command): Update.
7648 (find_location_by_number): Make "number" const. Use
7649 get_number_trailer.
7650 * cli/cli-utils.c (extract_arg): Return std::string.
7651 * probe.c (parse_probe_linespec): Update. Change types.
7652 (collect_probes): Take string arguments.
7653 (parse_probe_linespec): Likewise.
7654 (info_probes_for_ops): Update.
7655 (enable_probes_command): Update.
7656 (disable_probes_command): Update.
7657 * break-catch-sig.c (catch_signal_split_args): Update.
7658 * mi/mi-parse.c (mi_parse): Update.
7659
7660 2017-09-11 Tom Tromey <tom@tromey.com>
7661
7662 * language.h (language_enum): Make argument const.
7663 * language.c (language_enum): Make argument const.
7664
7665 2017-09-11 Tom Tromey <tom@tromey.com>
7666
7667 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7668 as function.
7669 (skip_to_space): Rename from skip_to_space_const.
7670 * common/common-utils.c (skip_to_space): New function.
7671 (skip_to_space): Rename from skip_to_space_const.
7672 * cli/cli-utils.h (get_number): Rename from get_number_const.
7673 (extract_arg): Rename from extract_arg_const.
7674 * cli/cli-utils.c (get_number): Rename from get_number_const.
7675 (extract_arg): Rename from extract_arg_const.
7676 (number_or_range_parser::get_number): Use ::get_number.
7677 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7678 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7679 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7680 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7681 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7682 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7683 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7684 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7685
7686 2017-09-11 Tom Tromey <tom@tromey.com>
7687
7688 * python/python.c (do_start_initialization): Use
7689 py-event-types.def to initialize types.
7690 Define all object type structures.
7691 * python/python-internal.h: Don't declare event initialization
7692 functions.
7693 * python/py-threadevent.c (thread_event_object_type): Don't
7694 define.
7695 * python/py-stopevent.c (stop_event_object_type): Don't define.
7696 * python/py-signalevent.c (signal_event_object_type): Don't
7697 declare or define.
7698 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7699 (clear_objfiles_event_object_type): Don't declare or define.
7700 * python/py-infevents.c (inferior_call_pre_event_object_type)
7701 (inferior_call_post_event_object_type)
7702 (register_changed_event_object_type)
7703 (memory_changed_event_object_type): Don't declare or define.
7704 * python/py-inferior.c (new_thread_event_object_type)
7705 (new_inferior_event_object_type)
7706 (inferior_deleted_event_object_type): Don't declare or define.
7707 * python/py-exitedevent.c (exited_event_object_type): Don't
7708 declare or define.
7709 * python/py-evts.c (gdbpy_initialize_py_events): Use
7710 py-all-events.def.
7711 * python/py-events.h (thread_event_object_type): Don't declare.
7712 (events_object): Use py-all-events.def.
7713 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7714 py-event-types.def.
7715 * python/py-event-types.def: New file.
7716 * python/py-continueevent.c (create_continue_event_object): Don't
7717 declare or define.
7718 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7719 declare or define.
7720 * python/py-all-events.def: New file.
7721
7722 2017-09-11 Tom Tromey <tom@tromey.com>
7723
7724 * python/py-threadevent.c (create_thread_event_object): Return
7725 gdbpy_ref.
7726 * python/py-stopevent.h (create_stop_event_object)
7727 (create_breakpoint_event_object, create_signal_event_object):
7728 Update.
7729 * python/py-stopevent.c (create_stop_event_object): Return
7730 gdbpy_ref.
7731 (emit_stop_event): Update.
7732 * python/py-signalevent.c (create_signal_event_object): Return
7733 gdbpy_ref.
7734 * python/py-infevents.c (create_inferior_call_event_object):
7735 Update.
7736 * python/py-event.h (create_event_object)
7737 (create_thread_event_object): Update.
7738 * python/py-event.c (create_event_object): Return gdbpy_ref.
7739 * python/py-continueevent.c: Return gdbpy_ref.
7740 * python/py-bpevent.c (create_breakpoint_event_object): Return
7741 gdbpy_ref.
7742
7743 2017-09-11 Tom Tromey <tom@tromey.com>
7744
7745 PR python/15622:
7746 * NEWS: Add entry.
7747 * python/python.c (do_start_initialization): Initialize new event
7748 types.
7749 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7750 (gdbpy_initialize_inferior_deleted_event)
7751 (gdbpy_initialize_new_thread_event): Declare.
7752 * python/py-threadevent.c (create_thread_event_object): Add option
7753 "thread" parameter.
7754 * python/py-inferior.c (new_thread_event_object_type)
7755 (new_inferior_event_object_type)
7756 (inferior_deleted_event_object_type): Declare.
7757 (python_new_inferior, python_inferior_deleted): New functions.
7758 (add_thread_object): Emit new_thread event.
7759 (gdbpy_initialize_inferior): Attach new functions to corresponding
7760 observers.
7761 (new_thread, new_inferior, inferior_deleted): Define new event
7762 types.
7763 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7764 registries.
7765 * python/py-events.h (events_object) <new_inferior,
7766 inferior_deleted, new_thread>: New fields.
7767 * python/py-event.h (create_thread_event_breakpoint): Add optional
7768 "thread" parameter.
7769
7770 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7771
7772 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7773 check current_ui instead.
7774 (internal_vproblem): Likewise.
7775
7776 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7777
7778 * thread.c (print_thread_info_1): Remove unnecessary calls to
7779 uiout->is_mi_like_p.
7780
7781 2017-09-09 Tom Tromey <tom@tromey.com>
7782
7783 * namespace.h (add_using_directive): Update.
7784 * namespace.c (add_using_directive): Change type of excludes to
7785 std::vector.
7786 * dwarf2read.c (read_import_statement): Use std::vector.
7787 (read_namespace): Update.
7788 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
7789
7790 2017-09-09 Tom Tromey <tom@tromey.com>
7791
7792 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
7793
7794 2017-09-09 Tom Tromey <tom@tromey.com>
7795
7796 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
7797
7798 2017-09-09 Tom Tromey <tom@tromey.com>
7799
7800 * stack.c (func_command): Use gdb::def_vector.
7801
7802 2017-09-09 Tom Tromey <tom@tromey.com>
7803
7804 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
7805 ui_out_emit_list, ui_out_emit_tuple.
7806 (mi_cmd_var_update): Likewise.
7807
7808 2017-09-09 Tom Tromey <tom@tromey.com>
7809
7810 * mi/mi-interp.c (mi_user_selected_context_changed): Use
7811 ui_out_redirect_pop.
7812 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7813 ui_out_redirect_pop.
7814 * utils.c (do_ui_out_redirect_pop)
7815 (make_cleanup_ui_out_redirect_pop): Remove.
7816 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
7817 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
7818 * ui-out.h (ui_out_redirect_pop): New class.
7819
7820 2017-09-09 Tom Tromey <tom@tromey.com>
7821
7822 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
7823 (list_available_thread_groups, mi_cmd_list_thread_groups)
7824 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
7825 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
7826 Likewise.
7827
7828 2017-09-09 Tom Tromey <tom@tromey.com>
7829
7830 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
7831 ui_out_emit_tuple.
7832
7833 2017-09-09 Tom Tromey <tom@tromey.com>
7834
7835 * target.c (flash_erase_command): Use ui_out_emit_tuple.
7836 * stack.c (print_frame): Use ui_out_emit_tuple.
7837 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
7838 (info_spu_mailbox_command, info_spu_dma_command)
7839 (info_spu_proxydma_command): Likewise.
7840 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
7841 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
7842 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7843 ui_out_emit_tuple.
7844 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
7845
7846 2017-09-09 Tom Tromey <tom@tromey.com>
7847
7848 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
7849 (class ui_out_emit_table): Update comment.
7850 * ui-out.c (do_cleanup_table_end)
7851 (make_cleanup_ui_out_table_begin_end): Remove.
7852 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
7853 (info_spu_dma_cmdlist): Likewise.
7854 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
7855 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
7856 ui_out_emit_table.
7857
7858 2017-09-09 Tom Tromey <tom@tromey.com>
7859
7860 * thread.c (print_thread_info_1): Use ui_out_emit_table,
7861 ui_out_emit_list, gdb::optional.
7862
7863 2017-09-09 John Baldwin <jhb@FreeBSD.org>
7864
7865 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
7866 prototype.
7867 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
7868 prototype.
7869 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
7870 prototype.
7871 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
7872 * ada-exp.y: Remove _initialize_ada_exp prototype.
7873 * ada-lang.c: Remove _initialize_ada_language prototype.
7874 * ada-tasks.c: Remove _initialize_tasks prototype.
7875 * addrmap.c: Remove _initialize_addrmap prototype.
7876 * agent.c: Remove _initialize_agent prototype.
7877 * aix-thread.c: Remove _initialize_aix_thread prototype.
7878 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
7879 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
7880 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
7881 prototype.
7882 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
7883 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
7884 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
7885 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
7886 prototype.
7887 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
7888 prototype.
7889 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
7890 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
7891 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
7892 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
7893 prototype.
7894 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
7895 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
7896 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
7897 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
7898 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7899 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
7900 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
7901 prototype.
7902 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
7903 prototype.
7904 * annotate.c: Remove _initialize_annotate prototype.
7905 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
7906 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
7907 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
7908 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
7909 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
7910 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
7911 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
7912 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
7913 prototype.
7914 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
7915 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
7916 * auto-load.c: Remove _initialize_auto_load prototype.
7917 * auxv.c: Remove _initialize_auxv prototype.
7918 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
7919 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
7920 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
7921 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
7922 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
7923 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
7924 prototype.
7925 * break-catch-throw.c: Remove _initialize_break_catch_throw
7926 prototype.
7927 * breakpoint.c: Remove _initialize_breakpoint prototype.
7928 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
7929 * btrace.c: Remove _initialize_btrace prototype.
7930 * charset.c: Remove _initialize_charset prototype.
7931 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
7932 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
7933 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
7934 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
7935 * cli/cli-script.c: Remove _initialize_cli_script prototype.
7936 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
7937 * coffread.c: Remove _initialize_coffread prototype.
7938 * compile/compile.c: Remove _initialize_compile prototype.
7939 * complaints.c: Remove _initialize_complaints prototype.
7940 * completer.c: Remove _initialize_completer prototype.
7941 * copying.awk: Remove _initialize_copying prototype.
7942 * copying.c: Regenerate.
7943 * core-regset.c: Remove _initialize_core_regset prototype.
7944 * corefile.c: Remove _initialize_core prototype.
7945 * corelow.c: Remove _initialize_corelow prototype.
7946 * cp-abi.c: Remove _initialize_cp_abi prototype.
7947 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
7948 * cp-support.c: Remove _initialize_cp_support prototype.
7949 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
7950 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
7951 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
7952 * ctf.c: Remove _initialize_ctf prototype.
7953 * d-lang.c: Remove _initialize_d_language prototype.
7954 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
7955 prototype.
7956 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
7957 * dbxread.c: Remove _initialize_dbxread prototype.
7958 * dcache.c: Remove _initialize_dcache prototype.
7959 * demangle.c: Remove _initialize_demangler prototype.
7960 * disasm-selftests.c: Remove _initialize_disasm_selftests
7961 prototype.
7962 * disasm.c: Remove _initialize_disasm prototype.
7963 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
7964 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
7965 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
7966 prototype.
7967 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
7968 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
7969 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
7970 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
7971 * elfread.c: Remove _initialize_elfread prototype.
7972 * exec.c: Remove _initialize_exec prototype.
7973 * extension.c: Remove _initialize_extension prototype.
7974 * f-lang.c: Remove _initialize_f_language prototype.
7975 * f-valprint.c: Remove _initialize_f_valprint prototype.
7976 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
7977 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
7978 * filesystem.c: Remove _initialize_filesystem prototype.
7979 * findcmd.c: Remove _initialize_mem_search prototype.
7980 * fork-child.c: Remove _initialize_fork_child prototype.
7981 * frame-base.c: Remove _initialize_frame_base prototype.
7982 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
7983 * frame.c: Remove _initialize_frame prototype.
7984 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
7985 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
7986 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
7987 * gcore.c: Remove _initialize_gcore prototype.
7988 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
7989 * gdbarch.c: Regenerate.
7990 * gdbarch.sh: Remove _initialize_gdbarch prototype.
7991 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
7992 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
7993 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
7994 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
7995 * go-lang.c: Remove _initialize_go_language prototype.
7996 * go32-nat.c: Remove _initialize_go32_nat prototype.
7997 * guile/guile.c: Remove _initialize_guile prototype.
7998 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
7999 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
8000 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
8001 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
8002 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
8003 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
8004 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
8005 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
8006 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
8007 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
8008 prototype.
8009 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
8010 prototype.
8011 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
8012 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
8013 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
8014 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
8015 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
8016 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
8017 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
8018 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
8019 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
8020 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
8021 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
8022 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
8023 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
8024 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
8025 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
8026 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
8027 prototype.
8028 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
8029 prototype.
8030 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
8031 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
8032 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
8033 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
8034 * infcall.c: Remove _initialize_infcall prototype.
8035 * infcmd.c: Remove _initialize_infcmd prototype.
8036 * inferior.c: Remove _initialize_inferiors prototype.
8037 * inflow.c: Remove _initialize_inflow prototype.
8038 * infrun.c: Remove _initialize_infrun prototype.
8039 * interps.c: Remove _initialize_interpreter prototype.
8040 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
8041 * jit.c: Remove _initialize_jit prototype.
8042 * language.c: Remove _initialize_language prototype.
8043 * linux-fork.c: Remove _initialize_linux_fork prototype.
8044 * linux-nat.c: Remove _initialize_linux_nat prototype.
8045 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
8046 * linux-thread-db.c: Remove _initialize_thread_db prototype.
8047 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
8048 * m2-lang.c: Remove _initialize_m2_language prototype.
8049 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
8050 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
8051 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
8052 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
8053 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
8054 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8055 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8056 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
8057 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
8058 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
8059 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8060 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8061 * machoread.c: Remove _initialize_machoread prototype.
8062 * macrocmd.c: Remove _initialize_macrocmd prototype.
8063 * macroscope.c: Remove _initialize_macroscope prototype.
8064 * maint.c: Remove _initialize_maint_cmds prototype.
8065 * mdebugread.c: Remove _initialize_mdebugread prototype.
8066 * memattr.c: Remove _initialize_mem prototype.
8067 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
8068 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
8069 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
8070 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
8071 * mi/mi-main.c: Remove _initialize_mi_main prototype.
8072 * microblaze-linux-tdep.c: Remove
8073 _initialize_microblaze_linux_tdep prototype.
8074 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
8075 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
8076 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
8077 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
8078 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
8079 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
8080 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
8081 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
8082 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
8083 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
8084 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
8085 prototype.
8086 * mipsread.c: Remove _initialize_mipsread prototype.
8087 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
8088 prototype.
8089 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
8090 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
8091 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
8092 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
8093 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
8094 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
8095 prototype.
8096 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
8097 * nto-procfs.c: Remove _initialize_procfs prototype.
8098 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
8099 * objc-lang.c: Remove _initialize_objc_language prototype.
8100 * objfiles.c: Remove _initialize_objfiles prototype.
8101 * observer.c: Remove observer_test_first_notification_function,
8102 observer_test_second_notification_function,
8103 observer_test_third_notification_function, and
8104 _initialize_observer prototypes.
8105 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
8106 * osabi.c: Remove _initialize_gdb_osabi prototype.
8107 * osdata.c: Remove _initialize_osdata prototype.
8108 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
8109 * parse.c: Remove _initialize_parse prototype.
8110 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
8111 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
8112 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
8113 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
8114 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
8115 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
8116 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
8117 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
8118 * printcmd.c: Remove _initialize_printcmd prototype.
8119 * probe.c: Remove _initialize_probe prototype.
8120 * proc-api.c: Remove _initialize_proc_api prototype.
8121 * proc-events.c: Remove _initialize_proc_events prototype.
8122 * proc-service.c: Remove _initialize_proc_service prototype.
8123 * procfs.c: Remove _initialize_procfs prototype.
8124 * psymtab.c: Remove _initialize_psymtab prototype.
8125 * python/python.c: Remove _initialize_python prototype.
8126 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
8127 * record-btrace.c: Remove _initialize_record_btrace prototype.
8128 * record-full.c: Remove _initialize_record_full prototype.
8129 * record.c: Remove _initialize_record prototype.
8130 * regcache.c: Remove _initialize_regcache prototype.
8131 * reggroups.c: Remove _initialize_reggroup prototype.
8132 * remote-notif.c: Remove _initialize_notif prototype.
8133 * remote-sim.c: Remove _initialize_remote_sim prototype.
8134 * remote.c: Remove _initialize_remote prototype.
8135 * reverse.c: Remove _initialize_reverse prototype.
8136 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
8137 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
8138 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
8139 prototype.
8140 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
8141 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
8142 * rust-exp.y: Remove _initialize_rust_exp prototype.
8143 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
8144 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
8145 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
8146 * score-tdep.c: Remove _initialize_score_tdep prototype.
8147 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
8148 prototype.
8149 * ser-go32.c: Remove _initialize_ser_dos prototype.
8150 * ser-mingw.c: Remove _initialize_ser_windows prototype.
8151 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
8152 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
8153 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
8154 * serial.c: Remove _initialize_serial prototype.
8155 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
8156 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
8157 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
8158 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
8159 * skip.c: Remove _initialize_step_skip prototype.
8160 * sol-thread.c: Remove _initialize_sol_thread prototype.
8161 * solib-aix.c: Remove _initialize_solib_aix prototype.
8162 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
8163 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
8164 * solib-frv.c: Remove _initialize_frv_solib prototype.
8165 * solib-spu.c: Remove _initialize_spu_solib prototype.
8166 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
8167 * solib-target.c: Remove _initialize_solib_target prototype.
8168 * solib.c: Remove _initialize_solib prototype.
8169 * source.c: Remove _initialize_source prototype.
8170 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
8171 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
8172 prototype.
8173 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
8174 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
8175 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
8176 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
8177 prototype.
8178 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
8179 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
8180 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
8181 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
8182 prototype.
8183 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
8184 prototype.
8185 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
8186 prototype.
8187 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
8188 prototype.
8189 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
8190 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
8191 prototype.
8192 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
8193 prototype.
8194 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
8195 prototype.
8196 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
8197 prototype.
8198 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
8199 prototype.
8200 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
8201 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
8202 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
8203 * stabsread.c: Remove _initialize_stabsread prototype.
8204 * stack.c: Remove _initialize_stack prototype.
8205 * stap-probe.c: Remove _initialize_stap_probe prototype.
8206 * std-regs.c: Remove _initialize_frame_reg prototype.
8207 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
8208 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
8209 * symfile.c: Remove _initialize_symfile prototype.
8210 * symmisc.c: Remove _initialize_symmisc prototype.
8211 * symtab.c: Remove _initialize_symtab prototype.
8212 * target-dcache.c: Remove _initialize_target_dcache prototype.
8213 * target-descriptions.c: Remove _initialize_target_descriptions
8214 prototype.
8215 * thread.c: Remove _initialize_thread prototype.
8216 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
8217 prototype.
8218 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
8219 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
8220 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
8221 prototype.
8222 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
8223 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
8224 * tracefile.c: Remove _initialize_tracefile prototype.
8225 * tracepoint.c: Remove _initialize_tracepoint prototype.
8226 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
8227 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
8228 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
8229 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
8230 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
8231 * tui/tui-win.c: Remove _initialize_tui_win prototype.
8232 * tui/tui.c: Remove _initialize_tui prototype.
8233 * typeprint.c: Remove _initialize_typeprint prototype.
8234 * user-regs.c: Remove _initialize_user_regs prototype.
8235 * utils.c: Remove _initialize_utils prototype.
8236 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
8237 * valarith.c: Remove _initialize_valarith prototype.
8238 * valops.c: Remove _initialize_valops prototype.
8239 * valprint.c: Remove _initialize_valprint prototype.
8240 * value.c: Remove _initialize_values prototype.
8241 * varobj.c: Remove _initialize_varobj prototype.
8242 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
8243 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
8244 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
8245 * windows-nat.c: Remove _initialize_windows_nat,
8246 _initialize_check_for_gdb_ini, and _initialize_loadable
8247 prototypes.
8248 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
8249 * xcoffread.c: Remove _initialize_xcoffread prototype.
8250 * xml-support.c: Remove _initialize_xml_support prototype.
8251 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
8252 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
8253 prototype.
8254 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
8255 prototype.
8256 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
8257
8258 2017-09-08 Keith Seitz <keiths@redhat.com>
8259
8260 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
8261 field.
8262
8263 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
8264
8265 * f-valprint.c (f_val_print): Remove check for one byte
8266 sized integers. Remove printing of character type.
8267
8268 2017-09-08 Frank Penczek <frank.penczek@intel.com>
8269 Christoph Weinmann <christoph.t.weinmann@intel.com>
8270 Bernhard Heckel <bernhard.heckel@intel.com>
8271
8272 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
8273 to maintain proper indentation when printing pointers/refs.
8274
8275 2017-09-07 Joel Brobecker <brobecker@adacore.com>
8276
8277 GDB 8.0.1 released.
8278
8279 2017-09-07 Joel Brobecker <brobecker@adacore.com>
8280
8281 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
8282
8283 2017-09-05 Tom Tromey <tom@tromey.com>
8284
8285 * parse.c (funcall_chain): Now a std::vector.
8286 (start_arglist, end_arglist): Simplify.
8287 (free_funcalls): Remove.
8288 (parse_exp_in_context_1): Remove cleanup.
8289
8290 2017-09-05 Tom Tromey <tom@tromey.com>
8291
8292 * go-exp.y (go_parse): Don't create a cleanup.
8293
8294 2017-09-05 Tom Tromey <tom@tromey.com>
8295
8296 * d-exp.y (PrimaryExpression): Use std::string.
8297 (d_parse): Don't create a cleanup.
8298
8299 2017-09-05 Tom Tromey <tom@tromey.com>
8300
8301 * utils.c (do_clear_parser_state): Remove.
8302 (make_cleanup_clear_parser_state): Remove.
8303 * p-exp.y (pascal_parse): Use scoped_restore.
8304 * m2-exp.y (m2_parse): Use scoped_restore.
8305 * f-exp.y (f_parse): Use scoped_restore.
8306 * d-exp.y (d_parse): Use scoped_restore.
8307 * c-exp.y (c_parse): Use scoped_restore.
8308 * ada-exp.y (ada_parse): Use scoped_restore.
8309 * utils.h (make_cleanup_clear_parser_state): Remove.
8310
8311 2017-09-06 Keith Seitz <keiths@redhat.com>
8312
8313 * dwarf2read.c (dw2_linkage_name_attr): New function.
8314 (dw2_linkage_name): New function.
8315 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
8316 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
8317 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
8318
8319 2017-09-06 Kamil Rytarowski <n54@gmx.com>
8320
8321 * config/djgpp/djconfig.sh: Correct shell portability issue.
8322
8323 2017-09-06 Kamil Rytarowski <n54@gmx.com>
8324
8325 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
8326
8327 2017-09-06 John Baldwin <jhb@FreeBSD.org>
8328
8329 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
8330 * NEWS: Mention new FreeBSD/mips native configuration.
8331 * configure.host: Add aarch64*-*-freebsd*.
8332 * configure.nat: Likewise.
8333 * aarch64-fbsd-nat.c: New file.
8334
8335 2017-09-06 John Baldwin <jhb@FreeBSD.org>
8336
8337 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
8338 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
8339 * NEWS: Mention new FreeBSD/aarch64 target.
8340 * configure.tgt: Add aarch64*-*-freebsd*.
8341 * aarch64-fbsd-tdep.c: New file.
8342 * aarch64-fbsd-tdep.h: New file.
8343
8344 2017-09-06 Kamil Rytarowski <n54@gmx.com>
8345
8346 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
8347
8348 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8349
8350 * parse.c (find_minsym_type_and_address): Don't relocate addresses
8351 of TLS symbols.
8352
8353 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8354
8355 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
8356 call.
8357
8358 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8359
8360 * infrun.c (follow_exec): Call add_thread after
8361 target_find_description.
8362
8363 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8364
8365 * infrun.c (handle_inferior_event_1): When exec'ing, read
8366 stop_pc after follow_exec.
8367
8368 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8369
8370 * remote.c (process_g_packet): Update error message.
8371
8372 2017-09-05 Yao Qi <yao.qi@linaro.org>
8373
8374 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
8375 targets.
8376
8377 2017-09-05 Pedro Alves <palves@redhat.com>
8378
8379 * eval.c (eval_call, evaluate_funcall): New functions, factored
8380 out from ...
8381 (evaluate_subexp_standard): ... this.
8382
8383 2017-09-05 Yao Qi <yao.qi@linaro.org>
8384
8385 * amd64-tdep.c (amd64_target_description): Create target
8386 descriptions.
8387 (_initialize_amd64_tdep): Don't call functions
8388 initialize_tdesc_amd64_*. Add self tests.
8389 * arch/amd64.c (amd64_create_target_description): Add parameter
8390 is_linux. Call set_tdesc_osabi if is_linux is true.
8391 * arch/amd64.h (amd64_create_target_description): Update the
8392 declaration.
8393 * arch/i386.c (i386_create_target_description): Add parameter
8394 is_linux. Call set_tdesc_osabi if is_linux is true.
8395 * arch/i386.h (i386_create_target_description): Update
8396 declaration.
8397 * configure.tgt: Add i386.o to gdb_target_obs.
8398 * features/Makefile (XMLTOC): Remove i386/*.xml.
8399 * features/i386/amd64-avx-avx512.c: Remove.
8400 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
8401 * features/i386/amd64-avx-mpx.c: Remove.
8402 * features/i386/amd64-avx.c: Remove.
8403 * features/i386/amd64-mpx.c: Remove.
8404 * features/i386/amd64.c: Remove.
8405 * features/i386/i386-avx-avx512.c: Remove.
8406 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
8407 * features/i386/i386-avx-mpx.c: Remove.
8408 * features/i386/i386-avx.c: Remove.
8409 * features/i386/i386-mmx.c: Remove.
8410 * features/i386/i386-mpx.c: Remove.
8411 * features/i386/i386.c: Remove.
8412 * i386-tdep.c: Don't include features/i386/i386*.c., include
8413 target-descriptions.h and arch/i386.h.
8414 (i386_target_description): Create target descriptions.
8415 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
8416 functions. Do self tests.
8417
8418 2017-09-05 Yao Qi <yao.qi@linaro.org>
8419
8420 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
8421 * features/i386/amd64-avx-avx512-linux.c: Removed.
8422 * features/i386/amd64-avx-linux.c: Removed.
8423 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
8424 * features/i386/amd64-avx-mpx-linux.c: Removed.
8425 * features/i386/amd64-linux.c: Removed.
8426 * features/i386/amd64-mpx-linux.c: Removed.
8427 * features/i386/x32-avx-avx512-linux.c: Removed.
8428 * features/i386/x32-avx-linux.c: Removed.
8429 * features/i386/x32-linux.c: Removed.
8430
8431 2017-09-05 Yao Qi <yao.qi@linaro.org>
8432
8433 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8434 features/i386/*.c.
8435 (amd64_linux_read_description): Call
8436 amd64_create_target_description.
8437 * arch/amd64.c: New file.
8438 * arch/amd64.h: New file.
8439 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8440 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8441
8442 2017-09-05 Yao Qi <yao.qi@linaro.org>
8443
8444 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8445 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8446 (amd64_linux_read_description): Create target descriptions.
8447 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8448 functions. Add unit tests.
8449 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8450 x32-core.xml.
8451 * features/i386/64bit-avx.c: Generated.
8452 * features/i386/64bit-avx512.c: Generated.
8453 * features/i386/64bit-core.c: Generated.
8454 * features/i386/64bit-linux.c: Generated.
8455 * features/i386/64bit-mpx.c: Generated.
8456 * features/i386/64bit-pkeys.c: Generated.
8457 * features/i386/64bit-segments.c: Generated.
8458 * features/i386/64bit-sse.c: Generated.
8459 * features/i386/x32-core.c: Generated.
8460 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8461 c files for amd64-linux and x32-linux.
8462
8463 2017-09-05 Yao Qi <yao.qi@linaro.org>
8464
8465 * amd64-linux-tdep.c (amd64_linux_read_description): New
8466 function.
8467 (amd64_linux_core_read_description): Call
8468 amd64_linux_read_description.
8469 (amd64_linux_init_abi): Likewise.
8470 (amd64_x32_linux_init_abi): Likewise.
8471 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8472 * x86-linux-nat.c (x86_linux_read_description): Call
8473 amd64_linux_read_description.
8474
8475 2017-09-05 Yao Qi <yao.qi@linaro.org>
8476
8477 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8478 comments.
8479
8480 2017-09-05 Yao Qi <yao.qi@linaro.org>
8481
8482 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8483 * features/i386/i386-avx-avx512-linux.c: Remove.
8484 * features/i386/i386-avx-linux.c: Remove.
8485 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8486 * features/i386/i386-avx-mpx-linux.c: Remove.
8487 * features/i386/i386-linux.c: Remove.
8488 * features/i386/i386-mmx-linux.c: Remove.
8489 * features/i386/i386-mpx-linux.c: Remove.
8490
8491 2017-09-05 Yao Qi <yao.qi@linaro.org>
8492
8493 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8494 (SFILES): Add arch/i386.c.
8495 (HFILES_NO_SRCDIR): Add arch/i386.h.
8496 * arch/i386.c: New file.
8497 * arch/i386.h: New file.
8498 * arch/tdesc.h (allocate_target_description): Declare.
8499 (set_tdesc_architecture): Declare.
8500 (set_tdesc_osabi): Declare.
8501 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8502 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8503 include arch/i386.h.
8504 (i386_linux_read_description): Remove code and call
8505 i386_create_target_description.
8506 (set_tdesc_architecture): New function.
8507 (set_tdesc_osabi): New function.
8508 * target-descriptions.h (allocate_target_description): Remove.
8509
8510 2017-09-05 Yao Qi <yao.qi@linaro.org>
8511
8512 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8513 * target-descriptions.c (tdesc_create_feature): Likewise, and
8514 adjust code.
8515 * features/i386/32bit-avx.c: Re-generated.
8516 * features/i386/32bit-avx512.c: Re-generated.
8517 * features/i386/32bit-core.c: Re-generated.
8518 * features/i386/32bit-linux.c: Re-generated.
8519 * features/i386/32bit-mpx.c: Re-generated.
8520 * features/i386/32bit-pkeys.c: Re-generated.
8521 * features/i386/32bit-sse.c: Re-generated.
8522
8523 2017-09-05 Yao Qi <yao.qi@linaro.org>
8524
8525 * regformats/regdef.h (struct reg): Override operator == and !=.
8526
8527 2017-09-05 Yao Qi <yao.qi@linaro.org>
8528
8529 * arch/tdesc.h: New file.
8530 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8531 * target-descriptions.c: Update comments.
8532 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8533 declarations.
8534 * features/i386/32bit-avx.c: Re-generated.
8535 * features/i386/32bit-avx512.c: Re-generated.
8536 * features/i386/32bit-core.c: Re-generated.
8537 * features/i386/32bit-linux.c: Re-generated.
8538 * features/i386/32bit-mpx.c: Re-generated.
8539 * features/i386/32bit-pkeys.c: Re-generated.
8540 * features/i386/32bit-sse.c: Re-generated.
8541
8542 2017-09-05 Yao Qi <yao.qi@linaro.org>
8543
8544 * regformats/regdat.sh: Update generated code.
8545
8546 2017-09-05 Yao Qi <yao.qi@linaro.org>
8547
8548 * regformats/regdat.sh: Adjust code order.
8549
8550 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8551
8552 * expprint.c (dump_subexp_body_standard): Use constant format
8553 string in fprintf_filtered call.
8554
8555 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8556
8557 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8558 NetBSD/i386.
8559 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8560
8561 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8562
8563 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8564
8565 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8566
8567 * bsd-kvm.o: Define _KMEMUSER.
8568 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8569 * configure: Regenerate.
8570
8571 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8572
8573 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8574 * i386-fbsd-nat.c: Likewise.
8575
8576 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8577
8578 * unittests/array-view-selftests.c: Add include of <array>.
8579
8580 2017-09-04 John Baldwin <jhb@FreeBSD.org>
8581
8582 * spu-tdep.c (flush_ea_cache): Add missing argument to
8583 call_function_by_hand.
8584
8585 2017-09-04 Pedro Alves <palves@redhat.com>
8586
8587 * NEWS (Safer support for debugging with no debug info): New.
8588
8589 2017-09-04 Pedro Alves <palves@redhat.com>
8590
8591 * c-exp.y (function_method, function_method_void): Add current
8592 instance flags to TYPE_INSTANCE.
8593 * dwarf2read.c (check_modifier): New.
8594 (compute_delayed_physnames): Assert that only C++ adds delayed
8595 physnames. Mark fn_fields as const/volatile depending on
8596 physname.
8597 * eval.c (make_params): New type_instance_flags parameter. Use
8598 it as the new type's instance flags.
8599 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8600 flags element and pass it to make_params.
8601 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8602 instance flags element.
8603 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8604 * gdbtypes.h: Include "enum-flags.h".
8605 (type_instance_flags): New enum-flags type.
8606 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8607 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8608 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8609 (follow_type_instance_flags): New function.
8610 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8611 * parser-defs.h (follow_type_instance_flags): Declare.
8612 * valops.c (value_struct_elt_for_reference): const/volatile must
8613 match too.
8614
8615 2017-09-04 Pedro Alves <palves@redhat.com>
8616
8617 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8618 function/method scopes; lookup the nested name as a function local
8619 static variable.
8620
8621 2017-09-04 Pedro Alves <palves@redhat.com>
8622
8623 (%type <voidval>): Add function_method.
8624 * c-exp.y (exp): New production for calls with no arguments.
8625 (function_method, function_method_void_or_typelist): New
8626 productions.
8627 (exp): New production for "method()::static_var".
8628 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8629 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8630 Handle OP_FUNC_STATIC_VAR.
8631 * parse.c (operator_length_standard):
8632 Handle OP_FUNC_STATIC_VAR.
8633
8634 2017-09-04 Pedro Alves <palves@redhat.com>
8635
8636 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8637 handling.
8638 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8639 Ditto.
8640 * parse.c (operator_length_standard, operator_check_standard):
8641 Ditto.
8642 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8643
8644 2017-09-04 Pedro Alves <palves@redhat.com>
8645
8646 * ax-gdb.c: Include "typeprint.h".
8647 (gen_expr_for_cast): New function.
8648 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8649 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8650 type is unknown.
8651 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8652 nodebug_data_symbol.
8653 * eval.c: Include "typeprint.h".
8654 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8655 Error out if symbol has unknown type.
8656 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8657 evaluate_subexp_for_cast.
8658 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8659 OP_VAR_MSYM_VALUE.
8660 (evaluate_subexp_for_cast): New function.
8661 * gdbtypes.c (init_nodebug_var_type): New function.
8662 (objfile_type): Use it to initialize types of variables with no
8663 debug info.
8664 * typeprint.c (error_unknown_type): New.
8665 * typeprint.h (error_unknown_type): New declaration.
8666 * compile/compile-c-types.c (convert_type_basic): Handle
8667 TYPE_CODE_ERROR; warn and fallback to int for variables with
8668 unknown type.
8669
8670 2017-09-04 Pedro Alves <palves@redhat.com>
8671
8672 * eval.c (evaluate_var_value): New function, factored out from ...
8673 (evaluate_subexp_standard): ... here.
8674
8675 2017-09-04 Pedro Alves <palves@redhat.com>
8676
8677 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8678 Remove useless assignments to 'op'.
8679
8680 2017-09-04 Pedro Alves <palves@redhat.com>
8681
8682 * eval.c (eval_skip_value): New function.
8683 (evaluate_subexp_standard): Use it.
8684
8685 2017-09-04 Pedro Alves <palves@redhat.com>
8686
8687 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8688 function name from symbol/minsym and pass it to
8689 error_call_unknown_return_type.
8690
8691 2017-09-04 Pedro Alves <palves@redhat.com>
8692
8693 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8694 * ax-gdb.c (gen_msym_var_ref): New function.
8695 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8696 * eval.c (evaluate_var_msym_value): New function.
8697 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8698 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8699 to call_function_by_hand.
8700 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8701 Handle OP_VAR_MSYM_VALUE.
8702 (union exp_element) <msymbol>: New field.
8703 * minsyms.h (struct type): Forward declare.
8704 (find_minsym_type_and_address): Declare.
8705 * parse.c (write_exp_elt_msym): New function.
8706 (write_exp_msymbol): Delete, refactored as ...
8707 (find_minsym_type_and_address): ... this new function.
8708 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8709 (operator_length_standard, operator_check_standard): Handle
8710 OP_VAR_MSYM_VALUE.
8711 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8712
8713 2017-09-04 Pedro Alves <palves@redhat.com>
8714
8715 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8716 TYPE_GNU_IFUNC specially here. Throw error if return type is
8717 unknown.
8718 * ada-typeprint.c (print_func_type): Handle functions with unknown
8719 return type.
8720 * c-typeprint.c (c_type_print_base): Handle functions and methods
8721 with unknown return type.
8722 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8723 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8724 * compile/compile-c-types.c: Include "objfiles.h".
8725 (convert_func): For functions with unknown return type, warn and
8726 default to int.
8727 * compile/compile-object-run.c (compile_object_run): Adjust call
8728 to call_function_by_hand_dummy.
8729 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8730 call_function_by_hand.
8731 * eval.c (evaluate_subexp_standard): Adjust calls to
8732 call_function_by_hand. Handle functions and methods with unknown
8733 return type. Pass expect_type to call_function_by_hand.
8734 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8735 return type.
8736 * gcore.c (call_target_sbrk): Adjust call to
8737 call_function_by_hand.
8738 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8739 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8740 an integer address type instead of nodebug.
8741 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8742 call_function_by_hand.
8743 * infcall.c (error_call_unknown_return_type): New function.
8744 (call_function_by_hand): New "default_return_type" parameter.
8745 Pass it down.
8746 (call_function_by_hand_dummy): New "default_return_type"
8747 parameter. Use it instead of defaulting to int. If there's no
8748 default and the return type is unknown, throw an error. If
8749 there's a default return type, and the called function has no
8750 debug info, then assume the function is prototyped.
8751 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8752 New "default_return_type" parameter.
8753 (error_call_unknown_return_type): New declaration.
8754 * linux-fork.c (call_lseek): Cast return type of lseek.
8755 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8756 call_function_by_hand.
8757 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8758 calls to call_function_by_hand.
8759 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8760 return type.
8761 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8762 (value_nsstring, print_object_command): Adjust calls to
8763 call_function_by_hand.
8764 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8765 functions with unknown return type.
8766 (pascal_type_print_func_varspec_suffix): New function.
8767 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8768 TYPE_CODE_METHOD>: Use it.
8769 * python/py-value.c (valpy_call): Adjust call to
8770 call_function_by_hand.
8771 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8772 call_function_by_hand.
8773 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8774 call_function_by_hand.
8775 * valops.c (value_allocate_space_in_inferior): Adjust call to
8776 call_function_by_hand.
8777 * typeprint.c (type_print_unknown_return_type): New function.
8778 * typeprint.h (type_print_unknown_return_type): New declaration.
8779
8780 2017-09-04 Pedro Alves <palves@redhat.com>
8781
8782 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
8783 types with more than one parameter as prototyped.
8784
8785 2017-09-04 Pedro Alves <palves@redhat.com>
8786
8787 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
8788 (disassemble_command): Use gdb_disassembly_flags instead of bare
8789 int.
8790 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
8791 (dump_insns, do_mixed_source_and_assembly_deprecated)
8792 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
8793 Use gdb_disassembly_flags instead of bare int.
8794 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
8795 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
8796 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
8797 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
8798 (enum gdb_disassembly_flag): ... values of this new enumeration.
8799 (gdb_disassembly_flags): Define.
8800 (gdb_disassembly)
8801 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
8802 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
8803 gdb_disassembly_flags instead of bare int.
8804 * record-btrace.c (btrace_insn_history)
8805 (record_btrace_insn_history, record_btrace_insn_history_range)
8806 (record_btrace_insn_history_from): Use gdb_disassembly_flags
8807 instead of bare int.
8808 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
8809 Use gdb_disassembly_flags instead of bare int.
8810 * target-debug.h (target_debug_print_gdb_disassembly_flags):
8811 Define.
8812 * target-delegates.c: Regenerate.
8813 * target.c (target_insn_history, target_insn_history_from)
8814 (target_insn_history_range): Use gdb_disassembly_flags instead of
8815 bare int.
8816 * target.h: Include "disasm.h".
8817 (struct target_ops) <to_insn_history, to_insn_history_from,
8818 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
8819 int.
8820 (target_insn_history, target_insn_history_from)
8821 (target_insn_history_range): Use gdb_disassembly_flags instead of
8822 bare int.
8823
8824 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8825
8826 * cli/cli-script.c (build_command_line): For if/while commands,
8827 check whether args is empty.
8828
8829 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8830
8831 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
8832 (enum command_control_type): Likewise.
8833 (struct command_line): Likewise.
8834 (free_command_lines): Likewise.
8835 (struct command_lines_deleter): Likewise.
8836 (command_line_up): Likewise.
8837 (read_command_lines): Likewise.
8838 (read_command_lines_1): Likewise.
8839 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
8840 (enum command_control_type): Likewise.
8841 (struct command_line): Likewise.
8842 (free_command_lines): Likewise.
8843 (struct command_lines_deleter): Likewise.
8844 (command_line_up): Likewise.
8845 (read_command_lines): Likewise.
8846 (read_command_lines_1): Likewise.
8847 * breakpoint.h: Include cli/cli-script.h.
8848 * extension-priv.h: Likewise.
8849 * gdbcmd.h: Likewise.
8850
8851 2017-09-04 Pedro Alves <palves@redhat.com>
8852
8853 * ada-lang.c (is_known_support_routine): Move sal declaration to
8854 where it is initialized.
8855 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
8856 (parse_breakpoint_sals, decode_static_tracepoint_spec)
8857 (clear_command, update_static_tracepoint): Remove init_sal
8858 references. Move declarations closer to initializations.
8859 * cli/cli-cmds.c (list_command): Move sal declarations closer to
8860 initializations.
8861 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
8862 references. Move sal declarations closer to initializations.
8863 * frame.c (find_frame_sal): Return a symtab_and_line via function
8864 return instead of output parameter. Remove init_sal references.
8865 * frame.h (find_frame_sal): Return a symtab_and_line via function
8866 return instead of output parameter.
8867 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
8868 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
8869 instead of memset.
8870 (gdbscm_find_pc_line): Remove init_sal reference.
8871 * infcall.c (call_function_by_hand_dummy): Remove init_sal
8872 references. Move declarations closer to initializations.
8873 * infcmd.c (set_step_frame): Update. Move declarations closer to
8874 initializations.
8875 (finish_backward): Remove init_sal references. Move declarations
8876 closer to initializations.
8877 * infrun.c (process_event_stop_test, handle_step_into_function)
8878 (insert_hp_step_resume_breakpoint_at_frame)
8879 (insert_step_resume_breakpoint_at_caller): Likewise.
8880 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
8881 (symbol_to_sal): Likewise.
8882 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
8883 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
8884 to its initialization.
8885 * reverse.c (save_bookmark_command): Use new/delete. Remove
8886 init_sal references. Move declarations closer to initializations.
8887 * source.c (get_current_source_symtab_and_line): Remove brace
8888 initialization.
8889 (set_current_source_symtab_and_line): Now takes the sal by const
8890 reference. Remove brace initialization.
8891 (line_info): Remove init_sal reference.
8892 * source.h (set_current_source_symtab_and_line): Now takes a
8893 symtab_and_line via const reference.
8894 * stack.c (set_current_sal_from_frame): Adjust.
8895 (print_frame_info): Adjust.
8896 (get_last_displayed_sal): Return the sal via function return
8897 instead of via output parameter. Simplify.
8898 (frame_info): Adjust.
8899 * stack.h (get_last_displayed_sal): Return the sal via function
8900 return instead of via output parameter.
8901 * symtab.c (init_sal): Delete.
8902 (find_pc_sect_line): Remove init_sal references. Move
8903 declarations closer to initializations.
8904 (find_function_start_sal): Remove init_sal references. Move
8905 declarations closer to initializations.
8906 * symtab.h (struct symtab_and_line): In-class initialize all
8907 fields.
8908 * tracepoint.c (set_traceframe_context)
8909 (print_one_static_tracepoint_marker): Remove init_sal references.
8910 Move declarations closer to initializations.
8911 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
8912 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
8913 declarations closer to initializations.
8914 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
8915 init_sal references. Adjust.
8916
8917 2017-09-04 Pedro Alves <palves@redhat.com>
8918
8919 * ax-gdb.c (agent_command_1): Use range-for.
8920 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8921 * breakpoint.c: Include "common/array-view.h".
8922 (init_breakpoint_sal, create_breakpoint_sal): Change sals
8923 parameter from struct symtabs_and_lines to
8924 array_view<symtab_and_line>. Adjust. Use range-for. Update.
8925 (breakpoint_sals_to_pc): Change sals parameter from struct
8926 symtabs_and_lines to std::vector reference.
8927 (check_fast_tracepoint_sals): Change sals parameter from struct
8928 symtabs_and_lines to std::array_view. Use range-for.
8929 (decode_static_tracepoint_spec): Return a std::vector instead of
8930 symtabs_and_lines. Update.
8931 (create_breakpoint): Update.
8932 (break_range_command, until_break_command, clear_command): Update.
8933 (base_breakpoint_decode_location, bkpt_decode_location)
8934 (bkpt_probe_create_sals_from_location)
8935 (bkpt_probe_decode_location, tracepoint_decode_location)
8936 (tracepoint_probe_decode_location)
8937 (strace_marker_create_sals_from_location): Return a std::vector
8938 instead of symtabs_and_lines.
8939 (strace_marker_create_breakpoints_sal): Update.
8940 (strace_marker_decode_location): Return a std::vector instead of
8941 symtabs_and_lines. Update.
8942 (update_breakpoint_locations): Change struct symtabs_and_lines
8943 parameters to gdb::array_view. Adjust.
8944 (location_to_sals): Return a std::vector instead of
8945 symtabs_and_lines. Update.
8946 (breakpoint_re_set_default): Use std::vector instead of struct
8947 symtabs_and_lines.
8948 (decode_location_default): Return a std::vector instead of
8949 symtabs_and_lines. Update.
8950 * breakpoint.h: Include "common/array-view.h".
8951 (struct breakpoint_ops) <decode_location>: Now returns a
8952 std::vector instead of returning a symtabs_and_lines via output
8953 parameter.
8954 (update_breakpoint_locations): Change sals parameters to use
8955 gdb::array_view.
8956 * cli/cli-cmds.c (edit_command, list_command): Update to use
8957 std::vector and gdb::array_view.
8958 (ambiguous_line_spec): Adjust to use gdb::array_view and
8959 range-for.
8960 (compare_symtabs): Rename to ...
8961 (cmp_symtabs): ... this. Change parameters to symtab_and_line
8962 const reference and adjust.
8963 (filter_sals): Rewrite using std::vector and standard algorithms.
8964 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
8965 (jump_command): Update to use std::vector.
8966 * linespec.c (struct linespec_state) <canonical_names>: Update
8967 comment.
8968 (add_sal_to_sals_basic): Delete.
8969 (add_sal_to_sals, filter_results, convert_results_to_lsals)
8970 (decode_line_2, create_sals_line_offset)
8971 (convert_address_location_to_sals, convert_linespec_to_sals)
8972 (convert_explicit_location_to_sals, parse_linespec)
8973 (event_location_to_sals, decode_line_full, decode_line_1)
8974 (decode_line_with_current_source)
8975 (decode_line_with_last_displayed, decode_objc)
8976 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
8977 (linespec_result::~linespec_result): Adjust to use std::vector
8978 instead of symtabs_and_lines.
8979 * linespec.h (linespec_sals::sals): Now a std::vector.
8980 (struct linespec_result): Use std::vector, bool, and in-class
8981 initialization.
8982 (decode_line_1, decode_line_with_current_source)
8983 (decode_line_with_last_displayed): Return std::vector.
8984 * macrocmd.c (info_macros_command): Use std::vector.
8985 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
8986 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
8987 std::vector.
8988 * probe.h (parse_probes): Return a std::vector.
8989 * python/python.c (gdbpy_decode_line): Use std::vector and
8990 gdb::array_view.
8991 * source.c (select_source_symtab, line_info): Use std::vector.
8992 * stack.c (func_command): Use std::vector.
8993 * symtab.h (struct symtabs_and_lines): Delete.
8994 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
8995
8996 2017-09-04 Pedro Alves <palves@redhat.com>
8997
8998 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8999 unittests/array-view-selftests.c.
9000 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
9001 * common/array-view.h: New file.
9002 * unittests/array-view-selftests.c: New file.
9003
9004 2017-09-04 Pedro Alves <palves@redhat.com>
9005
9006 * cli/cli-cmds.c (edit_command): Pass message to
9007 ambiguous_line_spec.
9008 (list_command): Pass message to ambiguous_line_spec. Say
9009 "first"/"last" instead of "start" and "end" to be consistent with
9010 the manual.
9011 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
9012 them to print formatted message.
9013
9014 2017-09-04 Pedro Alves <palves@redhat.com>
9015
9016 * btrace.c (ftrace_add_pt): Pass btrace_insn to
9017 ftrace_update_insns by reference instead of pointer.
9018
9019 2017-09-04 Yao Qi <yao.qi@linaro.org>
9020
9021 * i386-go32-tdep.c: Include x86-xstate.h.
9022 (i386_go32_init_abi): Call i386_target_description.
9023 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
9024 if xcr0 is X86_XSTATE_X87_MASK.
9025 * i386-tdep.h (tdesc_i386): Remove the declaration.
9026 (tdesc_i386_mmx): Likewise.
9027
9028 2017-09-04 Yao Qi <yao.qi@linaro.org>
9029
9030 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
9031 X86_XSTATE_SSE_MASK instead of 0.
9032
9033 2017-09-04 Yao Qi <yao.qi@linaro.org>
9034
9035 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
9036 i386_target_description.
9037 * i386-fbsd-nat.c (i386fbsd_read_description): Call
9038 i386_target_description.
9039 * i386-tdep.c (i386_gdbarch_init): Likewise.
9040
9041 2017-09-04 Yao Qi <yao.qi@linaro.org>
9042
9043 * amd64-darwin-tdep.c: Include "x86-xstate.h".
9044 (x86_darwin_init_abi_64): Call amd64_target_description.
9045 * amd64-dicos-tdep.c: Likewise.
9046 * amd64-fbsd-nat.c: Likewise.
9047 * amd64-fbsd-tdep.c: Likewise.
9048 * amd64-nbsd-tdep.c: Likewise.
9049 * amd64-obsd-tdep.c: Likewise.
9050 * amd64-sol2-tdep.c: Likewise.
9051 * amd64-windows-tdep.c: Likewise.
9052 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
9053
9054 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
9055
9056 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
9057 (btrace_function) <insn>: Change type to use std::vector.
9058 * btrace.c (ftrace_debug, ftrace_call_num_insn,
9059 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
9060 ftrace_update_insns, ftrace_compute_global_level_offset,
9061 btrace_stitch_bts, btrace_clear, btrace_insn_get,
9062 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
9063 change to std::vector.
9064 (ftrace_update_insns): Adjust to change to std::vector, change
9065 type of INSN parameter.
9066 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
9067 * record-btrace.c (btrace_call_history_insn_range,
9068 btrace_compute_src_line_range,
9069 record_btrace_frame_prev_register): Adjust to change to
9070 std::vector.
9071 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
9072 to change to std::vector.
9073
9074 2017-09-03 Tom Tromey <tom@tromey.com>
9075
9076 * corefile.c (reopen_exec_file): Use std::string.
9077
9078 2017-09-03 Tom Tromey <tom@tromey.com>
9079
9080 * compile/compile.c (compile_register_name_mangled): Return
9081 std::string.
9082 * compile/compile-loc2c.c (pushf_register_address): Update.
9083 (pushf_register): Update.
9084 * compile/compile-c-types.c (convert_array): Update.
9085 * compile/compile-c-symbols.c (generate_vla_size): Update.
9086 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
9087 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
9088 (convert_one_symbol): Update.
9089 (generate_c_for_for_one_variable): Update.
9090 * compile/compile-c-support.c (c_get_range_decl_name): Return a
9091 std::string.
9092 (generate_register_struct): Update.
9093 * compile/compile-internal.h (c_get_range_decl_name): Return a
9094 std::string.
9095 (compile_register_name_mangled): Return std::string.
9096
9097 2017-09-03 Tom Tromey <tom@tromey.com>
9098
9099 * utils.c (perror_string): Return a std::string.
9100 (throw_perror_with_name, perror_warning_with_name): Update.
9101
9102 2017-09-03 Tom Tromey <tom@tromey.com>
9103
9104 * demangle.c (demangle_command): Use std::string,
9105 unique_xmalloc_ptr.
9106
9107 2017-09-03 Tom Tromey <tom@tromey.com>
9108
9109 * cli/cli-setshow.c (do_set_command): Use std::string.
9110
9111 2017-09-03 Tom Tromey <tom@tromey.com>
9112
9113 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
9114
9115 2017-09-03 Tom Tromey <tom@tromey.com>
9116
9117 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
9118
9119 2017-09-03 Tom Tromey <tom@tromey.com>
9120
9121 * mi/mi-cmd-env.c (env_execute_cli_command): Use
9122 gdb::unique_xmalloc_ptr.
9123
9124 2017-09-03 Tom Tromey <tom@tromey.com>
9125
9126 * thread.c (print_thread_info_1): Use string_printf.
9127 (thread_apply_command, thread_apply_all_command): Use
9128 std::string.
9129
9130 2017-09-03 Tom Tromey <tom@tromey.com>
9131
9132 * valprint.c (val_print_string): Update.
9133 * gdbcore.h (memory_error_message): Return std::string.
9134 * corefile.c (memory_error_message): Return std::string.
9135 (memory_error): Update.
9136 * breakpoint.c (insert_bp_location): Update.
9137
9138 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
9139
9140 * target/waitstatus.h (target_waitstatus_to_string): Change
9141 return type to std::string.
9142 * target/waitstatus.c (target_waitstatus_to_string): Return
9143 std::string.
9144 * target.h (target_waitstatus_to_string): Remove declaration.
9145 * infrun.c (resume, clear_proceed_status_thread,
9146 print_target_wait_results, do_target_wait, save_waitstatus,
9147 stop_all_threads): Adjust.
9148 * record-btrace.c (record_btrace_wait): Adjust.
9149 * target-debug.h
9150 (target_debug_print_struct_target_waitstatus_p): Adjust.
9151
9152 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
9153
9154 PR gdb/22046
9155 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
9156 detection.
9157
9158 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
9159
9160 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
9161 for setting/unsetting environment variables on the remote target.
9162 (New remote packets): Add entries for QEnvironmentHexEncoded,
9163 QEnvironmentUnset and QEnvironmentReset.
9164 * common/environ.c (gdb_environ::operator=): Extend method to
9165 handle m_user_set_env_list and m_user_unset_env_list.
9166 (gdb_environ::clear): Likewise.
9167 (match_var_in_string): Change type of first parameter from 'char
9168 *' to 'const char *'.
9169 (gdb_environ::set): Extend method to handle
9170 m_user_set_env_list and m_user_unset_env_list.
9171 (gdb_environ::unset): Likewise.
9172 (gdb_environ::clear_user_set_env): New method.
9173 (gdb_environ::user_set_envp): Likewise.
9174 (gdb_environ::user_unset_envp): Likewise.
9175 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
9176 m_user_unset_env_list on move constructor/assignment.
9177 (unset): Add new default parameter 'update_unset_list = true'.
9178 (clear_user_set_env): New method.
9179 (user_set_envp): Likewise.
9180 (user_unset_envp): Likewise.
9181 (m_user_set_env_list): New std::set.
9182 (m_user_unset_env_list): Likewise.
9183 * common/rsp-low.c (hex2str): New function.
9184 (bin2hex): New overload for bin2hex function.
9185 * common/rsp-low.c (hex2str): New prototype.
9186 (str2hex): New overload prototype.
9187 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
9188 QEnvironmentUnset and QEnvironmentReset.
9189 (remote_protocol_features): Add QEnvironmentHexEncoded,
9190 QEnvironmentUnset and QEnvironmentReset packets.
9191 (send_environment_packet): New function.
9192 (extended_remote_environment_support): Likewise.
9193 (extended_remote_create_inferior): Call
9194 extended_remote_environment_support.
9195 (_initialize_remote): Add QEnvironmentHexEncoded,
9196 QEnvironmentUnset and QEnvironmentReset packet configs.
9197 * unittests/environ-selftests.c (gdb_selftest_env_var):
9198 New variable.
9199 (test_vector_initialization): New function.
9200 (test_init_from_host_environ): Likewise.
9201 (test_reinit_from_host_environ): Likewise.
9202 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
9203 Likewise.
9204 (test_unset_set_empty_vector): Likewise.
9205 (test_vector_clear): Likewise.
9206 (test_std_move): Likewise.
9207 (test_move_constructor):
9208 (test_self_move): Likewise.
9209 (test_set_unset_reset): Likewise.
9210 (run_tests): Rewrite in terms of the functions above.
9211
9212 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
9213
9214 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
9215 (adi_available): Use a temp variable of type CORE_ADDR as argument
9216 3 when calling target_auxv_search.
9217 (adi_normalize_address): Use masks and xor operators to calculate
9218 normalized address.
9219 (adi_read_versions, adi_write_versions, adi_print_versions)
9220 (do_examine, do_assign): Use paddress.
9221
9222 2017-08-29 John Baldwin <jhb@FreeBSD.org>
9223
9224 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
9225 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
9226 out of loop and add supply of FIR.
9227 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
9228 add collect of FIR.
9229
9230 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
9231
9232 PR gdb/21827
9233 * cli/cli-script.c (define_command): Don't convert command name
9234 to lower case.
9235
9236 2017-08-25 Joel Brobecker <brobecker@adacore.com>
9237
9238 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
9239 Update all callers accordingly. Remove all code blocks handling
9240 the case where DISPP is not NULL.
9241
9242 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9243
9244 PR symtab/22003
9245 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
9246 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9247 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
9248
9249 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9250
9251 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
9252 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
9253 (read_comp_units_from_section): New parameter abbrev_section, use
9254 read_and_check_comp_unit_head, allocate signatured_type if needed.
9255 (create_all_comp_units): Update read_comp_units_from_section caller.
9256
9257 2017-08-23 Pedro Alves <palves@redhat.com>
9258
9259 PR remote/21852
9260 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
9261 to null_ptid and switch to thread without reading the registers
9262 after adding the inferior.
9263
9264 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9265
9266 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
9267 compile-gcc.
9268 * compile/compile.c (compile_gcc, show_compile_gcc): New.
9269 (compile_to_object): Implement compile_gcc.
9270 (_initialize_compile): Install "set compile-gcc". Initialize
9271 compile_gcc.
9272
9273 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9274
9275 * compile/compile.c (compile_to_object): Conditionally call
9276 set_verbose. Conditionally call compile or compile_v0.
9277
9278 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
9279
9280 * sparc64-tdep.h: (adi_normalize_address): New export.
9281 * sparc-nat.h: (open_adi_tag_fd): New export.
9282 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
9283 * sparc64-linux-tdep.c:
9284 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
9285 (sparc64_linux_handle_segmentation_fault): New function.
9286 (sparc64_linux_init_abi): Register
9287 sparc64_linux_handle_segmentation_fault
9288 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
9289 (sparc64_addr_bits_remove): New function.
9290 (sparc64_init_abi): Register sparc64_addr_bits_remove.
9291 (MAX_PROC_NAME_SIZE): New macro.
9292 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
9293 (sparc64adilist): New variable.
9294 (adi_proc_list): New variable.
9295 (find_adi_info): New function.
9296 (add_adi_info): New function.
9297 (get_adi_info_proc): New function.
9298 (get_adi_info): New function.
9299 (info_adi_command): New function.
9300 (read_maps_entry): New function.
9301 (adi_available): New function.
9302 (adi_normalize_address): New function.
9303 (adi_align_address): New function.
9304 (adi_convert_byte_count): New function.
9305 (adi_tag_fd): New function.
9306 (adi_is_addr_mapped): New function.
9307 (adi_read_versions): New function.
9308 (adi_write_versions): New function.
9309 (adi_print_versions): New function.
9310 (do_examine): New function.
9311 (do_assign): New function.
9312 (adi_examine_command): New function.
9313 (adi_assign_command): New function.
9314 (_initialize_sparc64_adi_tdep): New function.
9315
9316 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
9317
9318 * breakpoint.c (breakpoints_info): Rename to ...
9319 (info_breakpoints_command): ... this.
9320 (watchpoints_info): Rename to ...
9321 (info_watchpoints_command): ... this.
9322 (tracepoints_info): Rename to ...
9323 (info_tracepoints_command): ... this.
9324 (_initialize_breakpoint): Adjust.
9325 * dcache.c (dcache_info): Rename to ...
9326 (info_display_command): ... this.
9327 (_initialize_dcache): Adjust.
9328 * frame.h (args_info): Rename to ...
9329 (info_args_command): ... this.
9330 (locals_info): Rename to ...
9331 (info_locals_command): ... this.
9332 * infcmd.c (nofp_registers_info): Rename to ...
9333 (info_registers_command): ... this.
9334 (float_info): Rename to ...
9335 (info_float_command): ... this.
9336 (program_info): Rename to ...
9337 (info_program_command): ... this.
9338 (all_registers_info): Rename to ...
9339 (info_all_registers_command): ... this.
9340 (vector_info): Rename to ...
9341 (info_vector_command): ... this.
9342 (float_info): Rename to ...
9343 (info_float_command): ... this.
9344 (_initialize_infcmd): Adjust.
9345 * inferior.h (term_info): Rename to ...
9346 (info_terminal_command): ... this.
9347 * inflow.c (term_info): Rename to ...
9348 (info_terminal_command): ... this.
9349 (_initialize_inflow): Adjust.
9350 * infrun.c (signals_info): Rename to ...
9351 (info_signals_command): ... this.
9352 (_initialize_infrun): Adjust.
9353 * objc-lang.c (classes_info): Rename to ...
9354 (info_classes_command): ... this.
9355 (selectors_info): Rename to ...
9356 (info_selectors_command): ... this.
9357 (_initialize_objc_language): Adjust.
9358 * printcmd.c (sym_info): Rename to ...
9359 (info_symbol_command): ... this.
9360 (address_info): Rename to ...
9361 (info_address_command): ... this.
9362 (display_info): Rename to ...
9363 (info_display_command): ... this.
9364 (_initialize_printcmd): Adjust.
9365 * reverse.c (bookmarks_info): Rename to ...
9366 (info_breakpoints_command): ... this.
9367 (_initialize_reverse): Adjust.
9368 * ser-go32.c (dos_info): Rename to ...
9369 (info_serial_command): ... this.
9370 (_initialize_ser_dos): Adjust.
9371 * skip.c (skip_info): Rename to ...
9372 (info_skip_command): ... this.
9373 (_initialize_step_skip): Adjust.
9374 * source.c (line_info): Rename to ...
9375 (info_line_command): ... this.
9376 (source_info): Rename to ...
9377 (info_source_command)
9378 * stack.c (frame_info): Rename to ...
9379 (info_frame_command): ... this.
9380 (locals_info): Rename to ...
9381 (info_locals_command): ... this.
9382 (args_info): Rename to ...
9383 (info_args_command): ... this.
9384 (_initialize_stack): Adjust.
9385 * symtab.c (sources_info): Rename to ...
9386 (info_sources_command): ... this.
9387 (variables_info): Rename to ...
9388 (info_variables_command): ... this.
9389 (functions_info): Rename to ...
9390 (info_functions_command): ... this.
9391 (types_info): Rename to ...
9392 (info_types_command): ... this.
9393 (_initialize_symtab): Adjust.
9394 * target.c (target_info): Rename to ...
9395 (info_target_command): ... this.
9396 (initialize_targets): Adjust.
9397 * tracepoint.c (tvariables_info): Rename to ...
9398 (info_tvariables_command): ... this.
9399 (scope_info): Rename to ...
9400 (info_scope_command): ... this.
9401 (trace_dump_actions): Adjust.
9402 (_initialize_tracepoint): Adjust.
9403
9404 2017-08-22 Tom Tromey <tom@tromey.com>
9405
9406 * breakpoint.h (install_breakpoint): Update.
9407 * breakpoint.c (add_solib_catchpoint): Update.
9408 (install_breakpoint): Change argument to a std::unique_ptr.
9409 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
9410 (create_breakpoint_sal, create_breakpoint): Update.
9411 (watch_command_1, catch_exec_command_1)
9412 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
9413 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
9414 Return the breakpoint.
9415 (set_raw_breakpoint_without_location, set_raw_breakpoint)
9416 (new_single_step_breakpoint): Update.
9417 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
9418 std::unique_ptr.
9419 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9420 std::unique_ptr.
9421 * break-catch-sig.c (create_signal_catchpoint): Use
9422 std::unique_ptr.
9423 * ada-lang.c (create_ada_exception_catchpoint): Use
9424 std::unique_ptr.
9425
9426 2017-08-22 Tom Tromey <tom@tromey.com>
9427
9428 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
9429
9430 2017-08-22 Tom Tromey <tom@tromey.com>
9431
9432 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9433 (lookup_partial_symbol): Update.
9434
9435 2017-08-22 Tom Tromey <tom@tromey.com>
9436
9437 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9438 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9439 (find_and_open_source, symtab_to_fullname): Update.
9440 * psymtab.c (psymtab_to_fullname): Update.
9441
9442 2017-08-22 Tom Tromey <tom@tromey.com>
9443
9444 * exec.c (exec_file_attach): Update.
9445 * linux-thread-db.c (try_thread_db_load): Update.
9446 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9447 * utils.c (gdb_realpath): Change return type.
9448 (gdb_realpath_keepfile): Update.
9449 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9450 (_initialize_utils): Register the new self test.
9451 * source.c (openp): Update.
9452 (find_and_open_source): Update.
9453 * nto-tdep.c (nto_find_and_open_solib): Update.
9454 * main.c (set_gdb_data_directory): Update.
9455 (captured_main_1): Update.
9456 * dwarf2read.c (dwarf2_get_dwz_file): Update
9457 (dw2_map_symbol_filenames): Update.
9458 * auto-load.c (auto_load_safe_path_vec_update): Update.
9459 (filename_is_in_auto_load_safe_path_vec): Change type of
9460 "filename_realp".
9461 (auto_load_objfile_script): Update.
9462 (file_is_auto_load_safe): Update. Use std::string.
9463 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9464
9465 2017-08-22 Tom Tromey <tom@tromey.com>
9466
9467 * utils.c (gdb_realpath_keepfile): Return a
9468 gdb::unique_xmalloc_ptr.
9469 * exec.c (exec_file_attach): Update.
9470 * utils.h (gdb_realpath_keepfile): Return a
9471 gdb::unique_xmalloc_ptr.
9472
9473 2017-08-22 Tom Tromey <tom@tromey.com>
9474
9475 * compile/compile.c (compile_file_command): Use
9476 gdb::unique_xmalloc_ptr, std::string.
9477 * utils.c (gdb_abspath): Change return type.
9478 * source.c (openp): Update.
9479 * objfiles.c (allocate_objfile): Update.
9480 * main.c (set_gdb_data_directory): Update.
9481 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9482
9483 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9484
9485 * cli-cmds.c (list_commands): List actual code around more than
9486 one location.
9487
9488 2017-08-21 John Baldwin <jhb@FreeBSD.org>
9489
9490 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9491
9492 2017-08-21 Pedro Alves <palves@redhat.com>
9493
9494 PR gdb/19487
9495 * c-exp.y (variable production): Handle function aliases.
9496 * minsyms.c (msymbol_is_text): New function.
9497 * minsyms.h (msymbol_is_text): Declare.
9498 * symtab.c (find_function_alias_target): New function.
9499 * symtab.h (find_function_alias_target): Declare.
9500
9501 2017-08-21 Pedro Alves <palves@redhat.com>
9502
9503 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9504 typedefs.
9505 * typeprint.c (whatis_exp): If handling "whatis", and expression
9506 is OP_TYPE, strip one typedef level. Otherwise don't strip
9507 typedefs here.
9508 * valops.c (value_cast): Save "to" type before resolving
9509 stubs/typedefs. Use that type as resulting value's type.
9510
9511 2017-08-18 Tom Tromey <tom@tromey.com>
9512 Pedro Alves <palves@redhat.com>
9513
9514 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9515 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9516 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9517 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9518 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9519 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9520 (linux_get_siginfo_data): Add "thread" argument. Use
9521 scoped_restore.
9522 * linux-nat.c (linux_child_follow_fork)
9523 (check_stopped_by_watchpoint): Use scoped_restore.
9524 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9525 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9526 (restore_inferior_ptid, save_inferior_ptid): Remove.
9527 * btrace.c (btrace_fetch): Use scoped_restore.
9528 * bsd-uthread.c (bsd_uthread_fetch_registers)
9529 (bsd_uthread_store_registers): Use scoped_restore.
9530 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9531 scoped_restore.
9532 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9533 (aix_thread_xfer_partial): Use scoped_restore.
9534 * inferior.h (save_inferior_ptid): Remove.
9535
9536 2017-08-18 Yao Qi <yao.qi@linaro.org>
9537
9538 PR tdep/21818
9539 * arm-tdep.c (gdb_print_insn_arm): Mark
9540 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9541
9542 2017-08-18 Yao Qi <yao.qi@linaro.org>
9543
9544 * NEWS: Mention GDBserver's new option "--selftest".
9545 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9546 * selftest.c: Move it to common/selftest.c.
9547 * selftest.h: Move it to common/selftest.h.
9548 * selftest-arch.c (reset): New function.
9549 (tests_with_arch): Call reset.
9550
9551 2017-08-18 Yao Qi <yao.qi@linaro.org>
9552
9553 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9554 instead of exception_fprintf and printf_filtered.
9555
9556 2017-08-18 Yao Qi <yao.qi@linaro.org>
9557
9558 * selftest.c (register_self_test): Rename it to
9559 selftests::register_test.
9560 (run_self_tests): selftest::run_tests.
9561 * selftest.h: Update declarations.
9562 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9563 selftests::register_test_foreach_arch.
9564 * selftest-arch.h: Update declaration.
9565 * aarch64-tdep.c: Update.
9566 * arm-tdep.c: Likewise.
9567 * disasm-selftests.c: Likewise.
9568 * dwarf2loc.c: Likewise.
9569 * dwarf2-frame.c: Likewise.
9570 * findvar.c: Likewise.
9571 * gdbarch-selftests.c: Likewise.
9572 * maint.c (maintenance_selftest): Likewise.
9573 * regcache.c: Likewise.
9574 * rust-exp.y: Likewise.
9575 * selftest-arch.c: Likewise.
9576 * unittests/environ-selftests.c: Likewise.
9577 * unittests/function-view-selftests.c: Likewise.
9578 * unittests/offset-type-selftests.c: Likewise.
9579 * unittests/optional-selftests.c: Likewise.
9580 * unittests/scoped_restore-selftests.c: Likewise.
9581 * utils-selftests.c: Likewise.
9582
9583 2017-08-17 Pedro Alves <palves@redhat.com>
9584
9585 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9586 local.
9587
9588 2017-08-17 Pedro Alves <palves@redhat.com>
9589
9590 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9591 field.
9592 (reset_die_in_process): Delete, replaced by ...
9593 (process_die_scope): ... this new class. Make it responsible for
9594 freeing cu->line_header too.
9595 (process_die): Use process_die_scope.
9596 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9597 cu->line_header_die_owner. Don't release the line header if it's
9598 owned by the CU.
9599 (setup_type_unit_groups): Make the CU/DIE own the line header.
9600 Don't release the line header here.
9601
9602 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9603
9604 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9605
9606 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9607
9608 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9609 Single-Key mode
9610
9611 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9612
9613 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9614 mode command list.
9615
9616 2017-08-15 Stafford Horne <shorne@gmail.com>
9617
9618 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9619
9620 2017-08-15 Stafford Horne <shorne@gmail.com>
9621
9622 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9623
9624 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9625
9626 PR gdb/21954
9627 * infcmd.c (unset_environment_command): Use the 'clear' method on
9628 the environment instead of resetting it.
9629
9630 2017-08-15 John Baldwin <jhb@FreeBSD.org>
9631
9632 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9633 platforms.
9634
9635 2017-08-14 Tom Tromey <tom@tromey.com>
9636
9637 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9638 (print_binary_chars): Likewise.
9639 (BITS_IN_BYTES): Remove.
9640
9641 2017-08-14 Tom Tromey <tom@tromey.com>
9642
9643 PR gdb/21675
9644 * valprint.c (LOW_ZERO): Change value to 034.
9645 (print_octal_chars): Add static_asserts for octal constants.
9646 * printcmd.c (print_scalar_formatted): Add 'd' case.
9647
9648 2017-08-11 Tom Tromey <tom@tromey.com>
9649
9650 * symfile.c (add_symbol_file_command): Use std::vector.
9651
9652 2017-08-14 Tom Tromey <tom@tromey.com>
9653
9654 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9655 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9656 std::move.
9657 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9658
9659 2017-08-11 Pedro Alves <palves@redhat.com>
9660
9661 * infrun.c (process_event_stop_test): Adjust
9662 function_name_is_marked_for_skip call.
9663 * skip.c: Include <list>.
9664 (skiplist_entry): Make it a class with private fields, and
9665 getters/setters.
9666 (skiplist_entry_chain): Delete.
9667 (skiplist_entries): New.
9668 (skiplist_entry_count): Delete.
9669 (highest_skiplist_entry_num): New.
9670 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9671 (add_skiplist_entry): Delete.
9672 (skiplist_entry::skiplist_entry): New.
9673 (skiplist_entry::add_entry): New.
9674 (skip_file_command, skip_function): Adjust.
9675 (compile_skip_regexp): Delete.
9676 (skip_command): Don't compile regexp here. Adjust to use
9677 skiplist_entry::add_entry.
9678 (skip_info): Adjust to use range-for and getters.
9679 (skip_enable_command, skip_disable_command): Adjust to use
9680 range-for and setters.
9681 (skip_delete_command): Adjust to use std::list.
9682 (add_skiplist_entry): Delete.
9683 (skip_file_p): Delete, refactored as ...
9684 (skiplist_entry::do_skip_file_p): ... this new method.
9685 (skip_gfile_p): Delete, refactored as ...
9686 (skiplist_entry::do_gskip_file_p): ... this new method.
9687 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9688 (skiplist_entry::skip_function_p): ... this new method.
9689 (function_name_is_marked_for_skip): Now returns bool, and takes
9690 the function sal by const reference. Adjust to use range-for and
9691 skiplist_entry methods.
9692 (_initialize_step_skip): Remove references to
9693 skiplist_entry_chain, skiplist_entry_count.
9694 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9695 takes the function sal by const reference.
9696
9697 2017-08-11 Yao Qi <yao.qi@linaro.org>
9698
9699 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9700 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9701 (dwarf2_frame_cache):
9702 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9703 RETURN_MASK_ALL and set *this_case to NULL.
9704 * frame-unwind.h: Update comments.
9705
9706 2017-08-11 Yao Qi <yao.qi@linaro.org>
9707
9708 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9709 (dwarf2_frame_state_copy_regs): Remove.
9710 (dwarf2_frame_state_free_regs): Remove.
9711 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9712 (dwarf2_restore_rule): Call method .alloc_regs instead of
9713 dwarf2_frame_state_alloc_regs.
9714 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9715 constructor. Call std::move.
9716 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9717 (dwarf2_frame_cache): Likewise.
9718
9719 [GDB_SELF_TEST]: Include selftest.h and
9720 selftest-arch.h.
9721 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9722 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9723 execute_cfa_program_test.
9724
9725 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9726 copy ctor, assignment operator, move assignment.
9727 <alloc_regs>: New method.
9728 <swap>: New method.
9729 (struct dwarf2_frame_state): Delete dtor.
9730 (dwarf2_frame_state_alloc_regs): Remove declaration.
9731 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9732 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9733
9734 2017-08-11 Yao Qi <yao.qi@linaro.org>
9735
9736 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9737 (dwarf2_frame_state::dwarf2_frame_state): New.
9738 (dwarf2_frame_state::~dwarf2_frame_state): New.
9739 (dwarf2_fetch_cfa_info): Update.
9740 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9741 rather than a pointer. Update code.
9742 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9743 dtor.
9744 <data_align, code_align, retaddr_column>: Change them to const.
9745 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9746 to bool.
9747
9748 2017-08-11 Yao Qi <yao.qi@linaro.org>
9749
9750 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9751 <loc.exp>: New field.
9752 * dwarf2-frame.c (execute_cfa_program): Update.
9753 (dwarf2_frame_prev_register): Update.
9754
9755 2017-08-10 Pedro Alves <palves@redhat.com>
9756
9757 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9758
9759 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9760
9761 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9762 (fbsd_pending_children): Use std::list.
9763 (fbsd_remember_child): Likewise.
9764 (fbsd_is_child_pending): Likewise.
9765 (fbsd_pending_vfork_done): Use std::forward_list.
9766 (fbsd_add_vfork_done): Likewise.
9767 (fbsd_is_vfork_done_pending): Likewise.
9768 (fbsd_next_vfork_done): Likewise.
9769
9770 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9771
9772 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9773 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9774 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9775 for `mapfilename'.
9776 (fbsd_xfer_partial): Use gdb::byte_vector.
9777 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
9778
9779 2017-08-09 John Baldwin <jhb@FreeBSD.org>
9780
9781 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
9782 "filestuff.h".
9783 (fbsd_find_memory_regions): Fix `mapfile' initialization.
9784
9785 2017-08-09 Tom Tromey <tom@tromey.com>
9786
9787 * skip.c (skiplist_entry): New constructor.
9788 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
9789 (skiplist_entry::file_is_glob): Now bool.
9790 (skiplist_entry::file, skiplist_entry::function): Now
9791 std::string.
9792 (make_skip_entry): Return a unique_ptr. Use new.
9793 (free_skiplist_entry, free_skiplist_entry_cleanup)
9794 (make_free_skiplist_entry_cleanup): Remove.
9795 (skip_command, skip_disable_command, add_skiplist_entry)
9796 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
9797 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
9798 (function_name_is_marked_for_skip): Update.
9799 (skip_delete_command): Update. Use delete.
9800
9801 2017-08-09 Jiong Wang <jiong.wang@arm.com>
9802
9803 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
9804 (aarch64_linux_core_read_description): New function.
9805 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
9806
9807 2017-08-09 Pedro Alves <palves@redhat.com>
9808
9809 * cp-name-parser.y (cp_comp_to_string): Return a
9810 gdb::unique_xmalloc_ptr<char>.
9811 * cp-support.c (replace_typedefs_qualified_name)
9812 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
9813 (cp_canonicalize_string_full): Use op= instead of explicit
9814 convertion.
9815 (cp_class_name_from_physname, method_name_from_physname)
9816 (cp_func_name, cp_remove_params): Adjust to use
9817 gdb::unique_xmalloc_ptr<char>.
9818 * cp-support.h (cp_comp_to_string): Return a
9819 gdb::unique_xmalloc_ptr<char>.
9820 * python/py-type.c (typy_lookup_type): Adjust to use
9821 gdb::unique_xmalloc_ptr<char>.
9822
9823 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
9824
9825 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
9826
9827 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
9828 Yao Qi <yao.qi@linaro.org>
9829
9830 * cp-support.c (cp_canonicalize_string_full): Use
9831 gdb::unique_xmalloc_ptr<char>.
9832 (cp_canonicalize_string): Likewise.
9833
9834 2017-08-09 Yao Qi <yao.qi@linaro.org>
9835
9836 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
9837 * regformats/i386/amd64-avx-avx512.dat: Remove.
9838 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
9839 * regformats/i386/amd64-avx-mpx.dat:Remove.
9840 * regformats/i386/amd64-avx.dat: Remove.
9841 * regformats/i386/amd64-mpx.dat: Remove.
9842 * regformats/i386/i386-avx-avx512.dat: Remove.
9843 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
9844 * regformats/i386/i386-avx-mpx.dat: Remove.
9845 * regformats/i386/i386-mmx.dat: Remove.
9846 * regformats/i386/i386-mpx.dat: Remove.
9847
9848 2017-08-09 Yao Qi <yao.qi@linaro.org>
9849
9850 * amd64-tdep.h (tdesc_x32): Remove the declaration.
9851 * amd64-tdep.c: Don't include features/i386/x32*.c.
9852 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
9853 functions.
9854 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
9855 and i386/x32-avx-avx512.
9856 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
9857 and i386/x32.xml.
9858 * features/i386/x32-avx-avx512.c: Removed.
9859 * features/i386/x32-avx-avx512.xml: Removed.
9860 * features/i386/x32-avx.c: Removed.
9861 * features/i386/x32-avx.xml: Removed.
9862 * features/i386/x32.c: Removed.
9863 * features/i386/x32.xml: Removed.
9864 * regformats/i386/x32-avx-avx512.dat: Removed.
9865 * regformats/i386/x32-avx.dat: Removed.
9866 * regformats/i386/x32.dat: Removed.
9867
9868 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9869
9870 PR breakpoints/21886
9871 * mem-break.c (default_memory_insert_breakpoint): Use
9872 `->placed_address' rather than `->reqstd_address' for the
9873 breakpoint location.
9874
9875 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9876
9877 * arch-utils.c (default_print_insn): Remove arch/mach/endian
9878 assertions.
9879
9880 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9881
9882 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
9883 a union of `tdep_info', `tdesc_data' and `id'.
9884 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
9885 rather than `info.tdep_info'.
9886 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
9887 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9888 * i386-tdep.c (i386_gdbarch_init): Likewise.
9889 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
9890 * mips-tdep.c (mips_gdbarch_init): Likewise.
9891 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9892 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9893 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
9894 `info.tdep_info'.
9895 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
9896 `info.tdep_info'.
9897 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9898 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
9899 `info.tdep_info'.
9900 * spu-tdep.c (spu_gdbarch_init): Likewise.
9901 * gdbarch.h: Regenerate.
9902
9903 2017-08-07 Leszek Swirski <leszeks@google.com>
9904
9905 PR symtab/20899
9906 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
9907
9908 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
9909
9910 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
9911 (gdbsim_open): Rename gdb_argv args object to argv.
9912
9913 2017-08-05 Tom Tromey <tom@tromey.com>
9914
9915 * compile/compile-object-load.c (compile_object_load): Use
9916 gdb::unique_xmalloc_ptr.
9917 * cli/cli-dump.c (scan_filename): Rename from
9918 scan_filename_with_cleanup. Change return type.
9919 (scan_expression): Rename from scan_expression_with_cleanup.
9920 Change return type.
9921 (dump_memory_to_file, dump_value_to_file, restore_command):
9922 Use gdb::unique_xmalloc_ptr. Update.
9923 * cli/cli-cmds.c (find_and_open_script): Use
9924 gdb::unique_xmalloc_ptr.
9925 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
9926 * symmisc.c (maintenance_print_symbols)
9927 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
9928 * symfile.c (symfile_bfd_open, generic_load)
9929 (add_symbol_file_command, remove_symbol_file_command): Use
9930 gdb::unique_xmalloc_ptr.
9931 * source.c (openp): Use gdb::unique_xmalloc_ptr.
9932 * psymtab.c (maintenance_print_psymbols): Use
9933 gdb::unique_xmalloc_ptr.
9934 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
9935 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
9936 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
9937 (reload_shared_libraries_1): Likewise.
9938
9939 2017-08-05 Tom Tromey <tom@tromey.com>
9940
9941 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
9942 (rust_op_vector, rust_set_vector): New typedefs.
9943 (current_parser): New global.
9944 (work_obstack): Change to pointer type. Update all users.
9945 (rust_ast, pstate): Remove globals.
9946 (struct rust_parser): New.
9947 (%union) <params, field_inits>: Change type.
9948 (start, tuple_expr, unit_expr, struct_expr_list, literal)
9949 (field_expr, expr_list, maybe_expr_list, type_list): Update.
9950 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
9951 (convert_params_to_types, convert_params_to_expression): Change
9952 type of "params".
9953 (ast_string): Change type of "fields".
9954 (rust_parse): Make a rust_parser. Remove cleanups.
9955 (rust_lex_tests): Make and install an auto_obstack.
9956
9957 2017-08-04 Yao Qi <yao.qi@linaro.org>
9958
9959 * configure.srv (ipa_x32_linux_regobj): New.
9960 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
9961 instead of X86_TDESC_AVX512.
9962 (initialize_low_tracepoint): Call
9963 init_registers_x32_avx_avx512_linux.
9964
9965 2017-08-04 Yao Qi <yao.qi@linaro.org>
9966
9967 * utils.h (gdb_argv): Add namespace std for nullptr_t.
9968
9969 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
9970
9971 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
9972
9973 2017-08-03 Tom Tromey <tom@tromey.com>
9974
9975 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
9976 Remove.
9977 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
9978
9979 2017-08-03 Tom Tromey <tom@tromey.com>
9980
9981 * python/py-param.c (compute_enum_values): Use gdb_argv.
9982
9983 2017-08-03 Tom Tromey <tom@tromey.com>
9984
9985 * utils.h (struct gdb_argv_deleter): New.
9986 (gdb_argv): New class.
9987 * utils.c (gdb_argv::reset): New method.
9988 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
9989 * tracefile.c (tsave_command): Use gdb_argv.
9990 * top.c (new_ui_command): Use gdb_argv.
9991 * symmisc.c (maintenance_print_symbols)
9992 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
9993 * symfile.c (symbol_file_command, generic_load)
9994 (remove_symbol_file_command): Use gdb_argv.
9995 * stack.c (backtrace_command): Use gdb_argv.
9996 * source.c (add_path, show_substitute_path_command)
9997 (unset_substitute_path_command, set_substitute_path_command):
9998 Use gdb_argv.
9999 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
10000 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
10001 * remote.c (extended_remote_run, remote_put_command)
10002 (remote_get_command, remote_delete_command): Use gdb_argv.
10003 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
10004 (gdbsim_open): Use gdb_argv.
10005 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
10006 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
10007 * procfs.c (procfs_info_proc): Use gdb_argv.
10008 * interps.c (interpreter_exec_cmd): Use gdb_argv.
10009 * infrun.c (handle_command): Use gdb_argv.
10010 * inferior.c (add_inferior_command, clone_inferior_command):
10011 Use gdb_argv.
10012 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
10013 * exec.c (exec_file_command): Use gdb_argv.
10014 * cli/cli-cmds.c (alias_command): Use gdb_argv.
10015 * compile/compile.c (build_argc_argv): Use gdb_argv.
10016
10017 2017-08-03 Tom Tromey <tom@tromey.com>
10018
10019 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
10020
10021 2017-08-03 Tom Tromey <tom@tromey.com>
10022
10023 * python/python.c (compute_python_string): Return std::string.
10024 (gdbpy_eval_from_control_command): Update.
10025 (do_start_initialization): Use std::string.
10026 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
10027 xstrprintf.
10028 * python/py-breakpoint.c (local_setattro): Use string_printf, not
10029 xstrprintf.
10030
10031 2017-08-03 Tom Tromey <tom@tromey.com>
10032
10033 * top.h (do_restore_instream_cleanup): Remove.
10034 * top.c (do_restore_instream_cleanup): Remove.
10035 (read_command_file): Use scoped_restore.
10036 * cli/cli-script.c (execute_user_command): Use scoped_restore.
10037
10038 2017-08-03 Tom Tromey <tom@tromey.com>
10039
10040 * cli/cli-script.c (execute_user_command)
10041 (execute_control_command): Use scoped_restore.
10042
10043 2017-08-03 Tom Tromey <tom@tromey.com>
10044
10045 * cli/cli-script.c (do_restore_user_call_depth): Remove.
10046 (execute_user_command): Remove user_call_depth; use
10047 user_args_stack's size instead.
10048
10049 2017-08-03 Tom Tromey <tom@tromey.com>
10050
10051 * top.h (in_user_command): Remove.
10052 * top.c (in_user_command): Remove.
10053 * cli/cli-script.c (do_restore_user_call_depth)
10054 (execute_user_command): Update.
10055
10056 2017-08-03 Tom Tromey <tom@tromey.com>
10057
10058 * valops.c (search_struct_method): Use gdb::byte_vector.
10059 * valarith.c (value_concat): Use std::vector.
10060 * target.c (memory_xfer_partial): Use gdb::byte_vector.
10061 (simple_search_memory): Likewise.
10062 * printcmd.c (find_string_backward): Use gdb::byte_vector.
10063 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
10064 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
10065 * elfread.c (elf_rel_plt_read): Use std::string.
10066 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
10067 * cli/cli-dump.c (restore_section_callback): Use
10068 gdb::byte_vector.
10069
10070 2017-08-03 Tom Tromey <tom@tromey.com>
10071
10072 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
10073
10074 2017-08-03 Tom Tromey <tom@tromey.com>
10075
10076 * tui/tui-regs.c (tui_restore_gdbout): Remove.
10077 (tui_register_format): Use scoped_restore.
10078
10079 2017-08-03 Tom Tromey <tom@tromey.com>
10080
10081 * reverse.c (exec_direction_default): Remove.
10082 (exec_reverse_once): Use scoped_restore.
10083 * remote.c (restore_remote_timeout): Remove.
10084 (remote_flash_erase, remote_flash_write, remote_flash_done)
10085 (readchar, remote_serial_write): Use scoped_restore.
10086 * cli/cli-script.c (struct source_cleanup_lines_args)
10087 (source_cleanup_lines): Remove.
10088 (script_from_file): Use scoped_restore.
10089 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
10090 (source_command): Use scoped_restore.
10091
10092 2017-08-03 Tom Tromey <tom@tromey.com>
10093
10094 * utils.h (make_cleanup_free_so): Remove.
10095 * utils.c (do_free_so, make_cleanup_free_so): Remove.
10096 * solist.h (struct so_deleter): New.
10097 (so_list_up): New typedef.
10098 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
10099
10100 2017-08-03 Tom Tromey <tom@tromey.com>
10101
10102 * utils.h (make_cleanup_restore_current_language): Remove.
10103 * utils.c (do_restore_current_language)
10104 (make_cleanup_restore_current_language): Remove.
10105 * parse.c (parse_exp_in_context_1)
10106 (parse_expression_with_language): Use
10107 scoped_restore_current_language.
10108 * mi/mi-main.c (mi_cmd_execute): Use
10109 scoped_restore_current_language.
10110 * language.h (scoped_restore_current_language): New class.
10111
10112 2017-08-03 Tom Tromey <tom@tromey.com>
10113
10114 * compile/compile.c (cleanup_unlink_file): Remove.
10115 (compile_to_object): Use gdb::unlinker.
10116 (eval_compile_command): Likewise.
10117
10118 2017-08-03 Tom Tromey <tom@tromey.com>
10119
10120 * utils.h (make_cleanup_fclose): Remove.
10121 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
10122
10123 2017-08-03 Tom Tromey <tom@tromey.com>
10124
10125 * top.c (open_terminal_stream): Return gdb_file_up.
10126 (new_ui_command): Update.
10127
10128 2017-08-03 Tom Tromey <tom@tromey.com>
10129
10130 * source.c (print_source_lines_base, forward_search_command)
10131 (reverse_search_command): Use gdb_file_up.
10132
10133 2017-08-03 Tom Tromey <tom@tromey.com>
10134
10135 * fbsd-nat.c (fbsd_find_memory_regions): Update.
10136
10137 2017-08-03 Tom Tromey <tom@tromey.com>
10138
10139 * cli/cli-cmds.c (find_and_open_script): Change return type.
10140 Remove "streamp" and "full_path" parameters.
10141 (source_script_with_search): Update.
10142 * auto-load.c (source_script_file): Update.
10143 * cli/cli-cmds.h (find_and_open_script): Change type.
10144 (open_script): New struct.
10145
10146 2017-08-03 Tom Tromey <tom@tromey.com>
10147
10148 * xml-support.c (xml_fetch_content_from_file): Update.
10149 * ui-file.c (stdio_file::open): Update.
10150 * tracefile-tfile.c (tfile_start): Update.
10151 * remote.c (remote_file_put, remote_file_get): Update.
10152 * nat/linux-procfs.c (linux_proc_get_int)
10153 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
10154 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
10155 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
10156 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
10157 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
10158 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
10159 * linux-nat.c (linux_proc_pending_signals): Update.
10160 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
10161 (file_closer): Remove.
10162 * compile/compile.c (compile_to_object): Update.
10163 * common/filestuff.h (struct gdb_file_deleter): New.
10164 (gdb_file_up): New typedef.
10165 (gdb_fopen_cloexec): Change return type.
10166 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
10167 * cli/cli-dump.c (fopen_with_cleanup): Remove.
10168 (dump_binary_file, restore_binary_file): Update.
10169 * auto-load.c (auto_load_objfile_script_1): Update.
10170
10171 2017-08-03 Tom Tromey <tom@tromey.com>
10172
10173 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
10174 (info_static_tracepoint_markers_command): Likewise.
10175 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
10176 * skip.c (skip_info): Use ui_out_emit_table.
10177 * progspace.c (print_program_space): Use ui_out_emit_table.
10178 * osdata.c (info_osdata): Use ui_out_emit_table.
10179 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
10180 ui_out_emit_table.
10181 * linux-thread-db.c (info_auto_load_libthread_db): Use
10182 ui_out_emit_table.
10183 * inferior.c (print_inferior): Use ui_out_emit_table.
10184 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
10185 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
10186 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
10187 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
10188 * ui-out.h (class ui_out_emit_table): New.
10189
10190 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
10191
10192 * mips-tdep.c (mips_fpu_type_str): New function.
10193 (mips_dump_tdep): Call it.
10194
10195 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
10196
10197 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
10198 `->mips_fpu_type'.
10199
10200 2017-07-31 Xavier Roirand <roirand@adacore.com>
10201
10202 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
10203
10204 2017-07-27 Xavier Roirand <roirand@adacore.com>
10205
10206 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
10207
10208 2017-07-26 Yao Qi <yao.qi@linaro.org>
10209
10210 * cli/cli-cmds.c (maintenancechecklist): New variable.
10211 * gdbcmd.h (maintenancechecklist): Declare it.
10212 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
10213 Call i386_linux_read_description with different masks.
10214 * maint.c (maintenance_check_command): New function.
10215 (_initialize_maint_cmds): Call add_prefix_cmd.
10216 * target-descriptions.c (tdesc_reg): override operator != and ==.
10217 (tdesc_type): Likewise.
10218 (tdesc_feature): Likewise.
10219 (target_desc): Likewise.
10220 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
10221 (maintenance_check_xml_descriptions): New function.
10222 (_initialize_target_descriptions) Add command "xml-descriptions".
10223 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
10224
10225 2017-07-26 Yao Qi <yao.qi@linaro.org>
10226
10227 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
10228 Include features/i386/32bit-*.c.
10229 (i386_linux_read_description): Generate target description if it
10230 doesn't exist.
10231 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
10232 functions.
10233 * features/i386/32bit-linux.c: Re-generated.
10234 * features/i386/32bit-sse.c: Likewise.
10235 * target-descriptions.c (print_c_feature::visit): Print code to
10236 set register number if needed.
10237 (print_c_feature) <m_next_regnum>: New field.
10238
10239 2017-07-26 Yao Qi <yao.qi@linaro.org>
10240
10241 * features/Makefile (CFILES): Rename with TDESC_CFILES.
10242 (FEATURE_XMLFILES): New.
10243 (FEATURE_CFILES): New.
10244 New rules.
10245 (clean-cfiles): Remove generated c files.
10246 * features/i386/32bit-avx.c: Generated.
10247 * features/i386/32bit-avx512.c: Generated.
10248 * features/i386/32bit-core.c: Generated.
10249 * features/i386/32bit-linux.c: Generated.
10250 * features/i386/32bit-mpx.c: Generated.
10251 * features/i386/32bit-pkeys.c: Generated.
10252 * features/i386/32bit-sse.c: Generated.
10253 * target-descriptions.c: Include algorithm.
10254 (tdesc_element_visitor): Add method visit_end.
10255 (print_c_tdesc): Implement visit_end.
10256 (print_c_tdesc:: m_filename_after_features): Move it to
10257 protected.
10258 (print_c_feature): New class.
10259 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
10260 name starts with "i386/32bit-".
10261
10262 2017-07-26 Yao Qi <yao.qi@linaro.org>
10263
10264 * target-descriptions.c (tdesc_element_visitor): New class.
10265 (tdesc_element): New class.
10266 (tdesc_reg): Inherit from tdesc_element.
10267 (tdesc_reg::accept): New function.
10268 (tdesc_type): Inherit from tdesc_element.
10269 (tdesc_type::accept): New function.
10270 (tdesc_feature): Inherit from tdesc_element.
10271 (tdesc_feature::accept): New function.
10272 (target_desc): Inherit from tdesc_element.
10273 (target_desc::target_desc): New.
10274 (target_desc::~target_desc): New.
10275 (target_desc::accept): New.
10276 (allocate_target_description): Use new.
10277 (free_target_description): Use delete.
10278 (print_c_tdesc): New class.
10279 (maint_print_c_tdesc_cmd): Adjust.
10280
10281 * features/aarch64.c: Re-generated.
10282 * features/arc-arcompact.c: Re-generated.
10283 * features/arc-v2.c: Re-generated.
10284 * features/arm/arm-with-iwmmxt.c: Re-generated.
10285 * features/arm/arm-with-m.c: Re-generated.
10286 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
10287 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
10288 * features/arm/arm-with-neon.c: Re-generated.
10289 * features/arm/arm-with-vfpv2.c: Re-generated.
10290 * features/arm/arm-with-vfpv3.c: Re-generated.
10291 * features/i386/amd64-avx-avx512.c: Re-generated.
10292 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10293 * features/i386/amd64-avx.c: Re-generated.
10294 * features/i386/amd64-avx-linux.c: Re-generated.
10295 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
10296 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10297 * features/i386/amd64-avx-mpx.c: Re-generated.
10298 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
10299 * features/i386/amd64.c: Re-generated.
10300 * features/i386/amd64-linux.c: Re-generated.
10301 * features/i386/amd64-mpx.c: Re-generated.
10302 * features/i386/amd64-mpx-linux.c: Re-generated.
10303 * features/i386/i386-avx-avx512.c: Re-generated.
10304 * features/i386/i386-avx-avx512-linux.c: Re-generated.
10305 * features/i386/i386-avx.c: Re-generated.
10306 * features/i386/i386-avx-linux.c: Re-generated.
10307 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
10308 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
10309 * features/i386/i386-avx-mpx.c: Re-generated.
10310 * features/i386/i386-avx-mpx-linux.c: Re-generated.
10311 * features/i386/i386.c: Re-generated.
10312 * features/i386/i386-linux.c: Re-generated.
10313 * features/i386/i386-mmx.c: Re-generated.
10314 * features/i386/i386-mmx-linux.c: Re-generated.
10315 * features/i386/i386-mpx.c: Re-generated.
10316 * features/i386/i386-mpx-linux.c: Re-generated.
10317 * features/i386/x32-avx-avx512.c: Re-generated.
10318 * features/i386/x32-avx-avx512-linux.c: Re-generated.
10319 * features/i386/x32-avx.c: Re-generated.
10320 * features/i386/x32-avx-linux.c: Re-generated.
10321 * features/i386/x32.c: Re-generated.
10322 * features/i386/x32-linux.c: Re-generated.
10323 * features/microblaze.c: Re-generated.
10324 * features/microblaze-with-stack-protect.c: Re-generated.
10325 * features/mips64-dsp-linux.c: Re-generated.
10326 * features/mips64-linux.c: Re-generated.
10327 * features/mips-dsp-linux.c: Re-generated.
10328 * features/mips-linux.c: Re-generated.
10329 * features/nds32.c: Re-generated.
10330 * features/nios2.c: Re-generated.
10331 * features/nios2-linux.c: Re-generated.
10332 * features/rs6000/powerpc-32.c: Re-generated.
10333 * features/rs6000/powerpc-32l.c: Re-generated.
10334 * features/rs6000/powerpc-403.c: Re-generated.
10335 * features/rs6000/powerpc-403gc.c : Re-generated.
10336 * features/rs6000/powerpc-405.c: Re-generated.
10337 * features/rs6000/powerpc-505.c: Re-generated.
10338 * features/rs6000/powerpc-601.c: Re-generated.
10339 * features/rs6000/powerpc-602.c: Re-generated.
10340 * features/rs6000/powerpc-603.c: Re-generated.
10341 * features/rs6000/powerpc-604.c: Re-generated.
10342 * features/rs6000/powerpc-64.c: Re-generated.
10343 * features/rs6000/powerpc-64l.c: Re-generated.
10344 * features/rs6000/powerpc-7400.c: Re-generated.
10345 * features/rs6000/powerpc-750.c: Re-generated.
10346 * features/rs6000/powerpc-860.c: Re-generated.
10347 * features/rs6000/powerpc-altivec32.c: Re-generated.
10348 * features/rs6000/powerpc-altivec32l.c: Re-generated.
10349 * features/rs6000/powerpc-altivec64.c: Re-generated.
10350 * features/rs6000/powerpc-altivec64l.c: Re-generated.
10351 * features/rs6000/powerpc-cell32l.c: Re-generated.
10352 * features/rs6000/powerpc-cell64l.c: Re-generated.
10353 * features/rs6000/powerpc-e500.c: Re-generated.
10354 * features/rs6000/powerpc-e500l.c: Re-generated.
10355 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
10356 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
10357 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
10358 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
10359 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
10360 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
10361 * features/rs6000/powerpc-vsx32.c: Re-generated.
10362 * features/rs6000/powerpc-vsx32l.c: Re-generated.
10363 * features/rs6000/powerpc-vsx64.c: Re-generated.
10364 * features/rs6000/powerpc-vsx64l.c: Re-generated.
10365 * features/rs6000/rs6000.c: Re-generated.
10366 * features/s390-linux32.c: Re-generated.
10367 * features/s390-linux32v1.c: Re-generated.
10368 * features/s390-linux32v2.c: Re-generated.
10369 * features/s390-linux64.c: Re-generated.
10370 * features/s390-linux64v1.c: Re-generated.
10371 * features/s390-linux64v2.c: Re-generated.
10372 * features/s390-te-linux64.c: Re-generated.
10373 * features/s390-tevx-linux64.c: Re-generated.
10374 * features/s390-vx-linux64.c: Re-generated.
10375 * features/s390x-linux64.c: Re-generated.
10376 * features/s390x-linux64v1.c: Re-generated.
10377 * features/s390x-linux64v2.c: Re-generated.
10378 * features/s390x-te-linux64.c: Re-generated.
10379 * features/s390x-tevx-linux64.c: Re-generated.
10380 * features/s390x-vx-linux64.c: Re-generated.
10381 * features/sparc/sparc32-solaris.c: Re-generated.
10382 * features/sparc/sparc64-solaris.c: Re-generated.
10383 * features/tic6x-c62x.c: Re-generated.
10384 * features/tic6x-c62x-linux.c: Re-generated.
10385 * features/tic6x-c64x.c: Re-generated.
10386 * features/tic6x-c64x-linux.c: Re-generated.
10387 * features/tic6x-c64xp.c: Re-generated.
10388 * features/tic6x-c64xp-linux.c: Re-generated.
10389
10390 2017-07-26 Yao Qi <yao.qi@linaro.org>
10391
10392 * i386-linux-tdep.c (i386_linux_read_description): New function.
10393 (i386_linux_core_read_description): Call
10394 i386_linux_read_description.
10395 * i386-linux-tdep.h (i386_linux_read_description): Declare.
10396 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
10397 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
10398 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
10399 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
10400 * x86-linux-nat.c (x86_linux_read_description): Call
10401 i386_linux_read_description.
10402
10403 2017-07-26 Yao Qi <yao.qi@linaro.org>
10404
10405 * NEWS: Mention it.
10406 * features/Makefile (%.c: %.xml): Pass the xml file name to
10407 command "maint print c-tdesc".
10408 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
10409 name from 'arg'.
10410
10411 2017-07-26 Yao Qi <yao.qi@linaro.org>
10412
10413 * target-descriptions.c (target_desc): Add ctor and dtor. Do
10414 in-class initialization.
10415 (tdesc_create_feature): Call new instead of XCNEW.
10416 (free_target_description): Ue delete.
10417
10418 2017-07-25 John Baldwin <jhb@FreeBSD.org>
10419
10420 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
10421
10422 2017-07-25 Yao Qi <yao.qi@linaro.org>
10423
10424 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
10425 constant.
10426 (amd64_x32_init_abi): Likewise.
10427 * amd64-tdep.h (amd64_init_abi): Update declaration.
10428 (amd64_x32_init_abi): Likewise.
10429
10430 2017-07-25 Yao Qi <yao.qi@linaro.org>
10431
10432 PR tdep/21717
10433 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10434 condition for FPSCR.
10435 (arm_linux_store_inferior_registers): Likewise.
10436
10437 2017-07-22 Tom Tromey <tom@tromey.com>
10438
10439 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10440 <syscalls_counts>: Now a std::vector.
10441 (get_catch_syscall_inferior_data): Use "new".
10442 (catch_syscall_inferior_data_cleanup): Use "delete".
10443 (insert_catch_syscall, remove_catch_syscall)
10444 (clear_syscall_counts): Update.
10445
10446 2017-07-22 Tom Tromey <tom@tromey.com>
10447
10448 * break-catch-syscall.c (syscall_catchpoint)
10449 <syscalls_to_be_caught>: Now a std::vector<int>
10450 (~syscall_catchpoint): Remove.
10451 (insert_catch_syscall, remove_catch_syscall)
10452 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10453 (print_mention_catch_syscall, print_recreate_catch_syscall):
10454 Update.
10455 (create_syscall_event_catchpoint): Change type of "filter"
10456 parameter.
10457 (catch_syscall_split_args): Return a std::vector.
10458 (catch_syscall_command_1, catching_syscall_number_1): Update.
10459
10460 2017-07-22 Tom Tromey <tom@tromey.com>
10461
10462 * break-catch-throw.c (struct exception_catchpoint)
10463 <exception_rx>: Now a std::string.
10464 (~exception_catchpoint): Remove.
10465 (print_one_detail_exception_catchpoint): Update.
10466 (handle_gnu_v3_exceptions): Change type of except_rx.
10467 (extract_exception_regexp): Return a std::string.
10468 (catch_exception_command_1): Update.
10469
10470 2017-07-22 Tom Tromey <tom@tromey.com>
10471
10472 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10473 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10474 std::vector.
10475 <catch_all>: Now a bool.
10476 (~signal_catchpoint): Remove.
10477 (signal_catchpoint_insert_location)
10478 (signal_catchpoint_remove_location)
10479 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10480 (signal_catchpoint_print_mention)
10481 (signal_catchpoint_print_recreate)
10482 (signal_catchpoint_explains_signal): Update.
10483 (create_signal_catchpoint): Change type of "filter" and
10484 "catch_all".
10485 (catch_signal_split_args): Return a std::vector. Change type of
10486 "catch_all".
10487 (catch_signal_command): Update.
10488
10489 2017-07-20 Pedro Alves <palves@redhat.com>
10490
10491 * ada-lang.c (ada_language_defn): Make extern.
10492 (_initialize_ada_language): Remove add_language call.
10493 * c-lang.c (c_language_defn, cplus_language_defn)
10494 (asm_language_defn, minimal_language_defn): Make extern.
10495 (_initialize_c_language): Delete.
10496 * completer.c (compare_cstrings): Delete, moved to utils.h.
10497 * d-lang.c (d_language_defn): Make extern.
10498 (_initialize_d_language): Remove add_language calls.
10499 * defs.h (enum language): Add comment.
10500 * f-lang.c (f_language_defn): Make extern.
10501 (_initialize_f_language): Remove add_language call.
10502 * go-lang.c (go_language_defn): Make extern.
10503 (_initialize_go_language): Remove add_language call.
10504 * language.c: Include <algorithm>.
10505 (languages): Redefine as const array.
10506 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10507 (set_language_command): Handle "local". Use for-range loop.
10508 (set_language): Remove loop.
10509 (language_enum): Rewrite.
10510 (language_def, language_str): Remove loops.
10511 (add_language): Delete.
10512 (add_set_language_command): New, based on add_languages.
10513 (skip_language_trampoline): Adjust.
10514 (local_language_defn): Delete.
10515 (language_gdbarch_post_init): Adjust.
10516 (_initialize_language): Remove add_language calls. Call
10517 add_set_language_command.
10518 * language.h (add_language): Delete.
10519 (auto_language_defn)
10520 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10521 (asm_language_defn, c_language_defn, cplus_language_defn)
10522 (d_language_defn, f_language_defn, go_language_defn)
10523 (m2_language_defn, objc_language_defn, opencl_language_defn)
10524 (pascal_language_defn, rust_language_defn): Declare.
10525 * m2-lang.c (m2_language_defn): Make extern.
10526 (_initialize_m2_language): Remove add_language call.
10527 * objc-lang.c (objc_language_defn): Make extern.
10528 (_initialize_objc_language): Remove add_language call.
10529 * opencl-lang.c (opencl_language_defn): Make extern.
10530 (_initialize_opencl_language): Remove add_language call.
10531 * p-lang.c (pascal_language_defn): Make extern.
10532 (_initialize_pascal_language): Delete.
10533 * rust-lang.c (rust_language_defn): Make extern.
10534 (_initialize_rust_language): Delete.
10535 * utils.h (compare_cstrings): New static inline function.
10536
10537 2017-07-20 Pedro Alves <palves@redhat.com>
10538
10539 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10540 (get_var_value): Constify parameters.
10541 (get_int_var_value): Change prototype.
10542 (to_fixed_range_type): Adjust.
10543 * ada-lang.h (get_int_var_value): Change prototype.
10544
10545 2017-07-20 Pedro Alves <palves@redhat.com>
10546
10547 * dwarf2read.c (dw2_lookup_symbol): Use
10548 SYMBOL_MATCHES_SEARCH_NAME.
10549 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10550
10551 2017-07-20 Pedro Alves <palves@redhat.com>
10552
10553 * block.c (block_iter_name_step, block_iter_name_first)
10554 (block_iter_name_next): Delete.
10555 (block_lookup_symbol_primary): Adjust to use
10556 dict_iter_match_first/dict_iter_match_next.
10557 * block.h (block_iter_name_first, block_iter_name_next): Delete
10558 declarations.
10559 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10560 dict_iter_match_first/dict_iter_match_next.
10561
10562 2017-07-20 Pedro Alves <palves@redhat.com>
10563
10564 * cp-support.c (cp_find_first_component_aux): Add missing case for
10565 end of string.
10566
10567 2017-07-18 David Blaikie <dblaikie@gmail.com>
10568
10569 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10570 of dwo_cu's dwo_file.
10571
10572 2017-07-18 Yao Qi <yao.qi@linaro.org>
10573
10574 * remote.c (store_registers_using_G): Remove one line comment.
10575
10576 2017-07-18 Yao Qi <yao.qi@linaro.org>
10577
10578 * regcache.c (regcache_cpy): Simplify it.
10579 (regcache::cpy_no_passthrough): Remove it.
10580 * regcache.h (cpy_no_passthrough): Remove it.
10581 (regcache_dup, regcache_cpy): Update comments.
10582
10583 2017-07-18 Pedro Alves <palves@redhat.com>
10584
10585 * remote-sim.c (sim_command_completer): Adjust to work with a
10586 completion_tracker instead of a VEC.
10587
10588 2017-07-17 Pedro Alves <palves@redhat.com>
10589
10590 * completer.c (complete_source_filenames): New function.
10591 (complete_address_and_linespec_locations): New function.
10592 (location_completer): Use complete_address_and_linespec_locations.
10593 (completion_tracker::build_completion_result): Honor the tracker's
10594 request to suppress append.
10595 * completer.h (completion_tracker::suppress_append_ws)
10596 (completion_tracker::set_suppress_append_ws): New methods.
10597 (completion_tracker::m_suppress_append_ws): New field.
10598 (complete_source_filenames): New declaration.
10599 * linespec.c (linespec_complete_what): New.
10600 (struct ls_parser) <complete_what, completion_word,
10601 completion_quote_char, completion_quote_end, completion_tracker>:
10602 New fields.
10603 (string_find_incomplete_keyword_at_end): New.
10604 (linespec_lexer_lex_string): Record quote char. If in completion
10605 mode, don't throw.
10606 (linespec_lexer_consume_token): Advance the completion word point.
10607 (linespec_lexer_peek_token): Save/restore completion info.
10608 (save_stream_and_consume_token): New.
10609 (set_completion_after_number): New.
10610 (linespec_parse_basic): Set what to complete next depending on
10611 token. Handle function and label completions specially.
10612 (parse_linespec): Disable objc shortcut in completion mode. Set
10613 what to complete next depending on token type. Skip keyword if in
10614 completion mode.
10615 (complete_linespec_component, linespec_complete): New.
10616 * linespec.h (linespec_complete): Declare.
10617
10618 2017-07-17 Pedro Alves <palves@redhat.com>
10619
10620 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10621 Handle 'operator<' / 'operator<<'.
10622
10623 2017-07-17 Pedro Alves <palves@redhat.com>
10624
10625 * completer.c (collect_explicit_location_matches): Handle
10626 MATCH_LABEL.
10627 (convert_explicit_location_to_linespec): New, factored out from
10628 ...
10629 (convert_explicit_location_to_sals): ... this.
10630 (complete_label): New.
10631 (linespec_complete_label, find_label_symbols_in_block): New.
10632 (find_label_symbols): Add completion_mode parameter and adjust to
10633 call find_label_symbols_in_block.
10634 * linespec.h (linespec_complete_label): Declare.
10635
10636 2017-07-17 Pedro Alves <palves@redhat.com>
10637
10638 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10639 complete_symbol_mode parameter.
10640 * cli/cli-cmds.c (complete_command): Get the completion result out
10641 of the handle_brkchars tracker if used a custom word point.
10642 * completer.c: Include "linespec.h".
10643 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10644 (advance_to_expression_complete_word_point): New.
10645 (completion_tracker::completes_to_completion_word): New.
10646 (complete_files_symbols): Pass down
10647 complete_symbol_mode::EXPRESSION.
10648 (explicit_options, probe_options): New.
10649 (collect_explicit_location_matches): Complete on the
10650 explictit_loc->foo instead of word. Use
10651 linespec_complete_function. Handle MATCH_LINE. Handle offering
10652 keyword and options completions.
10653 (backup_text_ptr): Delete.
10654 (skip_keyword): New.
10655 (complete_explicit_location): Remove 'word' parameter. Add
10656 language, quoted_arg_start and quoted_arg_end parameters.
10657 Rewrite, parsing left to right.
10658 (location_completer): Rewrite.
10659 (location_completer_handle_brkchars): New function.
10660 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10661 (enum complete_line_internal_reason): Adjust comments.
10662 (completion_tracker::discard_completions): New.
10663 (completer_handle_brkchars_func_for_completer): Handle
10664 location_completer.
10665 (gdb_custom_word_point_brkchars)
10666 (gdb_org_rl_basic_quote_characters): New.
10667 (gdb_completion_word_break_characters_throw)
10668 (completion_find_completion_word): Handle trackers that use a
10669 custom word point.
10670 (completion_tracker::advance_custom_word_point_by): New.
10671 (completion_tracker::build_completion_result): Don't rely on
10672 readline appending the quote char.
10673 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10674 use a custom word point.
10675 (gdb_rl_attempted_completion_function): Restore
10676 rl_basic_quote_characters.
10677 * completer.h (class completion_tracker): Extend intro comment.
10678 (completion_tracker::set_quote_char)
10679 (completion_tracker::quote_char)
10680 (completion_tracker::set_use_custom_word_point)
10681 (completion_tracker::use_custom_word_point)
10682 (completion_tracker::custom_word_point)
10683 (completion_tracker::set_custom_word_point)
10684 (completion_tracker::advance_custom_word_point_by)
10685 (completion_tracker::completes_to_completion_word)
10686 (completion_tracker::discard_completions): New methods.
10687 (completion_tracker::m_quote_char)
10688 (completion_tracker::m_use_custom_word_point)
10689 (completion_tracker::m_custom_word_point): New fields.
10690 (advance_to_expression_complete_word_point): Declare.
10691 * f-lang.c (f_collect_symbol_completion_matches): Add
10692 complete_symbol_mode parameter.
10693 * language.h (struct language_defn)
10694 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10695 parameter.
10696 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10697 (linespec_complete_function): New function.
10698 (linespec_lexer_lex_keyword): Adjust.
10699 * linespec.h (linespec_keywords, linespec_complete_function): New
10700 declarations.
10701 * location.c (find_end_quote): New function.
10702 (explicit_location_lex_one): Add explicit_completion_info
10703 parameter. Save quoting info. Don't throw if being called for
10704 completion. Don't handle Ada operators here.
10705 (is_cp_operator, skip_op_false_positives, first_of)
10706 (explicit_location_lex_one_function): New function.
10707 (string_to_explicit_location): Replace 'dont_throw' parameter with
10708 an explicit_completion_info pointer parameter. Handle it. Don't
10709 use explicit_location_lex_one to lex function names. Use
10710 explicit_location_lex_one_function instead.
10711 * location.h (struct explicit_completion_info): New.
10712 (string_to_explicit_location): Replace 'dont_throw' parameter with
10713 an explicit_completion_info pointer parameter.
10714 * symtab.c (default_collect_symbol_completion_matches_break_on):
10715 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10716 (default_collect_symbol_completion_matches)
10717 (collect_symbol_completion_matches): Add complete_symbol_mode
10718 parameter.
10719 (collect_symbol_completion_matches_type): Pass down
10720 complete_symbol_mode::EXPRESSION.
10721 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10722 parameter. Handle LINESPEC mode.
10723 * symtab.h (complete_symbol_mode): New.
10724 (default_collect_symbol_completion_matches_break_on)
10725 (default_collect_symbol_completion_matches)
10726 (collect_symbol_completion_matches)
10727 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10728 parameter.
10729
10730 2017-07-17 Pedro Alves <palves@redhat.com>
10731
10732 * utils.c (enum class strncmp_iw_mode): New.
10733 (strcmp_iw): Rename to ...
10734 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10735 parameters. Handle them.
10736 (strncmp_iw): New.
10737 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10738 * utils.h (strncmp_iw): Declare.
10739 (strcmp_iw): Move describing comments here.
10740
10741 2017-07-17 Pedro Alves <palves@redhat.com>
10742
10743 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10744 CP_OPERATOR_STR.
10745 * c-typeprint.c (is_type_conversion_operator): Use
10746 CP_OPERATOR_STR.
10747 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10748 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10749 CP_OPERATOR_LEN.
10750 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10751 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10752 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10753 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10754 CP_OPERATOR_STR.
10755 * location.c: Include "cp-support.h".
10756 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10757 CP_OPERATOR_STR.
10758 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10759 CP_OPERATOR_LEN.
10760
10761 2017-07-17 Pedro Alves <palves@redhat.com>
10762
10763 * cli/cli-cmds.c (complete_command): Use a completion tracker
10764 along with completion_find_completion_word for handle_brkchars
10765 phase.
10766 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10767 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10768 (struct gdb_rl_completion_word_info): New.
10769 (gdb_rl_find_completion_word): New.
10770 (completion_find_completion_word): New.
10771 * completer.h (completion_find_completion_word): Declare.
10772
10773 2017-07-17 Pedro Alves <palves@redhat.com>
10774
10775 * ada-lang.c (symbol_completion_match): Adjust comments.
10776 (symbol_completion_add): Replace vector parameter with
10777 completion_tracker parameter. Use it.
10778 (ada_make_symbol_completion_list): Rename to...
10779 (ada_collect_symbol_completion_matches): ... this. Add
10780 completion_tracker parameter and use it.
10781 (ada_language_defn): Adjust.
10782 * break-catch-syscall.c (catch_syscall_completer): Adjust
10783 prototype and work with completion_tracker instead of VEC.
10784 * breakpoint.c (condition_completer): Adjust prototype and work
10785 with completion_tracker instead of VEC.
10786 * c-lang.c (c_language_defn, cplus_language_defn)
10787 (asm_language_defn, minimal_language_defn): Adjust to renames.
10788 * cli/cli-cmds.c (complete_command): Rework using
10789 completion_tracker. Catch exceptions when completing.
10790 * cli/cli-decode.c (integer_unlimited_completer)
10791 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
10792 with completion_tracker instead of VEC.
10793 * command.h (struct completion_tracker): Forward declare.
10794 (completer_ftype, completer_handle_brkchars_ftype): Change
10795 types.
10796 (complete_on_cmdlist, complete_on_enum): Adjust.
10797 * completer.c: Include <algorithm>.
10798 (struct gdb_completer_state): New.
10799 (current_completion): New global.
10800 (readline_line_completion_function): Delete.
10801 (noop_completer, filename_completer)
10802 (filename_completer_handle_brkchars, complete_files_symbols)
10803 (linespec_location_completer): Adjust to work with a
10804 completion_tracker instead of a VEC.
10805 (string_or_empty): New.
10806 (collect_explicit_location_matches): Adjust to work with a
10807 completion_tracker instead of a VEC.
10808 (explicit_location_completer): Rename to ...
10809 (complete_explicit_location): ... this and adjust to work with a
10810 completion_tracker instead of a VEC.
10811 (location_completer): Adjust to work with a completion_tracker
10812 instead of a VEC.
10813 (add_struct_fields): Adjust to work with a completion_list instead
10814 of VEC.
10815 (expression_completer): Rename to ...
10816 (complete_expression): ... this and adjust to work with a
10817 completion_tracker instead of a VEC. Use complete_files_symbols.
10818 (expression_completer): Reimplement on top of complete_expression.
10819 (symbol_completer): Adjust to work with a completion_tracker
10820 instead of a VEC.
10821 (enum complete_line_internal_reason): Add describing comments.
10822 (complete_line_internal_normal_command): Adjust to work with a
10823 completion_tracker instead of a VEC.
10824 (complete_line_internal): Rename to ...
10825 (complete_line_internal_1): ... this and adjust to work with a
10826 completion_tracker instead of a VEC. Assert TEXT is NULL in the
10827 handle_brkchars phase.
10828 (new_completion_tracker): Delete.
10829 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
10830 complete_line_internal_1.
10831 (free_completion_tracker): Delete.
10832 (INITIAL_COMPLETION_HTAB_SIZE): New.
10833 (completion_tracker::completion_tracker)
10834 (completion_tracker::~completion_tracker): New.
10835 (maybe_add_completion): Delete.
10836 (completion_tracker::maybe_add_completion)
10837 (completion_tracker::add_completion)
10838 (completion_tracker::add_completions): New.
10839 (throw_max_completions_reached_error): Delete.
10840 (complete_line): Adjust to work with a completion_tracker instead
10841 of a VEC. Don't create a completion_tracker_t or check for max
10842 completions here.
10843 (command_completer, command_completer_handle_brkchars)
10844 (signal_completer, reg_or_group_completer_1)
10845 (reg_or_group_completer, default_completer_handle_brkchars):
10846 Adjust to work with a completion_tracker.
10847 (gdb_completion_word_break_characters_throw): New.
10848 (gdb_completion_word_break_characters): Reimplement.
10849 (line_completion_function): Delete.
10850 (completion_tracker::recompute_lowest_common_denominator)
10851 (expand_preserving_ws)
10852 (completion_tracker::build_completion_result)
10853 (completion_result::completion_result)
10854 (completion_result::completion_result)
10855 (completion_result::~completion_result)
10856 (completion_result::completion_result)
10857 (completion_result::release_match_list, compare_cstrings)
10858 (completion_result::sort_match_list)
10859 (completion_result::reset_match_list)
10860 (gdb_rl_attempted_completion_function_throw)
10861 (gdb_rl_attempted_completion_function): New.
10862 * completer.h (completion_list, struct completion_result)
10863 (class completion_tracker): New.
10864 (complete_line): Add completion_tracker parameter.
10865 (readline_line_completion_function): Delete.
10866 (gdb_rl_attempted_completion_function): New.
10867 (noop_completer, filename_completer, expression_completer)
10868 (location_completer, symbol_completer, command_completer)
10869 (signal_completer, reg_or_group_completer): Update prototypes.
10870 (completion_tracker_t, new_completion_tracker)
10871 (make_cleanup_free_completion_tracker): Delete.
10872 (enum maybe_add_completion_enum): Delete.
10873 (maybe_add_completion): Delete.
10874 (throw_max_completions_reached_error): Delete.
10875 * corefile.c (complete_set_gnutarget): Adjust to work with a
10876 completion_tracker instead of a VEC.
10877 * cp-abi.c (cp_abi_completer): Adjust to work with a
10878 completion_tracker instead of a VEC.
10879 * d-lang.c (d_language_defn): Adjust.
10880 * disasm.c (disassembler_options_completer): Adjust to work with a
10881 completion_tracker instead of a VEC.
10882 * f-lang.c (f_make_symbol_completion_list): Rename to ...
10883 (f_collect_symbol_completion_matches): ... this. Adjust to work
10884 with a completion_tracker instead of a VEC.
10885 (f_language_defn): Adjust.
10886 * go-lang.c (go_language_defn): Adjust.
10887 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
10888 Adjust to work with a completion_tracker instead of a VEC.
10889 * infrun.c (handle_completer): Likewise.
10890 * interps.c (interpreter_completer): Likewise.
10891 * interps.h (interpreter_completer): Likewise.
10892 * language.c (unknown_language_defn, auto_language_defn)
10893 (local_language_defn): Adjust.
10894 * language.h (language_defn::la_make_symbol_completion_list):
10895 Rename to ...
10896 (language_defn::la_collect_symbol_completion_matches): ... this
10897 and adjust to work with a completion_tracker instead of a VEC.
10898 * m2-lang.c (m2_language_defn): Adjust.
10899 * objc-lang.c (objc_language_defn): Adjust.
10900 * opencl-lang.c (opencl_language_defn): Adjust.
10901 * p-lang.c (pascal_language_defn): Adjust.
10902 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
10903 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
10904 with a completion_tracker.
10905 * rust-lang.c (rust_language_defn): Adjust.
10906 * symtab.c (free_completion_list, do_free_completion_list)
10907 (return_val, completion_tracker): Delete.
10908 (completion_list_add_name, completion_list_add_symbol)
10909 (completion_list_add_msymbol, completion_list_objc_symbol)
10910 (completion_list_add_fields, add_symtab_completions): Add
10911 completion_tracker parameter and use it.
10912 (default_make_symbol_completion_list_break_on_1): Rename to...
10913 (default_collect_symbol_completion_matches_break_on): ... this.
10914 Add completion_tracker parameter and use it instead of allocating
10915 a completion tracker here.
10916 (default_make_symbol_completion_list_break_on): Delete old
10917 implementation.
10918 (default_make_symbol_completion_list): Delete.
10919 (default_collect_symbol_completion_matches): New.
10920 (make_symbol_completion_list): Delete.
10921 (collect_symbol_completion_matches): New.
10922 (make_symbol_completion_type): Rename to ...
10923 (collect_symbol_completion_matches_type): ... this. Add
10924 completion_tracker parameter and use it instead of VEC.
10925 (make_file_symbol_completion_list_1): Rename to...
10926 (collect_file_symbol_completion_matches): ... this. Add
10927 completion_tracker parameter and use it instead of VEC.
10928 (make_file_symbol_completion_list): Delete.
10929 (add_filename_to_list): Use completion_list instead of a VEC.
10930 (add_partial_filename_data::list): Now a completion_list.
10931 (make_source_files_completion_list): Work with a completion_list
10932 instead of a VEC.
10933 * symtab.h: Include "completer.h".
10934 (default_make_symbol_completion_list_break_on)
10935 (default_make_symbol_completion_list, make_symbol_completion_list)
10936 (make_symbol_completion_type, make_file_symbol_completion_list)
10937 (make_source_files_completion_list): Delete.
10938 (default_collect_symbol_completion_matches_break_on)
10939 (default_collect_symbol_completion_matches)
10940 (collect_symbol_completion_matches)
10941 (collect_symbol_completion_matches_type)
10942 (collect_file_symbol_completion_matches)
10943 (make_source_files_completion_list): New.
10944 * top.c (init_main): Don't install a rl_completion_entry_function
10945 hook. Install a rl_attempted_completion_function hook instead.
10946 * tui/tui-layout.c (layout_completer): Adjust to work with a
10947 completion_tracker.
10948 * tui/tui-regs.c (tui_reggroup_completer):
10949 * tui/tui-win.c (window_name_completer, focus_completer)
10950 (winheight_completer): Adjust to work with a completion_tracker.
10951 * value.c: Include "completer.h".
10952 (complete_internalvar): Adjust to work with a completion_tracker.
10953 * value.h (complete_internalvar): Likewise.
10954
10955 2017-07-17 Pedro Alves <palves@redhat.com>
10956
10957 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
10958 renames.
10959 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
10960 comments to completer_ftype's declaration.
10961 <completer_handle_brkchars>: Change type to
10962 completer_handle_brkchars_ftype.
10963 * command.h (completer_ftype): Add describing comment and give
10964 names to parameters.
10965 (completer_ftype_void): Rename to ...
10966 (completer_handle_brkchars_ftype) ... this. Add describing comment.
10967 (set_cmd_completer_handle_brkchars): Adjust.
10968 * completer.c (filename_completer_handle_brkchars): New function.
10969 (complete_line_internal_normal_command): New function, factored
10970 out from ...
10971 (complete_line_internal): ... here.
10972 (command_completer_handle_brkchars)
10973 (default_completer_handle_brkchars)
10974 (completer_handle_brkchars_func_for_completer): New functions.
10975 * completer.h (set_gdb_completion_word_break_characters): Delete
10976 declaration.
10977 (completer_handle_brkchars_func_for_completer): New declaration.
10978 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
10979 completer_handle_brkchars_func_for_completer.
10980
10981 2017-07-17 Pedro Alves <palves@redhat.com>
10982
10983 * completer.c (symbol_completer): New function, based on
10984 make_symbol_completion_list_fn.
10985 * completer.h (symbol_completer): New declaration.
10986 * guile/scm-cmd.c (cmdscm_completers): Adjust.
10987 * python/py-cmd.c (completers): Adjust.
10988 * symtab.c (make_symbol_completion_list_fn): Delete.
10989 * symtab.h (make_symbol_completion_list_fn): Delete.
10990 * cli/cli-decode.c (add_cmd): Adjust.
10991
10992 2017-07-17 Pedro Alves <palves@redhat.com>
10993
10994 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
10995 * dwarf2read.c: Include "filename-seen-cache.h".
10996 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
10997 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
10998 * filename-seen-cache.c: New file.
10999 * filename-seen-cache.h: New file.
11000 * symtab.c: Include "filename-seen-cache.h".
11001 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
11002 (create_filename_seen_cache, clear_filename_seen_cache)
11003 (delete_filename_seen_cache, filename_seen): Delete, parts moved
11004 to filename-seen-cache.h/filename-seen-cache.c.
11005 (output_source_filename, sources_info)
11006 (maybe_add_partial_symtab_filename)
11007 (make_source_files_completion_list): Adjust to use
11008 filename_seen_cache.
11009
11010 2017-07-17 Pedro Alves <palves@redhat.com>
11011
11012 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
11013 fields.
11014 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
11015 dwarf2_debug_sections*)): New.
11016 (dwarf2_per_objfile::dwarf2_per_objfile(const
11017 dwarf2_per_objfile&)): Declare as deleted.
11018 (dwarf2_per_objfile::operator=): Declare as deleted.
11019 (dwarf2_per_objfile::dwarf2_per_objfile)
11020 (dwarf2_per_objfile::~dwarf2_per_objfile)
11021 (dwarf2_per_objfile::free_cached_comp_units): New.
11022 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
11023 ctor. Call dwarf2_per_objfile's ctor manually.
11024 (dwarf2_locate_sections): Deleted/refactored as ...
11025 (dwarf2_per_objfile::locate_sections): ... this new method.
11026 (free_cached_comp_units): Defer to
11027 dwarf2_per_objfile::free_cached_comp_units.
11028 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
11029
11030 2017-07-14 Tom Tromey <tom@tromey.com>
11031
11032 PR rust/21764:
11033 * rust-exp.y (convert_ast_to_expression): Add "want_type"
11034 parameter.
11035 <UNOP_SIZEOF>: Split into separate case.
11036 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
11037
11038 2017-07-14 Tom Tromey <tom@tromey.com>
11039
11040 PR rust/21763:
11041 * symtab.c (symbol_matches_domain): Add language_rust to special
11042 case.
11043 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
11044 treat LOC_TYPEDEF symbols as variables.
11045
11046 2017-07-14 Pedro Alves <palves@redhat.com>
11047
11048 * symtab.c (make_file_symbol_completion_list_1): Iterate over
11049 symtabs matching all symtabs with SRCFILE as file name instead of
11050 only considering the first hit, with lookup_symtab.
11051
11052 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11053
11054 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
11055 operator_name parameters.
11056 (gen_expr): Update function call.
11057
11058 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11059
11060 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
11061 parameter.
11062 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
11063 Likewise.
11064 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
11065 parameter, use agent_expr::gdbarch instead, update function
11066 calls.
11067 (locexpr_tracepoint_var_ref): Likewise.
11068 (loclist_tracepoint_var_ref): Likewise.
11069 * ax-gdb.c (gen_trace_static_fields): Likewise.
11070 (gen_traced_pop): Likewise.
11071 (gen_frame_args_address): Likewise.
11072 (gen_frame_locals_address): Likewise.
11073 (gen_var_ref): Likewise.
11074 (gen_struct_ref_recursive): Likewise.
11075 (gen_static_field): Likewise.
11076 (gen_maybe_namespace_elt): Likewise.
11077 (gen_expr): Likewise.
11078 (gen_trace_for_var): Likewise.
11079 (gen_trace_for_expr): Likewise.
11080 (gen_trace_for_return_address): Likewise.
11081
11082 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11083
11084 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
11085 parameter.
11086 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
11087
11088 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11089
11090 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
11091 from ax, update calls.
11092 (gen_usual_arithmetic): Likewise.
11093 (gen_integral_promotions): Likewise.
11094 (gen_bitfield_ref): Likewise.
11095 (gen_primitive_field): Likewise.
11096 (gen_struct_ref_recursive): Likewise.
11097 (gen_struct_ref): Likewise.
11098 (gen_maybe_namespace_elt): Likewise.
11099 (gen_struct_elt_for_reference): Likewise.
11100 (gen_namespace_elt): Likewise.
11101 (gen_aggregate_elt_ref): Likewise.
11102 (gen_expr): Get gdbarch from ax, update calls.
11103 (gen_expr_binop_rest): Likewise.
11104
11105 2017-07-13 Pedro Alves <palves@redhat.com>
11106
11107 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
11108 as default tdesc.
11109 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
11110 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
11111 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
11112 tdesc_amd64_linux as default tdesc. Get final tdesc from the
11113 tdep.
11114 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
11115 Get final tdesc from the tdep.
11116 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
11117 default tdesc.
11118 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
11119 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
11120 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
11121 Use it as default tdesc.
11122 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
11123 down to amd_init_abi. No longer handle fallback tdesc here.
11124 * amd64-tdep.h (tdesc_x32): Declare.
11125 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
11126 parameter.
11127 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
11128 as default tdesc.
11129
11130 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11131
11132 * s390-linux-tdep.c (s390_process_record): Add support for
11133 instructions new in arch12.
11134
11135 2017-07-11 John Baldwin <jhb@FreeBSD.org>
11136
11137 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
11138 PT_GETFSBASE and PT_GETGSBASE.
11139 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
11140 PT_SETGSBASE.
11141
11142 2017-07-11 John Baldwin <jhb@FreeBSD.org>
11143
11144 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
11145 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
11146 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
11147 those rules.
11148 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
11149 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
11150 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
11151 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
11152 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
11153 * features/i386/amd64.xml: Add 64bit-segments.xml.
11154 * features/i386/amd64-avx-avx512.c: Regenerated.
11155 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
11156 * features/i386/amd64-avx-mpx.c: Regenerated.
11157 * features/i386/amd64-avx.c: Regenerated.
11158 * features/i386/amd64-mpx.c: Regenerated.
11159 * features/i386/amd64.c: Regenerated.
11160 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
11161 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11162 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
11163 * regformats/i386/amd64-avx.dat: Regenerated.
11164 * regformats/i386/amd64-mpx.dat: Regenerated.
11165 * regformats/i386/amd64.dat: Regenerated.
11166
11167 2017-07-10 Yao Qi <yao.qi@linaro.org>
11168
11169 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
11170 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
11171
11172 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
11173
11174 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
11175 unsetenv.
11176 * gnulib/aclocal.m4: Regenerate.
11177 * gnulib/config.in: Regenerate.
11178 * gnulib/configure: Regenerate.
11179 * gnulib/import/Makefile.am: Regenerate.
11180 * gnulib/import/Makefile.in: Regenerate.
11181 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
11182 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
11183 * gnulib/import/m4/environ.m4: New file.
11184 * gnulib/import/m4/setenv.m4: New file.
11185 * gnulib/import/setenv.c: New file.
11186 * gnulib/import/unsetenv.c: New file.
11187
11188 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
11189
11190 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
11191 address when op is DW_OP_addr.
11192
11193 2017-07-09 Tom Tromey <tom@tromey.com>
11194
11195 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
11196 check and apply to outer type.
11197
11198 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11199
11200 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
11201 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
11202 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
11203 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
11204
11205 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11206
11207 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
11208
11209 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11210
11211 * corelow.c (get_core_siginfo): Remove.
11212 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
11213 instead of get_core_siginfo.
11214 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
11215 * gdbarch.h: Re-generate.
11216 * gdbarch.c: Re-generate.
11217 * linux-tdep.c (linux_core_xfer_siginfo): New.
11218 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
11219
11220 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11221
11222 * corelow.c (thread_section_name): Move to ...
11223 * gdbcore.h (thread_section_name): ... here.
11224
11225 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11226
11227 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
11228 (struct siginfo32): New.
11229 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
11230 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
11231 via ptrace(PT_LWPINFO).
11232
11233 2017-07-07 John Baldwin <jhb@FreeBSD.org>
11234
11235 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
11236 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
11237 (fbsd_get_siginfo_type): New.
11238 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
11239 (_initialize_fbsd_tdep): New.
11240
11241 2017-07-06 David Blaikie <dblaikie@gmail.com>
11242
11243 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
11244 a singular dwo_unit*) to support multiple CUs in the same way that
11245 multiple TUs are supported.
11246 (create_cus_hash_table): Replace create_dwo_cu with a function for
11247 parsing multiple CUs from a DWO file.
11248 (open_and_init_dwo_file): Use create_cus_hash_table rather than
11249 create_dwo_cu.
11250 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
11251 htab_find, rather than comparing the signature to a singleton CU in
11252 the dwo_file.
11253
11254 2017-07-06 Pedro Alves <palves@redhat.com>
11255
11256 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
11257
11258 2017-07-04 Pedro Alves <palves@redhat.com>
11259
11260 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
11261 * gdbtypes.h (TYPE_STATIC): Delete.
11262 (struct fn_field) <is_public, is_abstract, is_static, is_final,
11263 is_synchronized, is_native>: Delete.
11264 <dummy>: Bump.
11265 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
11266 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
11267 (TYPE_FN_FIELD_ABSTRACT): Delete.
11268
11269 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
11270
11271 * buffer.h (buffer_finish): Fix spelling mistakes.
11272
11273 2017-07-01 Eli Zaretskii <eliz@gnu.org>
11274
11275 * .dir-locals.el: Automatically switch to C-style comments in
11276 versions of Emacs that support the feature.
11277
11278 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11279 Pedro Alves <palves@redhat.com>
11280
11281 PR cli/21688
11282 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
11283 (process_next_line): New variable 'inline_cmd'.
11284 Adjust 'if' clauses for "python", "compile" and "guile" to use
11285 'command_name_equals' and check for '!inline_cmd'.
11286
11287 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11288
11289 PR cli/21688
11290 * cli/cli-script.c (command_name_equals_not_inline): New function.
11291 (process_next_line): Adjust 'if' clauses for "python", "compile"
11292 and "guile" to use command_name_equals_not_inline.
11293
11294 2017-06-29 Pedro Alves <palves@redhat.com>
11295
11296 * completer.c (expression_completer): Call
11297 linespec_location_completer instead of location_completer.
11298
11299 2017-06-29 Pedro Alves <palves@redhat.com>
11300
11301 * completer.c (expression_completer): Remove code that recomputes
11302 'text' from 'word'.
11303
11304 2017-06-29 Yao Qi <yao.qi@linaro.org>
11305
11306 * regformats/regdat.sh: Generate code with
11307 "ifndef IN_PROCESS_AGENT".
11308
11309 2017-06-28 Pedro Alves <palves@redhat.com>
11310
11311 * command.h: Include "common/scoped_restore.h".
11312
11313 2017-06-28 Yao Qi <yao.qi@linaro.org>
11314
11315 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
11316 instead of obstack_grow.
11317
11318 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
11319
11320 PR gdb/21337
11321 * symfile.c (reread_symbols): Call objfiles_changed just before
11322 read_symbols.
11323
11324 2017-06-27 Pedro Alves <palves@redhat.com>
11325
11326 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
11327 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
11328 (completion_list_add_symbol, completion_list_add_msymbol):
11329 ... these new functions.
11330 (add_symtab_completions)
11331 (default_make_symbol_completion_list_break_on_1): Adjust.
11332
11333 2017-06-27 Pedro Alves <palves@redhat.com>
11334
11335 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
11336 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
11337 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
11338 dtor.
11339 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
11340 'storage_obstack' field an auto_obstack. In-class initialize all
11341 non-bitfield fields. Make minsyms_read bool.
11342 * symfile.c (read_symbols): Adjust.
11343
11344 2017-06-27 Alan Hayward <alan.hayward@arm.com>
11345
11346 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
11347 (gdbsim_store_register): Likewise.
11348
11349 2017-06-27 Pedro Alves <palves@redhat.com>
11350
11351 * c-exp.y (name_obstack): Now an auto_obstack.
11352 (yylex): Use auto_obstack::clear.
11353 (c_parse): Use auto_obstack::clear instead of reinitializing and
11354 freeing the obstack.
11355 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
11356 * d-exp.y (name_obstack): Now an auto_obstack.
11357 (yylex): Use auto_obstack::clear.
11358 (d_parse): Use auto_obstack::clear instead of reinitializing and
11359 freeing the obstack.
11360 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
11361 auto_obstack.
11362 * dwarf2read.c (create_addrmap_from_index)
11363 (dwarf2_build_psymtabs_hard)
11364 (update_enumeration_type_from_children): Likewise.
11365 * gdb_obstack.h (auto_obstack): New type.
11366 * go-exp.y (name_obstack): Now an auto_obstack.
11367 (build_packaged_name): Use auto_obstack::clear.
11368 (go_parse): Use auto_obstack::clear instead of reinitializing and
11369 freeing the obstack.
11370 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
11371 auto_obstack.
11372 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
11373 * rust-exp.y (work_obstack): Now an auto_obstack.
11374 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
11375 reinitializing and freeing the obstack.
11376 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
11377 (host_char_to_target): Use auto_obstack.
11378 * utils.h (make_cleanup_obstack_free): Delete declaration.
11379 * valprint.c (generic_emit_char, generic_printstr): Use
11380 auto_obstack.
11381
11382 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
11383
11384 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
11385 thread.
11386 (darwin_init_thread_list): Don't update dummy thread.
11387 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
11388
11389 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11390
11391 * record-full.c (netorder16): Remove.
11392
11393 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11394
11395 * common/diagnostics.h: Define macros for GCC.
11396 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
11397 * common/vec.h: Include diagnostics.h.
11398 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
11399 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
11400 warning.
11401
11402 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11403
11404 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
11405 New macro.
11406 * ada-lex.l: Ignore deprecated register warnings.
11407
11408 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11409
11410 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
11411 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
11412
11413 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11414
11415 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
11416 its own line.
11417
11418 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11419
11420 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
11421
11422 2017-06-23 Alan Hayward <alan.hayward@arm.com>
11423
11424 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
11425 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
11426 (xtensa_register_read_masked): Likewise.
11427
11428 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
11429
11430 * common/environ.c (gdb_environ::unset): Update comment.
11431
11432 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11433
11434 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11435 registers.
11436
11437 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11438
11439 * record-full.c (record_full_exec_insn): Use byte_vector.
11440
11441 2017-06-22 Yao Qi <yao.qi@linaro.org>
11442
11443 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11444 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11445
11446 2017-06-22 Alan Hayward <alan.hayward@arm.com>
11447
11448 * remote.c (cached_reg): Move from here...
11449 * regcache.h (cached_reg): ...to here.
11450 * python/py-unwind.c (struct reg_info): Remove.
11451 (cached_frame_info): Use cached_reg_t.
11452 (pyuw_prev_register): Likewise.
11453 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11454 (pyuw_dealloc_cache): Free all registers.
11455
11456 2017-06-22 Pedro Alves <palves@redhat.com>
11457 Simon Marchi <simon.marchi@ericsson.com>
11458
11459 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11460 warning.
11461 * common/diagnostics.h: New file.
11462
11463 2017-06-22 Pedro Alves <palves@redhat.com>
11464
11465 * common/agent.h: Add include guards.
11466
11467 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11468
11469 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11470 talk about addressable units instead of bytes.
11471
11472 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11473
11474 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11475 of '::const_iterator'.
11476
11477 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11478
11479 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11480 'unittests/environ-selftests.c'.
11481 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11482 * charset.c (find_charset_names): Declare object 'iconv_env'.
11483 Update code to use 'iconv_env' object. Remove call to
11484 'free_environ'.
11485 * common/environ.c: Include <utility>.
11486 (make_environ): Delete function.
11487 (free_environ): Delete function.
11488 (gdb_environ::clear): New function.
11489 (gdb_environ::operator=): New function.
11490 (gdb_environ::get): Likewise.
11491 (environ_vector): Delete function.
11492 (set_in_environ): Delete function.
11493 (gdb_environ::set): New function.
11494 (unset_in_environ): Delete function.
11495 (gdb_environ::unset): New function.
11496 (gdb_environ::envp): Likewise.
11497 * common/environ.h: Include <vector>.
11498 (struct gdb_environ): Delete; transform into...
11499 (class gdb_environ): ... this class.
11500 (free_environ): Delete prototype.
11501 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11502 environ_vector): Likewise.
11503 * infcmd.c (run_command_1): Update code to call
11504 'envp' from 'gdb_environ' class.
11505 (environment_info): Update code to call methods from 'gdb_environ'
11506 class.
11507 (unset_environment_command): Likewise.
11508 (path_info): Likewise.
11509 (path_command): Likewise.
11510 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11511 (inferior::inferior): Initialize 'environment' using the host's
11512 information.
11513 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11514 Include "environ.h".
11515 (class inferior) <environment>: Change type from 'struct
11516 gdb_environ' to 'gdb_environ'.
11517 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11518 methods from 'gdb_environ' class.
11519 * solib.c (solib_find_1): Likewise
11520 * unittests/environ-selftests.c: New file.
11521
11522 2017-06-20 Yao Qi <yao.qi@linaro.org>
11523
11524 * features/i386/i386-linux.xml: Exchange the order of including
11525 32bit-linux.xml and 32bit-sse.xml.
11526 * features/i386/i386-linux.c: Regenerated.
11527
11528 2017-06-20 Yao Qi <yao.qi@linaro.org>
11529
11530 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11531 Delete copy ctor and assignment operator.
11532 (tdesc_type): Likewise.
11533 (tdesc_feature): Likewise.
11534 (tdesc_free_reg): Remove.
11535 (tdesc_create_reg): Use new.
11536 (tdesc_free_type): Remove.
11537 (tdesc_create_vector): Use new.
11538 (tdesc_create_union): Likewise.
11539 (tdesc_create_flags): Likewise.
11540 (tdesc_create_enum): Likewise.
11541 (tdesc_free_feature): Delete.
11542 (free_target_description): Use delete.
11543
11544 2017-06-19 John Baldwin <jhb@FreeBSD.org>
11545
11546 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11547 registers.
11548
11549 2017-06-19 Pedro Alves <palves@redhat.com>
11550
11551 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11552 after gdb::unlinker.
11553
11554 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11555
11556 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11557 gdb_environ to access an environment variable.
11558
11559 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11560
11561 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11562 gdb_byte*.
11563
11564 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11565
11566 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11567
11568 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11569
11570 * configure: Re-generate.
11571 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11572
11573 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11574
11575 * configure: Re-generate.
11576 * warning.m4: Pass -Werror to compiler when checking for
11577 supported warning flags.
11578
11579 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11580
11581 * Makefile.in (COMPILE.pre): Add "-x c++".
11582
11583 2017-06-16 Alan Hayward <alan.hayward@arm.com>
11584 Pedro Alves <palves@redhat.com>
11585 Yao Qi <yao.qi@linaro.org>
11586
11587 * defs.h (RequireLongest): New.
11588 (extract_integer): Declare function template.
11589 (extract_signed_integer): Remove the declaration, but define it
11590 static inline.
11591 (extract_unsigned_integer): Likewise.
11592 (store_integer): Declare function template.
11593 (store_signed_integer): Remove the declaration, but define it
11594 static inline.
11595 (store_unsigned_integer): Likewise.
11596 * findvar.c (extract_integer): New function template.
11597 (extract_signed_integer): Remove.
11598 (extract_unsigned_integer): Remove.
11599 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11600 instantiations.
11601 (store_integer): New function template.
11602 (store_signed_integer): Remove.
11603 (store_unsigned_integer): Remove.
11604 (store_integer): Explicit instantiations.
11605 * regcache.c (regcache_raw_read_signed): Update.
11606 (regcache::raw_read): New function.
11607 (regcache::raw_read_signed): Remove.
11608 (regcache::raw_read_unsigned): Remove.
11609 (regcache_raw_read_unsigned): Update.
11610 (regcache_raw_write_unsigned): Update.
11611 (regcache::raw_write_signed): Remove.
11612 (regcache::raw_write): New function.
11613 (regcache_cooked_read_signed): Update.
11614 (regcache::raw_write_unsigned): Remove.
11615 (regcache::cooked_read_signed): Remove.
11616 (regcache_cooked_read_unsigned): Update.
11617 (regcache::cooked_read_unsigned): Remove.
11618 (regcache_cooked_write_signed): Update.
11619 (regcache_cooked_write_unsigned): Update.
11620 * regcache.h (regcache) <raw_read_signed>: Remove.
11621 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11622 <raw_read, raw_write>: New.
11623 <cooked_read_signed, cooked_write_signed>: Remove.
11624 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11625 <cooked_read, cooked_write>: New.
11626 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11627 (sh64_pseudo_register_write): Update.
11628
11629 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11630
11631 * arc-tdep.c (arc_disassembler_options): New variable.
11632 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11633 of default_print_insn.
11634 (arc_delayed_print_insn): Set info->section when needed,
11635 use default_print_insn to retrieve a disassembler.
11636
11637 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11638
11639 PR gdb/21574
11640 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11641 to mention $SHELL and startup-with-shell.
11642
11643 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11644
11645 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11646
11647 2017-06-14 Yao Qi <yao.qi@linaro.org>
11648
11649 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11650 default_print_insn instead of print_insn_aarch64.
11651 * arm-tdep.c (gdb_print_insn_arm): Call
11652 default_print_insn instead of print_insn_big_arm
11653 and print_insn_little_arm.
11654 * i386-tdep.c (i386_print_insn): Call default_print_insn
11655 instead of print_insn_i386.
11656 * ia64-tdep.c (ia64_print_insn): Call
11657 default_print_insn instead of print_insn_ia64.
11658 * mips-tdep.c (gdb_print_insn_mips): Call
11659 default_print_insn instead of print_insn_big_mips
11660 and print_insn_little_mips.
11661 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11662 instead of print_insn_spu.
11663
11664 2017-06-14 Pedro Alves <palves@redhat.com>
11665
11666 * ada-lang.c: Include "common/byte-vector.h".
11667 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11668 * charset.c (wchar_iterator::iterate): Resize the vector instead
11669 of reserving it.
11670 * common/byte-vector.h: Include "common/def-vector.h".
11671 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11672 * cli/cli-dump.c: Include "common/byte-vector.h".
11673 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11674 * common/byte-vector.h: New file.
11675 * common/def-vector.h: New file.
11676 * common/default-init-alloc.h: New file.
11677 * dwarf2loc.c: Include "common/byte-vector.h".
11678 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11679 instead of reserving it.
11680 * dwarf2read.c: Include "common/byte-vector.h".
11681 (data_buf::m_vec): Now a gdb::byte_vector.
11682 * gdb_regex.c: Include "common/def-vector.h".
11683 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11684 * mi/mi-main.c: Include "common/byte-vector.h".
11685 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11686 * printcmd.c: Include "common/byte-vector.h".
11687 (print_scalar_formatted): Use gdb::byte_vector.
11688 * valprint.c: Include "common/byte-vector.h".
11689 (maybe_negate_by_bytes, print_decimal_chars): Use
11690 gdb::byte_vector.
11691
11692 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11693
11694 * darwin-nat.c: Include "nat/fork-inferior.h".
11695
11696 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11697
11698 * configure.nat: Factor out Darwin bits that are not
11699 architecture-specific. Add fork-inferior.o.
11700
11701 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11702
11703 * configure.nat: Factor out AIX bits that are not
11704 architecture-specific. Add fork-inferior.o.
11705
11706 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11707
11708 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11709 (read_pieced_value, write_pieced_value): ...here. Reduce to
11710 wrappers that just call rw_pieced_value.
11711
11712 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11713
11714 * dwarf2loc.c (write_pieced_value): When writing the data for a
11715 memory piece, use write_memory_with_notification instead of
11716 write_memory.
11717
11718 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11719
11720 * valops.c (read_value_memory): Change embedded_offset to
11721 represent a bit offset instead of a byte offset.
11722 * value.h (read_value_memory): Adjust comment.
11723
11724 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11725
11726 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11727 dest_offset_bits and source_offset_bits.
11728 (write_pieced_value): Likewise.
11729
11730 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11731
11732 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11733 given by DW_OP_bit_piece.
11734 (write_pieced_value): Likewise.
11735
11736 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11737
11738 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11739 some other preparations to the places where sufficient information
11740 is available.
11741 (write_pieced_value): Likewise.
11742
11743 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11744
11745 * dwarf2loc.c (bits_to_bytes): New function.
11746 (read_pieced_value): Fix offset calculations for register pieces
11747 on big-endian targets.
11748 (write_pieced_value): Likewise.
11749
11750 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11751
11752 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11753 (write_pieced_value): Likewise.
11754
11755 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11756
11757 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11758 transfer the source value's least significant bits, instead of its
11759 lowest-addressed ones. Rename type_len to max_offset.
11760 (read_pieced_value): Mirror above changes to write_pieced_value as
11761 applicable.
11762
11763 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11764
11765 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11766 truncate full bytes from dest_offset_bits before using it as an
11767 offset into the buffer.
11768
11769 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11770
11771 * dwarf2loc.c (write_pieced_value): Include transfer size in
11772 byte-wise check.
11773
11774 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11775
11776 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11777 calculation of this_size.
11778
11779 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11780
11781 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
11782 when targeting a bit-field.
11783 (write_pieced_value): Likewise.
11784
11785 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11786
11787 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
11788 (allocate_piece_closure): Drop addr_size parameter.
11789 (dwarf2_evaluate_loc_desc_full): Adjust call to
11790 allocate_piece_closure.
11791
11792 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11793
11794 PR gdb/21226
11795 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
11796 the LSB end, independent of endianness.
11797
11798 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11799
11800 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
11801 size capping.
11802
11803 2017-06-13 Yao Qi <yao.qi@linaro.org>
11804
11805 * mips-linux-nat.c: Move include features/mips*-linux.c to
11806 mips-linux-tdep.c.
11807 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
11808 to mips-linux-tdep.c.
11809 * mips-linux-tdep.c: Include features/mips*-linux.c
11810 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
11811 functions.
11812 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
11813 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
11814 (tdesc_mips64_dsp_linux): Declare.
11815
11816 2017-06-12 Tom Tromey <tom@tromey.com>
11817
11818 * valprint.h (val_print_type_code_int): Remove.
11819 * valprint.c (generic_val_print_int): Always call
11820 val_print_scalar_formatted.
11821 (val_print_type_code_int): Remove.
11822 * printcmd.c (print_scalar_formatted): Handle options->format==0.
11823 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
11824 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
11825 * ada-valprint.c (ada_val_print_num): Use
11826 val_print_scalar_formatted.
11827
11828 2017-06-12 Tom Tromey <tom@tromey.com>
11829
11830 * printcmd.c (print_scalar_formatted): Unify the two switches.
11831 Don't convert scalars to LONGEST.
11832
11833 2017-06-12 Tom Tromey <tom@tromey.com>
11834
11835 PR exp/16225:
11836 * valprint.h (print_decimal_chars): Update.
11837 * valprint.c (maybe_negate_by_bytes): New function.
11838 (print_decimal_chars): Add "is_signed" argument.
11839 * printcmd.c (print_scalar_formatted): Update.
11840
11841 2017-06-12 Tom Tromey <tom@tromey.com>
11842
11843 PR exp/16225:
11844 * valprint.h (print_binary_chars, print_hex_chars): Update.
11845 * valprint.c (val_print_type_code_int): Update.
11846 (print_binary_chars): Add "zero_pad" argument.
11847 (emit_octal_digit): New function.
11848 (print_octal_chars): Don't zero-pad.
11849 (print_decimal_chars): Likewise.
11850 (print_hex_chars): Add "zero_pad" argument.
11851 * sh64-tdep.c (sh64_do_fp_register): Update.
11852 * regcache.c (regcache::dump): Update.
11853 * printcmd.c (print_scalar_formatted): Update.
11854 * infcmd.c (default_print_one_register_info): Update.
11855
11856 2017-06-12 Pedro Alves <palves@redhat.com>
11857 Alan Hayward <alan.hayward@arm.com>
11858
11859 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
11860 (mips_eabi_push_dummy_call): Rename local 'regsize' to
11861 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
11862 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
11863 Assert that abi_regsize bytes fit in 'ref_valbuf'.
11864
11865 2017-06-12 Pedro Alves <palves@redhat.com>
11866
11867 * dwarf2read.c (mapped_symtab::data): Now a vector of
11868 symtab_index_entry instead of vector of
11869 std::unique_ptr<symtab_index_entry>. All users adjusted to check
11870 whether an element's name is NULL instead of checking whether the
11871 element itself is NULL.
11872 (find_slot): Change return type. Adjust.
11873 (hash_expand, , add_index_entry, uniquify_cu_indices)
11874 (write_hash_table): Adjust.
11875
11876 2017-06-12 Pedro Alves <palves@redhat.com>
11877
11878 * dwarf2read.c (recursively_count_psymbols): New function.
11879 (write_psymtabs_to_index): Call it to compute number of psyms and
11880 pass estimate size of psyms_seen to unordered_set's ctor.
11881
11882 2017-06-12 Pedro Alves <palves@redhat.com>
11883
11884 * dwarf2read.c (write_hash_table): Check if key already exists
11885 before emplacing.
11886
11887 2017-06-12 Pedro Alves <palves@redhat.com>
11888
11889 * dwarf2read.c (data_buf::append_space): Rename to...
11890 (data_buf::grow): ... this, and make private. Adjust all callers.
11891 (data_buf::append_uint): New method.
11892 (add_address_entry, write_one_signatured_type)
11893 (write_psymtabs_to_index): Use it.
11894
11895 2017-06-12 Pedro Alves <palves@redhat.com>
11896
11897 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
11898 (file_write (FILE *, const std::vector<Elem>&)): Delete.
11899 (data_buf::file_write): Call ::fwrite directly.
11900
11901 2017-06-12 Pedro Alves <palves@redhat.com>
11902
11903 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
11904 std::vector::erase.
11905
11906 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11907
11908 Code cleanup: C++ify .gdb_index producer.
11909 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
11910 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
11911 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
11912 (create_strtab, add_string): Remove.
11913 (file_write, data_buf): New.
11914 (struct symtab_index_entry): Use std::vector for cu_indices.
11915 (struct mapped_symtab): Use std::vector for data.
11916 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
11917 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
11918 Remove.
11919 (find_slot): Change return type. Update it to the new data structures.
11920 (hash_expand, add_index_entry): Update it to the new data structures.
11921 (offset_type_compare): Remove.
11922 (uniquify_cu_indices): Update it to the new data structures.
11923 (c_str_view, c_str_view_hasher, vector_hasher): New.
11924 (add_indices_to_cpool): Remove.
11925 (write_hash_table): Update it to the new data structures.
11926 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
11927 (eq_psymtab_cu_index): Remove.
11928 (psym_index_map): New typedef.
11929 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
11930 reference and std::unordered_map for cu_index_htab.
11931 (add_address_entry, add_address_entry_worker, write_address_map)
11932 (write_psymbols): Update it to the new data structures.
11933 (write_obstack): Remove.
11934 (struct signatured_type_index_data): Change types_list to a data_buf
11935 reference and psyms_seen to a std::unordered_set reference.
11936 (write_one_signatured_type, recursively_write_psymbols)
11937 (write_psymtabs_to_index): Update it to the new data structures.
11938
11939 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
11940
11941 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
11942 separate-debug-file commands.
11943 * symfile.h (separate_debug_file_debug): New global.
11944 * symfile.c (separate_debug_file_debug): New global.
11945 (separate_debug_file_exists, find_separate_debug_file): Add
11946 debug output.
11947 (_initialize_symfile): Add "set debug separate-debug-file"
11948 command.
11949 * build-id.c (build_id_to_debug_bfd,
11950 find_separate_debug_file_by_buildid): Add debug output.
11951
11952 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
11953
11954 * gdbarch.sh (displaced_step_free_closure): Remove.
11955 * gdbarch.h, gdbarch.c: Re-generate.
11956 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
11957 displaced_step_free_closure.
11958 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
11959 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
11960 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
11961 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11962 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
11963 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11964 * arch-utils.h (simple_displaced_step_free_closure): Remove.
11965 * arch-utils.c (simple_displaced_step_free_closure): Remove.
11966 * infrun.c (displaced_step_clear): Call xfree instead of
11967 gdbarch_displaced_step_free_closure.
11968
11969 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
11970
11971 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
11972 NULL".
11973
11974 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11975
11976 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
11977 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
11978 (mn10300_push_dummy_call): Likewise.
11979
11980 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11981
11982 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
11983
11984 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11985
11986 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
11987
11988 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11989
11990 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
11991 able to start inferiors using a shell.
11992 (New remote packets): Announce new packet "QStartupWithShell".
11993 * remote.c: Add PACKET_QStartupWithShell.
11994 (extended_remote_create_inferior): Handle new
11995 PACKET_QStartupWithShell.
11996 (remote_protocol_features) <QStartupWithShell>: New entry for
11997 PACKET_QStartupWithShell.
11998 (_initialize_remote): Call "add_packet_config_cmd" for
11999 QStartupShell.
12000
12001 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12002 Pedro Alves <palves@redhat.com>
12003
12004 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
12005 and "nat/fork-inferior.h".
12006 * common/common-inferior.h: New file, with contents from
12007 "gdb/inferior.h".
12008 * commom/common-utils.c: Include "common-utils.h".
12009 (stringify_argv): New function.
12010 * common/common-utils.h (stringify_argv): New prototype.
12011 * configure.nat: Add "fork-inferior.o" as a dependency for
12012 "*linux*", "fbsd*" and "nbsd*" hosts.
12013 * corefile.c (get_exec_file): Update comment.
12014 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
12015 instead of "startup_inferior".
12016 (darwin_create_inferior): Call "add_thread_silent" after
12017 "fork_inferior".
12018 * fork-child.c: Cleanup unnecessary includes.
12019 (SHELL_FILE): Move to "common/common-fork-child.c".
12020 (environ): Likewise.
12021 (exec_wrapper): Initialize.
12022 (get_exec_wrapper): New function.
12023 (breakup_args): Move to "common/common-fork-child.c"; rename to
12024 "breakup_args_for_exec".
12025 (escape_bang_in_quoted_argument): Move to
12026 "common/common-fork-child.c".
12027 (saved_ui): New variable.
12028 (prefork_hook): New function.
12029 (postfork_hook): Likewise.
12030 (postfork_child_hook): Likewise.
12031 (gdb_startup_inferior): Likewise.
12032 (fork_inferior): Move to "common/common-fork-child.c". Update
12033 function to support gdbserver.
12034 (startup_inferior): Likewise.
12035 * gdbcore.h (get_exec_file): Remove declaration.
12036 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
12037 instead of "startup_inferior". Call "add_thread_silent" after
12038 "fork_inferior".
12039 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
12040 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
12041 instead of "startup_inferior". Call "add_thread_silent" after
12042 "fork_inferior".
12043 * inferior.h: Include "common-inferior.h".
12044 (trace_start_error): Move to "common/common-utils.h".
12045 (trace_start_error_with_name): Likewise.
12046 (fork_inferior): Move prototype to "nat/fork-inferior.h".
12047 (startup_inferior): Likewise.
12048 (gdb_startup_inferior): New prototype.
12049 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
12050 * nat/fork-inferior.h: New file.
12051 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
12052 instead of "startup_inferior". Call "add_thread_silent" after
12053 "fork_inferior".
12054 * target.h (target_terminal_init): Move prototype to
12055 "target/target.h".
12056 (target_terminal_inferior): Likewise.
12057 (target_terminal_ours): Likewise.
12058 * target/target.h (target_terminal_init): New prototype, moved
12059 from "target.h".
12060 (target_terminal_inferior): Likewise.
12061 (target_terminal_ours): Likewise.
12062 * utils.c (gdb_flush_out_err): New function.
12063
12064 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12065
12066 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
12067 * common/common-gdbthread.h: New file, with parts from
12068 "gdb/gdbthread.h".
12069 * gdbthread.h: Include "common-gdbthread.h".
12070 (switch_to_thread): Moved to "common/common-gdbthread.h".
12071
12072 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12073
12074 * Makefile.in (SFILES): Add "common/job-control.c".
12075 (HFILES_NO_SRCDIR): Add "common/job-control.h".
12076 (COMMON_OBS): Add "job-control.o".
12077 * common/job-control.c: New file, with contents from
12078 "gdb/inflow.c".
12079 * common/job-control.h: New file, with contents from "terminal.h".
12080 * fork-child.c: Include "job-control.h".
12081 * inflow.c: Include "job-control.h".
12082 (gdb_setpgid): Move to "common/common-inflow.c".
12083 (_initialize_inflow): Move setting of "job_control" to
12084 "handle_job_control".
12085 * terminal.h (job_control): Moved to "common/common-terminal.h".
12086 (gdb_setpgid): Likewise.
12087 * top.c: Include "job_control.h".
12088 * utils.c: Likewise.
12089 (job_control): Moved to "job-control.c".
12090
12091 2017-06-07 Pedro Alves <palves@redhat.com>
12092
12093 * Makefile.in (SFILES): Add gdb_regex.c.
12094 (COMMON_OBS): Add gdb_regex.o.
12095 * ada-lang.c (ada_add_standard_exceptions)
12096 (ada_add_exceptions_from_frame, name_matches_regex)
12097 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
12098 parameter type to compiled_regex. Adjust.
12099 (ada_exceptions_list): Use compiled_regex.
12100 * break-catch-throw.c (exception_catchpoint::pattern): Now a
12101 std::unique_ptr<compiled_regex>.
12102 (exception_catchpoint::~exception_catchpoint): Remove regfree
12103 call.
12104 (check_status_exception_catchpoint): Adjust to use compiled_regex.
12105 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
12106 * breakpoint.c (solib_catchpoint::compiled): Now a
12107 std::unique_ptr<compiled_regex>.
12108 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
12109 (check_status_catch_solib): Adjust to use compiled_regex.
12110 (add_solib_catchpoint): Adjust to use compiled_regex.
12111 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
12112 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
12113 compiled_regex reference. Adjust to use it.
12114 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
12115 declaration. Include "gdb_regex.h".
12116 (apropos_cmd): Change regex parameter to compiled_regex reference.
12117 * gdb_regex.c: New file.
12118 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
12119 declarations.
12120 (class compiled_regex): New.
12121 * linux-tdep.c: Include "common/gdb_optional.h".
12122 (struct mapping_regexes): New, factored out from
12123 mapping_is_anonymous_p, and adjusted to use compiled_regex.
12124 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
12125 gdb::optional and remove cleanups. Adjust to compiled_regex.
12126 * probe.c: Include "common/gdb_optional.h".
12127 (collect_probes): Use compiled_regex and gdb::optional and remove
12128 cleanups.
12129 * skip.c: Include "common/gdb_optional.h".
12130 (skiplist_entry::compiled_function_regexp): Now a
12131 gdb::optional<compiled_regex>.
12132 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
12133 (free_skiplist_entry): Remove regfree call.
12134 (compile_skip_regexp, skip_rfunction_p): Adjust to use
12135 compiled_regex and gdb::optional.
12136 * symtab.c: Include "common/gdb_optional.h".
12137 (search_symbols): Use compiled_regex and gdb::optional.
12138 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
12139 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
12140 to gdb_regex.c.
12141
12142 2017-06-07 Alan Hayward <alan.hayward@arm.com>
12143
12144 * regcache.c (regcache::save): Avoid buffer use.
12145 (regcache::dump): Likewise.
12146
12147 2017-06-07 Alan Hayward <alan.hayward@arm.com>
12148
12149 * sh-tdep.c (sh_pseudo_register_read): Remove
12150 MAX_REGISTER_SIZE.
12151 (sh_pseudo_register_write): Likewise.
12152 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
12153 (sh64_pseudo_register_write): Likewise
12154
12155 2017-06-07 Alan Hayward <alan.hayward@arm.com>
12156
12157 * aarch64-tdep.c (aarch64_store_return_value): Use
12158 V_REGISTER_SIZE.
12159 (aarch64_pseudo_read_value): Likewise.
12160 (aarch64_pseudo_write): Likewise.
12161
12162 2017-06-06 Yao Qi <yao.qi@linaro.org>
12163
12164 * regformats/regdef.h (set_register_cache): Remove the
12165 declaration.
12166
12167 2017-06-06 Alan Hayward <alan.hayward@arm.com>
12168
12169 * frame.c (frame_unwind_register_signed): Use
12170 frame_unwind_register_value.
12171
12172 2017-06-06 Pedro Alves <palves@redhat.com>
12173
12174 PR breakpoints/21553
12175 * breakpoint.c (create_breakpoints_sal_default)
12176 (init_breakpoint_sal, create_breakpoint_sal): Use
12177 gdb::unique_xmalloc_ptr for string parameters.
12178 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12179 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
12180 (base_breakpoint_create_breakpoints_sal)
12181 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
12182 (strace_marker_create_breakpoints_sal)
12183 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
12184 string parameters.
12185 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
12186 gdb::unique_xmalloc_ptr for string parameters.
12187 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12188 parameters.
12189
12190 2017-06-06 Alan Hayward <alan.hayward@arm.com>
12191
12192 * alpha-tdep.c (alpha_register_to_value): Use
12193 get_frame_register_value.
12194 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
12195
12196 2017-06-06 Alan Hayward <alan.hayward@arm.com>
12197
12198 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
12199 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
12200 (ia64_value_to_register): Likewise.
12201 (ia64_extract_return_value): Likewise.
12202 (ia64_store_return_value): Likewise.
12203 (ia64_push_dummy_call): Likewise.
12204
12205 2017-06-04 Joel Brobecker <brobecker@adacore.com>
12206
12207 GDB 8.0 released.
12208
12209 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
12210
12211 * x86-linux-nat.c (struct arch_lwp_info): Remove.
12212
12213 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
12214
12215 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
12216 parameter.
12217 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
12218
12219 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
12220
12221 * event-loop.c (poll_timers): Unallocate timer using delete
12222 instead of xfree.
12223
12224 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12225
12226 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
12227 (struct breakpoint) <~breakpoint>: New.
12228 (struct watchpoint): Inherit from breakpoint.
12229 <~watchpoint>: New.
12230 <base>: Remove.
12231 (struct tracepoint): Inherit from breakpoint.
12232 <base>: Remove.
12233 * breakpoint.c (longjmp_breakpoint_ops): Remove.
12234 (struct longjmp_breakpoint): Inherit from breakpoint.
12235 <~longjmp_breakpoint>: New.
12236 <base>: Remove.
12237 (new_breakpoint_from_type): Remove casts.
12238 (watchpoint_in_thread_scope): Remove reference to base field.
12239 (watchpoint_del_at_next_stop): Likewise.
12240 (update_watchpoint): Likewise.
12241 (watchpoint_check): Likewise.
12242 (bpstat_check_watchpoint): Likewise.
12243 (set_longjmp_breakpoint): Likewise.
12244 (struct fork_catchpoint): Inherit from breakpoint.
12245 <base>: Remove.
12246 (struct solib_catchpoint): Inherit from breakpoint.
12247 <~solib_catchpoint>: New.
12248 <base>: Remove.
12249 (dtor_catch_solib): Change to ...
12250 (solib_catchpoint::~solib_catchpoint): ... this.
12251 (breakpoint_hit_catch_solib): Remove reference to base field.
12252 (add_solib_catchpoint): Likewise.
12253 (create_fork_vfork_event_catchpoint): Likewise.
12254 (struct exec_catchpoint): Inherit from breakpoint.
12255 <~exec_catchpoint>: New.
12256 <base>: Remove.
12257 (dtor_catch_exec): Change to ...
12258 (exec_catchpoint::~exec_catchpoint): ... this.
12259 (dtor_watchpoint): Change to ...
12260 (watchpoint::~watchpoint): ... this.
12261 (watch_command_1): Remove reference to base field.
12262 (catch_exec_command_1): Likewise.
12263 (base_breakpoint_dtor): Change to ...
12264 (breakpoint::~breakpoint): ... this.
12265 (base_breakpoint_ops): Remove dtor field value.
12266 (longjmp_bkpt_dtor): Change to ...
12267 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
12268 (strace_marker_create_breakpoints_sal): Remove reference to base
12269 field.
12270 (delete_breakpoint): Don't manually call breakpoint destructor.
12271 (create_tracepoint_from_upload): Remove reference to base field.
12272 (trace_pass_set_count): Likewise.
12273 (initialize_breakpoint_ops): Don't initialize
12274 momentary_breakpoint_ops, don't set dtors.
12275 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
12276 <~ada_catchpoint>: New.
12277 <base>: Remove.
12278 (create_excep_cond_exprs): Remove reference to base field.
12279 (dtor_exception): Change to ...
12280 (ada_catchpoint::~ada_catchpoint): ... this.
12281 (dtor_catch_exception): Remove.
12282 (dtor_catch_exception_unhandled): Remove.
12283 (dtor_catch_assert): Remove.
12284 (create_ada_exception_catchpoint): Remove reference to base
12285 field.
12286 (initialize_ada_catchpoint_ops): Don't set dtors.
12287 * break-catch-sig.c (struct signal_catchpoint): Inherit from
12288 breakpoint.
12289 <~signal_catchpoint>: New.
12290 <base>: Remove.
12291 (signal_catchpoint_dtor): Change to ...
12292 (signal_catchpoint::~signal_catchpoint): ... this.
12293 (create_signal_catchpoint): Remove reference to base field.
12294 (initialize_signal_catchpoint_ops): Don't set dtor.
12295 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
12296 from breakpoint.
12297 <~syscall_catchpoint>: New.
12298 <base>: Remove.
12299 (dtor_catch_syscall): Change to ...
12300 (syscall_catchpoint::~syscall_catchpoint): ... this.
12301 (create_syscall_event_catchpoint): Remove reference to base
12302 field.
12303 (initialize_syscall_catchpoint_ops): Don't set dtor.
12304 * break-catch-throw.c (struct exception_catchpoint): Inherit
12305 from breakpoint.
12306 <~exception_catchpoint>: New.
12307 <base>: Remove.
12308 (dtor_exception_catchpoint): Change to ...
12309 (exception_catchpoint::~exception_catchpoint): ... this.
12310 (handle_gnu_v3_exceptions): Remove reference to base field.
12311 (initialize_throw_catchpoint_ops): Don't set dtor.
12312 * ctf.c (ctf_get_traceframe_address): Remove reference to base
12313 field.
12314 * remote.c (remote_get_tracepoint_status): Likewise.
12315 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
12316 * tracefile.c (tracefile_fetch_registers): Likewise.
12317 * tracepoint.c (actions_command): Likewise.
12318 (validate_actionline): Likewise.
12319 (tfind_1): Likewise.
12320 (get_traceframe_location): Likewise.
12321 (find_matching_tracepoint_location): Likewise.
12322 (parse_tracepoint_status): Likewise.
12323 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
12324
12325 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12326
12327 * breakpoint.c (struct longjmp_breakpoint): New struct.
12328 (is_tracepoint_type): Change return type to bool.
12329 (is_longjmp_type): New function.
12330 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
12331 (set_raw_breakpoint_without_location): Use
12332 new_breakpoint_from_type.
12333 (set_raw_breakpoint): Likewise.
12334
12335 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12336
12337 * breakpoint.c (new_breakpoint_from_type): New function.
12338 (create_breakpoint_sal): Use new_breakpoint_from_type and
12339 unique_ptr.
12340 (create_breakpoint): Likewise.
12341
12342 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
12343
12344 * memattr.c (mem_info_command): Rename to ...
12345 (info_mem_command): ... this.
12346 (mem_enable_command): Rename to ...
12347 (enable_mem_command): ... this.
12348 (mem_disable_command): Rename to ...
12349 (disable_mem_command): ... this.
12350 (mem_delete_command): Rename to ...
12351 (delete_mem_command): ... this.
12352 (_initialize_mem): Adjust function names.
12353
12354 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12355
12356 * btrace.c (handle_pt_insn_events): New.
12357 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
12358 STATUS. Split into this and ...
12359 (handle_pt_insn_event_flags): ... this.
12360
12361 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12362
12363 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
12364 and struct pt_insn.resynced.
12365 * configure: Regenerated.
12366 * config.in: Regenerated.
12367
12368 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12369
12370 * btrace.c (ftrace_find_call_by_number): New function.
12371 (ftrace_new_function): Store objects, not pointers.
12372 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
12373 ftrace_new_gap, ftrace_update_function,
12374 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
12375 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
12376 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
12377 btrace_ends_with_single_insn, btrace_call_get): Account for
12378 btrace_thread_info::functions now storing objects.
12379 * btrace.h (struct btrace_thread_info): Add constructor.
12380 (struct btrace_thread_info) <functions>: Make std::vector.
12381 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
12382 Initialize with default values.
12383 * record-btrace.c (record_btrace_frame_sniffer): Account for
12384 btrace_thread_info::functions now storing objects.
12385
12386 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12387
12388 * btrace.c: Remove typedef bfun_s.
12389 (ftrace_new_gap): Directly add gaps to the list of gaps.
12390 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
12391 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
12392 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
12393 instead of gdb VEC.
12394
12395 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12396
12397 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
12398 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
12399 with btrace_thread_info::next_segment and
12400 btrace_thread_info::prev_segment.
12401 * btrace.h: Remove struct btrace_func_link.
12402 (struct btrace_function): Replace pair of function segment pointers
12403 with pair of indices.
12404 * python/py-record-btrace.c (btpy_call_prev_sibling,
12405 btpy_call_next_sibling): Replace references to
12406 btrace_thread_info::segment with btrace_thread_info::next_segment and
12407 btrace_thread_info::prev_segment.
12408 * record-btrace.c (record_btrace_frame_this_id): Use
12409 btrace_find_call_by_number.
12410
12411 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12412
12413 * btrace.c (ftrace_new_function, ftrace_fixup_level,
12414 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
12415 btrace_insn_next, btrace_insn_prev): Remove references to
12416 btrace_thread_info::flow.
12417 * btrace.h (struct btrace_function): Remove FLOW.
12418
12419 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12420
12421 * btrace.c (ftrace_find_call_by_number): New function.
12422 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
12423 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
12424 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
12425 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
12426 index.
12427 * btrace.h (struct btrace_function): Turn UP into an index.
12428 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
12429 as an index.
12430 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
12431 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12432 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12433
12434 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12435
12436 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12437 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12438 ftrace_update_function, ftrace_compute_global_level_offset,
12439 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12440 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12441 btrace_insn_end, btrace_is_empty): Remove references to
12442 btrace_thread_info::begin and btrace_thread_info::end.
12443 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12444 (struct btrace_thread_info) <functions>: Adjust comment.
12445 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12446 btrace_thread_info::begin.
12447
12448 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12449
12450 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12451 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12452 ftrace_update_function): Remove arguments that implicitly were always
12453 BTINFO->END.
12454 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12455 Don't pass BTINFO->END.
12456
12457 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12458
12459 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12460 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12461 btrace_find_insn_by_number): Replace function segment pointer with
12462 index.
12463 (btrace_insn_cmp): Simplify.
12464 * btrace.h: (struct btrace_insn_iterator) Rename index to
12465 insn_index. Replace function segment pointer with index into function
12466 segment vector.
12467 * record-btrace.c (record_btrace_call_history): Replace function
12468 segment pointer use with index.
12469 (record_btrace_frame_sniffer): Retrieve function call segment through
12470 vector.
12471 (record_btrace_set_replay): Remove defunc't safety check.
12472
12473 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12474
12475 * btrace.c (btrace_ends_with_single_insn): New function.
12476 (btrace_call_get, btrace_call_number, btrace_call_begin,
12477 btrace_call_end, btrace_call_next, btrace_call_prev,
12478 btrace_find_call_by_number): Use index into call segment vector
12479 instead of pointer.
12480 (btrace_call_cmp): Simplify.
12481 * btrace.h (struct btrace_call_iterator): Replace function call segment
12482 pointer with index into vector.
12483 * record-btrace.c (record_btrace_call_history): Use index instead of
12484 pointer.
12485
12486 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12487
12488 * btrace.c (btrace_insn_begin, btrace_insn_end,
12489 btrace_find_insn_by_number): Add btinfo to iterator.
12490 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12491
12492 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12493
12494 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12495 and save pointers directly.
12496 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12497 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12498 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12499 changed signature of functions.
12500 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12501 (btrace_fetch): Remove code that adds btrace_function pointers to
12502 vector of btrace_functions.
12503 (btrace_clear): Simplify freeing vector of btrace_functions.
12504
12505 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12506
12507 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12508 Replace VEC_* with std::vector functions.
12509 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12510 (struct btrace_thread_info)<functions>: Change type to std::vector.
12511
12512 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12513
12514 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12515 "Removed targets and native configurations" up. Merge duplicate
12516 "New commands" sub-sections. Add "New options" sub-sections.
12517
12518 2017-05-26 Alan Hayward <alan.hayward@arm.com>
12519
12520 * defs.h (copy_integer_to_size): New declaration.
12521 * findvar.c (copy_integer_to_size): New function.
12522 (do_cint_test): New selftest function.
12523 (copy_integer_to_size_test): Likewise.
12524 (_initialize_findvar): Likewise.
12525 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12526 (mips_fbsd_collect_reg): Use raw_collect_integer.
12527 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12528 (mips64_fill_gregset): Use raw_collect_integer
12529 (mips64_fill_fpregset): Use raw_supply_integer.
12530 * regcache.c (regcache::raw_supply_integer): New function.
12531 (regcache::raw_collect_integer): Likewise.
12532 * regcache.h: (regcache::raw_supply_integer): New declaration.
12533 (regcache::raw_collect_integer): Likewise.
12534
12535 2017-05-24 Yao Qi <yao.qi@linaro.org>
12536
12537 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12538 (COMMON_OBS): Add gdbarch-selftests.o.
12539 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12540 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12541 * gdbarch-selftests.c: New file.
12542 * regcache.h (regcache) <~regcache>: Mark it virtual if
12543 GDB_SELF_TEST.
12544 <raw_write>: Likewise.
12545
12546 2017-05-24 Yao Qi <yao.qi@linaro.org>
12547
12548 * regcache.c (current_regcache): Change it to
12549 regcache::current_regcache.
12550 (regcache_observer_target_changed): Update.
12551 (regcache_thread_ptid_changed): Make it a regcache static
12552 method.
12553 (regcache_thread_ptid_changed): Update.
12554 (class regcache_access): New.
12555 (current_regcache_test): Update.
12556 (_initialize_regcache): Update.
12557 * regcache.h: Include forward_list.
12558 (regcache): Declare regcache_thread_ptid_changed and declare
12559 registers_changed_ptid as friend.
12560
12561 2017-05-24 Yao Qi <yao.qi@linaro.org>
12562
12563 * i387-tdep.c (i387_register_to_value): Use register_size
12564 instead of TYPE_LENGTH.
12565 * m68k-tdep.c (m68k_register_to_value): Likewise.
12566
12567 2017-05-24 Yao Qi <yao.qi@linaro.org>
12568
12569 * i387-tdep.c (i387_convert_register_p): Return false if type
12570 code isn't TYPE_CODE_FLT.
12571
12572 2017-05-24 Yao Qi <yao.qi@linaro.org>
12573
12574 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12575 length is 4.
12576 (alpha_register_to_value): Remove type length check.
12577 (alpha_value_to_register): Likewise.
12578
12579 2017-05-24 Yao Qi <yao.qi@linaro.org>
12580
12581 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12582 TYPE_CODE_FLT.
12583
12584 2017-05-24 Yao Qi <yao.qi@linaro.org>
12585
12586 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12587 TYPE_CODE_FLT or not.
12588
12589 2017-05-24 Yao Qi <yao.qi@linaro.org>
12590
12591 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12592 * avr-tdep.c (avr_gdbarch_init): Likewise.
12593 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12594 * cris-tdep.c (cris_gdbarch_init): Likewise.
12595 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12596 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12597 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12598 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12599 * mep-tdep.c (mep_gdbarch_init): Likewise.
12600 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12601 * mips-tdep.c (mips_gdbarch_init): Likewise.
12602 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12603 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12604 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12605 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12606 * v850-tdep.c (v850_gdbarch_init): Likewise.
12607
12608 2017-05-24 Yao Qi <yao.qi@linaro.org>
12609
12610 * selftest-arch.c (tests_with_arch): Call registers_changed
12611 and reinit_frame_cache.
12612 * selftest.c (run_self_tests): Likewise.
12613
12614 2017-05-24 Yao Qi <yao.qi@linaro.org>
12615
12616 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12617 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12618
12619 2017-05-24 Yao Qi <yao.qi@linaro.org>
12620
12621 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12622 set_gdbarch_print_insn.
12623
12624 2017-05-24 Yao Qi <yao.qi@linaro.org>
12625
12626 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12627 set_gdbarch_print_insn.
12628
12629 2017-05-24 Yao Qi <yao.qi@linaro.org>
12630
12631 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12632 set_gdbarch_print_insn.
12633 * arc-tdep.c (arc_gdbarch_init): Likewise.
12634 * arch-utils.c: include dis-asm.h.
12635 (default_print_insn): New function.
12636 * arch-utils.h (default_print_insn): Declare.
12637 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12638 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12639 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12640 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12641 * frv-tdep.c (frv_gdbarch_init): Likewise.
12642 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12643 * gdbarch.sh (print_insn): Use default_print_insn.
12644 * gdbarch.c: Regenerated.
12645 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12646 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12647 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12648 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12649 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12650 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12651 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12652 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12653 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12654 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12655 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12656 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12657 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12658 * mt-tdep.c (mt_gdbarch_init): Likewise.
12659 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12660 * nios2-tdep.c (nios2_print_insn): Remove.
12661 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12662 * rx-tdep.c (rx_gdbarch_init): Likewise.
12663 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12664 * score-tdep.c (score_print_insn): Remove.
12665 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12666 * sh-tdep.c (sh_gdbarch_init): Likewise.
12667 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12668 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12669 * tic6x-tdep.c (tic6x_print_insn): Remove.
12670 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12671 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12672 * v850-tdep.c (v850_gdbarch_init): Likewise.
12673 * vax-tdep.c (vax_gdbarch_init): Likewise.
12674 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12675 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12676
12677 2017-05-23 John Baldwin <jhb@FreeBSD.org>
12678
12679 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12680 (MIPS_FP0_REGNUM): Remove.
12681 (MIPS_FSR_REGNUM): Remove.
12682 (mips_fbsd_supply_fpregs): Use mips_regnum.
12683 (mips_fbsd_supply_gregs): Likewise.
12684 (mips_fbsd_collect_fpregs): Likewise.
12685 (mips_fbsd_collect_gregs): Likewise.
12686
12687 2017-05-23 John Baldwin <jhb@FreeBSD.org>
12688
12689 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12690 (getpfpregs_supplies): New function.
12691 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12692 getfpregs_supplies.
12693 (mips_fbsd_store_inferior_registers): Likewise.
12694
12695 2017-05-22 Pedro Alves <palves@redhat.com>
12696
12697 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12698 maintainer.
12699
12700 2017-05-22 Alan Hayward <alan.hayward@arm.com>
12701
12702 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12703 (store_register): Likewise.
12704 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12705 (get_decimal_float_return_value): Likewise.
12706 (do_ppc_sysv_return_value): Likewise.
12707 (ppc64_sysv_abi_push_integer): Likewise.
12708 (ppc64_sysv_abi_push_freg): Likewise.
12709 (ppc64_sysv_abi_return_value_base): Likewise.
12710 (ppc64_sysv_abi_return_value): Likewise.
12711 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12712 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12713 * rs6000-nat.c: Likewise.
12714 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12715 (rs6000_value_to_register): Likewise.
12716 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12717
12718 2017-05-21 Tom Tromey <tom@tromey.com>
12719
12720 PR rust/21466:
12721 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12722 arrays as "[T]", not "[T; ]".
12723
12724 2017-05-19 Tom Tromey <tom@tromey.com>
12725
12726 PR rust/21484:
12727 * rust-lang.c (exp_descriptor_rust): New function.
12728 (rust_language_defn): Use it.
12729 * p-lang.c (pascal_language_defn): Update.
12730 * opencl-lang.c (opencl_language_defn): Update.
12731 * objc-lang.c (objc_language_defn): Update.
12732 * m2-lang.c (m2_language_defn): Update.
12733 * language.h (struct language_defn)
12734 <la_watch_location_expression>: New member.
12735 * language.c (unknown_language_defn, auto_language_defn)
12736 (local_language_defn): Update.
12737 * go-lang.c (go_language_defn): Update.
12738 * f-lang.c (f_language_defn): Update.
12739 * d-lang.c (d_language_defn): Update.
12740 * c-lang.h (c_watch_location_expression): Declare.
12741 * c-lang.c (c_watch_location_expression): New function.
12742 (c_language_defn, cplus_language_defn, asm_language_defn)
12743 (minimal_language_defn): Use it.
12744 * breakpoint.c (watch_command_1): Call
12745 la_watch_location_expression.
12746 * ada-lang.c (ada_language_defn): Update.
12747
12748 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12749
12750 PR tui/21482
12751 * gdb_curses.h (NOMACROS): Define.
12752 (NCURSES_NOMACROS): Define.
12753
12754 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12755
12756 PR tui/21482
12757 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12758 arg to char *.
12759 * tui/tui-wingeneral.c (box_win): Likewise.
12760 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12761 (tui_show_source_line): Likewise.
12762 (tui_show_exec_info_content): Likewise.
12763
12764 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12765
12766 * sparc-tdep.c (sparc_structure_return_p)
12767 (sparc_arg_on_registers_p): New functions.
12768 (sparc32_store_arguments): Use them.
12769 * sparc64-tdep.c (sparc64_16_byte_align_p)
12770 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12771 Handle TYPE_CODE_ARRAY.
12772
12773 2017-05-17 Yao Qi <yao.qi@linaro.org>
12774
12775 * cli/cli-decode.c (add_alias_cmd): New function.
12776 * command.h (add_alias_cmd): Declare.
12777 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
12778 instead call add_alias_cmd.
12779
12780 2017-05-17 Pedro Alves <palves@redhat.com>
12781
12782 * Makefile.in (nat_extra_makefile_frag): Rename to ...
12783 (nat_makefile_frag): ... this. All references updated.
12784 * configure.ac: Likewise.
12785 * configure.nat: Likewise. Enhance comments.
12786 * configure: Regenerate.
12787
12788 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12789
12790 * procfs.c (procfs_create_inferior): Change prototype to match
12791 definition.
12792
12793 2017-05-13 Eli Zaretskii <eliz@gnu.org>
12794
12795 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
12796 C++ compiler warning.
12797
12798 2017-05-12 Tom Tromey <tom@tromey.com>
12799
12800 PR rust/21483:
12801 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
12802 recurse, just call value_struct_elt directly.
12803
12804 2017-05-12 Tom Tromey <tom@tromey.com>
12805
12806 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
12807 OP_RUST_ARRAY>: Fix.
12808
12809 2017-05-12 Tom Tromey <tom@tromey.com>
12810
12811 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
12812
12813 2017-05-09 Yao Qi <yao.qi@linaro.org>
12814
12815 * regcache.c: Include <forward_list>.
12816 (struct regcache_list): Remove.
12817 (current_regcache): Update.
12818 (get_thread_arch_aspace_regcache): Update for std::forward_list.
12819 (regcache_thread_ptid_changed): Likewise.
12820 (registers_changed_ptid): Likewise.
12821 (current_regcache_size): Likewise.
12822
12823 2017-05-09 Yao Qi <yao.qi@linaro.org>
12824
12825 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
12826 (current_regcache_size): New function.
12827 (current_regcache_test): New function.
12828 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
12829
12830 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12831
12832 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
12833 (print_gp_register_row): Use get_frame_register_value.
12834
12835 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12836
12837 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
12838 (mips_supply_fpregset): Likewise.
12839 (mips64_supply_gregset): Likewise.
12840
12841 2017-05-08 Alan Hayward <alan.hayward@arm.com>
12842
12843 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
12844 regcache->raw_supply_zeroed.
12845
12846 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12847
12848 * configure.nat: Rearrange 'case' statements to match
12849 host before cpu.
12850
12851 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12852
12853 * Makefile.in: Remove "@host_makefile_frag@". Add variables
12854 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
12855 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
12856 "@nat_extra_makefile_frag@".
12857 (Makefile): Remove dependency on "@frags@".
12858 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
12859 (data-directory/Makefile): Likewise.
12860 * config/aarch64/linux.mh: Deleted; moved contents to
12861 "gdb/configure.nat".
12862 * config/alpha/alpha-linux.mh: Likewise.
12863 * config/alpha/nbsd.mh: Likewise.
12864 * config/arm/linux.mh: Likewise.
12865 * config/arm/nbsdelf.mh: Likewise.
12866 * config/i386/cygwin.mh: Likewise.
12867 * config/i386/cygwin64.mh: Likewise.
12868 * config/i386/darwin.mh: Likewise.
12869 * config/i386/fbsd.mh: Likewise.
12870 * config/i386/fbsd64.mh: Likewise.
12871 * config/i386/go32.mh: Likewise.
12872 * config/i386/i386gnu.mh: Likewise.
12873 * config/i386/i386sol2.mh: Likewise.
12874 * config/i386/linux.mh: Likewise.
12875 * config/i386/linux64.mh: Likewise.
12876 * config/i386/mingw.mh: Likewise.
12877 * config/i386/mingw64.mh: Likewise.
12878 * config/i386/nbsd64.mh: Likewise.
12879 * config/i386/nbsdelf.mh: Likewise.
12880 * config/i386/nto.mh: Likewise.
12881 * config/i386/obsd.mh: Likewise.
12882 * config/i386/obsd64.mh: Likewise.
12883 * config/i386/sol2-64.mh: Likewise.
12884 * config/ia64/linux.mh: Likewise.
12885 * config/m32r/linux.mh: Likewise.
12886 * config/m68k/linux.mh: Likewise.
12887 * config/m68k/nbsdelf.mh: Likewise.
12888 * config/m68k/obsd.mh: Likewise.
12889 * config/m88k/obsd.mh: Likewise.
12890 * config/mips/fbsd.mh: Likewise.
12891 * config/mips/linux.mh: Likewise.
12892 * config/mips/nbsd.mh: Likewise.
12893 * config/mips/obsd64.mh: Likewise.
12894 * config/pa/linux.mh: Likewise.
12895 * config/pa/nbsd.mh: Likewise.
12896 * config/pa/obsd.mh: Likewise.
12897 * config/powerpc/aix.mh: Likewise.
12898 * config/powerpc/fbsd.mh: Likewise.
12899 * config/powerpc/linux.mh: Likewise.
12900 * config/powerpc/nbsd.mh: Likewise.
12901 * config/powerpc/obsd.mh: Likewise.
12902 * config/powerpc/ppc64-linux.mh: Likewise.
12903 * config/powerpc/spu-linux.mh: Likewise.
12904 * config/s390/linux.mh: Likewise.
12905 * config/sh/nbsd.mh: Likewise.
12906 * config/sparc/fbsd.mh: Likewise.
12907 * config/sparc/linux.mh: Likewise.
12908 * config/sparc/linux64.mh: Likewise.
12909 * config/sparc/nbsd64.mh: Likewise.
12910 * config/sparc/nbsdelf.mh: Likewise.
12911 * config/sparc/obsd64.mh: Likewise.
12912 * config/sparc/sol2.mh: Likewise.
12913 * config/tilegx/linux.mh: Likewise.
12914 * config/vax/nbsdelf.mh: Likewise.
12915 * config/vax/obsd.mh: Likewise.
12916 * config/xtensa/linux.mh: Likewise.
12917 * config/i386/i386gnu.mn: New file, with excerpts from
12918 "config/i386/i386gnu.mh".
12919 * configure: Regenerate.
12920 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
12921 *.mh files under "gdb/config".
12922 * configure.nat: New file, with contents from the
12923 "gdb/config/*/*.mh" files.
12924
12925 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
12926
12927 * btrace.c (btrace_clear): Free insn vector.
12928
12929 2017-05-05 Pedro Alves <palves@redhat.com>
12930
12931 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
12932 * configure: Regenerate.
12933
12934 2017-05-04 Pedro Alves <palves@redhat.com>
12935
12936 * Makefile.in (SFILES): Add progspace-and-thread.c.
12937 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
12938 (COMMON_OBS): Add progspace-and-thread.o.
12939 * breakpoint.c: Include "progspace-and-thread.h".
12940 (update_inserted_breakpoint_locations)
12941 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
12942 Use scoped_restore_current_pspace_and_thread.
12943 (create_std_terminate_master_breakpoint): Use
12944 scoped_restore_current_program_space.
12945 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
12946 (print_breakpoint_location): Use
12947 scoped_restore_current_program_space.
12948 (bp_loc_is_permanent): Use
12949 scoped_restore_current_pspace_and_thread.
12950 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
12951 (download_tracepoint_locations): Use
12952 scoped_restore_current_pspace_and_thread.
12953 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
12954 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
12955 (enum step_over_calls_kind): Moved from inferior.h.
12956 (class scoped_restore_current_thread): New class.
12957 * gdbthread.h (make_cleanup_restore_current_thread): Delete
12958 declaration.
12959 (scoped_restore_current_thread): New class.
12960 * infcmd.c: Include "common/gdb_optional.h".
12961 (continue_1, proceed_after_attach): Use
12962 scoped_restore_current_thread.
12963 (notice_new_inferior): Use scoped_restore_current_thread.
12964 * inferior.c: Include "progspace-and-thread.h".
12965 (restore_inferior, save_current_inferior): Delete.
12966 (add_inferior_command, clone_inferior_command): Use
12967 scoped_restore_current_pspace_and_thread.
12968 * inferior.h (scoped_restore_current_inferior): New class.
12969 * infrun.c: Include "progspace-and-thread.h" and
12970 "common/gdb_optional.h".
12971 (follow_fork_inferior): Use
12972 scoped_restore_current_pspace_and_thread.
12973 (scoped_restore_exited_inferior): New class.
12974 (handle_vfork_child_exec_or_exit): Use
12975 scoped_restore_exited_inferior,
12976 scoped_restore_current_pspace_and_thread,
12977 scoped_restore_current_thread and scoped_restore.
12978 (fetch_inferior_event): Use scoped_restore_current_thread.
12979 * linespec.c (decode_line_full, decode_line_1): Use
12980 scoped_restore_current_program_space.
12981 * mi/mi-main.c: Include "progspace-and-thread.h".
12982 (exec_continue): Use scoped_restore_current_thread.
12983 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
12984 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
12985 * proc-service.c (ps_pglobal_lookup): Use
12986 scoped_restore_current_program_space.
12987 * progspace-and-thread.c: New file.
12988 * progspace-and-thread.h: New file.
12989 * progspace.c (release_program_space, clone_program_space): Use
12990 scoped_restore_current_program_space.
12991 (restore_program_space, save_current_program_space)
12992 (save_current_space_and_thread): Delete.
12993 (switch_to_program_space_and_thread): Moved to
12994 progspace-and-thread.c.
12995 * progspace.h (save_current_program_space)
12996 (save_current_space_and_thread): Delete declarations.
12997 (scoped_restore_current_program_space): New class.
12998 * remote.c (remote_btrace_maybe_reopen): Use
12999 scoped_restore_current_thread.
13000 * symtab.c: Include "progspace-and-thread.h".
13001 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
13002 * thread.c (print_thread_info_1): Use
13003 scoped_restore_current_thread.
13004 (struct current_thread_cleanup): Delete.
13005 (do_restore_current_thread_cleanup)
13006 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
13007 (scoped_restore_current_thread::~scoped_restore_current_thread):
13008 ... this new dtor.
13009 (make_cleanup_restore_current_thread): Rename/convert to ...
13010 (scoped_restore_current_thread::scoped_restore_current_thread):
13011 ... this new ctor.
13012 (thread_apply_all_command): Use scoped_restore_current_thread.
13013 (thread_apply_command): Use scoped_restore_current_thread.
13014 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
13015 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
13016
13017 2017-05-04 Pedro Alves <palves@redhat.com>
13018
13019 * thread.c (make_cleanup_restore_current_thread): Move
13020 find_thread_ptid call before the is_stopped call. Assert that the
13021 thread is found. Replace is_stopped call by checking the thread's
13022 state directly. Remove unnecessary NULL-thread check.
13023
13024 2017-05-04 Pedro Alves <palves@redhat.com>
13025
13026 * corelow.c (thread_section_name): New class.
13027 (get_core_register_section, get_core_siginfo): Use it.
13028
13029 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
13030
13031 * corelow.c (sniff_core_bfd): Remove extra semicolon.
13032 (get_core_register_section): Remove xfree of NULL pointer.
13033
13034 2017-05-03 Alan Hayward <alan.hayward@arm.com>
13035
13036 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
13037 * regcache.c (regcache::raw_supply_zeroed): New function.
13038 * regcache.h (regcache::raw_supply_zeroed): New declaration.
13039
13040 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
13041
13042 * gdbarch.sh: Remove commented out definition of
13043 TARGET_CHAR_BIT.
13044 * gdbarch.h: Re-generate.
13045
13046 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
13047
13048 * configure: Regenerate.
13049
13050 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
13051
13052 * solib-target.c (solib_target_relocate_section_addresses):
13053 Remove num_section_bases, num_bases, segment_bases variables.
13054
13055 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13056
13057 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
13058
13059 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13060
13061 * solib-target.c: Include <vector>
13062 (struct lm_info_target) <~lm_info_target>: Remove.
13063 <segment_bases, section_bases>: Change type to
13064 std::vector<CORE_ADDR>.
13065 (library_list_start_segment, library_list_start_section,
13066 library_list_end_library,
13067 solib_target_relocate_section_addresses): Adjust.
13068
13069 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13070
13071 * gdbarch.sh (software_single_step): Change return type to
13072 std::vector<CORE_ADDR>.
13073 * gdbarch.c, gdbarch.h: Re-generate.
13074 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
13075 Adjust.
13076 (arm_deal_with_atomic_sequence_raw): Adjust.
13077 (thumb_get_next_pcs_raw): Adjust.
13078 (arm_get_next_pcs_raw): Adjust.
13079 (arm_get_next_pcs): Adjust.
13080 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
13081 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
13082 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
13083 (alpha_software_single_step): Adjust.
13084 * alpha-tdep.h (alpha_software_single_step): Adjust.
13085 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
13086 * arm-tdep.c (arm_software_single_step): Adjust.
13087 (arm_breakpoint_kind_from_current_state): Adjust.
13088 * arm-tdep.h (arm_software_single_step): Adjust.
13089 * breakpoint.c (insert_single_step_breakpoint): Adjust.
13090 * cris-tdep.c (cris_software_single_step): Adjust.
13091 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
13092 (micromips_deal_with_atomic_sequence): Adjust.
13093 (deal_with_atomic_sequence): Adjust.
13094 (mips_software_single_step): Adjust.
13095 * mips-tdep.h (mips_software_single_step): Adjust.
13096 * moxie-tdep.c (moxie_software_single_step): Adjust.
13097 * nios2-tdep.c (nios2_software_single_step): Adjust.
13098 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
13099 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
13100 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
13101 * s390-linux-tdep.c (s390_software_single_step): Adjust.
13102 * sparc-tdep.c (sparc_software_single_step): Adjust.
13103 * spu-tdep.c (spu_software_single_step): Adjust.
13104 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
13105
13106 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13107
13108 * gdbarch.sh: Use semi-colon as field separator instead of colon.
13109 * gdbarch.h: Re-generate.
13110
13111 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13112
13113 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
13114 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
13115 * python/py-instruction.c, python/py-instruction.h: New file.
13116 * python/py-record.c: Add py-instruction.h include.
13117 (gdbpy_initialize_record): Make gdb.Instruction a super class of
13118 gdb.RecordInstruction.
13119 * python/python-internal.h: Add gdbpy_initialize_instruction
13120 declaration.
13121 * python/python.c (do_start_initialization): Add
13122 gdbpy_initialize_instruction.
13123
13124 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13125
13126 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
13127 Remove.
13128 (btrace_func_from_recpy_func): New function.
13129 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
13130 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
13131 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
13132 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
13133 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
13134 Also, use new helper functions.
13135 (btpy_list_item): Use new helper functions.
13136 (recpy_bt_function_call_history): Use new type name.
13137 (btpy_call_getset): Remove.
13138 (gdbpy_initialize_btrace): Remove code to initialize
13139 gdb.BtraceFunctionCall.
13140 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
13141 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
13142 recpy_bt_func_prev, recpy_bt_func_next): New export.
13143 * python/py-record.c (recpy_func_type): New static object.
13144 (recpy_func_new, recpy_func_level, recpy_func_symbol,
13145 recpy_func_instructions, recpy_func_up, recpy_func_prev,
13146 recpy_func_next): New function.
13147 (recpy_element_hash, recpy_element_richcompare): Updated comment.
13148 (recpy_func_getset): New static object.
13149 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
13150 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
13151
13152 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13153
13154 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
13155 (btpy_object, btpy_insn_type, btpy_new): Remove.
13156 (btpy_list_object): Use gdb.RecordInstruction type instead of
13157 gdb.BtraceInstruction type.
13158 (btrace_insn_from_recpy_insn): New function.
13159 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
13160 btpy_new.
13161 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
13162 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
13163 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
13164 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
13165 instead of btpy_object.
13166 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13167 btpy_insn_data, btpy_insn_decode): Rename to ...
13168 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
13169 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
13170 recpy_bt_insn_decode): This. Also, use new helper functions.
13171 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
13172 recpy_insn_type.
13173 (btpy_insn_getset): Remove.
13174 (gdbpy_initialize_btrace): Remove code to initialize
13175 gdb.BtraceInstruction. Use recpy_element_object.
13176 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
13177 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
13178 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
13179 * python/py-record.c (recpy_insn_type): New static object.
13180 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
13181 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
13182 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
13183 New function.
13184 (recpy_insn_getset): New static object.
13185 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
13186 * python/py-record.h (recpy_element_object): New typedef.
13187 (recpy_insn_type, recpy_insn_new): New export.
13188
13189 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13190
13191 * py-record-btrace.c (btpy_insn_new): Removed.
13192 (btpy_insn_or_gap_new): New function.
13193 (btpy_insn_error): Removed.
13194 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13195 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
13196 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
13197 btpy_insn_or_gap_new instead of btpy_insn_new.
13198 (btpy_insn_getset): Remove btpy_insn_error.
13199 * py-record.c (recpy_gap_type): New static object.
13200 (recpy_gap_object): New typedef.
13201 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
13202 recpy_gap_reason_string): New function.
13203 (recpy_gap_getset): New static object.
13204 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
13205 * py-record.h (recpy_gap_new): New export.
13206
13207 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13208
13209 * python/py-record.c (recpy_ptid): Remove.
13210 (recpy_record_getset): Remove recpy_ptid.
13211
13212 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13213
13214 * btrace.c (btrace_fetch): Set inferior_ptid.
13215 * python/py-record-btrace.c: Add "py-record.h" include.
13216 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
13217 recpy_bt_end, recpy_bt_instruction_history,
13218 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
13219 in gdb.Record object instead of current ptid.
13220 * python/py-record.c: Include new "py-record.h" file.
13221 (recpy_record_object): Moved to py-record.h.
13222 * python/py-record.h: New file.
13223
13224 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13225
13226 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
13227 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
13228 indentation.
13229
13230 2017-05-01 Joel Brobecker <brobecker@adacore.com>
13231
13232 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
13233 the past maintainers section.
13234
13235 2017-04-28 Yao Qi <yao.qi@linaro.org>
13236
13237 * infcmd.c (get_return_value): Use regcache ctor, and remove
13238 cleanup.
13239
13240 2017-04-28 Yao Qi <yao.qi@linaro.org>
13241 Pedro Alves <palves@redhat.com>
13242
13243 * regcache.c (regcache::regcache): New tag dispatch ctor.
13244 (do_cooked_read): Moved above.
13245 (regcache_dup): Use the tag dispatch ctor..
13246 * regcache.h (regcache): Declare ctor, delete copy ctor and
13247 assignment operator, remove friend regcache_dup.
13248
13249 2017-04-28 Yao Qi <yao.qi@linaro.org>
13250
13251 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
13252 call method save instead of regcache_cpy.
13253 * regcache.h (struct regcache): Make regcache_dup a friend.
13254
13255 2017-04-28 Yao Qi <yao.qi@linaro.org>
13256
13257 * regcache.c (struct regcache): Move to regcache.h
13258 (regcache::arch): New method.
13259 (regcache_get_ptid): Update.
13260 (get_regcache_arch): Call arch method.
13261 (get_regcache_aspace): Call method aspace.
13262 (register_buffer): Change it to method.
13263 (regcache_save): Change it to regcache::save.
13264 (regcache_restore): Likewise.
13265 (regcache_cpy_no_passthrough): Remove the declaration.
13266 (regcache_cpy): Call methods restore and cpy_no_passthrough.
13267 (regcache_cpy_no_passthrough): Change it to method
13268 cpy_no_passthrough.
13269 (regcache_register_status): Change it to method
13270 get_register_status.
13271 (regcache_invalidate): Change it to method invalidate.
13272 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
13273 (regcache_raw_update): Change it to method raw_update.
13274 (regcache_raw_read): Likewise.
13275 (regcache_raw_read_signed): Likewise.
13276 (regcache_raw_read_unsigned): Likewise.
13277 (regcache_raw_write_signed): Likewise.
13278 (regcache_raw_write_unsigned): Likewise.
13279 (regcache_cooked_read): Likewise.
13280 (regcache_cooked_read_value): Likewise.
13281 (regcache_cooked_read_signed): Likewise.
13282 (regcache_cooked_read_unsigned): Likewise.
13283 (regcache_cooked_write_signed): Likewise.
13284 (regcache_cooked_write_unsigned): Likewise.
13285 (regcache_raw_set_cached_value): Likewise.
13286 (regcache_raw_write): Likewise.
13287 (regcache_cooked_write): Likewise.
13288 (regcache_xfer_part): Likewise.
13289 (regcache_raw_read_part): Likewise.
13290 (regcache_raw_write_part): Likewise.
13291 (regcache_cooked_read_part): Likewise.
13292 (regcache_cooked_write_part): Likewise.
13293 (regcache_raw_supply): Likewise.
13294 (regcache_raw_collect): Likewise.
13295 (regcache_transfer_regset): Likewise.
13296 (regcache_supply_regset): Likewise.
13297 (regcache_collect_regset): Likewise.
13298 (regcache_debug_print_register): Likewise.
13299 (enum regcache_dump_what): Move it to regcache.h.
13300 (regcache_dump): Change it to method dump.
13301 * regcache.h (enum regcache_dump_what): New.
13302 (class regcache): New.
13303 * target.c (target_fetch_registers): Call method
13304 debug_print_register.
13305 (target_store_registers): Likewise.
13306
13307 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13308
13309 * windows-nat.c (struct lm_info_windows): Initialize field.
13310 (windows_make_so): Allocate lm_info_windows with new.
13311 (windows_free_so): Free lm_info_windows with delete.
13312
13313 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13314
13315 * solib-darwin.c (struct lm_info_darwin): Initialize field.
13316 (darwin_current_sos): Allocate lm_info_darwin with new, remove
13317 cleanup.
13318 (darwin_free_so): Free lm_info_darwin with delete.
13319
13320 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13321
13322 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
13323 <l_addr_p>: Change type to bool.
13324 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
13325 (svr4_free_so): Free lm_info_svr4 with delete.
13326 (svr4_copy_library_list): Replace memcpy with call to copy
13327 constructor.
13328 (library_list_start_library, svr4_default_sos): Allocate
13329 lm_info_svr4 with new.
13330
13331 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13332
13333 * solib-target.c (struct lm_info_target): Add destructor,
13334 initialize fields.
13335 <name>: Change type to std::string.
13336 (library_list_start_library): Allocate lm_info_target with new.
13337 (solib_target_free_library_list): Free lm_info_target with
13338 delete.
13339 (solib_target_current_sos): Adapt to std::string.
13340 (solib_target_free_so): Free lm_info_target with delete.
13341
13342 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13343
13344 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
13345 fields.
13346 (frv_current_sos): Allocate lm_info_frv with new.
13347 (frv_relocate_main_executable): Free lm_info_frv with delete,
13348 allocate with new.
13349 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
13350
13351 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13352
13353 * solib-frv.c (struct lm_info_frv): Fix indentation.
13354
13355 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13356
13357 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
13358 map field.
13359 (dsbt_current_sos): Allocate lm_info_dsbt with new.
13360 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
13361 and allocate with new.
13362 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
13363
13364 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13365
13366 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
13367 <filename, member_name>: Change type to std::string.
13368 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
13369 (library_list_start_library): Allocate lm_info_aix with new.
13370 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
13371 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
13372 with copy constructor.
13373
13374 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13375
13376 * solist.h (struct lm_info): Remove.
13377 (struct lm_info_base): New class.
13378 (struct so_list) <lm_info>: Change type to lm_info_base *.
13379 * nto-tdep.c (struct lm_info): Remove.
13380 (lm_addr): Adjust.
13381 * solib-aix.c (struct lm_info): Rename to ...
13382 (struct lm_info_aix): ... this. Extend lm_info_base.
13383 (lm_info_p): Rename to ...
13384 (lm_info_aix_p): ... this, and adjust.
13385 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
13386 solib_aix_parse_libraries, library_list_start_library,
13387 solib_aix_free_library_list, solib_aix_parse_libraries,
13388 solib_aix_get_library_list,
13389 solib_aix_relocate_section_addresses, solib_aix_free_so,
13390 solib_aix_get_section_offsets,
13391 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
13392 Adjust.
13393 (struct solib_aix_inferior_data) <library_list>: Adjust.
13394 * solib-darwin.c (struct lm_info): Rename to ...
13395 (struct lm_info_darwin): ... this. Extend lm_info_base.
13396 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
13397 * solib-dsbt.c (struct lm_info): Rename to ...
13398 (struct lm_info_dsbt): ... this. Extend lm_info_base.
13399 (struct dsbt_info) <main_executable_lm_info): Adjust.
13400 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
13401 dsbt_relocate_section_addresses): Adjust.
13402 * solib-frv.c (struct lm_info): Rename to ...
13403 (struct lm_info_frv): ... this. Extend lm_info_base.
13404 (main_executable_lm_info): Adjust.
13405 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
13406 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
13407 find_canonical_descriptor_in_load_object,
13408 frv_fdpic_find_canonical_descriptor): Adjust.
13409 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
13410 to lm_info_svr4.
13411 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
13412 svr4_clear_so, svr4_copy_library_list,
13413 library_list_start_library, svr4_default_sos, svr4_read_so_list,
13414 svr4_current_sos, svr4_fetch_objfile_link_map,
13415 solist_update_incremental): Adjust.
13416 * solib-svr4.h (struct lm_info_svr4): Move here from
13417 solib-svr4.c.
13418 * solib-target.c (struct lm_info): Rename to ...
13419 (struct lm_info_target): ... this. Extend lm_info_base.
13420 (lm_info_p): Rename to ...
13421 (lm_info_target_p): ... this.
13422 (solib_target_parse_libraries, library_list_start_segment,
13423 library_list_start_section, library_list_start_library,
13424 library_list_end_library, solib_target_free_library_list,
13425 solib_target_current_sos, solib_target_free_so,
13426 solib_target_relocate_section_addresses): Adjust.
13427 * windows-nat.c (struct lm_info): Rename to ...
13428 (struct lm_info_windows): ... this. Extend lm_info_base.
13429 (windows_make_so, handle_load_dll, handle_unload_dll,
13430 windows_xfer_shared_libraries): Adjust.
13431
13432 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13433
13434 * solib-darwin.c (struct darwin_so_list): Remove.
13435 (darwin_current_sos): Allocate an so_list object instead of a
13436 darwin_so_list, separately allocate an lm_info object.
13437 (darwin_free_so): Free lm_info.
13438
13439 2017-04-28 John Baldwin <jhb@FreeBSD.org>
13440
13441 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13442 with fprintf_filtered.
13443
13444 2017-04-28 Yao Qi <yao.qi@linaro.org>
13445
13446 * regcache.c (regcache::regcache): New function.
13447 (regcache::~regcache): New function.
13448 (regcache_xmalloc_1): Remove.
13449 (regcache_xmalloc): Call new regcache.
13450 (regcache_xfree): Call delete regcache.
13451 (get_thread_arch_aspace_regcache): Call new regcache.
13452
13453 2017-04-28 Yao Qi <yao.qi@linaro.org>
13454
13455 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13456 lwp instead of ptid_get_lwp.
13457
13458 2017-04-28 Yao Qi <yao.qi@linaro.org>
13459
13460 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13461 lwp_info instead of getting from inferior_ptid.
13462
13463 2017-04-27 Keith Seitz <keiths@redhat.com>
13464
13465 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13466 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13467 (CV_CONVERSION_BADNESS): Define.
13468 (rank_one_type): Remove overly restrictive rvalue reference
13469 rank checks.
13470 Add cv-qualifier checks and subranks for type equality.
13471 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13472 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13473 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13474
13475 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13476
13477 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13478 count when creating the object.
13479
13480 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13481 Ulrich Weigand <uweigand@de.ibm.com>
13482
13483 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13484 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13485 is used in AIX.
13486 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13487 (process_xcoff_symbol): Likewise.
13488 (scan_xcoff_symtab): Likewise.
13489
13490 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13491
13492 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13493 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13494 (ia64_access_reg): Use get_frame_register_unsigned.
13495 (ia64_access_rse_reg): Likewise.
13496 (ia64_libunwind_frame_prev_register): Likewise.
13497
13498 2017-04-26 Jiong Wang <jiong.wang@arm.com>
13499
13500 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13501 * gdbarch.c: Regenerated.
13502 * gdbarch.h: Regenerated.
13503 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13504 visibility external.
13505 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13506 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13507 (enum cfa_how_kind): Move to ...
13508 (struct dwarf2_frame_state_reg_info): Likewise.
13509 (struct dwarf2_frame_state): Likewise.
13510 * dwarf2-frame.h: ... here.
13511 (dwarf2_frame_state_alloc_regs): New declaration.
13512 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13513 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13514
13515 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13516
13517 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13518 regcache_raw_read_unsigned.
13519 (xtensa_pseudo_register_write): Likewise.
13520
13521 2017-04-26 Alan Hayward <alan.hayward@arm.com>
13522
13523 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13524 (nds32_pseudo_register_write): Likewise.
13525
13526 2017-04-25 Yao Qi <yao.qi@linaro.org>
13527
13528 * regcache.c (struct regcache) <readonly_p>: Change its type
13529 to bool.
13530 (regcache_xmalloc_1): Update parameter type and callers update.
13531
13532 2017-04-25 Yao Qi <yao.qi@linaro.org>
13533
13534 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13535 set_gdbarch_wchar_bit.
13536 * arm-tdep.c (arm_gdbarch_init): Likewise.
13537
13538 2017-04-25 Pedro Alves <palves@redhat.com>
13539
13540 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13541 (BothAreRelocatable, memcopy, memmove): Don't define.
13542 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13543 macros.
13544
13545 2017-04-25 Pedro Alves <palves@redhat.com>
13546
13547 * common/common-defs.h: Include "common/poison.h".
13548 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13549 and adjust.
13550 * common/poison.h: New file.
13551 * common/traits.h: Include <type_traits>.
13552 (Not, Or, Requires): New, moved from common/function-view.h.
13553
13554 2017-04-25 Pedro Alves <palves@redhat.com>
13555
13556 * breakpoint.h (struct breakpoint): In-class initialize all
13557 fields. Make boolean fields "bool".
13558 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13559 memset call and initializations no longer necessary.
13560
13561 2017-04-25 Pedro Alves <palves@redhat.com>
13562
13563 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13564 reference.
13565 (pt_btrace_insn): New function.
13566 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13567
13568 2017-04-25 Pedro Alves <palves@redhat.com>
13569
13570 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13571 "base" field and inherit from "bp_location" instead. Add
13572 non-default ctor.
13573 (allocate_location_exception): Use new non-default ctor.
13574 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13575 (init_bp_location): Convert to ...
13576 (bp_location::bp_location): ... this new ctor, and remove memset
13577 call.
13578 (base_breakpoint_allocate_location): Use the new non-default ctor.
13579 * breakpoint.h (bp_location): Now a class. Declare default and
13580 non-default ctors. In-class initialize all members.
13581 (init_bp_location): Remove declaration.
13582
13583 2017-04-25 Pedro Alves <palves@redhat.com>
13584
13585 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13586 assignment operator.
13587
13588 2017-04-24 Yao Qi <yao.qi@linaro.org>
13589
13590 * doublest.c (convert_doublest_to_floatformat): Call
13591 floatformat_totalsize_bytes.
13592
13593 2017-04-22 Tom Tromey <tom@tromey.com>
13594
13595 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13596 ui_out_emit_list.
13597 * stack.c (print_frame): Use ui_out_emit_list.
13598 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13599 ui_out_emit_list.
13600 * mi/mi-main.c (print_one_inferior)
13601 (mi_cmd_data_list_register_names)
13602 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13603 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13604 ui_out_emit_list.
13605 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13606 (mi_output_solib_attribs): Use ui_out_emit_list,
13607 ui_out_emit_tuple.
13608 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13609 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13610 (mi_cmd_stack_list_args, list_args_or_locals): Use
13611 ui_out_emit_list.
13612 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13613 * breakpoint.c (print_solib_event, output_thread_groups): Use
13614 ui_out_emit_list.
13615
13616 2017-04-22 Tom Tromey <tom@tromey.com>
13617
13618 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13619 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13620 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13621
13622 2017-04-22 Tom Tromey <tom@tromey.com>
13623
13624 * tracepoint.c (tvariables_info_1)
13625 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13626
13627 2017-04-22 Tom Tromey <tom@tromey.com>
13628
13629 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13630 annotate_arg_emitter.
13631 * breakpoint.c (print_mention_watchpoint)
13632 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13633 * annotate.h (struct annotate_arg_emitter): New.
13634
13635 2017-04-22 Tom Tromey <tom@tromey.com>
13636
13637 * record-btrace.c (record_btrace_insn_history)
13638 (record_btrace_insn_history_range, record_btrace_call_history)
13639 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13640 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13641 ui_out_emit_tuple.
13642 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13643 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13644 * skip.c (skip_info): Use ui_out_emit_tuple.
13645 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13646 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13647 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13648 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13649 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13650 ui_out_emit_tuple.
13651 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13652 (output_register, mi_cmd_data_read_memory)
13653 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13654 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13655 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13656 Use ui_out_emit_tuple.
13657 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13658 ui_out_emit_tuple.
13659 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13660 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13661 * linux-thread-db.c (info_auto_load_libthread_db): Use
13662 ui_out_emit_tuple.
13663 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13664 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13665 * disasm.c (do_mixed_source_and_assembly_deprecated)
13666 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13667 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13668 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13669 * breakpoint.c (print_one_breakpoint_location)
13670 (print_one_breakpoint): Use ui_out_emit_tuple.
13671 * auto-load.c (print_script, info_auto_load_cmd): Use
13672 ui_out_emit_tuple.
13673 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13674
13675 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13676
13677 * thread.c (print_thread_info_1): Remove dead code.
13678
13679 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13680
13681 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13682 GDB_SELF_TEST.
13683 * arm-tdep.c (selftests::arm_record_test): Likewise.
13684
13685 2017-04-21 Yao Qi <yao.qi@linaro.org>
13686
13687 * regcache.c (regcache_restore): Remove argument 2. Replace
13688 argument 3 with regcache. Get register status from
13689 src->register_status and get register contents from
13690 register_buffer (src, regnum).
13691 (regcache_cpy): Update.
13692
13693 2017-04-19 Pedro Alves <palves@redhat.com>
13694
13695 * gdbthread.h (thread): Add missing closing parenthesis in
13696 comment.
13697
13698 2017-04-19 Pedro Alves <palves@redhat.com>
13699
13700 * common/refcounted-object.h: New file.
13701 * gdbthread.h: Include "common/refcounted-object.h".
13702 (thread_info): Inherit from refcounted_object and add comments.
13703 (thread_info::incref, thread_info::decref)
13704 (thread_info::m_refcount): Delete.
13705 (thread_info::deletable): Use the refcounted_object::refcount()
13706 method.
13707 * inferior.c (current_inferior_): Add comment.
13708 (set_current_inferior): Increment/decrement refcounts.
13709 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13710 not-deletable instead of comparing with the current inferior.
13711 (initialize_inferiors): Increment the initial inferior's refcount.
13712 * inferior.h (struct inferior): Forward declare.
13713 Include "common/refcounted-object.h".
13714 (current_inferior, set_current_inferior): Move declaration to
13715 before struct inferior's definition, and fix comment.
13716 (inferior): Inherit from refcounted_object. Add comments.
13717 * thread.c (switch_to_thread_no_regs): Reference the thread's
13718 inferior pointer directly instead of doing a ptid lookup.
13719 (switch_to_no_thread): New function.
13720 (switch_to_thread(thread_info *)): New function, factored out
13721 from ...
13722 (switch_to_thread(ptid_t)): ... this.
13723 (restore_current_thread): Delete.
13724 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13725 fields, and add 'inf' field.
13726 (do_restore_current_thread_cleanup): Check whether old->inf is
13727 alive instead of looking up an inferior by ptid. Use
13728 switch_to_thread and switch_to_no_thread.
13729 (restore_current_thread_cleanup_dtor): Use old->inf directly
13730 instead of lookup up an inferior by id. Decref the inferior.
13731 Don't restore 'removable'.
13732 (make_cleanup_restore_current_thread): Same the inferior pointer
13733 in old, instead of the inferior number. Incref the inferior.
13734 Don't save/clear 'removable'.
13735
13736 2017-04-19 Pedro Alves <palves@redhat.com>
13737
13738 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13739 unittests/scoped_restore-selftests.c.
13740 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13741 * common/scoped_restore.h (scoped_restore_base): Make "class".
13742 (scoped_restore_base::release): New public method.
13743 (scoped_restore_base::scoped_restore_base): New protected ctor.
13744 (scoped_restore_base::m_saved_var): New protected field.
13745 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13746 scoped_restore_base base class instead of m_saved_var directly.
13747 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13748 (scoped_restore_tmpl::scoped_restore_tmpl(const
13749 scoped_restore_tmpl<T>&)): Likewise.
13750 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13751 method.
13752 (scoped_restore_tmpl::saved_var): New method.
13753 (scoped_restore_tmpl::m_saved_var): Delete.
13754 * inferior.h (inferior::detaching): Now a bool.
13755 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13756 cleanup.
13757 * unittests/scoped_restore-selftests.c: New file.
13758
13759 2017-04-19 Pedro Alves <palves@redhat.com>
13760
13761 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13762 Re-sort in alphabetic order.
13763
13764 2017-04-18 Pedro Alves <palves@redhat.com>
13765
13766 * xml-support.c (obstack_xml_printf): Delete.
13767 * xml-support.h (obstack_xml_printf): Delete.
13768
13769 2017-04-18 Pedro Alves <palves@redhat.com>
13770
13771 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13772 vdebug, verror, body_text, start_element, end_element, name,
13773 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13774 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13775 is_xinclude>: Make private and add m_ prefix.
13776 (gdb_xml_parser::body_text): New method, based on ...
13777 (gdb_xml_body_text): ... this. Adjust.
13778 (gdb_xml_parser::vdebug): New method, based on ...
13779 (gdb_xml_debug): ... this. Adjust.
13780 (gdb_xml_parser::verror): New method, based on ...
13781 (gdb_xml_error): ... this. Adjust.
13782 (gdb_xml_parser::start_element): New method, based on ...
13783 (gdb_xml_start_element): ... this. Adjust.
13784 (gdb_xml_start_element_wrapper): Defer to
13785 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
13786 (gdb_xml_parser::end_element): New method, based on ...
13787 (gdb_xml_end_element_wrapper): ... this. Adjust.
13788 (gdb_xml_parser::~gdb_xml_parser): Adjust.
13789 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
13790 (gdb_xml_parser::use_dtd): New method, based on ...
13791 (gdb_xml_use_dtd): ... this. Adjust.
13792 (gdb_xml_parser::parse): New method, based on ...
13793 (gdb_xml_parse): ... this. Adjust.
13794 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
13795 (xinclude_start_include): Adjust to call the parser's name method.
13796 (xml_xinclude_default, xml_xinclude_start_doctype)
13797 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
13798 method.
13799 (xml_process_xincludes): Adjust to call parser methods.
13800 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
13801 declarations.
13802
13803 2017-04-18 Pedro Alves <palves@redhat.com>
13804
13805 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
13806 gdb::optional<std::string>.
13807 * xml-support.c: Include <string>.
13808 (scope_level::scope_level(scope_level &&))
13809 (scope_level::~scope_level): Delete.
13810 (scope_level::body): Now a std::string.
13811 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
13812 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
13813 parameter.
13814 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
13815 (xinclude_parsing_data::output): Now a std::string reference.
13816 (xinclude_start_include): Adjust.
13817 (xml_xinclude_default): Adjust.
13818 (xml_process_xincludes): Add 'output' parameter, and return bool.
13819 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
13820 and return bool.
13821 * xml-tdesc.c: Include <unordered_map> and <string>.
13822 (tdesc_xml_cache): Delete.
13823 (tdesc_xml_cache_s): Delete.
13824 (xml_cache): Now an std::unordered_map.
13825 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
13826 (target_fetch_description_xml): Change return type to
13827 gdb::optional<std::string>, and adjust.
13828 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
13829 (target_fetch_description_xml): Change return type to
13830 gdb::optional<std::string>.
13831
13832 2017-04-18 Pedro Alves <palves@redhat.com>
13833
13834 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13835 unittests/optional-selftests.c.
13836 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
13837 * unittests/optional-selftests.c: New file.
13838 * unittests/optional/assignment/1.cc: New file.
13839 * unittests/optional/assignment/2.cc: New file.
13840 * unittests/optional/assignment/3.cc: New file.
13841 * unittests/optional/assignment/4.cc: New file.
13842 * unittests/optional/assignment/5.cc: New file.
13843 * unittests/optional/assignment/6.cc: New file.
13844 * unittests/optional/assignment/7.cc: New file.
13845 * unittests/optional/cons/copy.cc: New file.
13846 * unittests/optional/cons/default.cc: New file.
13847 * unittests/optional/cons/move.cc: New file.
13848 * unittests/optional/cons/value.cc: New file.
13849 * unittests/optional/in_place.cc: New file.
13850 * unittests/optional/observers/1.cc: New file.
13851 * unittests/optional/observers/2.cc: New file.
13852
13853 2017-04-18 Pedro Alves <palves@redhat.com>
13854
13855 * common/gdb_optional.h: Include common/traits.h.
13856 (in_place_t): New type.
13857 (in_place): New constexpr variable.
13858 (optional::optional): Remove member initialization of
13859 m_instantiated.
13860 (optional::optional(in_place_t...)): New constructor.
13861 (optional::~optional): Use reset.
13862 (optional::optional(const optional&)): New.
13863 (optional::optional(const optional&&)): New.
13864 (optional::optional(T &)): New.
13865 (optional::optional(T &&)): New.
13866 (operator::operator=(const optional &)): New.
13867 (operator::operator=(optional &&)): New.
13868 (operator::operator= (const T &))
13869 (operator::operator= (T &&))
13870 (operator::emplace (Args &&... args)): Return a T&. Use reset.
13871 (operator::reset): New.
13872 (operator::m_instantiated):: Add in-class initializer.
13873 * common/traits.h: Include <type_traits>.
13874 (struct And): New types.
13875
13876 2017-04-18 Pedro Alves <palves@redhat.com>
13877
13878 * xml-support.c: Include <vector>.
13879 (scope_level::scope_level(const gdb_xml_element *))
13880 (scope_level::scope_level(scope_level&&)): New.
13881 (scope_level::~scope_level): New.
13882 (scope_level_s): Delete.
13883 (gdb_xml_parser::scopes): Now a std::vector.
13884 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
13885 Use std::vector.
13886 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
13887 scope cleanup code.
13888 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
13889 of the scopes member. Use std::vector::emplace_back.
13890
13891 2017-04-18 Pedro Alves <palves@redhat.com>
13892
13893 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
13894 a bool.
13895 (gdb_xml_end_element): Change type of first parameter.
13896 (gdb_xml_cleanup): Rename to ...
13897 (gdb_xml_parser::~gdb_xml_parser): ... this.
13898 (gdb_xml_create_parser_and_cleanup): Delete with ...
13899 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
13900 to this new ctor.
13901 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
13902 using gdb_xml_create_parser_and_cleanup.
13903 (xinclude_parsing_data): Add ctor/dtor.
13904 (xml_xinclude_cleanup): Delete.
13905 (xml_process_xincludes): Create a local xinclude_parsing_data
13906 instead of heap-allocating one. Create a local gdb_xml_parser
13907 instead of heap-allocating one with
13908 gdb_xml_create_parser_and_cleanup.
13909
13910 2017-04-18 John Baldwin <jhb@FreeBSD.org>
13911
13912 PR threads/20743
13913 * fbsd-nat.c (resume_one_thread_cb): Remove.
13914 (resume_all_threads_cb): Remove.
13915 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
13916 iterate_over_threads.
13917
13918 2017-04-17 Joel Brobecker <brobecker@adacore.com>
13919
13920 * NEWS: Create a new section for the next release branch.
13921 Rename the section of the current branch, now that it has
13922 been cut.
13923
13924 2017-04-17 Joel Brobecker <brobecker@adacore.com>
13925
13926 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
13927 * version.in: Bump version to 8.0.50.DATE-git.
13928
13929 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
13930
13931 PR gdb/21385
13932 * windows-nat.c (windows_create_inferior): Declare 'allargs'
13933 independently of the host, and fix build breakage on Cygwin.
13934
13935 2017-04-13 Pedro Alves <palves@redhat.com>
13936
13937 * inferior.c (free_inferior): Convert to ...
13938 (inferior::~inferior): ... this dtor.
13939 (inferior::inferior): New ctor, factored out from ...
13940 (add_inferior_silent): ... here. Allocate the inferior with a new
13941 expression.
13942 (delete_inferior): Call delete instead of free_inferior.
13943 * inferior.h (gdb_environ, continuation): Forward declare.
13944 (inferior): Now a class. Add in-class initialization to all
13945 members. Make boolean fields bool, except 'detaching'.
13946 (inferior::inferior): New explicit ctor.
13947 (inferior::~inferior): New.
13948
13949 2017-04-13 Pedro Alves <palves@redhat.com>
13950
13951 * inferior.c (init_inferior_list): Delete.
13952 * inferior.h (init_inferior_list): Delete.
13953
13954 2017-04-13 Pedro Alves <palves@redhat.com>
13955
13956 PR threads/13217
13957 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
13958 (top level): Call it twice, with different thread sets.
13959
13960 2017-04-13 Pedro Alves <palves@redhat.com>
13961
13962 * thread.c: Include <algorithm>.
13963 (thread_array_cleanup): Delete.
13964 (scoped_inc_dec_ref): New class.
13965 (live_threads_count): New function.
13966 (set_thread_refcount): Delete.
13967 (tp_array_compar_ascending): Now a bool.
13968 (tp_array_compar): Convert to a std::sort comparison function.
13969 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
13970 and live_threads_count.
13971
13972 2017-04-13 Pedro Alves <palves@redhat.com>
13973
13974 * infrun.c (follow_fork_inferior): Also switch the current
13975 inferior.
13976
13977 2017-04-13 Pedro Alves <palves@redhat.com>
13978
13979 * breakpoint.c (watch_command_1): Save watchpoint-frame info
13980 before calling create_internal_breakpoint.
13981
13982 2017-04-13 Pedro Alves <palves@redhat.com>
13983
13984 * fork-child.c (execv_argv): New class.
13985 (breakup_args): Refactored as ...
13986 (execv_argv::init_for_no_shell): .. this method of execv_argv.
13987 Copy arguments to storage and replace separators with NULL
13988 terminators in place.
13989 (escape_bang_in_quoted_argument): Adjust to return bool.
13990 (execv_argv::execv_argv): New ctor.
13991 (execv_argv::init_for_shell): New method, factored out from
13992 fork_inferior. Don't strdup strings into the vector.
13993 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
13994 Remove free_vector_argv call.
13995
13996 2017-04-13 Yao Qi <yao.qi@linaro.org>
13997
13998 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
13999 tdep->rx_psw_type.
14000
14001 2017-04-13 Yao Qi <yao.qi@linaro.org>
14002
14003 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
14004 * rx-tdep.c (rx_gdbarch_init): Likewise.
14005
14006 2017-04-13 Pedro Alves <palves@redhat.com>
14007
14008 * breakpoint.h (struct breakpoint): Reindent.
14009
14010 2017-04-13 Pedro Alves <palves@redhat.com>
14011
14012 * breakpoint.c (bp_location): Rename to ...
14013 (bp_locations): ... this. All references updated.
14014 (bp_location_count): Rename to ...
14015 (bp_locations_count): ... this. All references updated.
14016 (bp_location_placed_address_before_address_max): Rename to ...
14017 (bp_locations_placed_address_before_address_max): ... this. All
14018 references updated.
14019 (bp_location_shadow_len_after_address_max): Rename to ...
14020 (bp_locations_shadow_len_after_address_max): ... this. All
14021 references updated.
14022 (bp_location_compare_addrs): Rename to ...
14023 (bp_locations_compare_addrs): ... this. All references updated.
14024 (bp_location_compare):Rename to ...
14025 (bp_locations_compare): ... this. All references updated.
14026 (bp_location_target_extensions_update): Rename to ...
14027 (bp_locations_target_extensions_update): ... this. All references
14028 updated.
14029
14030 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14031
14032 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
14033 * common/common.m4: Check headers 'termios.h', 'termio.h' and
14034 'sgtty.h'.
14035 * common/gdb_termios.h: New file, with parts of "terminal.h".
14036 * inflow.c: Include "gdb_termios.h".
14037 * ser-unix.c: Include "gdb_termios.h".
14038 * terminal.h: Move terminal-related defines to
14039 "common/gdb_termios.h".
14040
14041 2017-04-12 Tom Tromey <tom@tromey.com>
14042
14043 * probe.c (parse_probes): Update.
14044 * location.h (delete_event_location): Don't declare.
14045 (event_location_deleter::operator()): Update.
14046 * location.c (event_location_deleter::operator()): Rename from
14047 delete_event_location.
14048 * linespec.h (linespec_result) <location>: Change type to
14049 event_location_up.
14050 * linespec.c (canonicalize_linespec, event_location_to_sals)
14051 (decode_objc): Update.
14052 (linespec_result): Don't call delete_event_location.
14053 * breakpoint.c (create_breakpoints_sal)
14054 (bkpt_probe_create_sals_from_location)
14055 (strace_marker_create_sals_from_location): Update.
14056
14057 2017-04-12 Tom Tromey <tom@tromey.com>
14058
14059 * linespec.h (struct linespec_result): Add constructor and
14060 destructor.
14061 (init_linespec_result, destroy_linespec_result)
14062 (make_cleanup_destroy_linespec_result): Don't declare.
14063 * linespec.c (init_linespec_result): Remove.
14064 (linespec_result::~linespec_result): Rename from
14065 destroy_linespec_result. Update.
14066 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
14067 Remove.
14068 * breakpoint.c (create_breakpoint, break_range_command)
14069 (decode_location_default): Update.
14070 * ax-gdb.c (agent_command_1): Update.
14071
14072 2017-04-12 Tom Tromey <tom@tromey.com>
14073
14074 * remote.c (remote_download_tracepoint): Update.
14075 * python/py-breakpoint.c (bppy_get_location): Update.
14076 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
14077 (gdbscm_breakpoint_location): Update.
14078 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
14079 * breakpoint.h (struct breakpoint) <location, location_range_end>:
14080 Change type to event_location_up.
14081 * breakpoint.c (create_overlay_event_breakpoint)
14082 (create_longjmp_master_breakpoint)
14083 (create_std_terminate_master_breakpoint)
14084 (create_exception_master_breakpoint)
14085 (breakpoint_event_location_empty_p, print_breakpoint_location)
14086 (print_one_breakpoint_location, create_thread_event_breakpoint)
14087 (init_breakpoint_sal, create_breakpoint)
14088 (print_recreate_ranged_breakpoint, break_range_command)
14089 (init_ada_exception_breakpoint, say_where): Update.
14090 (base_breakpoint_dtor): Don't call delete_event_location.
14091 (bkpt_print_recreate, tracepoint_print_recreate)
14092 (dprintf_print_recreate, update_static_tracepoint)
14093 (breakpoint_re_set_default): Update.
14094
14095 2017-04-12 Tom Tromey <tom@tromey.com>
14096
14097 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
14098 type of "to_do". Update.
14099 (compute_stack_depth): Use std::vector.
14100
14101 2017-04-12 Tom Tromey <tom@tromey.com>
14102
14103 * printcmd.c (find_instruction_backward): Use std::vector.
14104
14105 2017-04-12 Tom Tromey <tom@tromey.com>
14106
14107 * symfile.c (objfilep): Remove typedef.
14108 (reread_symbols): Use a std::vector.
14109
14110 2017-04-12 Tom Tromey <tom@tromey.com>
14111
14112 * mi/mi-main.c (exec_direction_forward): Remove.
14113 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
14114 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
14115 scoped_restore.
14116 * guile/guile.c (guile_repl_command, guile_command)
14117 (gdbscm_execute_gdb_command): Use scoped_restore.
14118 * go-exp.y (go_parse): Use scoped_restore.
14119 * d-exp.y (d_parse): Use scoped_restore.
14120 * cli/cli-decode.c (cmd_func): Use scoped_restore.
14121 * c-exp.y (c_parse): Use scoped_restore.
14122
14123 2017-04-12 Tom Tromey <tom@tromey.com>
14124
14125 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
14126 (mi_parse): Update return type.
14127 (mi_parse_free): Remove.
14128 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
14129 (mi_parse::~mi_parse): Rename from mi_parse_free.
14130 (mi_parse_cleanup): Remove.
14131 (mi_parse): Return a unique_ptr. Use new.
14132 * mi/mi-main.c (mi_execute_command): Update.
14133
14134 2017-04-12 Tom Tromey <tom@tromey.com>
14135
14136 * location.c (explicit_location_lex_one): Return a
14137 unique_xmalloc_ptr.
14138 (string_to_explicit_location): Update. Remove cleanups.
14139
14140 2017-04-12 Tom Tromey <tom@tromey.com>
14141
14142 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
14143 (compare_value_and_voffset): Change type. Update.
14144 (compute_vtable_size): Change type of "offset_vec".
14145 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
14146 (gnuv3_get_typeid): Remove extraneous declaration.
14147
14148 2017-04-12 Tom Tromey <tom@tromey.com>
14149
14150 * charset.h (wchar_iterator): Fix comment.
14151
14152 2017-04-12 Tom Tromey <tom@tromey.com>
14153
14154 * charset.c (iconv_wrapper): New class.
14155 (cleanup_iconv): Remove.
14156 (convert_between_encodings): Use it.
14157
14158 2017-04-12 Tom Tromey <tom@tromey.com>
14159
14160 * symfile.h (increment_reading_symtab): Update type.
14161 * symfile.c (decrement_reading_symtab): Remove.
14162 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
14163 * psymtab.c (psymtab_to_symtab): Update.
14164 * dwarf2read.c (dw2_instantiate_symtab): Update.
14165
14166 2017-04-12 Tom Tromey <tom@tromey.com>
14167
14168 * jit.c (struct jit_reader): Declare separately. Add constructor
14169 and destructor. Change type of "handle".
14170 (loaded_jit_reader): Define separately.
14171 (jit_reader_load): Update. New "new".
14172 (jit_reader_unload_command): Use "delete".
14173 * gdb-dlfcn.h (struct dlclose_deleter): New.
14174 (gdb_dlhandle_up): New typedef.
14175 (gdb_dlopen, gdb_dlsym): Update types.
14176 (gdb_dlclose): Remove.
14177 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
14178 (gdb_dlsym): Change type of "handle".
14179 (make_cleanup_dlclose): Remove.
14180 (dlclose_deleter::operator()): Rename from gdb_dlclose.
14181 * compile/compile-c-support.c (load_libcc): Update.
14182
14183 2017-04-12 Tom Tromey <tom@tromey.com>
14184
14185 * symtab.h (find_pcs_for_symtab_line): Change return type.
14186 * symtab.c (find_pcs_for_symtab_line): Change return type.
14187 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
14188 type of "vec". Update.
14189 (ltpy_get_pcs_for_line): Update.
14190 * linespec.c (decode_digits_ordinary): Update.
14191
14192 2017-04-12 Tom Tromey <tom@tromey.com>
14193
14194 * tracepoint.c (actions_command): Update.
14195 * python/python.c (python_command, python_interactive_command):
14196 Update.
14197 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
14198 * guile/guile.c (guile_command): Update.
14199 * defs.h (read_command_lines, read_command_lines_1): Return
14200 command_line_up.
14201 (command_lines_deleter): New struct.
14202 (command_line_up): New typedef.
14203 * compile/compile.c (compile_code_command)
14204 (compile_print_command): Update.
14205 * cli/cli-script.h (get_command_line, copy_command_lines): Return
14206 command_line_up.
14207 (make_cleanup_free_command_lines): Remove.
14208 * cli/cli-script.c (get_command_line, read_command_lines_1)
14209 (copy_command_lines): Return command_line_up.
14210 (while_command, if_command, read_command_lines, define_command)
14211 (document_command): Update.
14212 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
14213 Remove.
14214 * breakpoint.h (breakpoint_set_commands): Change type of
14215 "commands".
14216 * breakpoint.c (breakpoint_set_commands): Change type of
14217 "commands". Update.
14218 (do_map_commands_command, update_dprintf_command_list)
14219 (create_tracepoint_from_upload): Update.
14220
14221 2017-04-12 Tom Tromey <tom@tromey.com>
14222
14223 * tracepoint.c (scope_info): Update.
14224 * spu-tdep.c (spu_catch_start): Update.
14225 * python/python.c (gdbpy_decode_line): Update.
14226 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
14227 * python/py-breakpoint.c (bppy_init): Update.
14228 * probe.c (parse_probes): Update.
14229 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
14230 * location.h (event_location_deleter): New struct.
14231 (event_location_up): New typedef.
14232 (new_linespec_location, new_address_location, new_probe_location)
14233 (new_explicit_location, copy_event_location)
14234 (string_to_event_location, string_to_event_location_basic)
14235 (string_to_explicit_location): Update return type.
14236 (make_cleanup_delete_event_location): Remove.
14237 * location.c (new_linespec_location, new_address_location)
14238 (new_probe_location, new_explicit_location, copy_event_location):
14239 Return event_location_up.
14240 (delete_event_location_cleanup)
14241 (make_cleanup_delete_event_location): Remove.
14242 (string_to_explicit_location, string_to_event_location_basic)
14243 (string_to_event_location): Return event_location_up.
14244 * linespec.c (canonicalize_linespec, event_location_to_sals)
14245 (decode_line_with_current_source)
14246 (decode_line_with_last_displayed, decode_objc): Update.
14247 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
14248 * completer.c (location_completer): Update.
14249 * cli/cli-cmds.c (edit_command, list_command): Update.
14250 * breakpoint.c (create_overlay_event_breakpoint)
14251 (create_longjmp_master_breakpoint)
14252 (create_std_terminate_master_breakpoint)
14253 (create_exception_master_breakpoint)
14254 (create_thread_event_breakpoint): Update.
14255 (init_breakpoint_sal): Update. Remove some dead code.
14256 (create_breakpoint_sal): Change type of "location". Update.
14257 (create_breakpoints_sal, create_breakpoint, break_command_1)
14258 (dprintf_command, break_range_command, until_break_command)
14259 (init_ada_exception_breakpoint)
14260 (strace_marker_create_sals_from_location)
14261 (update_static_tracepoint, trace_command, ftrace_command)
14262 (strace_command, create_tracepoint_from_upload): Update.
14263 * break-catch-throw.c (re_set_exception_catchpoint): Update.
14264 * ax-gdb.c (agent_command_1): Update.
14265
14266 2017-04-12 Pedro Alves <palves@redhat.com>
14267
14268 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
14269 * configure.tgt: Handle i[34567]86-*-go32* and
14270 i[34567]86-*-msdosdjgpp*.
14271 * i386-tdep.c (i386_svr4_reg_to_regnum):
14272 Make extern.
14273 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
14274 i386-go32-tdep.c.
14275 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
14276 * i386-go32-tdep.c: New file.
14277 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
14278 declarations.
14279
14280 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
14281
14282 * aix-thread.c (pd_status2str): Change return type to const char *.
14283
14284 2017-04-12 Pedro Alves <palves@redhat.com>
14285
14286 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
14287 calls to set_gdbarch_gnu_triplet_regexp.
14288
14289 2017-04-12 Pedro Alves <palves@redhat.com>
14290
14291 PR gdb/21323
14292 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
14293 New enum value.
14294 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
14295 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
14296 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
14297 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
14298 * gdbarch.h, gdbarch.c: Regenerate.
14299 * aarch64-tdep.c (aarch64_gdbarch_init): Override
14300 gdbarch_wchar_bit and gdbarch_wchar_signed.
14301 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
14302 * arm-tdep.c (arm_gdbarch_init): Likewise.
14303 * avr-tdep.c (avr_gdbarch_init): Likewise.
14304 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
14305 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
14306 * i386-tdep.c (i386_go32_init_abi): Likewise.
14307 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
14308 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
14309 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
14310 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
14311 * sh-tdep.c (sh_gdbarch_init): Likewise.
14312 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
14313 * sparc64-tdep.c (sparc64_init_abi): Likewise.
14314 * windows-tdep.c (windows_init_abi): Likewise.
14315 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
14316
14317 2017-04-12 Pedro Alves <palves@redhat.com>
14318
14319 PR c++/21323
14320 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
14321 cplus_primitive_type_char32_t>: New enum values.
14322 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
14323 and cplus_primitive_type_char32_t.
14324 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
14325 32, use the archtecture's built-in type for char16_t and char32_t,
14326 respectively. Otherwise, fallback to init_integer_type as before,
14327 but make the type unsigned, and issue a complaint.
14328 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
14329
14330 2017-04-12 Alan Hayward <alan.hayward@arm.com>
14331
14332 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
14333 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
14334
14335 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14336
14337 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
14338 'const char *'.
14339
14340 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14341
14342 * common/common-utils.c (free_vector_argv): New function.
14343 * common/common-utils.h: Include <vector>.
14344 (free_vector_argv): New prototype.
14345 * darwin-nat.c (darwin_create_inferior): Rewrite function
14346 prototype in order to constify "exec_file" and accept a
14347 "std::string" for "allargs".
14348 * fork-child.c: Include <vector>.
14349 (breakup_args): Rewrite function, using C++.
14350 (fork_inferior): Rewrite function header, constify "exec_file_arg"
14351 and accept "std::string" for "allargs". Update the code to
14352 calculate "argv" based on "allargs". Update calls to "exec_fun"
14353 and "execvp".
14354 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
14355 order to constify "exec_file" and accept a "std::string" for
14356 "allargs".
14357 * go32-nat.c (go32_create_inferior): Likewise.
14358 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
14359 * infcmd.c (run_command_1): Constify "exec_file". Use
14360 "std::string" for inferior arguments.
14361 * inferior.h (fork_inferior): Update prototype.
14362 * linux-nat.c (linux_nat_create_inferior): Rewrite function
14363 prototype in order to constify "exec_file" and accept a
14364 "std::string" for "allargs".
14365 * nto-procfs.c (procfs_create_inferior): Likewise.
14366 * procfs.c (procfs_create_inferior): Likewise.
14367 * remote-sim.c (gdbsim_create_inferior): Likewise.
14368 * remote.c (extended_remote_run): Update code to accept
14369 "std::string" as argument.
14370 (extended_remote_create_inferior): Rewrite function prototype in
14371 order to constify "exec_file" and accept a "std::string" for
14372 "allargs".
14373 * rs6000-nat.c (super_create_inferior): Likewise.
14374 (rs6000_create_inferior): Likewise.
14375 * target.h (struct target_ops) <to_create_inferior>: Likewise.
14376 * windows-nat.c (windows_create_inferior): Likewise.
14377
14378 2017-04-11 Pedro Alves <palves@redhat.com>
14379
14380 * thread.c: Fix whitespace throughout.
14381
14382 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
14383
14384 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
14385
14386 2017-04-11 Alan Hayward <alan.hayward@arm.com>
14387
14388 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
14389
14390 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
14391
14392 PR gdb/21364
14393 * osdata.c (info_osdata): Check if 'type' is an empty string
14394 instead of NULL.
14395
14396 2017-04-10 Pedro Alves <palves@redhat.com>
14397
14398 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
14399 (ptid_to_global_thread_id, in_thread_list)
14400 (do_captured_list_thread_ids, set_resumed, set_running)
14401 (set_executing, set_stop_requested, finish_thread_state)
14402 (validate_registers_access, can_access_registers_ptid)
14403 (print_thread_info_1, switch_to_thread)
14404 (do_restore_current_thread_cleanup)
14405 (make_cleanup_restore_current_thread, thread_command)
14406 (thread_name_command): Use operator== instead of ptid_equal.
14407
14408 2017-04-10 Pedro Alves <palves@redhat.com>
14409
14410 * thread.c (struct current_thread_cleanup) <next>: Delete field.
14411 (current_thread_cleanup_chain): Delete.
14412 (restore_current_thread_cleanup_dtor)
14413 (make_cleanup_restore_current_thread): Remove references to
14414 current_thread_cleanup_chain.
14415
14416 2017-04-10 Alan Hayward <alan.hayward@arm.com>
14417
14418 * msp430-tdep.c (msp430_pseudo_register_read): Never return
14419 REG_UNKNOWN.
14420
14421 2017-04-10 Yao Qi <yao.qi@linaro.org>
14422
14423 PR gdb/19942
14424 * gdbthread.h (thread_info::deletable): New method.
14425 (thread_info::incref): New method.
14426 (thread_info::decref): New method.
14427 (thread_info::refcount): Move it to private.
14428 * infrun.c (save_stop_context): Call inc_refcount.
14429 (release_stop_context_cleanup): Likewise.
14430 * thread.c (set_thread_exited): New function.
14431 (init_thread_list): Delete "tp" only it is deletable, otherwise
14432 call set_thread_exited.
14433 (delete_thread_1): Call set_thread_exited.
14434 (current_thread_cleanup) <inferior_pid>: Remove.
14435 <thread>: New field.
14436 (restore_current_thread_ptid_changed): Removed.
14437 (do_restore_current_thread_cleanup): Adjust.
14438 (restore_current_thread_cleanup_dtor): Don't call
14439 find_thread_ptid.
14440 (set_thread_refcount): Use dec_refcount.
14441 (make_cleanup_restore_current_thread): Adjust.
14442 (thread_apply_all_command): Call inc_refcount.
14443 (_initialize_thread): Don't call
14444 observer_attach_thread_ptid_changed.
14445
14446 2017-04-10 Yao Qi <yao.qi@linaro.org>
14447
14448 * thread.c (delete_thread_1): Hoist code on marking thread as
14449 exited.
14450
14451 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14452
14453 * windows-nat.c (windows_detach): Initialize ptid with
14454 minus_one_ptid.
14455
14456 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14457
14458 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14459
14460 2017-04-07 Alan Hayward <alan.hayward@arm.com>
14461
14462 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14463 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14464 (bfin_pseudo_register_write): Likewise
14465
14466 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14467
14468 * common/ptid.h (struct ptid): Change to...
14469 (class ptid_t): ... this.
14470 <ptid_t>: New constructors.
14471 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14472 matches>: New methods.
14473 <make_null, make_minus_one>: New static methods.
14474 <pid>: Rename to...
14475 <m_pid>: ...this.
14476 <lwp>: Rename to...
14477 <m_lwp>: ...this.
14478 <tid>: Rename to...
14479 <m_tid>: ...this.
14480 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14481 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14482 as references, move comment to class ptid_t.
14483 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14484 ptid_t static methods.
14485 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14486 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14487 Take ptid arguments as references, implement using ptid_t methods.
14488 * unittests/ptid-selftests.c: New file.
14489 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14490 unittests/ptid-selftests.c.
14491 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14492
14493 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14494
14495 * python/python.c (python_run_simple_file): Cast mode literal to
14496 non-const char pointer as expected by PyFile_FromString.
14497
14498 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14499
14500 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14501 minus_one_ptid and null_ptid.
14502
14503 2017-04-05 Pedro Alves <palves@redhat.com>
14504
14505 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14506 * configure: Regenerate.
14507
14508 2017-04-05 Pedro Alves <palves@redhat.com>
14509
14510 * ada-exp.y (yyerror): Constify.
14511 * ada-lang.c (bound_name, get_selections)
14512 (ada_variant_discrim_type)
14513 (ada_variant_discrim_name, ada_value_struct_elt)
14514 (ada_lookup_struct_elt_type, is_unchecked_variant)
14515 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14516 (catch_ada_exception_command_split)
14517 (catch_ada_assert_command_split, catch_assert_command)
14518 (ada_op_name): Constify.
14519 * ada-lang.h (ada_yyerror, get_selections)
14520 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14521 * arc-tdep.c (arc_print_frame_cache): Constify.
14522 * arm-tdep.c (arm_skip_stub): Constify.
14523 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14524 (gen_aggregate_elt_ref): Constify.
14525 * bcache.c (print_bcache_statistics): Constify.
14526 * bcache.h (print_bcache_statistics): Constify.
14527 * break-catch-throw.c (catch_exception_command_1):
14528 * breakpoint.c (struct ep_type_description::description):
14529 Constify.
14530 (add_solib_catchpoint): Constify.
14531 (catch_fork_command_1): Add cast.
14532 (add_catch_command): Constify.
14533 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14534 Constify.
14535 * bsd-uthread.c (bsd_uthread_state): Constify.
14536 * buildsym.c (patch_subfile_names): Constify.
14537 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14538 Constify.
14539 * c-exp.y (yyerror): Constify.
14540 (token::oper): Constify.
14541 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14542 * c-varobj.c (cplus_describe_child): Constify.
14543 * charset.c (find_charset_names): Add cast.
14544 (find_charset_names): Constify array and add const_cast.
14545 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14546 (edit_command): Constify.
14547 * cli/cli-decode.c (lookup_cmd): Constify.
14548 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14549 Constify.
14550 (struct dump_context): Constify.
14551 (add_dump_command, restore_command): Constify.
14552 * cli/cli-script.c (get_command_line): Constify.
14553 * cli/cli-script.h (get_command_line): Constify.
14554 * cli/cli-utils.c (check_for_argument): Constify.
14555 * cli/cli-utils.h (check_for_argument): Constify.
14556 * coff-pe-read.c (struct read_pe_section_data): Constify.
14557 * command.h (lookup_cmd): Constify.
14558 * common/print-utils.c (decimal2str): Constify.
14559 * completer.c (gdb_print_filename): Constify.
14560 * corefile.c (set_gnutarget): Constify.
14561 * cp-name-parser.y (yyerror): Constify.
14562 * cp-valprint.c (cp_print_class_member): Constify.
14563 * cris-tdep.c (cris_register_name, crisv32_register_name):
14564 Constify.
14565 * d-exp.y (yyerror): Constify.
14566 (struct token::oper): Constify.
14567 * d-lang.h (d_yyerror): Constify.
14568 * dbxread.c (struct header_file_location::name): Constify.
14569 (add_old_header_file, add_new_header_file, last_function_name)
14570 (dbx_next_symbol_text, add_bincl_to_list)
14571 (find_corresponding_bincl_psymtab, set_namestring)
14572 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14573 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14574 * defs.h (command_line_input, print_address_symbolic)
14575 (deprecated_readline_begin_hook): Constify.
14576 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14577 Constify.
14578 * event-top.c (handle_line_of_input): Constify and add cast.
14579 * exceptions.c (catch_errors): Constify.
14580 * exceptions.h (catch_errors): Constify.
14581 * expprint.c (print_subexp_standard, op_string, op_name)
14582 (op_name_standard, dump_raw_expression, dump_raw_expression):
14583 * expression.h (op_name, op_string, dump_raw_expression):
14584 Constify.
14585 * f-exp.y (yyerror): Constify.
14586 (struct token::oper): Constify.
14587 (struct f77_boolean_val::name): Constify.
14588 * f-lang.c (f_word_break_characters): Constify.
14589 * f-lang.h (f_yyerror): Constify.
14590 * fork-child.c (fork_inferior): Add cast.
14591 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14592 (new_variant): Constify.
14593 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14594 * gdbarch.c: Regenerate.
14595 * gdbcore.h (set_gnutarget): Constify.
14596 * go-exp.y (yyerror): Constify.
14597 (token::oper): Constify.
14598 * go-lang.h (go_yyerror): Constify.
14599 * go32-nat.c (go32_sysinfo): Constify.
14600 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14601 * guile/scm-cmd.c (cmdscm_function): Constify.
14602 * guile/scm-param.c (pascm_param_value): Constify.
14603 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14604 (h8300sx_register_name): Constify.
14605 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14606 Constify.
14607 * ia64-tdep.c (ia64_register_names): Constify.
14608 * infcmd.c (construct_inferior_arguments): Constify.
14609 (path_command, attach_post_wait): Constify.
14610 * language.c (show_range_command, show_case_command)
14611 (unk_lang_error): Constify.
14612 * language.h (language_defn::la_error)
14613 (language_defn::la_name_of_this): Constify.
14614 * linespec.c (decode_line_2): Constify.
14615 * linux-thread-db.c (thread_db_err_str): Constify.
14616 * lm32-tdep.c (lm32_register_name): Constify.
14617 * m2-exp.y (yyerror): Constify.
14618 * m2-lang.h (m2_yyerror): Constify.
14619 * m32r-tdep.c (m32r_register_names): Constify and make static.
14620 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14621 * m88k-tdep.c (m88k_register_name): Constify.
14622 * macroexp.c (appendmem): Constify.
14623 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14624 (upgrade_type, parse_external, parse_partial_symbols)
14625 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14626 (new_symbol): Constify.
14627 * memattr.c (mem_info_command): Constify.
14628 * mep-tdep.c (register_name_from_keyword): Constify.
14629 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14630 Constify.
14631 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14632 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14633 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14634 cast.
14635 (mi_execute_async_cli_command): Constify.
14636 * mips-tdep.c (mips_register_name): Constify.
14637 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14638 (am33_register_name, am33_2_register_name)
14639 * moxie-tdep.c (moxie_register_names): Constify.
14640 * nat/linux-osdata.c (osdata_type): Constify fields.
14641 * nto-tdep.c (nto_parse_redirection): Constify.
14642 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14643 (lookup_child_selector): Constify.
14644 (objc_methcall::name): Constify.
14645 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14646 (lookup_struct_typedef): Constify.
14647 * objfiles.c (pc_in_section): Constify.
14648 * objfiles.h (pc_in_section): Constify.
14649 * p-exp.y (struct token::oper): Constify.
14650 (yyerror): Constify.
14651 * p-lang.h (pascal_yyerror): Constify.
14652 * parser-defs.h (op_name_standard): Constify.
14653 (op_print::string): Constify.
14654 (exp_descriptor::op_name): Constify.
14655 * printcmd.c (print_address_symbolic): Constify.
14656 * psymtab.c (print_partial_symbols): Constify.
14657 * python/py-breakpoint.c (stop_func): Constify.
14658 (bppy_get_expression): Constify.
14659 * python/py-cmd.c (cmdpy_completer::name): Constify.
14660 (cmdpy_function): Constify.
14661 * python/py-event.c (evpy_add_attribute)
14662 (gdbpy_initialize_event_generic): Constify.
14663 * python/py-event.h (evpy_add_attribute)
14664 (gdbpy_initialize_event_generic): Constify.
14665 * python/py-evts.c (add_new_registry): Constify.
14666 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14667 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14668 * python/py-inferior.c (get_buffer): Add cast.
14669 * python/py-param.c (parm_constant::name): Constify.
14670 * python/py-unwind.c (fprint_frame_id): Constify.
14671 * python/python.c (gdbpy_parameter_value): Constify.
14672 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14673 * remote.c (memory_packet_config::name): Constify.
14674 (show_packet_config_cmd, remote_write_bytes)
14675 (remote_buffer_add_string):
14676 * reverse.c (exec_reverse_once): Constify.
14677 * rs6000-tdep.c (variant::name, variant::description): Constify.
14678 * rust-exp.y (rustyyerror): Constify.
14679 * rust-lang.c (rust_op_name): Constify.
14680 * rust-lang.h (rustyyerror): Constify.
14681 * serial.h (serial_ops::name): Constify.
14682 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14683 (sh_sh3e_register_name, sh_sh2e_register_name)
14684 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14685 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14686 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14687 (sh_sh4al_dsp_register_name): Constify.
14688 * sh64-tdep.c (sh64_register_name): Constify.
14689 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14690 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14691 * stabsread.c (patch_block_stabs, read_type_number)
14692 (ref_map::stabs, ref_add, process_reference)
14693 (symbol_reference_defined, define_symbol, define_symbol)
14694 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14695 (read_one_struct_field, read_struct_fields, read_baseclasses)
14696 (read_tilde_fields, read_struct_type, read_array_type)
14697 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14698 (read_huge_number, read_range_type, read_args, common_block_start)
14699 (find_name_end): Constify.
14700 * stabsread.h (common_block_start, define_symbol)
14701 (process_one_symbol, symbol_reference_defined, ref_add):
14702 * symfile.c (get_section_index, add_symbol_file_command):
14703 * symfile.h (get_section_index): Constify.
14704 * target-descriptions.c (tdesc_type::name): Constify.
14705 (tdesc_free_type): Add cast.
14706 * target.c (find_default_run_target):
14707 (add_deprecated_target_alias, find_default_run_target)
14708 (target_announce_detach): Constify.
14709 (do_option): Constify.
14710 * target.h (add_deprecated_target_alias): Constify.
14711 * thread.c (print_thread_info_1): Constify.
14712 * top.c (deprecated_readline_begin_hook, command_line_input):
14713 Constify.
14714 (init_main): Add casts.
14715 * top.h (handle_line_of_input): Constify.
14716 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14717 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14718 (tfind_command): Rename to ...
14719 (tfind_command_1): ... this and constify.
14720 (tfind_command): New function.
14721 (tfind_end_command, tfind_start_command): Adjust.
14722 (encode_source_string): Constify.
14723 * tracepoint.h (encode_source_string): Constify.
14724 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14725 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14726 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14727 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14728 * tui/tui-win.c (parse_scrolling_args): Constify.
14729 * tui/tui-windata.c (tui_erase_data_content): Constify.
14730 * tui/tui-windata.h (tui_erase_data_content): Constify.
14731 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14732 * tui/tui.c (tui_enable): Add cast.
14733 * utils.c (defaulted_query): Constify.
14734 (init_page_info): Add cast.
14735 (puts_debug, subset_compare): Constify.
14736 * utils.h (subset_compare): Constify.
14737 * varobj.c (varobj_format_string): Constify.
14738 * varobj.h (varobj_format_string): Constify.
14739 * vax-tdep.c (vax_register_name): Constify.
14740 * windows-nat.c (windows_detach): Constify.
14741 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14742 * xml-support.c (gdb_xml_end_element): Constify.
14743 * xml-tdesc.c (tdesc_start_reg): Constify.
14744 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14745 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14746 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14747
14748 2017-04-05 Pedro Alves <palves@redhat.com>
14749
14750 * proc-api.c (struct trans): Constify.
14751 (procfs_note): Constify.
14752 * proc-events.c (struct trans, syscall_table):
14753 * proc-flags.c (struct trans): Constify.
14754 * proc-utils.h (procfs_note): Constify.
14755 * proc-why.c (struct trans): Constify.
14756 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14757 (procfs_detach): Constify.
14758 * sol-thread.c (struct string_map): Constify.
14759 (td_err_string, td_state_string): Constify.
14760
14761 2017-04-05 Pedro Alves <palves@redhat.com>
14762
14763 * proc-api.c (procfs_filename): Don't initialize
14764 procfs_filename.
14765 (prepare_to_trace): Assume procfs_filename is non-NULL.
14766 (_initialize_proc_api): Give procfs_filename a default value here.
14767
14768 2017-04-05 Pedro Alves <palves@redhat.com>
14769
14770 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14771 'cond_string' parameter.
14772 (extract_exception_regexp): Constify 'string' parameter.
14773 (catch_exception_command_1): Constify.
14774 * breakpoint.c (init_catchpoint)
14775 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14776 parameter.
14777 (ep_parse_optional_if_clause, catch_fork_command_1)
14778 (catch_exec_command_1): Constify.
14779 * breakpoint.h (init_catchpoint): Constify 'cond_string'
14780 parameter.
14781 (ep_parse_optional_if_clause): Constify.
14782 * cli/cli-utils.c (remove_trailing_whitespace)
14783 (check_for_argument): Constify.
14784 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
14785 non-const overload.
14786 (check_for_argument): Likewise.
14787
14788 2017-04-05 Pedro Alves <palves@redhat.com>
14789
14790 * event-top.c (command_line_handler): Add cast to execute_command
14791 call.
14792 * record-btrace.c (cmd_record_btrace_bts_start)
14793 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
14794 (cmd_record_btrace_start): Add cast to execute_command call.
14795 * record-full.c (record_full_goto_insn):
14796 * record.c (record_start, record_stop): Add cast to
14797 execute_command_to_string calls.
14798 (cmd_record_start): Add cast to execute_command calls.
14799
14800 2017-04-05 Pedro Alves <palves@redhat.com>
14801
14802 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
14803 static inline function.
14804 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
14805 array and use gdb_PyArg_ParseTupleAndKeywords.
14806 * python/py-cmd.c (cmdpy_init): Likewise.
14807 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
14808 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
14809 (infpy_search_memory): Likewise.
14810 * python/py-objfile.c (objfpy_add_separate_debug_file)
14811 (gdbpy_lookup_objfile): Likewise.
14812 * python/py-symbol.c (gdbpy_lookup_symbol)
14813 (gdbpy_lookup_global_symbol): Likewise.
14814 * python/py-type.c (gdbpy_lookup_type): Likewise.
14815 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
14816 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
14817 Likewise.
14818
14819 2017-04-05 Pedro Alves <palves@redhat.com>
14820
14821 * python/python-internal.h (gdb_PyGetSetDef): New type.
14822 * python/py-block.c (block_object_getset)
14823 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
14824 * python/py-event.c (event_object_getset)
14825 (finish_breakpoint_object_getset): Likewise.
14826 * python/py-inferior.c (inferior_object_getset): Likewise.
14827 * python/py-infthread.c (thread_object_getset): Likewise.
14828 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
14829 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
14830 * python/py-objfile.c (objfile_getset): Likewise.
14831 * python/py-progspace.c (pspace_getset): Likewise.
14832 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
14833 Likewise.
14834 * python/py-record.c (recpy_record_getset): Likewise.
14835 * python/py-symbol.c (symbol_object_getset): Likewise.
14836 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
14837 Likewise.
14838 * python/py-type.c (type_object_getset, field_object_getset):
14839 Likewise.
14840 * python/py-value.c (value_object_getset): Likewise.
14841
14842 2017-04-05 Pedro Alves <palves@redhat.com>
14843
14844 * python/python-internal.h (gdb_PyObject_CallMethod)
14845 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
14846 New functions.
14847 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
14848 (PySys_GetObject, PySys_SetPath): New macros.
14849
14850 2017-04-05 Pedro Alves <palves@redhat.com>
14851
14852 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
14853 info_osdata_command.
14854 * osdata.c (info_osdata_command): Rename to ...
14855 (info_osdata): ... this. Constify 'type' parameter, and remove
14856 the 'from_tty' parameter. Accept NULL TYPE.
14857 (info_osdata_command): New function.
14858 * osdata.h (info_osdata_command): Remove declaration.
14859 (info_osdata): New declaration.
14860
14861 2017-04-05 Pedro Alves <palves@redhat.com>
14862
14863 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
14864 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
14865 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
14866 parameter.
14867 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
14868 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
14869 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
14870 parameter.
14871 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
14872 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
14873 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
14874 (mi_cmd_file_list_exec_source_files)
14875 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
14876 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
14877 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
14878 parameter.
14879 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
14880 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
14881 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
14882 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
14883 (mi_cmd_stack_info_frame): Constify 'command' parameter.
14884 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
14885 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
14886 'command' parameter.
14887 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
14888 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
14889 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
14890 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
14891 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
14892 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
14893 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
14894 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
14895 (mi_cmd_var_set_update_range): Constify 'command' parameter.
14896 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
14897 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
14898 parameter.
14899 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
14900 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
14901 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
14902 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
14903 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
14904 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
14905 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
14906 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
14907 (mi_cmd_data_list_changed_registers)
14908 (mi_cmd_data_write_register_values)
14909 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
14910 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
14911 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
14912 (mi_cmd_list_features, mi_cmd_list_target_features)
14913 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
14914 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
14915 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
14916 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
14917 (mi_cmd_trace_frame_collected): Constify 'command'
14918 parameter.
14919 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
14920 'command' parameter.
14921
14922 2017-04-05 Pedro Alves <palves@redhat.com>
14923
14924 * ada-lang.c (ada_completer_word_break_characters): Now a const
14925 array.
14926 (ada_get_gdb_completer_word_break_characters): Constify.
14927 * completer.c (gdb_completer_command_word_break_characters)
14928 (gdb_completer_file_name_break_characters)
14929 (gdb_completer_quote_characters): Now const arrays.
14930 (get_gdb_completer_quote_characters): Constify.
14931 (set_rl_completer_word_break_characters): New function.
14932 (set_gdb_completion_word_break_characters)
14933 (complete_line_internal): Use it.
14934 * completer.h (get_gdb_completer_quote_characters): Constify.
14935 (set_rl_completer_word_break_characters): Declare.
14936 * f-lang.c (f_word_break_characters): Constify.
14937 * language.c (default_word_break_characters): Constify.
14938 * language.h (language_defn::la_word_break_characters): Constify.
14939 (default_word_break_characters): Constify.
14940 * top.c (init_main): Use set_rl_completer_word_break_characters.
14941
14942 2017-04-05 Pedro Alves <palves@redhat.com>
14943
14944 * aix-thread.c (aix_thread_pid_to_str)
14945 (aix_thread_extra_thread_info): Constify.
14946 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
14947 * bsd-uthread.c (bsd_uthread_extra_thread_info)
14948 (bsd_uthread_pid_to_str): Constify.
14949 * corelow.c (core_pid_to_str): Constify.
14950 * darwin-nat.c (darwin_pid_to_str): Constify.
14951 * fbsd-nat.c (fbsd_pid_to_str): Constify.
14952 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
14953 Constify.
14954 * gnu-nat.c (gnu_pid_to_str): Constify.
14955 * go32-nat.c (go32_pid_to_str): Constify.
14956 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
14957 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
14958 * inferior.c (inferior_pid_to_str): Constify.
14959 * linux-nat.c (linux_nat_pid_to_str): Constify.
14960 * linux-tdep.c (linux_core_pid_to_str): Constify.
14961 * linux-thread-db.c (thread_db_pid_to_str)
14962 (thread_db_extra_thread_info): Constify.
14963 * nto-tdep.c (nto_extra_thread_info): Constify.
14964 * nto-tdep.h (nto_extra_thread_info): Constify.
14965 * obsd-nat.c (obsd_pid_to_str): Constify.
14966 * procfs.c (procfs_pid_to_str): Constify.
14967 * ravenscar-thread.c (ravenscar_extra_thread_info)
14968 (ravenscar_pid_to_str): Constify.
14969 * remote-sim.c (gdbsim_pid_to_str): Constify.
14970 * remote.c (remote_threads_extra_info, remote_pid_to_str):
14971 Constify.
14972 * sol-thread.c (solaris_pid_to_str): Constify.
14973 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
14974 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
14975 * target.c (default_pid_to_str, target_pid_to_str)
14976 (normal_pid_to_str, default_pid_to_str): Constify.
14977 * target.h (target_ops::to_pid_to_str)
14978 (target_ops::to_extra_thread_info): Constify.
14979 (target_pid_to_str, normal_pid_to_str): Constify.
14980 * windows-nat.c (windows_pid_to_str): Constify.
14981 * gdbarch.sh (core_pid_to_str): Constify.
14982 * target-delegates.c: Regenerate.
14983 * gdbarch.h, gdbarch.c: Regenerate.
14984
14985 2017-04-05 Pedro Alves <palves@redhat.com>
14986
14987 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
14988 the memory of the temporary warning_pre_print override.
14989 * utils.c (warning_pre_print): Constify.
14990 * utils.h (warning_pre_print): Constify.
14991
14992 2017-04-05 Pedro Alves <palves@redhat.com>
14993
14994 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
14995 (shell_command): New function.
14996 (make_command): Use std::string.
14997 (init_cli_cmds): Register shell_command instead of shell_escape.
14998
14999 2017-04-05 Pedro Alves <palves@redhat.com>
15000
15001 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
15002 * tracepoint.c (default_collect): Don't initialize.
15003
15004 2017-04-05 Pedro Alves <palves@redhat.com>
15005
15006 * macroexp.c (macro_buffer::shared): Now a bool.
15007 (init_buffer): Update.
15008 (init_shared_buffer): Constify 'addr' parameter.
15009 (substitute_args, expand, macro_expand, macro_expand_next): Remove
15010 casts.
15011
15012 2017-04-05 Pedro Alves <palves@redhat.com>
15013
15014 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
15015 * disasm.c (set_disassembler_options): Constify local.
15016 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
15017
15018 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
15019
15020 PR gdb/21352
15021 * tracefile.c (tsave_command): Fix argument parsing for '-r'
15022 option.
15023
15024 2017-04-05 Yao Qi <yao.qi@linaro.org>
15025
15026 * frame.c (frame_unwind_register_unsigned): Call
15027 frame_unwind_register_value.
15028
15029 2017-04-05 Yao Qi <yao.qi@linaro.org>
15030
15031 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
15032 Use gdb_test_multiple, and don't match anchor.
15033
15034 2017-04-05 Pedro Alves <palves@redhat.com>
15035
15036 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
15037 (Write After Approval): Remove Simon Marchi.
15038
15039 2017-04-05 Pedro Alves <palves@redhat.com>
15040
15041 * common/gdb_optional.h (optional::optional): Make constexpr and
15042 initialize m_dummy.
15043
15044 2017-04-04 John Baldwin <jhb@FreeBSD.org>
15045
15046 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15047 (amd64fbsd_jmp_buf_reg_offset): Remove.
15048 (amd64fbsd_supply_uthread): Remove function.
15049 (amd64fbsd_collect_uthread): Remove function.
15050 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
15051 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
15052 (x86_64-*-freebsd*): Remove bsd-uthread.o.
15053 (fbsd-nat.c): Update comment.
15054 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15055 (i386fbsd_jmp_buf_reg_offset): Remove.
15056 (i386fbsd_supply_uthread): Remove function.
15057 (i386fbsd_collect_uthread): Remove function.
15058 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
15059
15060 2017-04-04 John Baldwin <jhb@FreeBSD.org>
15061
15062 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
15063 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
15064 * NEWS: Mention that support for FreeBSD/alpha was removed.
15065 * alpha-fbsd-tdep.c: Delete file.
15066 * config/alpha/fbsd.mh: Delete file.
15067 * configure.host: Delete alpha*-*-freebsd* and
15068 alpha*-*-kfreebsd*-gnu.
15069 * configure.tgt: Delete alpha*-*-freebsd* and
15070 alpha*-*-kfreebsd*-gnu.
15071
15072 2017-04-04 John Baldwin <jhb@FreeBSD.org>
15073
15074 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
15075 amd64bsd_store_inferior_registers): Use ptid from regcache.
15076
15077 2017-04-04 Pedro Alves <palves@redhat.com>
15078
15079 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
15080 data fields, make them private and add "m_" prefixes.
15081 (lnp_state_machine::lnp_state_machine): New ctor.
15082 (record_line, check_line_address, handle_set_discriminator)
15083 (handle_set_address, handle_advance_pc, handle_special_opcode)
15084 (handle_advance_line, handle_set_file, handle_negate_stmt)
15085 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
15086 (end_sequence, advance_line): New methods.
15087 (m_gdbarch, m_record_lines_p): New fields.
15088 (lnp_reader_state): Delete.
15089 (dwarf_record_line): Rename to ...
15090 (lnp_state_machine::record_line): ... adjust.
15091 (init_lnp_state_machine): Delete.
15092 (lnp_state_machine::lnp_state_machine): New.
15093 (check_line_address): Rename to ...
15094 (lnp_state_machine::check_line_address): This.
15095 (dwarf_decode_lines_1): Remove reference to "reader_state".
15096 Adjust lnp_state_machine having a non-default ctor. Use bool.
15097 State machine internal state manipulation moved to
15098 lnp_state_machine methods.
15099
15100 2017-04-04 Pedro Alves <palves@redhat.com>
15101
15102 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15103 unittests/offset-type-selftests.c.
15104 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
15105 * common/offset-type.h: New file.
15106 * common/preprocessor.h: New file.
15107 * common/traits.h: New file.
15108 * common/valid-expr.h: New file.
15109 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
15110 sect_offset and cu_offset strong typedefs throughout.
15111 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
15112 typedefs throughout.
15113 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
15114 sect_offset and cu_offset strong typedefs throughout.
15115 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
15116 typedefs throughout.
15117 * gdbtypes.h: Include "common/offset-type.h".
15118 (cu_offset): Now an offset type (strong typedef) instead of a
15119 struct.
15120 (sect_offset): Likewise.
15121 (union call_site_parameter_u): Rename "param_offset" field to
15122 "param_cu_off".
15123 * unittests/offset-type-selftests.c: New file.
15124
15125 2017-04-04 Pedro Alves <palves@redhat.com>
15126
15127 * common/underlying.h: New file.
15128 * dwarf2read.c: Include "common/gdb_optional.h" and
15129 "common/underlying.h".
15130 (dir_index, file_name_index): New types.
15131 (file_entry): Use them.
15132 (file_entry::include): Use to_underlying.
15133 (line_header::add_file_name): Use dir_index.
15134 (read_formatted_entries): Use gdb::optional. Read form before
15135 writting to file_entry.
15136 (dwarf_decode_line_header): Use dir_index.
15137 (lnp_state_machine::current_file): Use to_underlying.
15138 (lnp_state_machine::file): Change type to file_name_index.
15139 (dwarf_record_line): Use to_underlying.
15140 (init_lnp_state_machine): Use file_name_index.
15141 (dwarf_decode_lines_1): Use dir_index and file_name_index.
15142
15143 2017-04-04 Pedro Alves <palves@redhat.com>
15144
15145 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
15146 operator bool, has_value and get methods.
15147
15148 2017-04-04 Pedro Alves <palves@redhat.com>
15149
15150 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
15151 fields.
15152 (line_header): Initialize all data fields. Change type of
15153 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
15154 Change type of include_dirs to std::vector<const char *>. Remove
15155 num_include_dirs, include_dirs_size. Change type of file_names to
15156 std::vector<file_entry>. Remove num_file_names, file_names_size.
15157 (line_header::line_header): New.
15158 (line_header::add_include_dir, line_header::add_file_name): New
15159 methods.
15160 (line_header::include_dir_at): Remove NULL check.
15161 (line_header::file_name_at): Add const overload.
15162 (line_header_up): New unique_ptr typedef.
15163 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
15164 std::vector. Remove free_line_header call.
15165 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
15166 free_line_header call.
15167 (free_cu_line_header): Delete.
15168 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
15169 (setup_type_unit_groups): Use line_header_up instead of cleanups.
15170 Adjust to use std::vector.
15171 (free_line_header): Delete.
15172 (free_line_header_voidp): Use delete.
15173 (add_include_dir): Replace with ...
15174 (line_header::add_include_dir): ... this method. Use std::vector.
15175 (add_file_name): Replace with ...
15176 (line_header::add_file_name): ... this method. Use std::vector.
15177 (add_include_dir_stub): Delete.
15178 (read_formatted_entries): Remove memset.
15179 (dwarf_decode_line_header): Return a line_header_up instead of a
15180 raw pointer. Remove cleanup handling. Pass lambdas to
15181 read_formatted_entries. Adjust to use line_header methods.
15182 (dwarf_decode_lines_1): Adjust to use line_header methods.
15183 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
15184 use std::vector.
15185
15186 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
15187
15188 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
15189 instead of struct ptid.
15190
15191 2017-05-04 Alan Hayward <alan.hayward@arm.com>
15192
15193 * frame.c (get_frame_register_bytes): Unwind using value.
15194 (put_frame_register_bytes): Likewise.
15195
15196 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
15197
15198 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
15199 aggregate-like.
15200
15201 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
15202
15203 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
15204
15205 2017-03-29 Yao Qi <yao.qi@linaro.org>
15206
15207 * gdbthread.h (struct thread_info): Declare constructor and
15208 destructor. Add some in-class member initializers.
15209 * thread.c (free_thread): Remove.
15210 (init_thread_list): Call delete instead of free_thread.
15211 (new_thread): Call thread_info constructor.
15212 (thread_info::thread_info): New function.
15213 (thread_info::~thread_info): New function.
15214 (delete_thread_1): Call delete instead of free_thread.
15215 (make_cleanup_restore_current_thread): Move tp and frame to
15216 inner block.
15217
15218 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15219
15220 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
15221 (arc_skip_prologue): Likewise.
15222 (arc_make_frame_cache): Likewise.
15223 (arc_pv_get_operand): New function.
15224 (arc_is_in_prologue): Likewise.
15225 (arc_analyze_prologue): Likewise.
15226 (arc_print_frame_cache): Likewise.
15227 (MAX_PROLOGUE_LENGTH): New constant.
15228
15229 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15230
15231 * configure.tgt: Add arc-insn.o.
15232 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
15233 (dump_arc_instruction_command): New function.
15234 (arc_fprintf_disasm): Likewise.
15235 (arc_disassemble_info): Likewise.
15236 (arc_insn_get_operand_value): Likewise.
15237 (arc_insn_get_operand_value_signed): Likewise.
15238 (arc_insn_get_memory_base_reg): Likewise.
15239 (arc_insn_get_memory_offset): Likewise.
15240 (arc_insn_get_branch_target): Likewise.
15241 (arc_insn_dump): Likewise.
15242 (arc_insn_get_linear_next_pc): Likewise.
15243 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
15244 (arc_disassemble_info): Likewise.
15245 (arc_insn_get_branch_target): Likewise.
15246 (arc_insn_get_linear_next_pc): Likewise.
15247 * NEWS: Mention new "maint print arc arc-instruction".
15248
15249 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15250
15251 * arc-tdep (maintenance_print_arc_list): New variable.
15252 (maintenance_print_arc_command): New function.
15253
15254 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15255
15256 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
15257 Add "limm" and "reserved".
15258 (arc_cannot_fetch_register, arc_cannot_store_register): Add
15259 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
15260 * arc-tdep.h (arc_regnum): Likewise.
15261
15262 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15263
15264 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15265 for THREADPTR register.
15266 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
15267 register.
15268 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
15269 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
15270 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
15271
15272 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15273
15274 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
15275 registers above gdbarch_num_regs (gdbarch) as privileged in
15276 call0 ABI.
15277
15278 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15279
15280 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15281 for a single specified register or for all registers in
15282 a0_base..a0_base + C0_NREGS range.
15283 (supply_gregset_reg): Call regcache_raw_supply for a single
15284 specified register or for all registers in a0_base..a0_base +
15285 C0_NREGS range.
15286
15287 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15288
15289 * arch/xtensa.h (C0_NREGS): Add definition.
15290 * xtensa-tdep.c (C0_NREGS): Remove definition.
15291
15292 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15293
15294 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
15295 Drop xtensa_default_isa initialization.
15296 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
15297
15298 2017-03-27 Pedro Alves <palves@redhat.com>
15299
15300 * dwarf2read.c (file_entry) <dir_index>: Add comment.
15301 (file_entry::include_dir): New method.
15302 (line_header::include_dir_at, line_header::file_name_at): New
15303 methods.
15304 (setup_type_unit_groups, setup_type_unit_groups)
15305 (psymtab_include_file_name): Simplify using the new methods.
15306 (lnp_state_machine) <the_line_header>: New field.
15307 <file>: Add comment.
15308 (lnp_state_machine::current_file): New method.
15309 (dwarf_record_line): Simplify using the new methods.
15310 (init_lnp_state_machine): Initialize the "the_line_header" field.
15311 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
15312 Simplify using the new methods.
15313
15314 2017-03-27 Pedro Alves <palves@redhat.com>
15315
15316 * cp-name-parser.y (make_empty): Delete.
15317 (demangler_special, nested_name, ptr_operator, array_indicator)
15318 (direct_declarator, declarator_1): Use fill_comp instead of
15319 make_empty.
15320
15321 2017-03-27 Pedro Alves <palves@redhat.com>
15322
15323 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
15324 to ATTRIBUTE_PRINTF.
15325 * solib-target.c (library_list_start_list): Print "string" not
15326 "version".
15327 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
15328 gdb_xml_error call.
15329
15330 2017-03-27 Pedro Alves <palves@redhat.com>
15331
15332 * dwarf2read.c (struct file_and_directory): New.
15333 (dwarf2_get_dwz_file): Adjust to use std::string.
15334 (dw2_get_file_names_reader): Adjust to use file_and_directory.
15335 (find_file_and_directory): Adjust to return a file_and_directory
15336 object.
15337 (read_file_scope): Adjust to use file_and_directory. Remove
15338 make_cleanup/do_cleanups calls.
15339 (open_and_init_dwp_file): Adjust to use std::string. Remove
15340 make_cleanup/do_cleanups calls.
15341 * python/python.c (do_start_initialization): Adjust to ldirname
15342 returning a std::string.
15343 * utils.c (ldirname): Now returns a std::string.
15344 * utils.h (ldirname): Change return type to std::string.
15345 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
15346 returning a std::string.
15347 * xml-tdesc.c (file_read_description_xml): Likewise.
15348
15349 2017-03-24 Alan Hayward <alan.hayward@arm.com>
15350
15351 * regcache.c (regcache_debug_print_register): New function.
15352 * regcache.h (regcache_debug_print_register): New declaration.
15353 * target.c (debug_print_register): Remove.
15354 (target_fetch_registers): Call regcache_debug_print_register.
15355 (target_store_registers): Likewise.
15356
15357 2017-03-24 Pádraig Brady <pbrady@fb.com>
15358
15359 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
15360 reference beyond the 'lh->include_dirs' array before accessing to
15361 it.
15362 (psymtab_include_file_name): Likewise.
15363 (dwarf_decode_lines_1): Likewise.
15364 (dwarf_decode_lines): Likewise.
15365 (file_file_name): Likewise.
15366
15367 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
15368
15369 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
15370 inferior_ptid.
15371 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15372 ps_lsetfpregs): Likewise.
15373 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
15374 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15375 ps_lsetfpregs): Likewise.
15376 * target.c (target_fetch_registers, target_store_registers):
15377 Remove asserts.
15378
15379 2017-03-23 Alan Hayward <alan.hayward@arm.com>
15380
15381 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
15382
15383 2017-03-23 Yao Qi <yao.qi@linaro.org>
15384
15385 * aarch64-tdep.c (aarch64_process_record_test): Declare.
15386 (_initialize_aarch64_tdep): Register it.
15387 (aarch64_record_load_store): Handle PRFM instruction.
15388 (aarch64_process_record_test): New function.
15389
15390 2017-03-23 Yao Qi <yao.qi@linaro.org>
15391
15392 * aarch64-tdep.c (aarch64_record_load_store): Fix code
15393 indentation.
15394
15395 2017-03-23 Yao Qi <yao.qi@linaro.org>
15396
15397 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
15398
15399 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15400
15401 python/python.c (do_start_initialization): Fix memory leak.
15402
15403 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
15404
15405 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
15406 using get_ptrace_pid.
15407 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
15408 inferior_ptid.
15409 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
15410 inferior_ptid instead of pid.
15411
15412 2017-03-22 Yao Qi <yao.qi@linaro.org>
15413
15414 * aarch64-tdep.c: Wrap locally used classes in anonymous
15415 namespace.
15416 * arm-tdep.c: Likewise.
15417 * linespec.c: Likewise.
15418 * ui-out.c: Likewise.
15419
15420 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
15421
15422 PR gdb/19637
15423 * python/lib/gdb/printer/bound_registers.py: Import sys.
15424
15425 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15426
15427 * windows-nat.c (do_windows_fetch_inferior_registers): Add
15428 windows_thread_info parameter and use it instead of
15429 current_thread.
15430 (windows_fetch_inferior_registers): Don't set current_thread,
15431 pass the thread to do_windows_fetch_inferior_registers. Use
15432 ptid from regcache instead of inferior_ptid.
15433 (do_windows_store_inferior_registers): Add windows_thread_info
15434 parameter and use it instead of current_thread.
15435 (windows_store_inferior_registers): Don't set current_thread,
15436 pass the thread to do_windows_store_inferior_registers. Use
15437 ptid from regcache instead of inferior_ptid.
15438
15439 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15440
15441 * ser-mingw.c (ser_windows_raw): Remove reference to
15442 struct serial::current_timeout.
15443
15444 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15445
15446 PR tdep/20928
15447 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15448 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15449 (sparc64_fsr_type): Fix %fsr decoding.
15450
15451 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15452
15453 * python/py-record-btrace.c (btpy_insn_data): Change return type
15454 for Python 2.
15455
15456 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15457
15458 * spu-linux-nat.c (spu_fetch_inferior_registers,
15459 spu_store_inferior_registers): Use ptid from regcache, set and
15460 restore inferior_ptid.
15461 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15462 Likewise.
15463
15464 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15465
15466 * i386-linux-nat.c (fetch_register, store_register,
15467 i386_linux_fetch_inferior_registers,
15468 i386_linux_store_inferior_registers): Use ptid from regcache.
15469 * ia64-linux-nat.c (ia64_linux_fetch_register,
15470 ia64_linux_store_register): Likewise.
15471 * inf-ptrace.c (inf_ptrace_fetch_register,
15472 inf_ptrace_store_register): Likewise.
15473 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15474 m32r_linux_store_inferior_registers): Likewise.
15475 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15476 m68kbsd_store_inferior_registers): Likewise.
15477 * m68k-linux-nat.c (fetch_register, store_register,
15478 m68k_linux_fetch_inferior_registers,
15479 m68k_linux_store_inferior_registers): Likewise.
15480 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15481 m88kbsd_store_inferior_registers): Likewise.
15482 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15483 mips_fbsd_store_inferior_registers): Likewise.
15484 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15485 mips64_linux_regsets_store_registers): Likewise.
15486 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15487 mipsnbsd_store_inferior_registers): Likewise.
15488 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15489 mips64obsd_store_inferior_registers): Likewise.
15490 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15491 Likewise.
15492 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15493 ppcfbsd_store_inferior_registers): Likewise.
15494 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15495 ppc_linux_store_inferior_registers): Likewise.
15496 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15497 ppcnbsd_store_inferior_registers): Likewise.
15498 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15499 ppcobsd_store_registers): Likewise.
15500 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15501 Likewise.
15502 * ravenscar-thread.c (ravenscar_fetch_registers,
15503 ravenscar_store_registers, ravenscar_prepare_to_store):
15504 Likewise.
15505 * record-btrace.c (record_btrace_fetch_registers,
15506 record_btrace_store_registers, record_btrace_prepare_to_store):
15507 Likewise.
15508 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15509 Lookup inferior using ptid from regcache, instead of
15510 current_inferior.
15511 * remote.c (remote_fetch_registers, remote_store_registers): Use
15512 ptid from regcache.
15513 * rs6000-nat.c (fetch_register, store_register): Likewise.
15514 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15515 s390_linux_store_inferior_registers): Likewise.
15516 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15517 shnbsd_store_inferior_registers): Likewise.
15518 * sol-thread.c (sol_thread_fetch_registers,
15519 sol_thread_store_registers): Likewise.
15520 * sparc-nat.c (sparc_fetch_inferior_registers,
15521 sparc_store_inferior_registers): Likewise.
15522 * tilegx-linux-nat.c (fetch_inferior_registers,
15523 store_inferior_registers): Likewise.
15524 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15525 vaxbsd_store_inferior_registers): Likewise.
15526 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15527 store_xtregs): Likewise.
15528
15529 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15530
15531 PR gdb/14441
15532 * NEWS: Mention support for rvalue references in GDB and python.
15533 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15534 supports both lvalue and rvalue references.
15535
15536 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15537
15538 PR gdb/14441
15539 * gdbtypes.c (rank_one_type): Implement overloading
15540 resolution rules regarding rvalue references.
15541
15542 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15543
15544 PR gdb/14441
15545 * aarch64-tdep.c (aarch64_type_align)
15546 (aarch64_extract_return_value, aarch64_store_return_value): Change
15547 lvalue reference type checks to general reference type checks.
15548 * amd64-tdep.c (amd64_classify): Likewise.
15549 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15550 Likewise.
15551 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15552 (arm_store_return_value): Likewise.
15553 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15554 * c-typeprint.c (c_print_type): Likewise.
15555 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15556 (cplus_number_of_children, cplus_describe_child): Likewise.
15557 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15558 * completer.c (expression_completer): Likewise.
15559 * cp-support.c (make_symbol_overload_list_adl_namespace):
15560 Likewise.
15561 * darwin-nat-info.c (info_mach_region_command): Likewise.
15562 * dwarf2loc.c (entry_data_value_coerce_ref)
15563 (value_of_dwarf_reg_entry): Likewise.
15564 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15565 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15566 Likewise.
15567 * findvar.c (extract_typed_address, store_typed_address):
15568 Likewise.
15569 * gdbtypes.c (rank_one_type): Likewise.
15570 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15571 * infcall.c (value_arg_coerce): Likewise.
15572 * language.c (pointer_type): Likewise.
15573 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15574 Likewise.
15575 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15576 * mn10300-tdep.c (mn10300_type_align): Likewise.
15577 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15578 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15579 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15580 Likewise.
15581 * printcmd.c (print_formatted, x_command): Likewise.
15582 * python/py-type.c (typy_get_composite, typy_template_argument):
15583 Likewise.
15584 * python/py-value.c (valpy_referenced_value)
15585 (valpy_get_dynamic_type, value_has_field): Likewise.
15586 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15587 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15588 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15589 * spu-tdep.c (spu_scalar_value_p): Likewise.
15590 * symtab.c (lookup_symbol_aux): Likewise.
15591 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15592 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15593 Likewise.
15594 * valops.c (value_cast_pointers, value_cast)
15595 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15596 (value_struct_elt, value_struct_elt_bitpos)
15597 (value_find_oload_method_list, find_overload_match)
15598 (value_rtti_indirect_type): Likewise.
15599 * valprint.c (val_print_scalar_type_p, generic_val_print):
15600 Likewise.
15601 * value.c (value_actual_type, value_as_address, unpack_long)
15602 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15603 (coerce_ref): Likewise.
15604 * varobj.c (varobj_get_value_type): Likewise.
15605
15606 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15607
15608 PR gdb/14441
15609 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15610 table of constants.
15611 * python/lib/gdb/command/explore.py: Support exploring values
15612 of rvalue reference types.
15613 * python/lib/gdb/types.py: Implement get_basic_type() for
15614 rvalue reference types.
15615 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15616 constant.
15617 * python/py-value.c (valpy_getitem): Add an rvalue reference
15618 check.
15619 (valpy_reference_value): Add new parameter "refcode".
15620 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15621 New wrappers for valpy_reference_value().
15622 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15623 (gdbpy_invoke_xmethod): Likewise.
15624
15625 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15626
15627 PR gdb/14441
15628 * dwarf2read.c (process_die, read_type_die_1): Handle the
15629 DW_TAG_rvalue_reference_type DIE.
15630 (read_tag_reference_type): Add new parameter "refcode".
15631
15632 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15633
15634 PR gdb/14441
15635 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15636 (c_type_print_modifier, c_type_print_varspec_suffix)
15637 (c_type_print_base): Support printing rvalue reference types.
15638 * c-valprint.c (c_val_print, c_value_print): Support printing
15639 rvalue reference values.
15640
15641 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15642
15643 PR gdb/14441
15644 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15645 typename.
15646 * cp-support.c (replace_typedefs): Handle
15647 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15648 * python/py-type.c (typy_lookup_type): Likewise.
15649
15650 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15651
15652 PR gdb/14441
15653 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15654 * parse.c (insert_type): Change assert statement.
15655 (follow_types): Handle rvalue reference types.
15656 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15657 constant.
15658
15659 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15660
15661 PR gdb/14441
15662 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15663 value_ref() interface.
15664 * c-valprint.c (c_value_print): Likewise.
15665 * infcall.c (value_arg_coerce): Likewise.
15666 * python/py-value.c (valpy_reference_value): Likewise.
15667 * valops.c (value_cast, value_reinterpret_cast)
15668 (value_dynamic_cast, typecmp): Likewise.
15669 (value_ref): Parameterize by kind of return value reference type.
15670 * value.h (value_ref): Add new parameter "refcode".
15671
15672 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15673
15674 PR gdb/14441
15675 * dwarf2read.c (read_tag_reference_type): Use
15676 lookup_lvalue_reference_type() instead of lookup_reference_type().
15677 * eval.c (evaluate_subexp_standard): Likewise.
15678 * f-exp.y: Likewise.
15679 * gdbtypes.c (make_reference_type, lookup_reference_type):
15680 Generalize with rvalue reference types.
15681 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15682 convenience wrappers for lookup_reference_type().
15683 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15684 reference kind parameter.
15685 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15686 wrappers for lookup_reference_type().
15687 * guile/scm-type.c (gdbscm_type_reference): Use
15688 lookup_lvalue_reference_type() instead of lookup_reference_type().
15689 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15690 * parse.c (follow_types): Likewise.
15691 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15692 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15693 Likewise.
15694 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15695 (gdbpy_invoke_xmethod): Likewise.
15696 * stabsread.c: Provide extra argument to make_reference_type()
15697 call.
15698 * valops.c (value_ref, value_rtti_indirect_type): Use
15699 lookup_lvalue_reference_type() instead of lookup_reference_type().
15700
15701 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
15702
15703 PR gdb/14441
15704 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15705 (TYPE_IS_REFERENCE): New macro.
15706 (struct type): Add rvalue_reference_type field.
15707 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15708
15709 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15710
15711 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15712 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15713 New function definition.
15714 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15715 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15716 New function declaration.
15717 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15718 * mi/mi-interp.h: New file.
15719 * solib.c (info_sharedlibrary_command): Replace for loop with
15720 ALL_SO_LIBS macro
15721 * solib.h (update_solib_list): New function declaration.
15722 (so_list_head): Move macro.
15723 * solist.h (ALL_SO_LIBS): New macro.
15724
15725 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15726
15727 * infcmd.c (post_create_inferior): Remove unused argument in
15728 call to solib_add.
15729 * remote.c (remote_start_remote): Likewise.
15730 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15731 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15732 (enable_break): Likewise.
15733 * solib.c (update_solib_list): Remove unused target argument
15734 and its documentation.
15735 (solib_add): Remove unused target argument. Remove unused
15736 argument in call to update_solib_list.
15737 (info_sharedlibrary_command): Remove unused argument in call
15738 to update_solib_list.
15739 (sharedlibrary_command): Remove unused argument in call to
15740 solib_add.
15741 (handle_solib_event): Likewise.
15742 (reload_shared_libraries): Likewise.
15743 * solib.h (solib_add): Remove unused target argument.
15744
15745 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15746
15747 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15748 (s390_displaced_step_fixup): Cover relative branches with the
15749 default fixup handling. This fixes lack of support for some
15750 relative branch instructions.
15751
15752 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15753
15754 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15755 ptid from regcache.
15756
15757 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15758
15759 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15760 i386_darwin_store_inferior_registers): Use ptid from regcache.
15761
15762 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15763
15764 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15765 i386bsd_store_inferior_registers): Use ptid from regcache.
15766
15767 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15768
15769 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15770 hppaobsd_store_registers): Use ptid from regcache.
15771
15772 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15773
15774 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15775 hppanbsd_store_registers): Use ptid from regcache.
15776
15777 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15778
15779 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
15780 from regcache. Use get_ptrace_pid.
15781
15782 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15783
15784 * corelow.c (get_core_register_section): Use ptid from regcache,
15785 update doc.
15786
15787 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15788
15789 * bsd-uthread.c (bsd_uthread_fetch_registers,
15790 bsd_uthread_store_registers): Use ptid from regcache, set and
15791 restore inferior_ptid.
15792
15793 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15794
15795 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
15796 fetch_fp_regs, store_register, store_regs, store_fp_register,
15797 store_fp_regs): Use ptid from regcache.
15798
15799 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15800
15801 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
15802 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
15803 store_vfp_regs): Use ptid from regcache.
15804
15805 2017-03-17 Pedro Alves <palves@redhat.com>
15806
15807 PR remote/21188
15808 * ser-base.c (ser_base_wait_for): Add comment.
15809 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
15810 version.
15811 * ser-unix.c (hardwire_raw): Remove reference to
15812 scb->current_timeout.
15813 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
15814 (hardwire_ops): Install ser_base_readchar instead of
15815 hardwire_readchar.
15816 * serial.h (struct serial) <current_timeout, timeout_remaining>:
15817 Remove fields.
15818
15819 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
15820
15821 PR gdb/19637
15822 * python/lib/gdb/printer/bound_registers.py: Add support for
15823 Python 3.
15824
15825 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
15826
15827 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
15828 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
15829 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
15830 byte_offset to subobj_byte_offset. Fix the handling of
15831 DWARF_VALUE_STACK on big-endian targets when coming via an
15832 implicit pointer.
15833 (dwarf2_evaluate_loc_desc): Adjust call to
15834 dwarf2_evaluate_loc_desc_full.
15835 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
15836 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
15837
15838 2017-03-16 Yao Qi <yao.qi@linaro.org>
15839
15840 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
15841 and REVSH instructions.
15842
15843 2017-03-16 Yao Qi <yao.qi@linaro.org>
15844
15845 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
15846 (arm_record_test): Declare.
15847 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
15848 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
15849 align with the manual.
15850 (thumb_record_misc): Adjust the code order to align with the
15851 manual.
15852 (thumb2_record_decode_insn_handler): Fix instruction matching.
15853 (instruction_reader_thumb): New class.
15854 (arm_record_test): New function.
15855
15856 2017-03-16 Yao Qi <yao.qi@linaro.org>
15857
15858 * arm-tdep.c (abstract_memory_reader): New class.
15859 (instruction_reader): New class.
15860 (extract_arm_insn): Add argument 'reader'. Callers updated.
15861 (decode_insn): Likewise.
15862
15863 2017-03-16 Doug Evans <dje@google.com>
15864
15865 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
15866 member. Change type of TYPE member to SCM. All uses updated.
15867 (lsscm_make_lazy_string_smob): Add assert.
15868 (lsscm_make_lazy_string): Flag bad length values.
15869 (lsscm_elt_type): New function.
15870 (gdbscm_lazy_string_to_value): Rewrite to use
15871 lsscm_safe_lazy_string_to_value.
15872 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
15873 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
15874 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
15875 in incoming type.
15876 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15877 * guile/scm-type.c (tyscm_scm_to_type): New function.
15878
15879 2017-03-15 Doug Evans <dje@google.com>
15880
15881 PR python/17728, python/18439, python/18779
15882 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
15883 member. Change type of TYPE member to PyObject *. All uses updated.
15884 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
15885 (gdbpy_create_lazy_string_object): Flag bad length values.
15886 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
15887 Handle typedefs in incoming type.
15888 (stpy_lazy_string_elt_type): New function.
15889 (gdbpy_extract_lazy_string): Call it.
15890 * python/py-value.c (valpy_lazy_string): Flag bad length values.
15891 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
15892 typedefs in incoming type.
15893
15894 2017-03-16 Doug Evans <dje@google.com>
15895
15896 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15897 * guile/scm-type.c (tyscm_scm_to_type): New function.
15898
15899 2017-03-16 Jiong Wang <jiong.wang@arm.com>
15900
15901 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
15902 "ULONGEST" for "skip".
15903
15904 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15905
15906 PR gdb/21220
15907 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
15908 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
15909 (inf_ptrace_peek_poke): ...here. New function. Now also loop
15910 over ptrace peek/poke until end of buffer or error.
15911
15912 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
15913
15914 * parse.c (length_of_subexp): Make static.
15915 * parser-defs.h (length_of_subexp): Remove.
15916
15917 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15918
15919 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
15920 as well.
15921
15922 2017-03-14 Pedro Alves <palves@redhat.com>
15923
15924 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
15925 (main): Use std::unique_ptr. Remove calls to
15926 cp_demangled_name_parse_free.
15927
15928 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15929
15930 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
15931 alphabsd_store_inferior_registers): Use regcache->ptid instead
15932 of inferior_ptid.
15933
15934 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15935
15936 * aix-thread.c (aix_thread_fetch_registers,
15937 aix_thread_store_registers): Use regcache->ptid instead of
15938 inferior_ptid.
15939
15940 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15941
15942 * aarch64-linux-nat.c (fetch_gregs_from_thread,
15943 store_gregs_to_thread, fetch_fpregs_from_thread,
15944 store_fpregs_to_thread): Use regcache->ptid instead of
15945 inferior_ptid.
15946
15947 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15948
15949 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
15950 amd64_linux_fetch_inferior_registers): Use regcache->ptid
15951 instead of inferior_ptid.
15952
15953 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15954
15955 * target.c (target_fetch_registers, target_store_registers): Add
15956 assert.
15957
15958 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15959
15960 * regcache.h (regcache_get_ptid): New function.
15961 * regcache.c (regcache_get_ptid): New function.
15962
15963 2017-03-13 Mark Wielaard <mark@klomp.org>
15964
15965 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
15966
15967 2017-03-10 Keith Seitz <keiths@redhat.com>
15968
15969 PR c++/8218
15970 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
15971
15972 2017-03-08 Pedro Alves <palves@redhat.com>
15973
15974 PR gdb/18360
15975 * infrun.c (start_step_over, do_target_resume, resume)
15976 (restart_threads): Assert we're not resuming a thread that is
15977 meant to be stopped.
15978 (infrun_thread_stop_requested_callback): Delete.
15979 (infrun_thread_stop_requested): If the thread is internally
15980 stopped, queue a pending stop event and clear the thread's
15981 inline-frame state.
15982 (handle_stop_requested): New function.
15983 (handle_syscall_event, handle_inferior_event_1): Use
15984 handle_stop_requested.
15985 (handle_stop_requested): New function.
15986 (handle_signal_stop): Set the thread's stop_signal here instead of
15987 at caller.
15988 (finish_step_over): Clear step over info unconditionally.
15989 (handle_signal_stop): If the user had interrupted the event
15990 thread, consider the stop a random signal.
15991 (handle_signal_stop) <signal arrived while stepping over
15992 breakpoint>: Don't restart threads here.
15993 (stop_waiting): Don't clear step-over info here.
15994
15995 2017-03-08 Pedro Alves <palves@redhat.com>
15996
15997 PR 21206
15998 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
15999 goes to argument 2, not 1.
16000
16001 2017-03-08 Pedro Alves <palves@redhat.com>
16002
16003 PR cli/21218
16004 * top.c (gdb_readline_wrapper): Avoid passing NULL to
16005 display_gdb_prompt.
16006 (command_line_input): Add comment.
16007
16008 2017-03-08 Pedro Alves <palves@redhat.com>
16009
16010 PR tui/21216
16011 * tui/tui-file.c (tui_file::write): New.
16012 * tui/tui-file.h (tui_file): Override "write".
16013 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
16014 factored out from ...
16015 (tui_puts): ... here.
16016 (tui_putc): Use them.
16017 (tui_write): New function.
16018 * tui/tui-io.h (tui_write): Declare.
16019
16020 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
16021
16022 * Makefile.in (SFILES): Replace "environ.c" with
16023 "common/environ.c".
16024 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
16025 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
16026 to...
16027 * common/environ.c: ... here.
16028 * environ.h: Moved to...
16029 * common/environ.h: ... here.
16030
16031 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16032
16033 * gdbarch.sh (pstring_ptr): New static function.
16034 (gdbarch_disassembler_options): Use it.
16035 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
16036 not valid_disassembler_option->name.
16037 * gdbarch.c: Regenerate.
16038
16039 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16040
16041 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
16042
16043 2017-03-07 Pedro Alves <palves@redhat.com>
16044
16045 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
16046
16047 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
16048
16049 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
16050 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
16051 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
16052 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
16053
16054 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
16055
16056 * xtensa-linux-nat.c (fetch_gregs): Remove const.
16057
16058 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
16059
16060 * remote.c (remote_add_target_side_commands): Use range-based
16061 for loop.
16062
16063 2017-03-03 Yao Qi <yao.qi@linaro.org>
16064
16065 PR gdb/21165
16066 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
16067 value is lazy.
16068 * valprint.c (common_val_print): Likewise.
16069
16070 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
16071
16072 * NEWS: Mention new set/show disassembler-options commands.
16073 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
16074 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
16075 (prospective_options): New static variable.
16076 (gdb_disassembler::gdb_disassembler): Initialize
16077 m_di.disassembler_options.
16078 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
16079 (get_disassembler_options): New function.
16080 (set_disassembler_options): Likewise.
16081 (set_disassembler_options_sfunc): Likewise.
16082 (show_disassembler_options_sfunc): Likewise.
16083 (disassembler_options_completer): Likewise.
16084 (_initialize_disasm): Likewise.
16085 * disasm.h (get_disassembler_options): New prototype.
16086 (set_disassembler_options): Likewise.
16087 * gdbarch.sh (gdbarch_disassembler_options): New variable.
16088 (gdbarch_verify_disassembler_options): Likewise.
16089 * gdbarch.c: Regenerate.
16090 * gdbarch.h: Likewise.
16091 * arm-tdep.c (num_disassembly_options): Delete.
16092 (set_disassembly_style): Likewise.
16093 (arm_disassembler_options): New static variable.
16094 (set_disassembly_style_sfunc): Convert short style name into long
16095 option name. Call set_disassembler_options.
16096 (show_disassembly_style_sfunc): New function.
16097 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
16098 set_gdbarch_verify_disassembler_options.
16099 (_initialize_arm_tdep): Delete regnames variable and update callers.
16100 (arm_disassembler_options): Initialize.
16101 (disasm_options): New variable.
16102 (num_disassembly_options): Rename from this...
16103 (num_disassembly_styles): ...to this. Compute by scanning through
16104 disasm_options.
16105 (valid_disassembly_styles): Initialize using disasm_options.
16106 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
16107 set_arm_regname_option.
16108 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
16109 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
16110 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
16111 set_gdbarch_verify_disassembler_options.
16112 * s390-tdep.c (s390_disassembler_options): New static variable.
16113 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
16114 set_gdbarch_verify_disassembler_options.
16115
16116 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16117
16118 * remote.c (remote_add_target_side_condition): Remove "struct"
16119 keyword from range-based for loop.
16120
16121 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16122
16123 * remote.c (remote_add_target_side_condition): Use range-based
16124 for loop. Update comment.
16125
16126 2017-02-27 Yao Qi <yao.qi@linaro.org>
16127
16128 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
16129
16130 2017-02-26 Alan Hayward <alan.hayward@arm.com>
16131
16132 * regcache.c (regcache_raw_update): New function.
16133 (regcache_raw_read): Move code to regcache_raw_update.
16134 * regcache.h (regcache_raw_update): New declaration.
16135 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
16136
16137 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
16138
16139 * dwarf2read.c (create_debug_type_hash_table): Initialize
16140 header.signature and header.type_offset_in_tu.
16141
16142 2017-02-24 Pedro Alves <palves@redhat.com>
16143
16144 * symtab.c (make_file_symbol_completion_list_1): Use
16145 add_symtab_completions.
16146
16147 2017-02-24 Alan Hayward <alan.hayward@arm.com>
16148
16149 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
16150
16151 2017-02-24 Alan Hayward <alan.hayward@arm.com>
16152
16153 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
16154 I386_MAX_REGISTER_SIZE.
16155 (i386_pseudo_register_write): Likewise.
16156 (i386_process_record): Likewise.
16157 * i387-tdep.c (i387_supply_xsave): Likewise.
16158 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
16159 (store_register): Likewise.
16160
16161 2017-02-23 Pedro Alves <palves@redhat.com>
16162
16163 * ada-lang.c: Include "common/function-view.h".
16164 (ada_iterate_over_symbols): Adjust to use function_view as
16165 callback type.
16166 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
16167 (ada_make_symbol_completion_list): Use a lambda.
16168 (ada_exc_search_name_matches): Delete.
16169 (name_matches_regex): New.
16170 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
16171 * compile/compile-c-support.c: Include "common/function-view.h".
16172 (print_one_macro): Change prototype to accept a ui_file pointer.
16173 (write_macro_definitions): Use a lambda.
16174 * dwarf2read.c: Include "common/function-view.h".
16175 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
16176 (dw2_expand_symtabs_matching): Adjust to use function_view as
16177 callback type.
16178 * language.h: Include "common/function-view.h".
16179 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
16180 function_view as callback type.
16181 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
16182 * linespec.c: Include "common/function-view.h".
16183 (collect_info::add_symbol): New method.
16184 (struct symbol_and_data_callback, iterate_inline_only, struct
16185 symbol_matcher_data, iterate_name_matcher): Delete.
16186 (iterate_over_all_matching_symtabs): Adjust to use function_view
16187 as callback type and lambdas.
16188 (iterate_over_file_blocks): Adjust to use function_view as
16189 callback type.
16190 (decode_compound_collector): Now a class with private fields.
16191 (decode_compound_collector::release_symbols): New method.
16192 (collect_one_symbol): Rename to...
16193 (decode_compound_collector::operator()): ... this and adjust.
16194 (lookup_prefix_sym): decode_compound_collector construction bits
16195 move to decode_compound_collector ctor. Pass the
16196 decode_compound_collector object directly as callback. Remove
16197 cleanups and use decode_compound_collector::release_symbols
16198 instead.
16199 (symtab_collector): Now a class with private fields.
16200 (symtab_collector::release_symtabs): New method.
16201 (add_symtabs_to_list): Rename to...
16202 (symtab_collector::operator()): ... this and adjust.
16203 (collect_symtabs_from_filename): symtab_collector construction
16204 bits move to symtab_collector ctor. Pass the symtab_collector
16205 object directly as callback. Remove cleanups and use
16206 symtab_collector::release_symtabs instead.
16207 (collect_symbols): Delete.
16208 (add_matching_symbols_to_info): Use lambdas.
16209 * macrocmd.c (print_macro_callback): Delete.
16210 (info_macro_command): Use a lambda.
16211 (info_macros_command): Pass print_macro_definition as callable
16212 directly.
16213 (print_one_macro): Remove 'ignore' parameter.
16214 (macro_list_command): Adjust.
16215 * macrotab.c (macro_for_each_data::fn): Now a function_view.
16216 (macro_for_each_data::user_data): Delete field.
16217 (foreach_macro): Adjust to call the function_view.
16218 (macro_for_each): Adjust to use function_view as callback type.
16219 (foreach_macro_in_scope): Adjust to call the function_view.
16220 (macro_for_each_in_scope): Adjust to use function_view as callback
16221 type.
16222 * macrotab.h: Include "common/function-view.h".
16223 (macro_callback_fn): Declare a prototype instead of a pointer.
16224 Remove "user_data" parameter.
16225 (macro_for_each, macro_for_each_in_scope): Adjust to use
16226 function_view as callback type.
16227 * psymtab.c (partial_map_expand_apply)
16228 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
16229 Adjust to use function_view as callback type and to return bool.
16230 (psym_expand_symtabs_matching): Adjust to use function_view as
16231 callback types.
16232 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
16233 to use function_view as callback type and to return bool.
16234 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
16235 callback types.
16236 * symfile.c (expand_symtabs_matching): Adjust to use function_view
16237 as callback types.
16238 * symfile.h: Include "common/function-view.h".
16239 (expand_symtabs_file_matcher_ftype)
16240 (expand_symtabs_symbol_matcher_ftype)
16241 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
16242 return bool.
16243 (quick_symbol_functions::map_symtabs_matching_filename)
16244 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
16245 function_view as callback type and return bool.
16246 (expand_symtabs_matching): Adjust to use function_view as callback
16247 type.
16248 (maintenance_expand_name_matcher)
16249 (maintenance_expand_file_matcher): Delete.
16250 (maintenance_expand_symtabs): Use lambdas.
16251 * symtab.c (iterate_over_some_symtabs): Adjust to use
16252 function_view as callback types and return bool.
16253 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
16254 of a cleanup.
16255 (lookup_symtab_callback): Delete.
16256 (lookup_symtab): Use a lambda.
16257 (iterate_over_symbols): Adjust to use function_view as callback
16258 type.
16259 (struct search_symbols_data, search_symbols_file_matches)
16260 (search_symbols_name_matches): Delete.
16261 (search_symbols): Use a pair of lambdas.
16262 (struct add_name_data, add_macro_name, symbol_completion_matcher)
16263 (symtab_expansion_callback): Delete.
16264 (default_make_symbol_completion_list_break_on_1): Use lambdas.
16265 * symtab.h: Include "common/function-view.h".
16266 (iterate_over_some_symtabs): Adjust to use function_view as
16267 callback type and return bool.
16268 (iterate_over_symtabs): Adjust to use function_view as callback
16269 type.
16270 (symbol_found_callback_ftype): Remove 'data' parameter and return
16271 bool.
16272 (iterate_over_symbols): Adjust to use function_view as callback
16273 type.
16274
16275 2017-02-23 Pedro Alves <palves@redhat.com>
16276
16277 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
16278 (%.o) <unittests/%.c>: New pattern.
16279 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
16280 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
16281 * common/function-view.h: New file.
16282 * unittests/function-view-selftests.c: New file.
16283 * configure: Regenerate.
16284
16285 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
16286
16287 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
16288 inferior_ptid.
16289 * go32-nat.c (go32_thread_alive): Likewise.
16290
16291 2017-02-23 Yao Qi <yao.qi@linaro.org>
16292
16293 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
16294 delete.
16295
16296 2017-02-23 Yao Qi <yao.qi@linaro.org>
16297
16298 * varobj.c (varobj_clear_saved_item): Use delete instead of
16299 xfree.
16300 (update_dynamic_varobj_children): Likewise.
16301
16302 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16303
16304 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
16305
16306 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
16307
16308 * common/enum-flags.h (enum_flags::enum_flags): Initialize
16309 m_enum_value to 0 in default constructor.
16310
16311 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
16312
16313 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
16314 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
16315 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
16316 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
16317 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
16318 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
16319 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
16320 IS_STORE_CONDITIONAL_INSN.
16321
16322 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16323
16324 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
16325
16326 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16327
16328 * NEWS (Changes since GDB 7.12): Add DWARF-5.
16329
16330 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16331
16332 * dwarf2read.c (skip_one_die, read_attribute_value)
16333 (dwarf2_const_value_attr, dump_die_shallow)
16334 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
16335 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
16336
16337 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16338
16339 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
16340 (dwarf_parse_macro_header): Accept DWARF version 5.
16341 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
16342
16343 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16344
16345 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
16346 DW_AT_GNU_*.
16347 * common/common-exceptions.h (enum errors): Likewise.
16348 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
16349 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
16350 (dwarf_expr_context::execute_stack_op): Likewise.
16351 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
16352 Likewise.
16353 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
16354 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
16355 (show_entry_values_debug, call_site_to_target_addr)
16356 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
16357 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
16358 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
16359 (value_of_dwarf_block_entry, indirect_pieced_value)
16360 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
16361 (disassemble_dwarf_expression): Likewise.
16362 * dwarf2read.c (process_die, inherit_abstract_dies)
16363 (read_call_site_scope): Likewise.
16364 * gdbtypes.h (struct func_type, struct call_site_parameter)
16365 (struct call_site): Likewise.
16366 * stack.c (read_frame_arg): Likewise.
16367 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
16368
16369 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16370
16371 * defs.h (read_unsigned_leb128): New declaration.
16372 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
16373 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
16374 (dwarf2_find_location_expression): Call also
16375 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
16376 * dwarf2loc.h (dwarf2_version): New declaration.
16377 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
16378 rnglists.
16379 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
16380 .debug_rnglists.
16381 (struct dwop_section_names): Add loclists_dwo.
16382 (dwop_section_names): Add .debug_loclists.dwo.
16383 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
16384 (struct dwarf2_per_cu_data): Add dwarf_version.
16385 (struct dwo_sections): Add loclists.
16386 (struct attr_abbrev): Add implicit_const.
16387 (read_indirect_line_string): New declaration.
16388 (read_unsigned_leb128): Delete declaration.
16389 (rcuh_kind): New definition.
16390 (read_and_check_comp_unit_head): Change parameter
16391 is_debug_types_section to section_kind.
16392 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
16393 (read_comp_unit_head): Change parameter abfd to section, add parameter
16394 section_kind. Handle DWARF-5.
16395 (error_check_comp_unit_head): Accept also DWARF version 5.
16396 (read_and_check_comp_unit_head): Change parameter
16397 is_debug_types_section to section_kind.
16398 (read_and_check_type_unit_head): Delete function.
16399 (read_abbrev_offset): Handle DWARF-5.
16400 (create_debug_type_hash_table): Add parameter section_kind. Process
16401 only DW_UT_type. Use signature and type_offset_in_tu from struct
16402 comp_unit_head.
16403 (create_debug_types_hash_table): Update create_debug_type_hash_table
16404 caller.
16405 (create_all_type_units): Call create_debug_type_hash_table.
16406 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
16407 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
16408 caller.
16409 (skip_one_die): Handle DW_FORM_implicit_const.
16410 (dwarf2_rnglists_process): New function.
16411 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
16412 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
16413 (read_attribute_value): Handle DW_FORM_implicit_const,
16414 DW_FORM_line_strp.
16415 (read_attribute): Handle DW_FORM_implicit_const.
16416 (read_indirect_string_at_offset_from): New function from
16417 read_indirect_string_at_offset.
16418 (read_indirect_string_at_offset): Call
16419 read_indirect_string_at_offset_from.
16420 (read_indirect_line_string_at_offset): New function.
16421 (read_indirect_string): New function comment.
16422 (read_indirect_line_string): New function.
16423 (read_unsigned_leb128): Make it global.
16424 (dwarf2_string_attr): Handle DWARF-5.
16425 (add_include_dir_stub, read_formatted_entries): New functions.
16426 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
16427 Handle DWARF-5.
16428 (per_cu_header_read_in): Update read_comp_unit_head caller.
16429 (dwarf2_version): New function.
16430 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
16431 rnglists.
16432 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16433 fields.
16434
16435 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16436
16437 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16438
16439 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16440
16441 * dwarf2read.c (dwarf2_ranges_process): New function from
16442 dwarf2_ranges_read.
16443 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16444 dwarf2_ranges_process.
16445
16446 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16447
16448 * dwarf2read.c (create_debug_type_hash_table): New function from
16449 create_debug_types_hash_table.
16450 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16451 (create_all_type_units, open_and_init_dwo_file): Update
16452 create_debug_types_hash_table callers.
16453
16454 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16455
16456 PR gdb/16188
16457 * fork-child.c (trace_start_error): Fix thinko. va_end should
16458 refer to 'ap', not 'args'.
16459
16460 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16461 Pedro Alves <palves@redhat.com>
16462
16463 PR gdb/16188
16464 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16465 calls succeeded.
16466 * fork-child.c (trace_start_error): New function.
16467 (trace_start_error_with_name): Likewise.
16468 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16469 * inf-ptrace.c (inf_ptrace_me): Likewise.
16470 * inferior.h (trace_start_error): New prototype.
16471 (trace_start_error_with_name): Likewise.
16472
16473 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16474
16475 PR gdb/21164
16476 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16477 NULL before using it.
16478 * symmisc.c (maintenance_print_symbols): Likewise.
16479 (maintenance_print_msymbols): Likewise.
16480
16481 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16482
16483 * NEWS: Add record Python bindings entry.
16484
16485 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16486
16487 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16488 py-record-full.o.
16489 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16490 * python/py-record-btrace.c, python/py-record-btrace.h,
16491 python/py-record-full.c, python/py-record-full.h: New file.
16492 * python/py-record.c: Add include for py-record-btrace.h and
16493 py-record-full.h.
16494 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16495 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16496 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16497 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16498 New definition.
16499 (gdbpy_initialize_btrace): New export.
16500 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16501
16502 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16503
16504 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16505 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16506 * python/py-record.c: New file.
16507 * python/python-internal.h (gdbpy_start_recording,
16508 gdbpy_current_recording, gdpy_stop_recording,
16509 gdbpy_initialize_record): New export.
16510 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16511 (python_GdbMethods): Add gdbpy_start_recording,
16512 gdbpy_current_recording and gdbpy_stop_recording.
16513
16514 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16515
16516 * record-btrace.c (record_btrace_record_method): New function.
16517 (init_record_btrace_ops): Initialize to_record_method.
16518 * record-full.c (record_full_record_method): New function.
16519 (init_record_full_ops, init_record_full_core_ops): Add
16520 record_full_record_method.
16521 * record.h (enum record_method): New enum.
16522 * target-debug.h (target_debug_print_enum_record_method: New define.
16523 * target-delegates.c: Regenerate.
16524 * target.c (target_record_method): New function.
16525 * target.h: Include record.h.
16526 (struct target_ops) <to_record_method>: New field.
16527 (target_record_method): New export.
16528
16529 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16530
16531 * record.h (record_start, record_stop): New export.
16532 * record.c (record_start, record_stop): New function.
16533
16534 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16535
16536 * btrace.c (btrace_fetch): Copy function call segments pointer
16537 into a vector.
16538 (btrace_clear): Clear the vector.
16539 (btrace_find_insn_by_number): Use binary search to find the correct
16540 function call segment.
16541 * btrace.h (brace_fun_p): New typedef.
16542 (struct btrace_thread_info) <functions>: New field.
16543
16544 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16545
16546 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16547 * btrace.c (btrace_decode_error): ... here. New function.
16548 * btrace.h (btrace_decode_error): New export.
16549
16550 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16551
16552 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16553 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16554 btrace_find_insn_by_number): Remove special case for gaps.
16555 * btrace.h (btrace_insn_get_error): New export.
16556 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16557 * record-btrace.c (btrace_insn_history): Print number for gaps.
16558 (record_btrace_info, record_btrace_goto): Handle gaps.
16559
16560 2017-02-14 Tom Tromey <tom@tromey.com>
16561
16562 PR python/13598:
16563 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16564 event.
16565 * python/py-evts.c (gdbpy_initialize_py_events): Add
16566 before_prompt registry.
16567 * python/py-events.h (events_object) <before_prompt>: New field.
16568
16569 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16570
16571 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16572
16573 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
16574
16575 * symfile (_initialize_symfile): Add usage text to the load command's
16576 help text.
16577
16578 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16579
16580 * utils.c (defaulted_query): Don't query on secondary UIs.
16581
16582 2017-02-10 Tom Tromey <tom@tromey.com>
16583
16584 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16585
16586 2017-02-10 Tom Tromey <tom@tromey.com>
16587
16588 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16589 "cleanup" local.
16590 * python/py-type.c (typy_legacy_template_argument): Remove
16591 unnecessary "cleanup" local.
16592
16593 2017-02-10 Tom Tromey <tom@tromey.com>
16594
16595 * python/python.c (do_start_initialization): New function, from
16596 _initialize_python.
16597 (_initialize_python): Call do_start_initialization.
16598 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16599 goto.
16600
16601 2017-02-10 Tom Tromey <tom@tromey.com>
16602
16603 * python/py-prettyprint.c (pretty_print_one_value): Use
16604 gdbpy_ref.
16605
16606 2017-02-10 Tom Tromey <tom@tromey.com>
16607
16608 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16609 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16610 gdbpy_ref.
16611 * python/py-type.c (field_new): Use gdbpy_ref.
16612 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16613 gdbpy_ref.
16614 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16615 (py_free_pspace): Likewise.
16616 (pspace_to_pspace_object): Likewise.
16617 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16618 (py_free_objfile): Likewise.
16619 (objfile_to_objfile_object): Likewise.
16620 * python/py-inferior.c (delete_thread_object): Use
16621 gdbpy_ref.
16622 (infpy_read_memory): Likewise.
16623 (py_free_inferior): Likewise.
16624 * python/py-evtregistry.c (create_eventregistry_object): Use
16625 gdbpy_ref.
16626 * python/py-event.c (create_event_object): Use gdbpy_ref.
16627
16628 2017-02-10 Tom Tromey <tom@tromey.com>
16629
16630 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16631 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16632 used.
16633 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16634 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16635 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16636 python/py-framefilter.c, python/py-function.c,
16637 python/py-inferior.c, python/py-infevents.c,
16638 python/py-linetable.c, python/py-newobjfileevent.c,
16639 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16640 python/py-signalevent.c, python/py-stopevent.c,
16641 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16642 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16643 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16644 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16645
16646 2017-02-10 Tom Tromey <tom@tromey.com>
16647
16648 * ui-out.h (ui_out_emit_type): New class.
16649 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16650 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16651 and ui_out_emit_tuple.
16652 (enumerate_locals): Likewise.
16653 (py_mi_print_variables, py_print_locals, py_print_args): Use
16654 ui_out_emit_list.
16655 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16656 ui_out_emit_list.
16657 * common/gdb_optional.h: New file.
16658
16659 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
16660
16661 * MAINTAINERS (Write After Approval): Update my e-mail address.
16662
16663 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
16664
16665 PR gdb/21122
16666 * breakpoint.c (_initialize_breakpoint): Update the help description
16667 of the 'commands' command to indicate that it takes a list argument.
16668
16669 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16670
16671 * interps.c (current_interp_set_logging): Remove "return".
16672
16673 2017-02-09 Gary Benson <gbenson@redhat.com>
16674
16675 * symtab.c (add_symtab_completions): Prevent NULL pointer
16676 dereference.
16677
16678 2017-02-08 Pedro Alves <palves@redhat.com>
16679
16680 * interps.c (interp::interp): Remove reference to quiet_p.
16681 (interp_set): Make static. Remove dead "Switching to" output
16682 code.
16683 (interp_quiet_p, interp_set_quiet): Delete.
16684 (interpreter_exec_cmd): Don't set the interpreter quiet.
16685 * interps.h (interp_quiet_p): Make static.
16686 (class interp) <quiet_p>: Remove field
16687
16688 2017-02-08 Jerome Guitton <guitton@adacore.com>
16689
16690 * cli/cli-decode.c (find_command_name_length): Make it extern.
16691 * cli/cli-decode.h (find_command_name_length): Declare.
16692 * cli/cli-script.c (command_name_equals, line_first_arg):
16693 New functions.
16694 (process_next_line): Use cli-decode to parse command names.
16695 (build_command_line): Make args a constant pointer.
16696
16697 2017-02-08 Jerome Guitton <guitton@adacore.com>
16698
16699 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16700 Remove case-insensitive search.
16701
16702 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16703
16704 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16705 at the end of the line. Avoids an ARI warning.
16706
16707 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
16708
16709 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16710 rdseed instructions.
16711 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16712
16713 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16714
16715 PR tdep/20936
16716 Provide and use sparc32 and sparc64 target description XML files.
16717 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16718 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16719 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16720 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16721 * features/sparc/sparc32-solaris.xml: New file.
16722 * features/sparc/sparc64-solaris.xml: New file.
16723 * features/sparc/sparc32-solaris.c: Generated.
16724 * features/sparc/sparc64-solaris.c: Generated.
16725 * sparc-tdep.h: Account for differences in target descriptions.
16726 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16727 (sparc32_register_type): Use target provided registers.
16728 (validate_tdesc_registers): New function.
16729 (sparc32_gdbarch_init): Use tdesc_has_registers.
16730 Set pseudoregister functions.
16731 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16732 (sparc64_register_type): Use target provided registers.
16733 (sparc64_init_abi): Set pseudoregister functions.
16734
16735 2017-02-03 Tom Tromey <tom@tromey.com>
16736
16737 PR rust/21097:
16738 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16739 with a single member.
16740
16741 2017-02-03 Pedro Alves <palves@redhat.com>
16742
16743 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16744 (cli_interp_base::~cli_interp_base): New.
16745 (cli_interp): New struct.
16746 (as_cli_interp): Cast the interp itself to cli_interp.
16747 (cli_interpreter_pre_command_loop): Rename to ...
16748 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16749 parameter.
16750 (cli_interpreter_init): Rename to ...
16751 (cli_interp::init): ... this. Remove 'self' parameter. Use
16752 boolean. Make extern.
16753 (cli_interpreter_resume): Rename to ...
16754 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16755 extern.
16756 (cli_interpreter_suspend): Rename to ...
16757 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16758 extern.
16759 (cli_interpreter_exec): Rename to ...
16760 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16761 extern.
16762 (cli_interpreter_supports_command_editing): Rename to ...
16763 (cli_interp_base::supports_command_editing): ... this. Remove
16764 'interp' parameter. Make extern.
16765 (cli_ui_out): Rename to ...
16766 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16767 Make extern.
16768 (cli_set_logging): Rename to ...
16769 (cli_interp_base::set_logging): ... this. Remove 'interp'
16770 parameter. Make extern.
16771 (cli_interp_procs): Delete.
16772 (cli_interp_factory): Adjust to use "new".
16773 * cli/cli-interp.h: Include "interps.h".
16774 (struct cli_interp_base): New struct.
16775 * interps.c (struct interp): Delete. Fields moved to interps.h.
16776 (interp_new): Delete.
16777 (interp::interp, interp::~interp): New.
16778 (interp_set): Use bool, and return void. Assume the interpreter
16779 has suspend, init and resume methods, and that the all return
16780 void.
16781 (set_top_level_interpreter): interp_set returns void.
16782 (interp_ui_out): Adapt.
16783 (current_interp_set_logging): Adapt.
16784 (interp_data): Delete.
16785 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
16786 (interp_exec): Adapt.
16787 (top_level_interpreter_data): Delete.
16788 * interps.h (interp_init_ftype, interp_resume_ftype)
16789 (interp_suspend_ftype, interp_exec_ftype)
16790 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
16791 (class interp): New.
16792 (interp_new): Delete.
16793 (interp_set): Now returns void. Use bool.
16794 (interp_data, top_level_interpreter_data): Delete.
16795 * mi/mi-common.h: Include interps.h.
16796 (class mi_interp): Inherit from interp. Define a ctor. Declare
16797 init, resume, suspect, exec, interp_ui_out, set_logging and
16798 pre_command_loop methods.
16799 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
16800 (mi_interpreter_init): Rename to ...
16801 (mi_interp::init): ... this. Remove the 'interp' parameter, use
16802 bool, return void and make extern. Adjust.
16803 (mi_interpreter_resume): ... Rename to ...
16804 (mi_interp::resume): ... this. Remove the 'data' parameter,
16805 return void and make extern. Adjust.
16806 (mi_interpreter_suspend): ... Rename to ...
16807 (mi_interp::suspend): ... this. Remove the 'data' parameter,
16808 return void and make extern. Adjust.
16809 (mi_interpreter_exec): ... Rename to ...
16810 (mi_interp::exec): ... this. Remove the 'data' parameter and make
16811 extern. Adjust.
16812 (mi_interpreter_pre_command_loop): ... Rename to ...
16813 (mi_interp::pre_command_loop): ... this. Remove the 'self'
16814 parameter and make extern.
16815 (mi_on_normal_stop_1): Adjust.
16816 (mi_ui_out): Rename to ...
16817 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
16818 parameter and make extern. Adjust.
16819 (mi_set_logging): Rename to ...
16820 (mi_interp::set_logging): ... this. Remove the 'interp'
16821 parameter and make extern. Adjust.
16822 (mi_interp_procs): Delete.
16823 (mi_interp_factory): Adjust to use 'new'.
16824 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
16825 (mi_print_exception, mi_execute_command, mi_load_progress):
16826 Adjust.
16827 * tui/tui-interp.c (tui_interp): New class.
16828 (as_tui_interp): Return a tui_interp pointer.
16829 (tui_on_normal_stop, tui_on_signal_received)
16830 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
16831 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
16832 to use interp::interp_ui_out.
16833 (tui_init): Rename to ...
16834 (tui_interp::init): ... this. Remove the 'self' parameter, use
16835 bool, return void and make extern. Adjust.
16836 (tui_resume): Rename to ...
16837 (tui_interp::resume): ... this. Remove the 'data' parameter,
16838 return void and make extern. Adjust.
16839 (tui_suspend): Rename to ...
16840 (tui_interp::suspend): ... this. Remove the 'data' parameter,
16841 return void and make extern. Adjust.
16842 (tui_ui_out): Rename to ...
16843 (tui_interp::interp_ui_out): ... this. Remove the 'self'
16844 parameter, and make extern. Adjust.
16845 (tui_exec): Rename to ...
16846 (tui_interp::exec): ... this. Remove the 'data' parameter and
16847 make extern.
16848 (tui_interp_procs): Delete.
16849 (tui_interp_factory): Use "new".
16850
16851 2017-02-02 Tom Tromey <tom@tromey.com>
16852
16853 * rust-exp.y (ends_raw_string, space_then_number)
16854 (rust_identifier_start_p): Return bool.
16855 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
16856 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
16857 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
16858 (rust_chartype_p): Return bool.
16859 (val_print_struct, rust_print_struct_def, rust_print_type):
16860 Update.
16861 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
16862 Return bool.
16863
16864 2017-02-02 Tom Tromey <tom@tromey.com>
16865
16866 * rust-lang.c: Reindent.
16867
16868 2017-02-02 Tom Tromey <tom@tromey.com>
16869
16870 * rust-lang.h (rust_crate_for_block): Update.
16871 * rust-lang.c (rust_crate_for_block): Return std::string.
16872 (rust_get_disr_info): Use std:;string, not
16873 gdb::unique_xmalloc_ptr.
16874 * rust-exp.y (crate_name): Update.
16875
16876 2017-02-02 Pedro Alves <palves@redhat.com>
16877
16878 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
16879 field out of gdb_disassembler_test and make it static.
16880
16881 2017-02-02 Pedro Alves <palves@redhat.com>
16882
16883 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
16884 mi1_interp and mi_interp fields.
16885
16886 2017-02-02 Pedro Alves <palves@redhat.com>
16887
16888 * cli/cli-interp.c (struct saved_output_files, saved_output):
16889 Moved from cli/cli-logging.c.
16890 (cli_set_logging): New function.
16891 (cli_interp_procs): Install cli_set_logging.
16892 * cli/cli-interp.h (make_logging_output, cli_set_logging):
16893 Declare.
16894 * cli/cli-logging.c (struct saved_output_files, saved_output):
16895 Moved to cli/cli-interp.c.
16896 (pop_output_files): Don't save outputs here.
16897 (make_logging_output): New function.
16898 (handle_redirections): Don't build tee nor save previous outputs
16899 here.
16900 * interps.c (current_interp_set_logging): Change prototype.
16901 Assume there's always a set_logging_proc method installed.
16902 * interps.h (interp_set_logging_ftype): Change prototype.
16903 (current_interp_set_logging): Change prototype and adjust comment.
16904 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
16905 use make_logging_output.
16906 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
16907 2017-02-02 Pedro Alves <palves@redhat.com>
16908
16909 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
16910 from ...
16911 (set_logging_overwrite): ... here.
16912 (logging_no_redirect_file): Delete.
16913 (set_logging_redirect): Don't handle redirection on the fly.
16914 Instead warn that "logging off" / "logging on" is necessary.
16915 (pop_output_files): Delete references to logging_no_redirect_file.
16916 (show_logging_command): Always speak in terms of what will happen
16917 once logging is reenabled.
16918
16919 2017-02-02 Pedro Alves <palves@redhat.com>
16920
16921 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
16922
16923 2017-02-02 Pedro Alves <palves@redhat.com>
16924
16925 * disasm.c (gdb_pretty_print_insn): Rename to ...
16926 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
16927 Remove gdbarch parameter. Adapt to clear the object's buffers
16928 instead of allocating new buffers, and to print using the object's
16929 gdb_disassembler instead of calling gdb_print_insn.
16930 (dump_insns): Use gdb_pretty_print_disassembler.
16931 * disasm.h (gdb_pretty_print_insn): Delete declaration.
16932 (gdb_pretty_print_disassembler): New class.
16933 * record-btrace.c (btrace_insn_history): Use
16934 gdb_pretty_print_disassembler.
16935
16936 2017-02-02 Pedro Alves <palves@redhat.com>
16937
16938 * ada-lang.c (type_as_string): Use string_file.
16939 * ada-valprint.c (ada_print_floating): Use string_file.
16940 * ada-varobj.c (ada_varobj_scalar_image)
16941 (ada_varobj_get_value_image): Use string_file.
16942 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
16943 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
16944 * breakpoint.c (update_inserted_breakpoint_locations)
16945 (insert_breakpoint_locations, reattach_breakpoints)
16946 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
16947 (print_it_watchpoint): Use string_file.
16948 (save_breakpoints): Use stdio_file.
16949 * c-exp.y (oper): Use string_file.
16950 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
16951 tee_file.
16952 (pop_output_files): Use delete.
16953 (handle_redirections): Use stdio_file and tee_file.
16954 * cli/cli-setshow.c (do_show_command): Use string_file.
16955 * compile/compile-c-support.c (c_compute_program): Use
16956 string_file.
16957 * compile/compile-c-symbols.c (generate_vla_size): Take a
16958 'string_file &' instead of a 'ui_file *'.
16959 (generate_c_for_for_one_variable): Take a 'string_file &' instead
16960 of a 'ui_file *'. Use string_file.
16961 (generate_c_for_variable_locations): Take a 'string_file &'
16962 instead of a 'ui_file *'.
16963 * compile/compile-internal.h (generate_c_for_for_one_variable):
16964 Take a 'string_file &' instead of a 'ui_file *'.
16965 * compile/compile-loc2c.c (push, pushf, unary, binary)
16966 (print_label, pushf_register_address, pushf_register)
16967 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
16968 'ui_file *'. Adjust.
16969 * compile/compile.c (compile_to_object): Use string_file.
16970 * compile/compile.h (compile_dwarf_expr_to_c)
16971 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
16972 'ui_file *'.
16973 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
16974 (replace_typedefs_qualified_name): Use string_file and
16975 obstack_copy0.
16976 * disasm.c (gdb_pretty_print_insn): Use string_file.
16977 (gdb_disassembly): Adjust reference the null_stream global.
16978 (do_ui_file_delete): Delete.
16979 (gdb_insn_length): Use null_stream.
16980 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
16981 * dwarf2loc.c (dwarf2_compile_property_to_c)
16982 (locexpr_generate_c_location, loclist_generate_c_location): Take a
16983 'string_file &' instead of a 'ui_file *'.
16984 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
16985 * dwarf2read.c (do_ui_file_peek_last): Delete.
16986 (dwarf2_compute_name): Use string_file.
16987 * event-top.c (gdb_setup_readline): Use stdio_file.
16988 * gdbarch.sh (verify_gdbarch): Use string_file.
16989 * gdbtypes.c (safe_parse_type): Use null_stream.
16990 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
16991 string_file.
16992 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
16993 'string_file *' instead of a 'ui_file *'.
16994 (gdbscm_arch_disassemble): Use string_file.
16995 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
16996 * guile/scm-ports.c (class ioscm_file_port): Now a class that
16997 inherits from ui_file.
16998 (ioscm_file_port_delete, ioscm_file_port_rewind)
16999 (ioscm_file_port_put): Delete.
17000 (ioscm_file_port_write): Rename to ...
17001 (ioscm_file_port::write): ... this. Remove file_port_magic
17002 checks.
17003 (ioscm_file_port_new): Delete.
17004 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
17005 ui_file_up.
17006 * guile/scm-type.c (tyscm_type_name): Use string_file.
17007 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
17008 Use string_file.
17009 * infcmd.c (print_return_value_1): Use string_file.
17010 * infrun.c (print_target_wait_results): Use string_file.
17011 * language.c (add_language): Use string_file.
17012 * location.c (explicit_to_string_internal): Use string_file.
17013 * main.c (captured_main_1): Use null_file.
17014 * maint.c (maintenance_print_architecture): Use stdio_file.
17015 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
17016 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
17017 event_channel>: Change type to mi_console_file pointer.
17018 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
17019 (mi_console_file_delete): Delete.
17020 (struct mi_console_file): Delete.
17021 (mi_console_file_magic): Delete.
17022 (mi_console_file_new): Delete.
17023 (mi_console_file::mi_console_file): New.
17024 (mi_console_file_delete): Delete.
17025 (mi_console_file_fputs): Delete.
17026 (mi_console_file::write): New.
17027 (mi_console_raw_packet): Delete.
17028 (mi_console_file::flush): New.
17029 (mi_console_file_flush): Delete.
17030 (mi_console_set_raw): Rename to ...
17031 (mi_console_file::set_raw): ... this.
17032 * mi/mi-console.h (class mi_console_file): New class.
17033 (mi_console_file_new, mi_console_set_raw): Delete.
17034 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
17035 (mi_set_logging): Use delete and tee_file. Adjust.
17036 * mi/mi-main.c (output_register): Use string_file.
17037 (mi_cmd_data_evaluate_expression): Use string_file.
17038 (mi_cmd_data_read_memory): Use string_file.
17039 (mi_cmd_execute, print_variable_or_computed): Use string_file.
17040 * mi/mi-out.c (mi_ui_out::main_stream): New.
17041 (mi_ui_out::rewind): Use main_stream and
17042 string_file.
17043 (mi_ui_out::put): Use main_stream and string_file.
17044 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17045 Allocate a 'string_file' instead.
17046 (mi_out_new): Don't allocate a mem_fileopen stream here.
17047 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17048 (mi_ui_out::main_stream): Declare method.
17049 * printcmd.c (eval_command): Use string_file.
17050 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
17051 * python/py-arch.c (archpy_disassemble): Use string_file.
17052 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
17053 * python/py-frame.c (frapy_str): Use string_file.
17054 * python/py-framefilter.c (py_print_type, py_print_single_arg):
17055 Use string_file.
17056 * python/py-type.c (typy_str): Use string_file.
17057 * python/py-unwind.c (unwind_infopy_str): Use string_file.
17058 * python/py-value.c (valpy_str): Use string_file.
17059 * record-btrace.c (btrace_insn_history): Use string_file.
17060 * regcache.c (regcache_print): Use stdio_file.
17061 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
17062 * remote.c (escape_buffer): Use string_file.
17063 * rust-lang.c (rust_get_disr_info): Use string_file.
17064 * serial.c (serial_open_ops_1): Use stdio_file.
17065 (do_serial_close): Use delete.
17066 * stack.c (print_frame_arg): Use string_file.
17067 (print_frame_args): Remove local mem_fileopen stream, not used.
17068 (print_frame): Use string_file.
17069 * symmisc.c (maintenance_print_symbols): Use stdio_file.
17070 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
17071 Take a 'string_file *' instead of a 'ui_file *'.
17072 * top.c (new_ui): Use stdio_file and stderr_file.
17073 (free_ui): Use delete.
17074 (execute_command_to_string): Use string_file.
17075 (quit_confirm): Use string_file.
17076 * tracepoint.c (collection_list::append_exp): Use string_file.
17077 * tui/tui-disasm.c (tui_disassemble): Use string_file.
17078 * tui/tui-file.c: Don't include "ui-file.h".
17079 (enum streamtype, struct tui_stream): Delete.
17080 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
17081 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
17082 (tui_file::tui_file): New method.
17083 (tui_file_fputs): Delete.
17084 (tui_file_get_strbuf): Delete.
17085 (tui_file::puts): New method.
17086 (tui_file_adjust_strbuf): Delete.
17087 (tui_file_flush): Delete.
17088 (tui_file::flush): New method.
17089 * tui/tui-file.h: Tweak intro comment.
17090 Include ui-file.h.
17091 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
17092 (tui_file_adjust_strbuf): Delete declarations.
17093 (class tui_file): New class.
17094 * tui/tui-io.c (tui_initialize_io): Use tui_file.
17095 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
17096 (tui_register_format): Use string_stream.
17097 * tui/tui-stack.c (tui_make_status_line): Use string_file.
17098 (tui_get_function_from_frame): Use string_file.
17099 * typeprint.c (type_to_string): Use string_file.
17100 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
17101 (null_stream): New global.
17102 (ui_file_delete): Delete.
17103 (ui_file::ui_file): New.
17104 (null_file_isatty): Delete.
17105 (ui_file::~ui_file): New.
17106 (null_file_rewind): Delete.
17107 (ui_file::printf): New.
17108 (null_file_put): Delete.
17109 (null_file_flush): Delete.
17110 (ui_file::putstr): New.
17111 (null_file_write): Delete.
17112 (ui_file::putstrn): New.
17113 (null_file_read): Delete.
17114 (ui_file::putc): New.
17115 (null_file_fputs): Delete.
17116 (null_file_write_async_safe): Delete.
17117 (ui_file::vprintf): New.
17118 (null_file_delete): Delete.
17119 (null_file::write): New.
17120 (null_file_fseek): Delete.
17121 (null_file::puts): New.
17122 (ui_file_data): Delete.
17123 (null_file::write_async_safe): New.
17124 (gdb_flush, ui_file_isatty): Adjust.
17125 (ui_file_put, ui_file_rewind): Delete.
17126 (ui_file_write): Adjust.
17127 (ui_file_write_for_put): Delete.
17128 (ui_file_write_async_safe, ui_file_read): Adjust.
17129 (ui_file_fseek): Delete.
17130 (fputs_unfiltered): Adjust.
17131 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
17132 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
17133 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
17134 (set_ui_file_data): Delete.
17135 (string_file::~string_file, string_file::write)
17136 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
17137 (do_ui_file_as_string, ui_file_as_string): Delete.
17138 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
17139 (struct mem_file): Delete.
17140 (mem_file_new): Delete.
17141 (stdio_file::stdio_file): New.
17142 (mem_file_delete): Delete.
17143 (stdio_file::stdio_file): New.
17144 (mem_fileopen): Delete.
17145 (stdio_file::~stdio_file): New.
17146 (mem_file_rewind): Delete.
17147 (stdio_file::set_stream): New.
17148 (mem_file_put): Delete.
17149 (stdio_file::open): New.
17150 (mem_file_write): Delete.
17151 (stdio_file_magic, struct stdio_file): Delete.
17152 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
17153 (stdio_file::flush): New.
17154 (stdio_file_read): Rename to ...
17155 (stdio_file::read): ... this. Adjust.
17156 (stdio_file_write): Rename to ...
17157 (stdio_file::write): ... this. Adjust.
17158 (stdio_file_write_async_safe): Rename to ...
17159 (stdio_file::write_async_safe) ... this. Adjust.
17160 (stdio_file_fputs): Rename to ...
17161 (stdio_file::puts) ... this. Adjust.
17162 (stdio_file_isatty): Delete.
17163 (stdio_file_fseek): Delete.
17164 (stdio_file::isatty): New.
17165 (stderr_file_write): Rename to ...
17166 (stderr_file::write) ... this. Adjust.
17167 (stderr_file_fputs): Rename to ...
17168 (stderr_file::puts) ... this. Adjust.
17169 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
17170 (stderr_file::stderr_file): New.
17171 (tee_file_magic): Delete.
17172 (struct tee_file): Delete.
17173 (tee_file::tee_file): New.
17174 (tee_file_new): Delete.
17175 (tee_file::~tee_file): New.
17176 (tee_file_delete): Delete.
17177 (tee_file_flush): Rename to ...
17178 (tee_file::flush): ... this. Adjust.
17179 (tee_file_write): Rename to ...
17180 (tee_file::write): ... this. Adjust.
17181 (tee_file::write_async_safe): New.
17182 (tee_file_fputs): Rename to ...
17183 (tee_file::puts): ... this. Adjust.
17184 (tee_file_isatty): Rename to ...
17185 (tee_file::isatty): ... this. Adjust.
17186 * ui-file.h (struct obstack, struct ui_file): Don't
17187 forward-declare.
17188 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
17189 (ui_file_write_ftype)
17190 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
17191 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
17192 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
17193 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
17194 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
17195 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
17196 (set_ui_file_fseek): Delete.
17197 (ui_file_data, ui_file_delete, ui_file_rewind)
17198 (struct ui_file): New.
17199 (ui_file_up): New.
17200 (class null_file): New.
17201 (null_stream): Declare.
17202 (ui_file_write_for_put, ui_file_put): Delete.
17203 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
17204 Delete.
17205 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
17206 (gdb_fopen, tee_file_new): Delete.
17207 (struct string_file): New.
17208 (struct stdio_file): New.
17209 (stdio_file_up): New.
17210 (struct stderr_file): New.
17211 (class tee_file): New.
17212 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
17213 of a 'ui_file *'. Adjust.
17214 * ui-out.h (class ui_out) <field_stream>: Likewise.
17215 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
17216 (null_stream): Delete.
17217 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
17218 Adjust.
17219 * utils.h (struct ui_file): Delete forward declaration..
17220 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
17221 (error_stream): Take a 'string_file &' instead of a
17222 'ui_file *'.
17223 * varobj.c (varobj_value_get_print_value): Use string_file.
17224 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
17225 * gdbarch.c: Regenerate.
17226
17227 2017-02-02 Pedro Alves <palves@redhat.com>
17228
17229 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
17230 (gdb_pretty_print_insn): ... this. Now a free function. Add back
17231 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
17232 Adjust to call gdb_print_insn instead of
17233 gdb_disassembler::print_insn.
17234 (dump_insns, do_mixed_source_and_assembly_deprecated)
17235 (do_mixed_source_and_assembly, do_assembly_only): Add back a
17236 'gdbarch' parameter. Remove gdb_disassembler parameter.
17237 (gdb_disassembly): Don't allocate a gdb_disassembler here.
17238 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
17239 declaration.
17240 (gdb_pretty_print_insn): Re-add declaration.
17241 * record-btrace.c (btrace_insn_history): Don't allocate a
17242 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
17243
17244 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
17245
17246 * disasm.h (gdb_disassembly): Remove file_string parameter.
17247 * disasm.c (gdb_disassembly): Likewise.
17248 * cli/cli-cmds.c (print_disassembly): Adapt.
17249 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
17250 * stack.c (do_gdb_disassembly): Likewise.
17251
17252 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
17253
17254 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
17255 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
17256 targets. And if the implicit value is longer than needed, extract
17257 the first bytes instead of the "least significant" ones.
17258
17259 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17260
17261 * btrace.c (btrace_enable): Do not call btrace_add_pc for
17262 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
17263 (btrace_fetch): Assert can_access_registers_ptid.
17264 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
17265 validate_registers_access.
17266
17267 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17268
17269 * gdbthread.h (can_access_registers_ptid): New.
17270 * thread.c (can_access_registers_ptid): New.
17271
17272 2017-02-01 Pedro Alves <palves@redhat.com>
17273
17274 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
17275
17276 2017-01-31 Pedro Alves <palves@redhat.com>
17277
17278 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
17279 Fix typos.
17280
17281 2017-01-31 Pedro Alves <palves@redhat.com>
17282
17283 * stack.c (print_frame_args): Remove local mem_fileopen stream,
17284 not used.
17285
17286 2017-01-31 Pedro Alves <palves@redhat.com>
17287
17288 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
17289
17290 2017-01-31 Pedro Alves <palves@redhat.com>
17291
17292 * common/scoped_restore.h
17293 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
17294 change the value's parameter type to T2.
17295 (make_scoped_restore): Likewise.
17296
17297 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17298 Richard Henderson <rth@redhat.com>
17299
17300 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
17301 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
17302 GS_BASE for older kernels.
17303 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
17304 GS_BASE for older kernels.
17305 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
17306 and GS_BASE to the offset table.
17307 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
17308 system register group.
17309 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
17310 for older kernels.
17311 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
17312 amd64 ABI.
17313 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
17314 AMD64_GSBASE_REGNUM.
17315 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
17316 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
17317 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
17318 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
17319 i386/64bit-segments.xml in those rules.
17320 * features/i386/64bit-segments.xml: New file.
17321 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
17322 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
17323 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
17324 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
17325 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
17326 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
17327 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
17328 * features/i386/amd64-avx-linux.c: Regenerated.
17329 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
17330 * features/i386/amd64-avx-mpx.c: Regenerated.
17331 * features/i386/amd64-avx512-linux.c: Regenerated.
17332 * features/i386/amd64-linux.c: Regenerated.
17333 * features/i386/amd64-mpx-linux.c: Regenerated.
17334 * features/i386/i386-avx-mpx-linux.c: Regenerated.
17335 * features/i386/i386-avx-mpx.c: Regenerated.
17336 * features/i386/x32-avx-linux.c: Regenerated.
17337 * features/i386/x32-avx512-linux.c: Regenerated.
17338 * regformats/i386/amd64-avx-linux.dat: Regenerated.
17339 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
17340 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
17341 * regformats/i386/amd64-linux.dat: Regenerated.
17342 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
17343 * regformats/i386/x32-avx-linux.dat: Regenerated.
17344 * regformats/i386/x32-avx512-linux.dat: Regenerated.
17345 * regformats/i386/x32-linux.dat: Regenerated.
17346
17347 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17348
17349 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
17350 Set to AMD64_NUM_REGS.
17351
17352 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17353
17354 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
17355 that checks validity of a register number.
17356
17357 2017-01-27 Kees Cook <keescook@google.com>
17358
17359 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
17360 fetch_fpregs if target has fpa registers.
17361 (arm_linux_store_inferior_registers): Call store_fpregs if target
17362 has fpa registers.
17363
17364 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
17365
17366 * cris-tdep.c (cris_gdbarch_init): Remove check for
17367 info.byte_order and force it to BFD_ENDIAN_LITTLE.
17368
17369 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
17370
17371 * corelow.c (get_core_register_section): Check for regset
17372 existence before checking for REGSET_VARIABLE_SIZE.
17373
17374 2017-01-26 Yao Qi <yao.qi@linaro.org>
17375 Pedro Alves <palves@redhat.com>
17376
17377 PR gdb/20939
17378 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
17379 call memory_error, save memaddr instead.
17380 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
17381 negative, cal memory_error.
17382 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
17383
17384 2017-01-26 Yao Qi <yao.qi@linaro.org>
17385
17386 * disasm-selftests.c (memory_error_test): New function.
17387 (_initialize_disasm_selftests): Register memory_error_test.
17388
17389 2017-01-26 Yao Qi <yao.qi@linaro.org>
17390
17391 * Makefile.in (SFILES): Add disasm-selftests.c and
17392 selftest-arch.c.
17393 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
17394 * disasm-selftests.c: New file.
17395 * selftest-arch.c: New file.
17396 * selftest-arch.h: New file.
17397
17398 2017-01-26 Yao Qi <yao.qi@linaro.org>
17399
17400 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
17401 to bfd_arch_mep. Don't return 0 if section is not
17402 found. Call print_insn_mep.
17403
17404 2017-01-26 Pedro Alves <palves@redhat.com>
17405 Yao Qi <yao.qi@linaro.org>
17406
17407 * arm-tdep.c: Include "disasm.h".
17408 (gdb_print_insn_arm): Update code to get gdbarch.
17409 * disasm.c (dis_asm_read_memory): Change it to
17410 gdb_disassembler::dis_asm_read_memory.
17411 (dis_asm_memory_error): Likewise.
17412 (dis_asm_print_address): Likewise.
17413 (gdb_pretty_print_insn): Change it to
17414 gdb_disassembler::pretty_print_insn.
17415 (dump_insns): Add one argument gdb_disassemlber. All
17416 callers updated.
17417 (do_mixed_source_and_assembly_deprecated): Likewise.
17418 (do_mixed_source_and_assembly): Likewise.
17419 (do_assembly_only): Likewise.
17420 (gdb_disassembler::gdb_disassembler): New.
17421 (gdb_disassembler::print_insn): New.
17422 * disasm.h (class gdb_disassembler): New.
17423 (gdb_pretty_print_insn): Remove declaration.
17424 (gdb_disassemble_info): Likewise.
17425 * guile/scm-disasm.c (class gdbscm_disassembler): New.
17426 (gdbscm_disasm_read_memory_worker): Update.
17427 (gdbscm_disasm_read_memory): Update.
17428 (gdbscm_disasm_memory_error): Remove.
17429 (gdbscm_disasm_print_address): Remove.
17430 (gdbscm_disassembler::gdbscm_disassembler): New.
17431 (gdbscm_print_insn_from_port): Update.
17432 * mips-tdep.c: Include disasm.h.
17433 (gdb_print_insn_mips): Update code to get gdbarch.
17434 * record-btrace.c (btrace_insn_history): Update.
17435 * spu-tdep.c: Include disasm.h.
17436 (struct spu_dis_asm_data): Remove.
17437 (struct spu_dis_asm_info): New.
17438 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17439 SPU id.
17440 (gdb_print_insn_spu): Cast disassemble_info to
17441 spu_dis_asm_info.
17442
17443 2017-01-26 Yao Qi <yao.qi@linaro.org>
17444
17445 * disasm.c (do_ui_file_delete): Delete.
17446 (gdb_insn_length): Move code creating stream to ...
17447 * utils.c (null_stream): ... here. New function.
17448 * utils.h (null_stream): Declare.
17449
17450 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17451
17452 * python/py-inferior.c (find_thread_object): Return directly
17453 from the loop. Remove "found" variable.
17454
17455 2017-01-21 Joel Brobecker <brobecker@adacore.com>
17456
17457 GDB 7.12.1 released.
17458
17459 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17460
17461 * python/py-function.c (fnpy_call): Reorder declarations to have
17462 the gdbpy_enter object declared first.
17463 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17464
17465 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17466
17467 PR python/21068
17468 * python/python-internal.h (PyMem_RawMalloc): Define for
17469 Python < 3.4.
17470 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17471 PyMem_RawMalloc instead of PyMem_Malloc.
17472
17473 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17474 Luis Machado <lgustavo@codesourcery.com>
17475
17476 * NEWS (New commands): Mention flash-erase.
17477 (New MI commands): Mention target-flash-erase.
17478 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17479 command.
17480 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17481 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17482 * target.c (flash_erase_command): New function.
17483 (initialize_targets): Add new flash-erase command.
17484 * target.h (flash_erase_command): New declaration.
17485
17486 2017-01-20 Joel Brobecker <brobecker@adacore.com>
17487
17488 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17489 HAVE_SYS_PROCFS_H is defined.
17490
17491 2017-01-18 Alan Hayward <alan.hayward@arm.com>
17492
17493 * remote.c (struct cached_reg): Change data into a pointer.
17494 * (stop_reply_dtr): Free data pointers before deleting vector.
17495 (process_stop_reply): Likewise.
17496 (remote_parse_stop_reply): Allocate space for data
17497
17498 2017-01-18 Alan Hayward <alan.hayward@arm.com>
17499
17500 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17501 MAX_REGISTER_SIZE.
17502 (amd64_pseudo_register_read_value): Likewise.
17503 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17504 (store_register_using_P): Likewise.
17505 * regcache.c (regcache_xfer_part): Likewise.
17506
17507 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17508
17509 Split real and pseudo registers.
17510 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17511 (sparc32_pseudo_regnum): New enum.
17512 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17513 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17514 (SPARC32_CP0_REGISTERS): New macro.
17515 (sparc32_pseudo_register_name): New function.
17516 (sparc32_register_name): Use sparc32_pseudo_register_name.
17517 (sparc32_pseudo_register_type): New function.
17518 (sparc32_register_type): Use sparc32_pseudo_register_type.
17519 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17520 pseudo register numbers.
17521 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17522 (SPARC64_CP0_REGISTERS): New macro.
17523 (sparc64_pseudo_register_name): New function.
17524 (sparc64_register_name): Use sparc64_pseudo_register_name.
17525 (sparc64_pseudo_register_type): New function.
17526 (sparc64_register_type): Use sparc64_pseudo_register_type.
17527 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17528 pseudo register numbers.
17529 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17530 sparc64_store_arguments): Handle pseudo register numbers.
17531
17532 2017-01-13 Yao Qi <yao.qi@linaro.org>
17533
17534 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17535 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17536 output.
17537 (getpkt_or_notif_sane_1): Likewise.
17538
17539 2017-01-13 Yao Qi <yao.qi@linaro.org>
17540
17541 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17542 of CC. Pass "-x c++-header" instead of "-x c".
17543
17544 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17545
17546 * remote.c (remote_can_async_p): Update comment.
17547
17548 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17549
17550 * linux-nat.c (linux_nat_can_async_p): Update comment.
17551
17552 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17553
17554 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17555
17556 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17557
17558 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17559
17560 2017-01-10 Tom Tromey <tom@tromey.com>
17561
17562 * python/py-type.c (typy_legacy_template_argument): Update.
17563 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17564 ~demangle_parse_info): Declare new members.
17565 (cp_demangled_name_to_comp): Return unique_ptr.
17566 (cp_demangled_name_parse_free)
17567 (make_cleanup_cp_demangled_name_parse_free)
17568 (cp_new_demangle_parse_info): Remove.
17569 * cp-support.c (do_demangled_name_parse_free_cleanup)
17570 (make_cleanup_cp_demangled_name_parse_free): Remove.
17571 (inspect_type, cp_canonicalize_string_full)
17572 (cp_canonicalize_string): Update.
17573 (mangled_name_to_comp): Change return type.
17574 (cp_class_name_from_physname, method_name_from_physname)
17575 (cp_func_name, cp_remove_params): Update.
17576 * cp-name-parser.y (demangle_parse_info): New constructor, from
17577 cp_new_demangle_parse_info.
17578 (~demangle_parse_info): New destructor, from
17579 cp_demangled_name_parse_free.
17580 (cp_merge_demangle_parse_infos): Update.
17581 (cp_demangled_name_to_comp): Change return type.
17582
17583 2017-01-10 Tom Tromey <tom@tromey.com>
17584
17585 * top.c (prevent_dont_repeat): Change return type.
17586 * python/python.c (execute_gdb_command): Use std::string.
17587 Update.
17588 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17589 * command.h (prevent_dont_repeat): Change return type.
17590 * breakpoint.c (bpstat_do_actions_1): Update.
17591
17592 2017-01-10 Tom Tromey <tom@tromey.com>
17593
17594 * value.h (scoped_value_mark::~scoped_value_mark): Call
17595 free_to_mark.
17596 (scoped_value_mark::free_to_mark): New method.
17597 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17598 scoped_value_mark.
17599
17600 2017-01-10 Tom Tromey <tom@tromey.com>
17601
17602 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17603 (valpy_reference_value, valpy_const_value, valpy_get_address)
17604 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17605 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17606 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17607 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17608 scoped_value_mark.
17609 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17610 * value.h (scoped_value_mark): New class.
17611
17612 2017-01-10 Tom Tromey <tom@tromey.com>
17613
17614 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17615 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17616 * psymtab.c (discard_psymtabs_upto): Remove.
17617 (make_cleanup_discard_psymtabs): Remove.
17618 (struct psymtab_state): Remove.
17619
17620 2017-01-10 Tom Tromey <tom@tromey.com>
17621
17622 * record-full.c (record_full_save_cleanups): Remove.
17623 (record_full_save): Use gdb::unlinker.
17624 * gcore.c (do_bfd_delete_cleanup): Remove.
17625 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17626 cleanups.
17627 * dwarf2read.c (unlink_if_set): Remove.
17628 (write_psymtabs_to_index): Use gdb::unlinker.
17629 * common/gdb_unlinker.h: New file.
17630
17631 2017-01-10 Tom Tromey <tom@tromey.com>
17632
17633 * windows-tdep.c (windows_xfer_shared_library): Update.
17634 * windows-nat.c (windows_make_so): Update.
17635 * utils.h (make_cleanup_bfd_unref): Remove.
17636 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17637 * symfile.h (symfile_bfd_open)
17638 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17639 * symfile.c (read_symbols, symbol_file_add)
17640 (separate_debug_file_exists): Update.
17641 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17642 (generic_load, reread_symbols): Update.
17643 * symfile-mem.c (symbol_file_add_from_memory): Update.
17644 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17645 (spu_symbol_file_add_from_memory): Update.
17646 * solist.h (struct target_so_ops) <bfd_open>: Return
17647 gdb_bfd_ref_ptr.
17648 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17649 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17650 gdb_bfd_ref_ptr.
17651 (solib_map_sections, reload_shared_libraries_1): Update.
17652 * solib-svr4.c (enable_break): Update.
17653 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17654 * solib-frv.c (enable_break2): Update.
17655 * solib-dsbt.c (enable_break): Update.
17656 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17657 gdb_bfd_ref_ptr.
17658 (darwin_solib_get_all_image_info_addr_at_init): Update.
17659 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17660 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17661 * record-full.c (record_full_save): Update.
17662 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17663 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17664 * minidebug.c (find_separate_debug_file_in_section): Return
17665 gdb_bfd_ref_ptr.
17666 * machoread.c (macho_add_oso_symfile): Change abfd to
17667 gdb_bfd_ref_ptr.
17668 (macho_symfile_read_all_oso): Update.
17669 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17670 (macho_symfile_read): Update.
17671 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17672 (jit_bfd_try_read_symtab): Update.
17673 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17674 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17675 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17676 gdb_bfd_ref_ptr.
17677 (gdb_bfd_ref_policy): New struct.
17678 (gdb_bfd_ref_ptr): New typedef.
17679 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17680 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17681 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17682 gdb_bfd_ref_ptr.
17683 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17684 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17685 (gcore_command): Update.
17686 * exec.c (exec_file_attach): Update.
17687 * elfread.c (elf_symfile_read): Update.
17688 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17689 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17690 (open_and_init_dwo_file): Update.
17691 (open_dwp_file): Return gdb_bfd_ref_ptr.
17692 (open_and_init_dwp_file): Update.
17693 * corelow.c (core_open): Update.
17694 * compile/compile-object-load.c (compile_object_load): Update.
17695 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17696 * coffread.c (coff_symfile_read): Update.
17697 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17698 gdb_bfd_ref_ptr. Rename.
17699 (dump_bfd_file, restore_command): Update.
17700 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17701 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17702 (find_separate_debug_file_by_buildid): Update.
17703
17704 2017-01-10 Tom Tromey <tom@tromey.com>
17705
17706 * common/gdb_ref_ptr.h: New file.
17707 * python/py-ref.h (struct gdbpy_ref_policy): New.
17708 (gdbpy_ref): Now a typedef.
17709
17710 2017-01-10 Tom Tromey <tom@tromey.com>
17711
17712 * utils.h (make_cleanup_htab_delete): Don't declare.
17713 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17714 Remove.
17715 * linespec.c (decode_compound_collector): Add constructor,
17716 destructor.
17717 (lookup_prefix_sym): Remove cleanup.
17718 (symtab_collector): Add constructor, destructor.
17719 (collect_symtabs_from_filename): Remove cleanup.
17720 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17721 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17722 Use htab_up.
17723 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17724 * dwarf2read.c (dw2_expand_symtabs_matching)
17725 (dw2_map_symbol_filenames, dwarf_decode_macros)
17726 (write_psymtabs_to_index): Use htab_up.
17727 * dwarf2loc.c (func_verify_no_selftailcall)
17728 (call_site_find_chain_1, func_verify_no_selftailcall)
17729 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17730 std::vector, gdb::unique_xmalloc_ptr.
17731 (call_sitep): Remove typedef.
17732 (dwarf2_locexpr_baton_eval): Remove unused variable.
17733
17734 2017-01-10 Tom Tromey <tom@tromey.com>
17735
17736 * python/python-internal.h (make_cleanup_py_decref)
17737 (make_cleanup_py_xdecref): Don't declare.
17738 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17739 (py_xdecref, make_cleanup_py_xdecref): Remove.
17740
17741 2017-01-10 Tom Tromey <tom@tromey.com>
17742
17743 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17744 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17745
17746 2017-01-10 Tom Tromey <tom@tromey.com>
17747
17748 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17749
17750 2017-01-10 Tom Tromey <tom@tromey.com>
17751
17752 * python/py-utils.c (unicode_to_encoded_string)
17753 (python_string_to_target_string)
17754 (python_string_to_target_python_string)
17755 (python_string_to_host_string, gdbpy_obj_to_string)
17756 (get_addr_from_python): Use gdbpy_ref.
17757
17758 2017-01-10 Tom Tromey <tom@tromey.com>
17759
17760 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17761 gdbpy_ref.
17762
17763 2017-01-10 Tom Tromey <tom@tromey.com>
17764
17765 * python/python.c (eval_python_command, gdbpy_decode_line)
17766 (gdbpy_run_events, gdbpy_start_type_printers)
17767 (gdbpy_apply_type_printers): Use gdbpy_ref.
17768
17769 2017-01-10 Tom Tromey <tom@tromey.com>
17770
17771 * python/py-param.c (get_doc_string, compute_enum_values): Use
17772 gdbpy_ref.
17773
17774 2017-01-10 Tom Tromey <tom@tromey.com>
17775
17776 * python/py-inferior.c (find_thread_object, build_inferior_list):
17777 Use gdbpy_ref.
17778
17779 2017-01-10 Tom Tromey <tom@tromey.com>
17780
17781 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17782
17783 2017-01-10 Tom Tromey <tom@tromey.com>
17784
17785 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
17786 gdbpy_ref.
17787
17788 2017-01-10 Tom Tromey <tom@tromey.com>
17789
17790 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
17791 extra incref.
17792 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
17793 Use gdbpy_ref.
17794
17795 2017-01-10 Tom Tromey <tom@tromey.com>
17796
17797 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17798 gdbpy_ref.
17799
17800 2017-01-10 Tom Tromey <tom@tromey.com>
17801
17802 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
17803 decref results of PyArg_ParseTupleAndKeywords.
17804
17805 2017-01-10 Tom Tromey <tom@tromey.com>
17806
17807 * python/python.c (python_run_simple_file): Use
17808 unique_xmalloc_ptr, gdbpy_ref.
17809
17810 2017-01-10 Tom Tromey <tom@tromey.com>
17811
17812 * python/py-prettyprint.c (print_stack_unless_memory_error)
17813 (print_string_repr, print_children): Use gdbpy_ref.
17814 (dummy_python_frame): New class.
17815 (dummy_python_frame::dummy_python_frame): Rename from
17816 push_dummy_python_frame.
17817 (py_restore_tstate): Remove.
17818
17819 2017-01-10 Tom Tromey <tom@tromey.com>
17820
17821 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17822
17823 2017-01-10 Tom Tromey <tom@tromey.com>
17824
17825 * python/python.c (ensure_python_env, restore_python_env):
17826 Remove.
17827 * python/python-internal.h (ensure_python_env): Don't declare.
17828 * varobj.h (varobj_ensure_python_env): Don't declare.
17829 * varobj.c (varobj_ensure_python_env): Remove.
17830
17831 2017-01-10 Tom Tromey <tom@tromey.com>
17832
17833 * varobj.c (varobj_value_get_print_value): Use
17834 gdbpy_enter_varobj.
17835
17836 2017-01-10 Tom Tromey <tom@tromey.com>
17837
17838 * python/py-prettyprint.c (print_string_repr, print_children):
17839 Update.
17840 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
17841 of "encoding".
17842 * varobj.c (varobj_value_get_print_value): Update.
17843 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
17844
17845 2017-01-10 Tom Tromey <tom@tromey.com>
17846
17847 * varobj.c (varobj_get_display_hint)
17848 (dynamic_varobj_has_child_method, install_new_value_visualizer)
17849 (varobj_set_visualizer, free_variable): Use
17850 gdbpy_enter_varobj.
17851
17852 2017-01-10 Tom Tromey <tom@tromey.com>
17853
17854 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
17855 (do_finish_initialization): New function. Use gdbpy_ref.
17856 (gdbpy_finish_initialization): Use gdbpy_enter. Call
17857 do_finish_initialization.
17858
17859 2017-01-10 Tom Tromey <tom@tromey.com>
17860
17861 * python/py-param.c (get_set_value, get_show_value): Use
17862 gdbpy_enter, gdbpy_ref.
17863
17864 2017-01-10 Tom Tromey <tom@tromey.com>
17865
17866 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
17867
17868 2017-01-10 Tom Tromey <tom@tromey.com>
17869
17870 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
17871
17872 2017-01-10 Tom Tromey <tom@tromey.com>
17873
17874 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
17875 Use gdbpy_enter_varobj.
17876
17877 2017-01-10 Tom Tromey <tom@tromey.com>
17878
17879 * varobj.c (gdbpy_enter_varobj): New constructor.
17880 * python/python-internal.h (gdbpy_enter_varobj): New class.
17881 * python/py-varobj.c (py_varobj_get_iterator): Use
17882 gdbpy_enter_varobj.
17883
17884 2017-01-10 Tom Tromey <tom@tromey.com>
17885
17886 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
17887 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17888 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
17889 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
17890 unique_xmalloc_ptr.
17891 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
17892
17893 2017-01-10 Tom Tromey <tom@tromey.com>
17894
17895 * python/py-xmethods.c (invoke_match_method): Use
17896 gdbpy_ref.
17897
17898 2017-01-10 Tom Tromey <tom@tromey.com>
17899
17900 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
17901 gdbpy_enter, gdbpy_ref.
17902
17903 2017-01-10 Tom Tromey <tom@tromey.com>
17904
17905 * python/python.c (python_interactive_command): Use gdbpy_enter.
17906
17907 2017-01-10 Tom Tromey <tom@tromey.com>
17908
17909 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
17910 gdbpy_ref.
17911
17912 2017-01-10 Tom Tromey <tom@tromey.com>
17913
17914 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
17915 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17916
17917 2017-01-10 Tom Tromey <tom@tromey.com>
17918
17919 * utils.h (htab_deleter): New struct.
17920 (htab_up): New typedef.
17921 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
17922 gdbpy_enter, gdbpy_ref, htab_up.
17923
17924 2017-01-10 Tom Tromey <tom@tromey.com>
17925
17926 * python/py-unwind.c (pending_frame_invalidate): Remove.
17927 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
17928
17929 2017-01-10 Tom Tromey <tom@tromey.com>
17930
17931 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
17932 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
17933
17934 2017-01-10 Tom Tromey <tom@tromey.com>
17935
17936 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
17937
17938 2017-01-10 Tom Tromey <tom@tromey.com>
17939
17940 * python/python.c (gdbpy_eval_from_control_command)
17941 (gdbpy_source_script, gdbpy_run_events)
17942 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
17943 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
17944 gdbpy_enter.
17945
17946 2017-01-10 Tom Tromey <tom@tromey.com>
17947
17948 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
17949
17950 2017-01-10 Tom Tromey <tom@tromey.com>
17951
17952 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
17953
17954 2017-01-10 Tom Tromey <tom@tromey.com>
17955
17956 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
17957 (python_on_inferior_call_pre, python_on_inferior_call_post)
17958 (python_on_memory_change, python_on_register_change)
17959 (python_inferior_exit, python_new_objfile, add_thread_object)
17960 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
17961
17962 2017-01-10 Tom Tromey <tom@tromey.com>
17963
17964 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
17965 (bpfinishpy_handle_exit): Use gdbpy_enter.
17966
17967 2017-01-10 Tom Tromey <tom@tromey.com>
17968
17969 * python/py-cmd.c (cmdpy_destroyer)
17970 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
17971 gdbpy_enter.
17972
17973 2017-01-10 Tom Tromey <tom@tromey.com>
17974
17975 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17976 gdbpy_enter.
17977 (gdbpy_breakpoint_has_cond): Likewise.
17978
17979 2017-01-10 Tom Tromey <tom@tromey.com>
17980
17981 * python/python.c (gdbpy_enter): New constructor.
17982 (~gdbpy_enter): New destructor.
17983 (restore_python_env, ensure_python_env): Rewrite.
17984 * python/python-internal.h (gdbpy_enter): New class.
17985
17986 2017-01-10 Tom Tromey <tom@tromey.com>
17987
17988 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
17989
17990 2017-01-10 Tom Tromey <tom@tromey.com>
17991
17992 * python/py-value.c (value_has_field, get_field_flag)
17993 (get_field_type, valpy_getitem, convert_value_from_python): Use
17994 gdbpy_ref.
17995
17996 2017-01-10 Tom Tromey <tom@tromey.com>
17997
17998 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
17999 gdbpy_ref.
18000
18001 2017-01-10 Tom Tromey <tom@tromey.com>
18002
18003 * python/py-prettyprint.c (search_pp_list)
18004 (find_pretty_printer_from_objfiles)
18005 (find_pretty_printer_from_progspace)
18006 (find_pretty_printer_from_gdb, find_pretty_printer)
18007 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
18008 gdbpy_ref.
18009
18010 2017-01-10 Tom Tromey <tom@tromey.com>
18011
18012 * python/py-param.c (call_doc_function): Use gdbpy_ref.
18013
18014 2017-01-10 Tom Tromey <tom@tromey.com>
18015
18016 * python/py-linetable.c (build_line_table_tuple_from_pcs)
18017 (ltpy_get_all_source_lines): Use gdbpy_ref.
18018
18019 2017-01-10 Tom Tromey <tom@tromey.com>
18020
18021 * python/py-framefilter.c (extract_sym, extract_value)
18022 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
18023 gdbpy_ref.
18024
18025 2017-01-10 Tom Tromey <tom@tromey.com>
18026
18027 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
18028
18029 2017-01-10 Tom Tromey <tom@tromey.com>
18030
18031 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
18032
18033 2017-01-10 Tom Tromey <tom@tromey.com>
18034
18035 * python/py-function.c (convert_values_to_python, fnpy_init): Use
18036 gdbpy_ref.
18037
18038 2017-01-10 Tom Tromey <tom@tromey.com>
18039
18040 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
18041
18042 2017-01-10 Tom Tromey <tom@tromey.com>
18043
18044 * python/py-type.c (convert_field, make_fielditem, typy_fields)
18045 (typy_range): Use gdbpy_ref.
18046
18047 2017-01-10 Tom Tromey <tom@tromey.com>
18048
18049 * python/py-threadevent.c (create_thread_event_object): Use
18050 gdbpy_ref.
18051 * python/py-stopevent.c (create_stop_event_object): Simplify.
18052 (emit_stop_event): Use gdbpy_ref.
18053 * python/py-signalevent.c (create_signal_event_object): Use
18054 gdbpy_ref.
18055 * python/py-newobjfileevent.c (create_new_objfile_event_object)
18056 (emit_new_objfile_event, create_clear_objfiles_event_object)
18057 (emit_clear_objfiles_event): Use gdbpy_ref.
18058 * python/py-infevents.c (create_inferior_call_event_object)
18059 (create_register_changed_event_object)
18060 (create_memory_changed_event_object, emit_inferior_call_event)
18061 (emit_memory_changed_event, emit_register_changed_event): Use
18062 gdbpy_ref.
18063 * python/py-exitedevent.c (create_exited_event_object)
18064 (emit_exited_event): Use gdbpy_ref.
18065 * python/py-event.h (evpy_emit_event): Remove
18066 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
18067 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
18068 * python/py-continueevent.c (emit_continue_event): Use
18069 gdbpy_ref.
18070 * python/py-breakpoint.c (gdbpy_breakpoint_created)
18071 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
18072 gdbpy_ref.
18073 * python/py-bpevent.c (create_breakpoint_event_object): Use
18074 gdbpy_ref.
18075
18076 2017-01-10 Tom Tromey <tom@tromey.com>
18077
18078 * python/py-ref.h: New file.
18079
18080 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18081
18082 * cli-out.c (cli_ui_out::do_redirect): Change return type to
18083 void.
18084 * cli-out.h (cli_ui_out::do_redirect): Likewise.
18085 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
18086 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
18087 * ui-out.c (ui_out::redirect): Likewise.
18088 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
18089 * cli/cli-logging.c (set_logging_redirect): Update call site of
18090 ui_out::redirect.
18091 (handle_redirections): Likewise.
18092 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
18093 * top.c (execute_command_to_string): Likewise.
18094 * utils.c (do_ui_out_redirect_pop): Likewise.
18095
18096 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18097
18098 * stack.c (_initialize_stack): Update "frame" command help message.
18099
18100 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
18101
18102 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
18103
18104 2017-01-06 Yao Qi <yao.qi@linaro.org>
18105
18106 * x86-linux-nat.h: Include gdb_proc_service.h.
18107
18108 2017-01-06 Yao Qi <yao.qi@linaro.org>
18109
18110 * ser-base.h: Include serial.h.
18111
18112 2017-01-06 Yao Qi <yao.qi@linaro.org>
18113
18114 * ppc-linux-tdep.h: Include ppc-tdep.h.
18115
18116 2017-01-06 Yao Qi <yao.qi@linaro.org>
18117
18118 * nat/amd64-linux-siginfo.h: Include signal.h.
18119
18120 2017-01-06 Yao Qi <yao.qi@linaro.org>
18121
18122 * nat/aarch64-linux-hw-point.h: Include break-common.h.
18123
18124 2017-01-06 Yao Qi <yao.qi@linaro.org>
18125
18126 * mi/mi-parse.h: Include mi-cmds.h.
18127
18128 2017-01-06 Yao Qi <yao.qi@linaro.org>
18129
18130 * inf-loop.c: Don't include "target.h".
18131 * inf-loop.h: Include it here.
18132
18133 2017-01-06 Yao Qi <yao.qi@linaro.org>
18134
18135 * dfp.h: Include "dboulest.h" and "expression.h".
18136
18137 2017-01-06 Yao Qi <yao.qi@linaro.org>
18138
18139 * ax-gdb.h: Include "ax.h".
18140
18141 2017-01-06 Yao Qi <yao.qi@linaro.org>
18142
18143 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
18144 with nat/gdb_ptrace.h.
18145
18146 2017-01-05 Yao Qi <yao.qi@linaro.org>
18147
18148 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
18149 new line.
18150 (mips64_fbsd_sigframe_init): Likewise.
18151
18152 2017-01-04 John Baldwin <jhb@FreeBSD.org>
18153
18154 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
18155 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
18156
18157 2017-01-04 John Baldwin <jhb@FreeBSD.org>
18158
18159 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
18160 * NEWS: Mention new FreeBSD/mips native configuration.
18161 * config/mips/fbsd.mh: New file.
18162 * configure.host: Add mips*-*-freebsd*.
18163 * mips-fbsd-nat.c: New file.
18164
18165 2017-01-04 John Baldwin <jhb@FreeBSD.org>
18166
18167 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
18168 (ALLDEPFILES): Add mips-fbsd-tdep.c.
18169 * NEWS: Mention new FreeBSD/mips target.
18170 * configure.tgt: Add mips*-*-freebsd*.
18171 * mips-fbsd-tdep.c: New file.
18172 * mips-fbsd-tdep.h: New file.
18173
18174 2017-01-04 Yao Qi <yao.qi@linaro.org>
18175
18176 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
18177 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
18178
18179 2017-01-01 Joel Brobecker <brobecker@adacore.com>
18180
18181 Update copyright year range in all GDB files.
18182
18183 2017-01-01 Joel Brobecker <brobecker@adacore.com>
18184
18185 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
18186
18187 For older changes see ChangeLog-2016.
18188 \f
18189 Local Variables:
18190 mode: change-log
18191 left-margin: 8
18192 fill-column: 74
18193 version-control: never
18194 coding: utf-8
18195 End: