Update documentation regarding the bfd returned by bfd_openr_next_archived_file
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
68f81d60
RH
12017-12-15 Richard Henderson <rth@redhat.com>
2 Uros Bizjak <ubizjak@gmail.com>
3
4 PR gdb/19061
5 * alpha-tdep.c (alpha_software_single_step): Call
6 alpha_deal_with_atomic_sequence here.
7 (set_gdbarch_software_single_step): Set to
8 alpha_software_single_step.
9 * nat/linux-ptrace.h [__alpha__]: Define GDB_ARCH_IS_TRAP_BRKPT
10 and GDB_ARCH_IS_TRAP_HWBKPT.
11
97d4fac1
YQ
122017-12-15 Yao Qi <yao.qi@linaro.org>
13
14 * unittests/memory-map-selftests.c: Wrap test with HAVE_LIBEXPAT.
15
828d5846
XR
162017-12-15 Xavier Roirand <roirand@adacore.com>
17
18 * ada-lang.c (ada_value_primitive_field): Handle field search
19 in case of homonyms.
20 (find_struct_field): Ditto.
21 (ada_search_struct_field): Ditto.
22 (ada_value_struct_elt): Ditto.
23 (ada_lookup_struct_elt_type): Ditto.
24
8e557e52
SM
252017-12-14 Simon Marchi <simon.marchi@ericsson.com>
26
27 * python/py-breakpoint.c (bppy_init): Use 'O' format specifier
28 for "qualified" and use PyObject_IsTrue.
29
8af5c486
JK
302017-12-14 Jan Kratochvil <jan.kratochvil@redhat.com>
31
32 * dwarf2read.c (dw2_debug_names_iterator::next): Support
33 DW_IDX_type_unit.
34 (debug_names::dwarf5_offset_size, unit_kind): New.
35 (debug_names::insert): Add parameter kind.
36 (debug_names::build): Support DW_IDX_type_unit.
37 (debug_names::recursively_write_psymbols): Update
38 (debug_names::write_psymbols caller.
39 (debug_names::write_one_signatured_type_data)
40 (debug_names::write_one_signatured_type): New.
41 (debug_names::index_key, debug_names::symbol_value)
42 (debug_names::write_psymbols): Add kind.
43 (debug_names::write_one_signatured_type): New.
44 (write_debug_names): Move dwarf5_offset_size to debug_names.
45 Use debug_names::write_one_signatured_type for type units.
46
79e8fcaa
JB
472017-12-14 Joel Brobecker <brobecker@adacore.com>
48
49 * ada-lang.c (ada_value_equal): Add handling of typedef types
50 when comparing array objects.
51
e05fa6f9
JB
522017-12-14 Joel Brobecker <brobecker@adacore.com>
53
54 * ada-tasks.c (read_atcb): Properly set task_info->ptid
55 when !target_has_execution as well.
56 (task_command): Remove error when !target_has_execution.
57
b89641ba
SM
582017-12-13 Simon Marchi <simon.marchi@ericsson.com>
59
60 * location.h (string_to_event_location): Add match_type
61 parameter.
62 * location.c (string_to_event_location): Likewise.
63 * python/py-breakpoint.c (bppy_init): Handle qualified
64 parameter.
65
a22ecf70
PA
662017-12-13 Pedro Alves <palves@redhat.com>
67
68 * completer.c (completion_tracker::maybe_add_completion): New
69 'text' and 'word' parameters. Use make_completion_match_str.
70 (completion_tracker::add_completion): New 'text' and 'word'
71 parameters. Pass down.
72 (completion_tracker::recompute_lowest_common_denominator): Change
73 parameter type to gdb::unique_xmalloc_ptr rval ref. Adjust.
74 * completer.h (completion_tracker::add_completion): New 'text' and
75 'word' parameters.
76 (completion_tracker::recompute_lowest_common_denominator): Change
77 parameter type to gdb::unique_xmalloc_ptr rval ref.
78 (completion_tracker::recompute_lowest_common_denominator): Change
79 parameter type to gdb::unique_xmalloc_ptr rval ref.
80 * symtab.c (completion_list_add_name): Pass down 'text' and 'word'
81 as well.
82
60a20c19
PA
832017-12-13 Pedro Alves <palves@redhat.com>
84
85 * cli/cli-decode.c (complete_on_cmdlist, complete_on_enum): Use
86 make_completion_match_str.
87 * completer.c: Use gdb::unique_xmalloc_ptr and
88 make_completion_match_str.
89 (make_completion_match_str_1): New.
90 (make_completion_match_str(const char *, const char *,
91 const char *)): New.
92 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
93 const char *, const char *)): New.
94 * completer.h (make_completion_match_str(const char *,
95 const char *, const char *)): New.
96 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
97 const char *, const char *)): New.
98 * interps.c (interpreter_completer): Use make_completion_match_str.
99 * symtab.c (completion_list_add_name, add_filename_to_list): Use
100 make_completion_match_str.
101
96647014
SH
1022017-12-13 Stafford Horne <shorne@gmail.com>
103
104 * or1k-tdep.c (or1k_analyse_inst): Use _() wrapper for message
105 strings.
106 (or1k_unwind_pc): Use paddress() instead of %p.
107 (or1k_unwind_sp): Likewise.
108 (or1k_frame_cache): Use host_address_to_string()/paddress()
109 instead of %p and use _() wrapper for message strings.
110
3bbd9f18
SM
1112017-12-13 Simon Marchi <simon.marchi@ericsson.com>
112
113 * contrib/ari/gdb_ari.sh: Fix typo in help.
114
9937536c
JB
1152017-12-13 Joel Brobecker <brobecker@adacore.com>
116
117 * event-top.c (handle_line_of_input): Set server_command.
118
a994fec4
FJ
1192017-12-12 Stafford Horne <shorne@gmail.com>
120 Stefan Wallentowitz <stefan@wallentowitz.de>
121 Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
122 Franck Jullien <franck.jullien@gmail.com>
123 Jeremy Bennett <jeremy.bennett@embecosm.com>
124
125 * configure.tgt: Add targets for or1k and or1knd.
126 * or1k-tdep.c: New file.
127 * or1k-tdep.h: New file.
128 * features/Makefile: Add or1k.xml to build.
129 * features/or1k.xml: New file.
130 * features/or1k-core.xml: New file.
131 * features/or1k.c: Generated.
132
db9077b7
AM
1332017-12-12 Alan Modra <amodra@gmail.com>
134
135 PR tdep/22576
136 * ppc64-tdep.c (ppc64_plt_entry_point): Rewrite to take TOC-relative
137 PLT offset, and retrieve r2 from stack when executing in reverse.
138 (ppc64_standard_linkage1_target): Drop pc param. Calculate offset
139 rather than PLT address.
140 (ppc64_standard_linkage2_target): Likewise.
141 (ppc64_standard_linkage3_target): Likewise.
142 (ppc64_standard_linkage4_target): Likewise.
143 (ppc64_skip_trampoline_code_1): Adjust to suit.
144
a9334058
SM
1452017-12-11 Simon Marchi <simon.marchi@ericsson.com>
146
147 PR gdb/22556
148 * remote.c (remote_thread_name): Return NULL if name is empty.
149 (remote_threads_extra_info): Return NULL if extra info is empty.
150
3c0aa29a
PA
1512017-12-11 Pedro Alves <palves@redhat.com>
152
153 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index)
154 (elf_sym_fns_debug_names): Move to elfread.c.
155 * dwarf2read.c (dwarf2_initialize_objfile): Return a boolean
156 instead of a sym_fns and add 'index_kind' output parameter. Fill
157 the latter in with the index variant kind if using an index.
158 (enum dw_index_kind): Moved to symfile.h.
159 * elfread.c (elf_sym_fns_gdb_index, elf_sym_fns_debug_names)
160 (elf_sym_fns_lazy_psyms): Move from defs.h.
161 (elf_symfile_read): Adjust to new dwarf2_initialize_objfile
162 interface.
163 * symfile.h (enum class dw_index_kind): New, moved from
164 dwarf2read.c.
165 (dwarf2_initialize_objfile): Change prototype.
166
f2f9e7ec
UW
1672017-12-11 Ulrich Weigand <uweigand@de.ibm.com>
168
169 * target-float.c (mpfr_float_ops::from_target): Use mpfr_set_ui
170 instead of mpfr_set_si to convert mantissa bits.
171
08f49010
XR
1722017-12-11 Xavier Roirand <roirand@adacore.com>
173 Joel Brobecker <brobecker@adacore.com>
174
175 * ada-lang.c (ada_tag_value_at_base_address): Change the way
176 tagged type base address is computed.
177 (enum ada_primitive_types) <ada_primitive_type_storage_offset>:
178 New enumerate.
179 (ada_language_arch_info): Set the ada_primitive_type_storage_offset
180 element of lai->primitive_type_vector.
181
a3c5fafd
PA
1822017-12-08 Pedro Alves <palves@redhat.com>
183
184 * dwarf2read.c (mock_mapped_index): Reimplement as an extension of
185 mapped_index_base.
186 (check_match): Adjust to use mock_index directly.
187 (check_find_bounds_finds)
188 (test_mapped_index_find_name_component_bounds): Adjust to work
189 with a mapped_index_base.
190
44ed8f3e
PA
1912017-12-08 Pedro Alves <palves@redhat.com>
192
193 * dwarf2read.c (struct mapped_index_base): New, partially factored
194 out from ...
195 (struct mapped_index): ... this. Inherit mapped_index_base.
196 (mapped_index::symbol_name_slot_invalid):
197 (mapped_index::symbol_name_at): Add override marker.
198 (mapped_index::symbol_name_count): New.
199 (struct mapped_debug_names): Inherit mapped_index_base.
200 (mapped_debug_names::symbol_name_at): New.
201 (mapped_debug_names::symbol_name_count): New.
202 (mapped_index::find_name_components_bounds): Rename to ...
203 (mapped_index_base::find_name_components_bounds): ... this.
204 (mapped_index::build_name_components): Rename to ...
205 (mapped_index_base::build_name_components): ... this. Adjust to
206 use mapped_index_base::symbol_name_count and
207 mapped_index_base::symbol_name_slot_invalid.
208 (dw2_expand_symtabs_matching_symbol): Take a mapped_index_base
209 instead of a mapped_index. Use
210 dw2_expand_symtabs_matching_symbol.
211
f00a2de2
PA
2122017-12-08 Pedro Alves <palves@redhat.com>
213
214 * dwarf2read.c (mapped_index::symbol_table_slot): New.
215 (mapped_index::address_table): Now a gdb::array_view of const
216 gdb_byte.
217 (mapped_index::symbol_table): Now a gdb::array_view of
218 symbol_table_slot.
219 (mapped_index::address_table_size)
220 (mapped_index::symbol_table_slots): Delete.
221 (create_addrmap_from_index): Adjust.
222 (find_slot_in_mapped_hash): Adjust.
223 (read_index_from_section): Adjust.
224 (dwarf2_read_index): Adjust.
225
927aa2e7
JK
2262017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
227 Pedro Alves <palves@redhat.com>
228
229 * defs.h (elf_sym_fns_debug_names): New declaration.
230 * dwarf2read.c: Include "hash_enum.h".
231 (mapped_debug_names): New.
232 (struct dwarf2_per_objfile): Add debug_names, debug_aranges and
233 debug_names_table.
234 (dwarf2_elf_names): Add ".debug_names" and ".debug_aranges".
235 (struct dwz_file): Add debug_names.
236 (dwarf2_per_objfile::locate_sections): Handle debug_names and
237 debug_aranges.
238 (locate_dwz_sections): Handle debug_names.
239 (create_signatured_type_table_from_debug_names)
240 (create_addrmap_from_aranges): New.
241 (dwarf2_read_index): Update function comment.
242 (dwarf5_augmentation): Moved up.
243 (read_debug_names_from_section, create_cus_from_debug_names_list)
244 (create_cus_from_debug_names, dwarf2_read_debug_names): New.
245 (dwarf5_djb_hash): Moved up.
246 (dw2_debug_names_iterator): New.
247 (read_indirect_string_at_offset): New declaration.
248 (mapped_debug_names::namei_to_name)
249 (dw2_debug_names_iterator::find_vec_in_debug_names)
250 (dw2_debug_names_iterator::next, dw2_debug_names_lookup_symbol)
251 (dw2_debug_names_dump, dw2_debug_names_expand_symtabs_for_function)
252 (dw2_debug_names_expand_symtabs_matching, dwarf2_debug_names_functions):
253 New.
254 (dwarf2_initialize_objfile): Return also elf_sym_fns_debug_names.
255 (debug_names::djb_hash): Rename it to dwarf5_djb_hash.
256 (debug_names::build): Update djb_hash caller.
257 (write_debug_names): Move out and rename augmentation to
258 dwarf5_augmentation.
259 * elfread.c (elf_sym_fns_debug_names): New.
260 * psymtab.h (dwarf2_debug_names_functions): New declaration.
261 * symfile.h (struct dwarf2_debug_sections): Add debug_names and
262 debug_aranges.
263 * xcoffread.c (dwarf2_xcoff_names): Add debug_names and debug_aranges.
264
e5fa6583
PA
2652017-12-08 Pedro Alves <palves@redhat.com>
266
267 * common/hash_enum.h: New file.
268
4b514bc8
JK
2692017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
270
271 * dwarf2read.c (create_cu_from_index_list): New from ...
272 (create_cus_from_index_list): ... this function, use it.
273 (dw_expand_symtabs_matching_file_matcher)
274 (dw2_expand_symtabs_matching_one): New from ...
275 (dw2_expand_symtabs_matching): ... this function, use them.
276
abccd1e7
JK
2772017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
278
279 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move here
280 declarations from elfread.c.
281 (dwarf2_initialize_objfile): Change return value.
282 * elfread.c (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move these
283 declarations to defs.h.
284 (elf_symfile_read): Adjust dwarf2_initialize_objfile caller.
285 * symfile.h (dwarf2_initialize_objfile): Change return type.
286
437afbb8
JK
2872017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
288 Pedro Alves <palves@redhat.com>
289
290 * contrib/gdb-add-index.sh (index): Rename to ...
291 (index4): ... here.
292 (index5, debugstr, debugstrmerge, debugstrerr): New variables.
293 Support also .debug_names and .debug_str.
294 * dwarf2read.c: Include cmath, set, list.
295 (INDEX_SUFFIX): Rename to ...
296 (INDEX4_SUFFIX): ... here.
297 (INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
298 (file_write(FILE *, const void *, size_t)): New.
299 (file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
300 (data_buf::append_unsigned_leb128, data_buf::empty): New.
301 (data_buf::file_write): Use ::file_write.
302 (data_buf::c_str, dwarf5_djb_hash, debug_names)
303 (check_dwarf64_offsets): New.
304 (psyms_seen_size, write_gdbindex): New from
305 write_psymtabs_to_index code.
306 (dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
307 (enum dw_index_kind): New.
308 (write_psymtabs_to_index): New parameter index_kind. Support
309 filename_str and out_file_str. Move code to write_gdbindex,
310 possibly call write_debug_names.
311 (save_gdb_index_command): New parameter -dwarf-5.
312 (_initialize_dwarf2_read): Document the new parameter -dwarf-5.
313
6432ec65
JK
3142017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
315 Pedro Alves <palves@redhat.com>
316
317 * contrib/cc-with-tweaks.sh: Change interpreter to bash, incl. initial
318 comment.
319 (GDB_ADD_INDEX): New variable.
320 <$want_index>: Call $GDB_ADD_INDEX.
321
92469284
SDJ
3222017-12-08 Sergio Durigan Junior <sergiodj@redhat.com>
323
324 * dtrace-probe.c (dtrace_process_dof_probe): Do not declare a new
325 "expression_up" inside the TRY block.
326
f17d9474
YQ
3272017-12-08 Yao Qi <yao.qi@linaro.org>
328
329 * breakpoint.c (update_watchpoint): Call
330 address_significant.
331
a0de8c21
YQ
3322017-12-08 Yao Qi <yao.qi@linaro.org>
333
334 * breakpoint.c (adjust_breakpoint_address): Call
335 address_significant.
336
a738ea1d
YQ
3372017-12-08 Yao Qi <yao.qi@linaro.org>
338
339 * aarch64-tdep.c (aarch64_gdbarch_init): Install gdbarch
340 significant_addr_bit.
341 * gdbarch.sh (significant_addr_bit): New.
342 * gdbarch.c, gdbarch.h: Re-generated.
343 * target.c (memory_xfer_partial): Call address_significant.
344 * utils.c (address_significant): New function.
345 * utils.h (address_significant): Declare.
346
8e481c3b
TT
3472017-12-08 Tom Tromey <tom@tromey.com>
348
349 * printcmd.c (ui_printf): Update. Use std::vector.
350 * common/format.h (struct format_piece): Add constructor.
351 <string>: Now const.
352 (class format_pieces): New class.
353 (parse_format_string, free_format_pieces)
354 (free_format_pieces_cleanup): Remove.
355 * common/format.c (format_pieces::format_pieces): Rename from
356 parse_format_string. Update.
357 (free_format_pieces, free_format_pieces_cleanup): Remove.
358 * breakpoint.c (parse_cmd_to_aexpr): Update. Use std::vector.
359 * ax-gdb.h (gen_printf): Remove argument.
360 * ax-gdb.c (gen_printf): Remove "frags" argument.
361 (maint_agent_printf_command): Update. Use std::vector.
362
6b05c8bd
YQ
3632017-12-08 Yao Qi <yao.qi@linaro.org>
364
365 PR breakpionts/22567
366 * linespec.c (minsym_found): Set sal.section.
367
336ef6d2
AA
3682017-12-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
369
370 * configure.tgt (s390*-*-linux*): Add symfile-mem.o.
371
fa6eb693
KS
3722017-12-07 Keith Seitz <keiths@redhat.com>
373
374 PR breakpoints/22569
375 * location.c (string_to_explicit_location): When terminating
376 parsing early, break out of enclosing loop instead of returning.
377
883fd55a
KS
3782017-12-07 Keith Seitz <keiths@redhat.com>
379
380 * NEWS (New commands): Mention set/show print type nested-type-limit.
381 * c-typeprint.c (c_type_print_base): Print out nested types.
382 * dwarf2read.c (struct typedef_field_list): Rename to ...
383 (struct decl_field_list): ... this. Change all uses.
384 (struct field_info) <nested_types_list, nested_types_list_count>:
385 New fields.
386 (add_partial_symbol): Look for nested type definitions in C++, too.
387 (dwarf2_add_typedef): Rename to ...
388 (dwarf2_add_type_defn): ... this.
389 (type_can_define_types): New function.
390 Update assertion to use type_can_define_types.
391 Permit NULL for a field's name.
392 (process_structure_scope): Handle child DIEs of types that can
393 define types.
394 Copy the list of nested types into the type struct.
395 * gdbtypes.h (struct typedef_field): Rename to ...
396 (struct decl_field): ... this. Change all uses.
397 [is_protected, is_private]: New fields.
398 (struct cplus_struct_type) <nested_types, nested_types_count>: New
399 fields.
400 (TYPE_NESTED_TYPES_ARRAY, TYPE_NESTED_TYPES_FIELD)
401 (TYPE_NESTED_TYPES_FIELD_NAME, TYPE_NESTED_TYPES_FIELD_TYPE)
402 (TYPE_NESTED_TYPES_COUNT, TYPE_NESTED_TYPES_FIELD_PROTECTED)
403 (TYPE_NESTED_TYPES_FIELD_PRIVATE): New macros.
404 * typeprint.c (type_print_raw_options, default_ptype_flags): Add
405 default value for print_nested_type_limit.
406 (print_nested_type_limit): New static variable.
407 (set_print_type_nested_types, show_print_type_nested_types): New
408 functions.
409 (_initialize_typeprint): Register new commands for set/show
410 `print-nested-type-limit'.
411 * typeprint.h (struct type_print_options) [print_nested_type_limit]:
412 New field.
413
99598d71
TT
4142017-12-07 Tom Tromey <tom@tromey.com>
415
416 PR breakpoints/22511:
417 * breakpoint.c (commands_command_1): Don't throw an exception when
418 no commands have been read.
419
23a8d186
AS
4202017-12-07 Adam Stylinski <adam.stylinski@etegent.com>
421
422 PR c++/21222
423 * target-descriptions.c (print_c_tdesc::visit_pre): Change type of
424 range-for variable.
425
30970df7
SM
4262017-12-07 Simon Marchi <simon.marchi@ericsson.com>
427
428 * common/selftest.h (struct selftest): Add virtual destructor.
429
824cc835
PM
4302017-12-07 Phil Muldoon <pmuldoon@redhat.com>
431
432 * python/py-breakpoint.c (bppy_init): Use string_to_event_location
433 over basic location code. Implement explicit location keywords.
434 (bppy_init_validate_args): New function.
435 * NEWS: Document Python explicit breakpoint locations.
436
9c226a86
JB
4372017-12-07 Joel Brobecker <brobecker@adacore.com>
438
439 * MAINTAINERS: Restore target entries for m68hc11-elf,
440 score-elf and xstormy16-elf, incorrectly removed in a previous
441 patch meant to only update the list of active maintainers.
442
649a140c
PA
4432017-12-06 Pedro Alves <palves@redhat.com>
444
445 * break-catch-syscall.c (insert_catch_syscall)
446 (remove_catch_syscall): Adjust to pass reference to
447 inf_data->syscalls_counts directly via gdb::array_view.
448 * fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
449 and gdb::array_view.
450 * linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
451 * remote.c (remote_set_syscall_catchpoint): Likewise.
452 * target-debug.h (target_debug_print_bool): New.
453 (define target_debug_print_gdb_array_view_const_int): New.
454 * target-delegates.c: Regenerate.
455 * target.h (target_ops) <to_set_syscall_catchpoint>: Use
456 gdb::array_view and bool.
457 (target_set_syscall_catchpoint): Likewise.
458
9a93831c
SM
4592017-12-06 Simon Marchi <simon.marchi@ericsson.com>
460
461 * break-catch-syscall.c (catch_syscall_completer): Get pointers
462 to syscall group strings after building the string vector.
463
7cc244de
PA
4642017-12-06 Pedro Alves <palves@redhat.com>
465
466 * remote.c (remote_query_supported): Don't send "xmlRegisters=" if
467 "qXfer:features:read"" is disabled.
468 (remote_write_qxfer, remote_read_qxfer, remote_search_memory):
469 Check packet_config_support instead of packet->support directly.
470
858c9d13
SM
4712017-12-05 Simon Marchi <simon.marchi@ericsson.com>
472
473 * target-descriptions.c (struct tdesc_feature) <registers>: Use
474 tdesc_reg_up typedef.
475 (struct target_desc) <features>: Use tdesc_feature_up typedef.
476
d4a0e8b5
SM
4772017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
478
479 * target-descriptions.c (struct tdesc_type): Use default
480 destructor.
481 <u>: Remove.
482 <accept>: Remove.
483 (struct tdesc_type_builtin): New.
484 (struct tdesc_type_vector): New.
485 (struct tdesc_type_with_fields): New.
486 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
487 (tdesc_gdb_type): Remove.
488 (tdesc_register_type): Adjust.
489 (tdesc_create_vector): Create tdesc_type_vector.
490 (tdesc_create_struct): Create tdesc_type_with_fields.
491 (tdesc_set_struct_size): Change parameter type.
492 (tdesc_create_union): Create tdesc_type_with_fields.
493 (tdesc_create_flags): Likewise.
494 (tdesc_create_enum): Likewise.
495 (tdesc_add_field): Change parameter type.
496 (tdesc_add_typed_bitfield): Likewise.
497 (tdesc_add_bitfield): Likewise.
498 (tdesc_add_flag): Likewise.
499 (tdesc_add_enum_value): Likewise.
500 (print_c_tdesc) <visit>: Remove overload with tdesc_type
501 parameter, add overloads for tdesc_type_builtin,
502 tdesc_type_with_fields and tdesc_type_vector.
503 <m_printed_type>: Remove.
504 <m_printed_element_type, m_printed_type_with_fields>: Add.
505 * target-descriptions.h (tdesc_create_enum): Change return type.
506 (tdesc_add_typed_bitfield): Change parameter type.
507 (tdesc_add_enum_value): Change parameter type.
508 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
509 type to tdesc_type_with_fields.
510 (tdesc_start_struct): Adjust.
511 (tdesc_start_flags): Adjust.
512 (tdesc_start_enum): Adjust.
513 (tdesc_start_field): Adjust.
514 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
515 (struct tdesc_type_vector): Forward-declare.
516 (struct tdesc_type_with_fields): Forward-declare.
517 (tdesc_create_struct): Change return type.
518 (tdesc_create_union): Likewise.
519 (tdesc_create_flags): Likewise.
520 (tdesc_add_field): Change parameter type.
521 (tdesc_set_struct_size): Likewise.
522 (tdesc_add_bitfield): Likewise.
523 (tdesc_add_flag): Likewise.
524 * features: Re-generate C files.
525
f0cddbef
SM
5262017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
527
528 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
529 (struct tdesc_arch_reg): Add constructor.
530 (DEF_VEC_O (tdesc_arch_reg)): Remove.
531 (struct tdesc_arch_data): Initialize fields.
532 <arch_regs>: Change type to std::vector.
533 (target_find_description): Adjust.
534 (tdesc_find_type): Adjust.
535 (tdesc_data_init): Call tdesc_arch_data constructor.
536 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
537 (tdesc_data_cleanup): Free data with delete.
538 (tdesc_numbered_register): Adjust.
539 (tdesc_find_arch_register): Adjust.
540 (tdesc_use_registers): Adjust.
541
d05200d1
SM
5422017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
543
544 * target-descriptions.c (tdesc_type_field): Remove typedef.
545 (DEF_VEC_O (tdesc_type_field)): Remove.
546 (struct tdesc_type_field): Add constructor.
547 <name>: Change type to std::string.
548 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
549 kind uses it.
550 <~tdesc_type>: Destroy vector if the type kind uses it.
551 <u::u::fields>: Change type to std::vector.
552 (tdesc_gdb_type): Adjust.
553 (tdesc_add_field): Adjust.
554 (tdesc_add_typed_bitfield): Adjust.
555 (tdesc_add_field): Adjust.
556 (tdesc_add_enum_value): Adjust.
557 (class print_c_tdesc) <visit>: Adjust.
558
082b9140
SM
5592017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
560
561 * target-descriptions.c (struct tdesc_type) <name>: Change type
562 to std::string.
563 <~tdesc_type>: Don't manually free name.
564 <operator==>: Adjust.
565 (tdesc_named_type): Adjust.
566 (tdesc_find_type): Adjust.
567 (tdesc_gdb_type): Adjust.
568 (class print_c_tdesc) <visit>: Adjust.
569
53c934e9
SM
5702017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
571
572 * target-descriptions.c (tdesc_type_p): Remove typedef.
573 (DEF_VEC_P (tdesc_type_p)): Remove.
574 (struct tdesc_feature) <types>: Change type to std::vector.
575 <~tdesc_feature>: Replace with default implementation.
576 <accept>: Adjust.
577 (tdesc_named_type): Adjust.
578 (tdesc_create_vector): Adjust.
579 (tdesc_create_struct): Adjust.
580 (tdesc_create_union): Adjust.
581 (tdesc_create_flags): Adjust.
582 (tdesc_create_enum): Adjust.
583
a8142ee1
SM
5842017-12-05 Simon Marchi <simon.marchi@ericsson.com>
585
586 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
587 type of name_ parameter, adjust to std::string change.
588 <name, group, type>: Change type to std::string.
589 <~tdesc_reg>: Replace with default implementation.
590 <operator==>: Adjust.
591 (tdesc_find_register_early): Adjust.
592 (tdesc_register_name): Adjust.
593 (tdesc_register_type): Adjust.
594 (tdesc_register_in_reggroup_p): Adjust.
595 (class print_c_tdesc) <visit>: Adjust.
596 (class print_c_feature) <visit>: Adjust.
858c9d13
SM
597 * features/arc-arcompact.c: Re-generate.
598 * features/arc-v2.c: Re-generate.
a8142ee1 599
c9c895b9
SM
6002017-12-05 Simon Marchi <simon.marchi@ericsson.com>
601
602 * target-descriptions.c (tdesc_reg_p): Remove typedef.
603 (DEF_VEC_P (tdesc_reg_p)): Remove.
604 (struct tdesc_feature) <registers>: Change type to std::vector.
605 <~tdesc_feature>: Don't manually free registers.
606 <accept>: Adjust.
607 <operator==>: Adjust.
608 (tdesc_has_registers): Adjust.
609 (tdesc_find_register_early): Adjust.
610 (tdesc_use_registers): Adjust.
611 (tdesc_create_reg): Adjust.
612
f65ff9f9
SM
6132017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
614
615 * target-descriptions.c (tdesc_feature) <name>: Change type to
616 std::string.
617 <~tdesc_feature>: Don't manually free name.
618 <operator==>: Adjust.
619 (tdesc_find_feature): Adjust.
620 (tdesc_feature_name): Adjust.
621 (class print_c_tdesc) <visit_pre>: Adjust.
622 (class print_c_feature) <visit_pre>: Adjust.
623
3eea796c
SM
6242017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
625
626 * target-descriptions.c (tdesc_feature_p): Remove typedef.
627 (DEF_VEC_P (tdesc_feature_p)): Remove.
628 (struct target_desc) <features>: Change type to std::vector.
629 <~target_desc>: Replace with default implementation.
630 <accept>: Adjust.
631 <operator==>: Adjust.
632 (tdesc_has_registers): Adjust.
633 (tdesc_find_feature): Adjust.
634 (tdesc_use_registers): Adjust.
635 (tdesc_create_feature): Adjust.
636
40e2a983
SM
6372017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
638
639 * target-descriptions.c (arch_p): Remove typedef.
640 (DEF_VEC_P (arch_p)): Remove.
641 (struct target_desc) <compatible>: Change type to std::vector.
642 <~target_desc>: Don't manually free compatible.
643 (tdesc_compatible_p): Adjust.
644 (tdesc_add_compatible): Adjust.
645 (class print_c_tdesc) <visit_pre>: Adjust.
646
129c10bc
SM
6472017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
648
649 * target-descriptions.c (property_s): Remove typedef.
650 (DEF_VEC_O (property_s)): Remove.
651 (struct target_desc) <properties>: Make an std::vector.
652 <~target_desc>: Don't manually free properties.
653 (tdesc_property): Adjust.
654 (set_tdesc_property): Adjust.
655 (class print_c_tdesc) <visit_pre>: Adjust.
656
ed9376bd
SM
6572017-12-05 Simon Marchi <simon.marchi@ericsson.com>
658
659 * common/gdb_assert.h (gdb_static_assert): Redefine using
660 static_assert.
661
798a7429
SM
6622017-12-05 Simon Marchi <simon.marchi@ericsson.com>
663
664 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
665 unused variables.
666 (ada_is_redundant_range_encoding): Likewise.
667 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
668 Likewise.
669 * alpha-tdep.c (alpha_software_single_step): Likewise.
670 * arm-tdep.c (_initialize_arm_tdep): Likewise.
671 * auto-load.c (info_auto_load_cmd): Likewise.
672 * break-catch-syscall.c (insert_catch_syscall): Likewise.
673 (remove_catch_syscall): Likewise.
674 * breakpoint.c (condition_completer): Likewise.
675 (clear_command): Likewise.
676 (update_breakpoint_locations): Likewise.
677 * btrace.c (btrace_disable): Likewise.
678 (btrace_teardown): Likewise.
679 (btrace_maint_update_pt_packets): Likewise.
680 (maint_btrace_clear_cmd): Likewise.
681 * cli/cli-decode.c (lookup_cmd_1): Likewise.
682 (lookup_cmd_composition): Likewise.
683 * cli/cli-dump.c (scan_filename): Likewise.
684 (restore_command): Likewise.
685 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
686 * compile/compile-object-load.c (compile_object_load): Likewise.
687 * compile/compile-object-run.c (compile_object_run): Likewise.
688 * compile/compile.c (compile_to_object): Likewise.
689 * completer.c (filename_completer): Likewise.
690 (complete_files_symbols): Likewise.
691 (complete_expression): Likewise.
692 * corelow.c (core_open): Likewise.
693 * ctf.c (ctf_start): Likewise.
694 (ctf_write_status): Likewise.
695 (ctf_write_uploaded_tsv): Likewise.
696 (ctf_write_definition_end): Likewise.
697 (ctf_open_dir): Likewise.
698 (ctf_xfer_partial): Likewise.
699 (ctf_trace_find): Likewise.
700 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
701 Likewise.
702 * dwarf2loc.c (allocate_piece_closure): Likewise.
703 (indirect_pieced_value): Likewise.
704 (dwarf2_evaluate_loc_desc_full): Likewise.
705 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
706 (dw2_expand_symtabs_matching): Likewise.
707 (dw2_map_symbol_filenames): Likewise.
708 (read_and_check_comp_unit_head): Likewise.
709 (read_cutu_die_from_dwo): Likewise.
710 (lookup_dwo_unit): Likewise.
711 (read_comp_units_from_section): Likewise.
712 (dwarf2_compute_name): Likewise.
713 (handle_DW_AT_stmt_list): Likewise.
714 (create_cus_hash_table): Likewise.
715 (create_dwp_v2_section): Likewise.
716 (dwarf2_rnglists_process): Likewise.
717 (dwarf2_ranges_process): Likewise.
718 (dwarf2_record_block_ranges): Likewise.
719 (is_vtable_name): Likewise.
720 (read_formatted_entries): Likewise.
721 (skip_form_bytes): Likewise.
722 * elfread.c (elf_symtab_read): Likewise.
723 * exec.c (exec_file_command): Likewise.
724 * f-valprint.c (f_val_print): Likewise.
725 (info_common_command_for_block): Likewise.
726 * guile/guile.c (initialize_scheme_side): Likewise.
727 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
728 * guile/scm-cmd.c (cmdscm_completer): Likewise.
729 (gdbscm_register_command_x): Likewise.
730 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
731 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
732 * guile/scm-ports.c (file_port_magic): Likewise.
733 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
734 (ppscm_pretty_print_one_value): Likewise.
735 (ppscm_print_children): Likewise.
736 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
737 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
738 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
739 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
740 * i386-tdep.c (i386_register_reggroup_p): Likewise.
741 * infcmd.c (run_command_1): Likewise.
742 (until_next_fsm_clean_up): Likewise.
743 * linespec.c (linespec_complete): Likewise.
744 (find_label_symbols): Likewise.
745 * m2-valprint.c (m2_val_print): Likewise.
746 * memattr.c (require_user_regions): Likewise.
747 (lookup_mem_region): Likewise.
748 (disable_mem_command): Likewise.
749 (mem_delete): Likewise.
750 * mep-tdep.c (mep_register_name): Likewise.
751 (mep_analyze_prologue): Likewise.
752 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
753 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
754 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
755 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
756 * minidebug.c (lzma_open): Likewise.
757 * minsyms.c (lookup_minimal_symbol): Likewise.
758 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
759 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
760 (mips_o64_return_value): Likewise.
761 (mips_single_step_through_delay): Likewise.
762 (_initialize_mips_tdep): Likewise.
763 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
764 (nios2_software_single_step): Likewise.
765 * parse.c (find_minsym_type_and_address): Likewise.
766 * psymtab.c (psym_relocate): Likewise.
767 * python/py-breakpoint.c (bppy_get_commands): Likewise.
768 (gdbpy_breakpoint_modified): Likewise.
769 * python/py-infevents.c (create_inferior_call_event_object):
770 Likewise.
771 * python/py-record-btrace.c (btpy_list_item): Likewise.
772 * python/py-type.c (typy_str): Likewise.
773 * python/py-value.c (valpy_call): Likewise.
774 * python/python.c (do_start_initialization): Likewise.
775 * record-btrace.c (record_btrace_insn_history_range): Likewise.
776 (record_btrace_call_history_range): Likewise.
777 (record_btrace_record_method): Likewise.
778 (record_btrace_xfer_partial): Likewise.
779 (btrace_get_frame_function): Likewise.
780 * record-full.c (record_full_open): Likewise.
781 * record.c (get_context_size): Likewise.
782 * registry.h (DEFINE_REGISTRY): Likewise.
783 * remote-fileio.c (remote_fileio_request): Likewise.
784 * remote.c (remote_update_thread_list): Likewise.
785 (remote_check_symbols): Likewise.
786 (remote_commit_resume): Likewise.
787 (remote_interrupt): Likewise.
788 (remote_insert_breakpoint): Likewise.
789 (compare_sections_command): Likewise.
790 * rust-exp.y (super_name): Likewise.
791 (lex_string): Likewise.
792 (convert_ast_to_type): Likewise.
793 (convert_ast_to_expression): Likewise.
794 * rust-lang.c (rust_print_struct_def): Likewise.
795 (rust_print_type): Likewise.
796 (rust_evaluate_subexp): Likewise.
797 * rx-tdep.c (rx_register_type): Likewise.
798 * ser-event.c (serial_event_clear): Likewise.
799 * serial.c (serial_open): Likewise.
800 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
801 * symfile.c (section_is_overlay): Likewise.
802 (overlay_unmapped_address): Likewise.
803 (overlay_mapped_address): Likewise.
804 (simple_overlay_update_1): Likewise.
805 (simple_overlay_update): Likewise.
806 * symtab.c (symbol_find_demangled_name): Likewise.
807 (search_symbols): Likewise.
808 * target-descriptions.c (tdesc_predefined_type): Likewise.
809 * target.c (target_commit_resume): Likewise.
810 * thread.c (print_selected_thread_frame): Likewise.
811 * top.c (new_ui_command): Likewise.
812 (gdb_readline_no_editing): Likewise.
813 * tracefile-tfile.c (tfile_open): Likewise.
814 * tracepoint.c (create_tsv_from_upload): Likewise.
815 * utils.c (quit): Likewise.
816 (defaulted_query): Likewise.
817 * valarith.c (value_concat): Likewise.
818 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
819 * xml-tdesc.c (target_fetch_description_xml): Likewise.
820 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
821 (xtensa_pseudo_register_write): Likewise.
822
7403715e
TT
8232017-12-04 Tom Tromey <tom@tromey.com>
824
825 * NEWS: Mention Rust trait object inspection.
826
50a1fdd5
PA
8272017-12-04 Pedro Alves <palves@redhat.com>
828
829 PR gdb/22499
830 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
831 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
832 (vex2_prefix_p, vex3_prefix_p): New functions.
833 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
834 VEX3 prefixes.
835 (fixup_riprel): Set VEX3.!B.
836
1e97a227
SM
8372017-12-03 Simon Marchi <simon.marchi@ericsson.com>
838
839 * target.h (mem_region_vector): Remove.
840 (struct target_ops) <to_memory_map>: Change return type to
841 std::vector<mem_region>.
842 * target-debug.h (target_debug_print_mem_region_vector): Rename
843 to ...
844 (target_debug_print_std_vector_mem_region): ... this.
845 * target-delegates.c: Re-generate.
846
10f64178
PA
8472017-12-03 Pedro Alves <palves@redhat.com>
848
849 * make-target-delegates (munge_type): Also munge '<', '>', and
850 ':'. Avoid double underscores in identifiers, and trailing
851 underscores.
852 * target-debug.h
853 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
854 ...
855 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
856 * target-delegates.c: Regenerate.
857
6d83e819
SM
8582017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
859
860 * common/poison.h (XDELETE): Fix typo.
861
97cbe998
SDJ
8622017-12-01 Andrew Cagney <cagney@redhat.com>
863 Joel Brobecker <brobecker@adacore.com>
864 Sergio Durigan Junior <sergiodj@redhat.com>
865
866 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
867 feature.
868 * coffread.c (coff_symfile_read): Do not map over sections with
869 'coff_locate_sections' if readnever is on.
870 * dwarf2read.c (dwarf2_has_info): Return 0 if
871 readnever is on.
872 * elfread.c (elf_symfile_read): Do not map over sections with
873 'elf_locate_sections' if readnever is on.
874 * main.c (validate_readnow_readnever): New function.
875 (captured_main_1): Add support for --readnever.
876 (print_gdb_help): Document --readnever.
877 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
878 flag.
879 * symfile.c (readnever_symbol_files): New global.
880 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
881 'READNEVER_SYMBOL_FILES' is set.
882 (validate_readnow_readnever): New function.
883 (symbol_file_command): Handle '-readnever' option.
884 Call 'validate_readnow_readnever'.
885 (add_symbol_file_command): Handle '-readnever' option.
886 Call 'validate_readnow_readnever'.
887 (_initialize_symfile): Document new '-readnever' option for
888 both 'symbol-file' and 'add-symbol-file' commands.
889 * top.h (readnever_symbol_files): New extern global.
890 * xcoffread.c (xcoff_initial_scan): Do not read debug
891 information if readnever is on.
892
40fc416f
SDJ
8932017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
894
895 * symfile.c (symbol_file_command): Call
896 'symbol_file_add_main_1' only after processing all command
897 line options.
898 (add_symbol_file_command): Modify logic to make arguments
899 position-independent.
900
ec6a20c2
JB
9012017-12-01 Joel Brobecker <brobecker@adacore.com>
902
903 * ada-lang.c (symbol_list_obstack): Delete.
904 (resolve_subexp): Make sure "candidates" gets xfree'ed.
905 (ada_lookup_symbol_list_worker): Remove the limitation that
906 the result is only good until the next call, now making it
907 the responsibility of the caller to free the result when no
908 longer needed. Adjust the function's intro comment accordingly.
909 (ada_lookup_symbol_list): Adjust the function's intro comment.
910 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
911 (ada_lookup_encoded_symbol, get_var_value): Likewise.
912 (_initialize_ada_language): Remove symbol_list_obstack
913 initialization.
914 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
915 (write_var_or_type, write_name_assoc): Likewise.
916
d0df06af
TT
9172017-12-01 Tom Tromey <tom@tromey.com>
918
919 * Makefile.in (all_deps_files): New variable.
920 Include .Po files using all_deps_files.
921
2ee0c9b3
JB
9222017-12-01 Joel Brobecker <brobecker@adacore.com>
923
924 * MAINTAINERS: Update list of maintainers, moving those who
925 stepped down or became inactive to the "Past Maintainers"
926 section.
927
44122162
RO
9282017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
929
930 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
931 sys/proc.h.
932 (NEW_PROC_API): Remove.
933 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
934 Likewise.
935 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
936 * configure: Regenerate.
937 * config.in: Regenerate.
938 * gdbserver/configure: Regenerate.
939 * gdbserver/config.in: Regenerate.
940
941 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
942 NEW_PROC_API test.
943 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
944
945 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
946
947 * proc-api.c: Remove !NEW_PROC_API support.
948 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
949 Remove tests for macros always defined on Solaris.
950 * proc-events.c: Remove !NEW_PROC_API support.
951 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
952 HAVE_SYS_USER_H tests.
953 (init_syscall_table): Remove non-Solaris syscalls.
954 Remove tests for syscalls present on all Solaris versions.
955 Add missing Solaris 10+ syscalls.
956 (signal_table): Remove non-Solaris signals.
957 Remove tests for signals present on all Solaris versions.
958 (fault_table): Remove non-Solaris faults.
959 Remove tests for faults present on all Solaris versions.
960 * proc-flags.c: Remove !NEW_PROC_API support.
961 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
962 Remove non-Solaris flags.
963 * proc-why.c: Remove !NEW_PROC_API support.
964 (pr_why_table): Remove meaningless comments.
965 Remove tests for reasons present on all Solaris versions.
966 Remove OSF/1 cases.
967 (proc_prettyfprint_why): Likewise.
968
969 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
970 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
971 Remove WA_READ test, IRIX watchpoint support.
972 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
973 types. Change users.
974 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
975 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
976 Change callers.
977 Remove CTL_PROC_NAME_FMT tests.
978 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
979 users.
980 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
981 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
982 (proc_modify_flag): Replace GDBRESET by PCUNSET.
983 Remove PR_ASYNC, PR_KLC tests.
984 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
985 (proc_parent_pid): Remove PCWATCH etc. tests.
986 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
987 Remove PCAGENT test.
988 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
989 Remove SYS_lwpcreate || SYS_lwp_create test.
990 (proc_get_current_thread): Likewise.
991 [PIOCNTHR && PIOCTLIST]: Remove.
992 [PIOCLSTATUS]: Remove.
993 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
994 [PRFS_STOPEXEC]: Remove.
995 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
996 (syscall_is_exit): Likewise.
997 (syscall_is_exec): Likewise.
998 (syscall_is_lwp_create): Likewise.
999 Remove SYS_syssgi support.
1000 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
1001 [SYS_syssgi]: Remove.
1002 Remove non-Solaris cases, conditionals.
1003 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
1004 Remove.
1005 (procfs_init_inferior) [SYS_syssgi]: Remove.
1006 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
1007 (procfs_inferior_created) [SYS_syssgi]: Remove.
1008 (procfs_set_watchpoint): Remove !AIX5 test.
1009 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
1010 case.
1011 (mappingflags) [MA_PHYS]: Remove.
1012 (info_mappings_callback): Remove PCAGENT test.
1013 Remove PIOCOPENLWP || PCAGENT test.
1014
e8020e54
RO
10152017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1016
1017 * sol-thread.c (info_solthreads): Constify args.
1018 Cast args to void *.
1019
75059544
JB
10202017-11-29 John Baldwin <jhb@FreeBSD.org>
1021
1022 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
1023
f5a91472
JB
10242017-11-29 Joel Brobecker <brobecker@adacore.com>
1025
1026 * ada-lang.c (to_fixed_range_type): Make sure that the size
1027 of the range type being returned is the same as the size
1028 of the range type being fixed.
1029
bd69330d
PA
10302017-11-29 Pedro Alves <palves@redhat.com>
1031
1032 PR c++/19436
1033 * NEWS: Mention setting breakpoints on functions with C++ ABI
1034 tags.
1035 * completer.h (completion_match_for_lcd) <match,
1036 mark_ignored_range>: New methods.
1037 <finish>: Consider ignored ranges.
1038 <clear>: Clear ignored ranges.
1039 <m_ignored_ranges, m_finished_storage>: New fields.
1040 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1041 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1042 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1043 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1044 * language.c (default_symbol_name_matcher): Pass the
1045 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1046 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1047 * utils.c (skip_abi_tag): New function.
1048 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1049 Handle ABI tags.
1050 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1051 parameter.
1052
10532017-11-29 Pedro Alves <palves@redhat.com>
1054
1055 PR c++/19436
1056 * NEWS: Mention setting breakpoints on functions with C++ ABI
1057 tags.
1058 * completer.h (completion_match_for_lcd) <match,
1059 mark_ignored_range>: New methods.
1060 <finish>: Consider ignored ranges.
1061 <clear>: Clear ignored ranges.
1062 <m_ignored_ranges, m_finished_storage>: New fields.
1063 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1064 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1065 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1066 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1067 * language.c (default_symbol_name_matcher): Pass the
1068 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1069 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1070 * utils.c (skip_abi_tag): New function.
1071 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1072 Handle ABI tags.
1073 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1074 parameter.
1075
a20714ff
PA
10762017-11-29 Pedro Alves <palves@redhat.com>
1077
1078 * NEWS: Mention that breakpoints on C++ functions are now set on
1079 on all namespaces/classes by default, and mention "break
1080 -qualified".
1081 * ax-gdb.c (agent_command_1): Adjust to pass a
1082 symbol_name_match_type to new_linespec_location.
1083 * breakpoint.c (parse_breakpoint_sals): Adjust to
1084 get_linespec_location's return type change.
1085 (strace_marker_create_sals_from_location): Adjust to pass a
1086 symbol_name_match_type to new_linespec_location.
1087 (strace_marker_decode_location): Adjust to get_linespec_location's
1088 return type change.
1089 (strace_command): Adjust to pass a symbol_name_match_type to
1090 new_linespec_location.
1091 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
1092 mention "-qualified".
1093 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
1094 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
1095 enumerator.
1096 (complete_address_and_linespec_locations): New parameter
1097 'match_type'. Pass it down.
1098 (explicit_options): Add "-qualified".
1099 (collect_explicit_location_matches): Pass the requested match type
1100 to the linespec completers. Handle MATCH_QUALIFIED.
1101 (location_completer): Handle "-qualified" combined with linespecs.
1102 * cp-support.c (cp_search_name_hash): New.
1103 (cp_symbol_name_matches_1): Implement wild matching for C++.
1104 (cp_fq_symbol_name_matches): Reimplement.
1105 (cp_get_symbol_name_matcher): Return different matchers depending
1106 on the lookup name's match type.
1107 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
1108 * cp-support.h (cp_search_name_hash): New declaration.
1109 * dwarf2read.c
1110 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
1111 symbols.
1112 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
1113 tests.
1114 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
1115 pass a symbol_name_match_type to new_linespec_location.
1116 * linespec.c (linespec_parse_basic): Lookup function symbols using
1117 the parser's symbol name match type.
1118 (convert_explicit_location_to_linespec): New
1119 symbol_name_match_type parameter. Pass it down to
1120 find_linespec_symbols.
1121 (convert_explicit_location_to_sals): Pass the location's name
1122 match type to convert_explicit_location_to_linespec.
1123 (parse_linespec): New match_type parameter. Save it in the
1124 parser.
1125 (linespec_parser_new): Default to symbol_name_match_type::WILD.
1126 (linespec_complete_function): New symbol_name_match_type
1127 parameter. Use it.
1128 (complete_linespec_component): Pass down the parser's recorded
1129 name match type.
1130 (linespec_complete_label): New symbol_name_match_type parameter.
1131 Use it.
1132 (linespec_complete): New symbol_name_match_type parameter. Save
1133 it in the parser and pass it down. Adjust to
1134 get_linespec_location's prototype change.
1135 (find_function_symbols, find_linespec_symbols): New
1136 symbol_name_match_type parameter. Pass it down instead of
1137 assuming symbol_name_match_type::WILD.
1138 * linespec.h (linespec_complete, linespec_complete_function)
1139 (linespec_complete_label): New symbol_name_match_type parameter.
1140 * location.c (event_location::linespec_location): Now a struct
1141 linespec_location.
1142 (EL_LINESPEC): Adjust.
1143 (initialize_explicit_location): Default to
1144 symbol_name_match_type::WILD.
1145 (new_linespec_location): New symbol_name_match_type parameter.
1146 Record it in the location.
1147 (get_linespec_location): Now returns a struct linespec_location.
1148 (new_explicit_location): Also copy func_name_match_type.
1149 (explicit_to_string_internal)
1150 (string_to_explicit_location): Handle "-qualified".
1151 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
1152 Copy symbol_name_match_type fields.
1153 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
1154 type change.
1155 (event_location_to_string): Adjust to LINESPEC_LOCATION type
1156 change. Handle "-qualfied".
1157 (string_to_explicit_location): Handle "-qualified".
1158 (string_to_event_location_basic): New symbol_name_match_type
1159 parameter. Pass it down.
1160 (string_to_event_location): Handle "-qualified".
1161 * location.h (struct linespec_location): New.
1162 (explicit_location::func_name_match_type): New field.
1163 (new_linespec_location): Now returns a const linespec_location *.
1164 (string_to_event_location_basic): New symbol_name_match_type
1165 parameter.
1166 (explicit_completion_info::saw_explicit_location_option): New
1167 field.
1168 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
1169 symbol_name_match_type to new_linespec_location.
1170 * python/py-breakpoint.c (bppy_init): Likewise.
1171 * python/python.c (gdbpy_decode_line): Likewise.
1172
a207cff2
PA
11732017-11-29 Pedro Alves <palves@redhat.com>
1174
1175 * ada-lang.c (ada_lookup_name_info::matches): Change type of
1176 parameter from completion_match to completion_match_result.
1177 Adjust.
1178 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
1179 * completer.c (completion_tracker::maybe_add_completion): Add
1180 match_for_lcd parameter and use it.
1181 (completion_tracker::add_completion): Likewise.
1182 * completer.h (class completion_match_for_lcd): New class.
1183 (completion_match_result::match_for_lcd): New field.
1184 (completion_match_result::set_match): New method.
1185 (completion_tracker): Add comments.
1186 (completion_tracker::add_completion): Add match_for_lcd parameter.
1187 (completion_tracker::reset_completion_match_result): Reset
1188 match_for_lcd too.
1189 (completion_tracker::maybe_add_completion): Add match_for_lcd
1190 parameter.
1191 (completion_tracker::m_lowest_common_denominator_unique): Extend
1192 comments.
1193 * cp-support.c (cp_symbol_name_matches_1)
1194 (cp_fq_symbol_name_matches): Change type of parameter from
1195 completion_match to completion_match_result. Adjust.
1196 * language.c (default_symbol_name_matcher): Change type of
1197 parameter from completion_match to completion_match_result.
1198 Adjust.
1199 * language.h (completion_match_for_lcd): Forward declare.
1200 (default_symbol_name_matcher): Change type of parameter from
1201 completion_match to completion_match_result.
1202 * symtab.c (compare_symbol_name): Adjust.
1203 (completion_list_add_name): Pass the match_for_lcd to the tracker.
1204 * symtab.h (ada_lookup_name_info::matches): Change type of
1205 parameter from completion_match to completion_match_result.
1206 (symbol_name_matcher_ftype): Likewise, and update comments.
1207
4024cf2b
PA
12082017-11-29 Pedro Alves <palves@redhat.com>
1209
1210 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
1211 * minsyms.c (msymbol_is_text): Delete.
1212 (msymbol_is_function): New function.
1213 * minsyms.h (msymbol_is_text): Delete.
1214 (msymbol_is_function): New declaration.
1215 * symtab.c (find_function_alias_target): Use msymbol_is_function.
1216
5dcf52c1
TT
12172017-11-29 Tom Tromey <tom@tromey.com>
1218
1219 * Makefile.in (distclean): Handle the case where rmdir fails.
1220
8ca2f0b9
TT
12212017-11-29 Tom Tromey <tom@tromey.com>
1222
1223 * symfile.c (_initialize_symfile): Update usage text for
1224 add-symbol-file, symbol-file, load.
1225
02ca603a
TT
12262017-11-29 Tom Tromey <tom@tromey.com>
1227
1228 * symfile.c (add_symbol_file_command): Error if some arguments to
1229 -s are missing. Change unrecognized-argument error message.
1230 (_initialize_symfile): Fix usage text for add-symbol-file.
1231
18ca7347
TT
12322017-11-27 Tom Tromey <tom@tromey.com>
1233
1234 * Makefile.in (REMOTE_OBS): Remove.
1235 (SFILES): Remove remote sources.
1236 (COMMON_SFILES): Add remote sources.
1237 (ALLDEPFILES): Remove dcache.c.
1238
66599a7d
TT
12392017-11-27 Tom Tromey <tom@tromey.com>
1240
1241 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
1242 variables.
1243 (SFILES): Use SUBDIR_TARGET_SRCS.
1244 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
1245 (CONFIG_SRC_SUBDIR): Add target.
1246 (%.o): Remove target rule.
1247
4f04fba8
TT
12482017-11-27 Tom Tromey <tom@tromey.com>
1249
1250 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
1251 registry.o, thread-fsm.o, debug.o.
1252 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
1253 thread-fsm.c, debug.c.
1254
b5adff3b
TT
12552017-11-27 Tom Tromey <tom@tromey.com>
1256
1257 * Makefile.in (COMMON_SFILES): New.
1258 (SFILES): Move some entries to COMMON_SFILES.
1259 (COMMON_OBS): Use COMMON_SFILES.
1260
afa0a411
TT
12612017-11-27 Tom Tromey <tom@tromey.com>
1262
1263 * Makefile.in (YYFILES): Update comment.
1264 (YYOBJ): Redefine.
1265
8fd8d003
TT
12662017-11-27 Tom Tromey <tom@tromey.com>
1267
1268 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
1269 (CONFIG_SRC_SUBDIR): Add python.
1270 (%.o): Remove python rule.
1271 (python/%.o): New rule.
1272 * configure: Rebuild.
1273 * configure.ac (CONFIG_OBS): Refer to python/python.o
1274
bd810fff
TT
12752017-11-27 Tom Tromey <tom@tromey.com>
1276
1277 * configure: Rebuild.
1278 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
1279 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
1280 (CONFIG_SRC_SUBDIR): Add guile.
1281 (%.o): Remove guile rule.
1282
75787ac1
TT
12832017-11-27 Tom Tromey <tom@tromey.com>
1284
1285 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
1286 (%.o): Remove unittests rule.
1287 (CONFIG_SRC_SUBDIR): Add unittests.
1288
5c8a9431
TT
12892017-11-27 Tom Tromey <tom@tromey.com>
1290
1291 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
1292 (CONFIG_SRC_SUBDIR): Add tui.
1293 (%.o): Remove tui rule.
1294
a26aa30c
TT
12952017-11-27 Tom Tromey <tom@tromey.com>
1296
1297 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
1298 (%.o): Remove compile rule.
1299 (CONFIG_SRC_SUBDIR): Add compile.
1300
6f3cdf9a
TT
13012017-11-27 Tom Tromey <tom@tromey.com>
1302
1303 * Makefile.in (SUBDIR_MI_OBS): Redefine.
1304 (%.o): Remove mi rule.
1305 (CONFIG_SRC_SUBDIR): Add mi.
1306 (COMMON_OBS): Use mi/mi-common.o
1307
f06afa53
TT
13082017-11-27 Tom Tromey <tom@tromey.com>
1309
1310 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
1311 (%.o): Remove cli rule.
1312 (CONFIG_SRC_SUBDIR): Add cli.
1313
b22c88c2
TT
13142017-11-27 Tom Tromey <tom@tromey.com>
1315
1316 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
1317 * configure: Rebuild.
1318 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
1319 (CONFIG_DEP_SUBDIR): New variable.
1320 (%.o): Add order-only dependency.
1321 ($(CONFIG_DEP_SUBDIR)): New target.
1322
ee9a09e9
DC
13232017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
1324
1325 PR gdb/21945
1326 * findcmd.c (_initialize_mem_search): Update find command help
1327 text.
1328
e8e7d10c
SM
13292017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
1330
1331 * python/python.c (do_start_initialization): Change progname
1332 type to gdb::unique_xmalloc_ptr. Release the pointer when using
1333 Python 2.
1334
6a997029
TT
13352017-11-26 Tom Tromey <tom@tromey.com>
1336
1337 * common/format.h: Add include guards.
1338
41272101
TT
13392017-11-26 Tom Tromey <tom@tromey.com>
1340
1341 * nat/linux-personality.h (class
1342 maybe_disable_address_space_randomization): New class.
1343 (maybe_disable_address_space_randomization): Don't declare
1344 function.
1345 * nat/linux-personality.c (restore_personality)
1346 (make_disable_asr_cleanup): Remove.
1347 (maybe_disable_address_space_randomization): Now a constructor.
1348 (~maybe_disable_address_space_randomization): New destructor.
1349 * linux-nat.c (linux_nat_create_inferior): Update.
1350
44287fd8
TT
13512017-11-26 Tom Tromey <tom@tromey.com>
1352
1353 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
1354
5ffd2cb7
UW
13552017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
1356
1357 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
1358 "cooked" register. Access only first four bytes of branch target
1359 registers.
1360
0e5457dc
SDJ
13612017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
1362
1363 PR gdb/22491
1364 * stap-probe.c (relocate_address): New function.
1365 (stap_probe::get_relocated_address): Use 'relocate_address'.
1366 (stap_probe::set_semaphore): Use 'relocate_address' and pass
1367 'm_sem_addr'.
1368 (stap_probe::clear_semaphore): Likewise.
1369
deeeba55
PA
13702017-11-25 Pedro Alves <palves@redhat.com>
1371
1372 * dictionary.c: Include "safe-ctype.h".
1373 * minsyms.c: Include "safe-ctype.h".
1374 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
1375
a81aaca0
PA
13762017-11-25 Pedro Alves <palves@redhat.com>
1377
1378 * completer.c (complete_line_internal_1): Skip spaces until the
1379 start of the command.
1380
0662b6a7
PA
13812017-11-24 Pedro Alves <palves@redhat.com>
1382
1383 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
1384 cp_fq_symbol_name_matches. Pass language_cplus to
1385 strncmp_with_mode.
1386 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
1387 (selftests::test_cp_symbol_name_cmp): New.
1388 (_initialize_cp_support): Register "cp_symbol_name_matches"
1389 selftests.
1390 * language.c (default_symbol_name_matcher): Pass language_minimal
1391 to strncmp_iw_with_mode.
1392 * utils.c: Include "cp-support.h" and <algorithm>.
1393 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
1394 (cp_is_operator): New functions.
1395 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
1396 skip whitespace in the symbol name when the lookup name doesn't
1397 have spaces, and vice versa.
1398 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
1399 * utils.h (strncmp_iw_with_mode): Add language parameter.
1400
e547c119
JB
14012017-11-24 Joel Brobecker <brobecker@adacore.com>
1402
1403 * ada-lang.c (ada_exception_message_1, ada_exception_message):
1404 New functions.
1405 (print_it_exception): If available, display the exception
1406 message as well.
1407 * NEWS: Document new feature.
1408
d7fcdff9
UW
14092017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1410
1411 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
1412
30649c14
PR
14132017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
1414
1415 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
1416 (dtrace_probe::is_enabled, dtrace_probe::enable)
1417 (dtrace_probe::disable): Remove keyword 'struct' at for-range
1418 variable
1419 * probe.c (gen_ui_out_table_header_info)
1420 (print_ui_out_not_applicables): Remove keyword 'struct' at
1421 for-range variable
1422
7696f5c9
AH
14232017-11-24 Alan Hayward <alan.hayward@arm.com>
1424
1425 * configure.tgt: Add arch/aarch64.o
1426
8172f16b
SM
14272017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1428
1429 * common/common-utils.h: Include poison.h.
1430 (xfree): Remove declaration, add definition with static_assert.
1431 * common/common-utils.c (xfree): Remove.
1432 * common/poison.h (IsMallocatable): Define.
1433 (IsFreeable): Define.
1434 (free): Delete for non-freeable types.
1435 (xnew): New.
1436 (XNEW): Undef and redefine.
1437 (xcnew): New.
1438 (XCNEW): Undef and redefine.
1439 (xdelete): New.
1440 (XDELETE): Undef and redefine.
1441 (xnewvec): New.
1442 (XNEWVEC): Undef and redefine.
1443 (xcnewvec): New.
1444 (XCNEWVEC): Undef and redefine.
1445 (xresizevec): New.
1446 (XRESIZEVEC): Undef and redefine.
1447 (xdeletevec): New.
1448 (XDELETEVEC): Undef and redefine.
1449 (xnewvar): New.
1450 (XNEWVAR): Undef and redefine.
1451 (xcnewvar): New.
1452 (XCNEWVAR): Undef and redefine.
1453 (xresizevar): New.
1454 (XRESIZEVAR): Undef and redefine.
1455
7aabaf9d
SM
14562017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1457
1458 * gdbthread.h (private_thread_info): Define structure type, add
1459 virtual pure destructor.
1460 (thread_info) <priv>: Change type to unique_ptr.
1461 <private_dtor>: Remove.
1462 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
1463 (private_thread_info::~private_thread_info): Provide default
1464 implementation.
1465 (thread_info::~thread_info): Don't call private_dtor nor
1466 manually free priv.
1467 * aix-thread.c (private_thread_info): Rename to ...
1468 (aix_thread_info): ... this.
1469 (get_aix_thread_info): New.
1470 (sync_threadlists): Adjust.
1471 (iter_tid): Adjust.
1472 (aix_thread_resume): Adjust.
1473 (aix_thread_fetch_registers): Adjust.
1474 (aix_thread_store_registers): Adjust.
1475 (aix_thread_extra_thread_info): Adjust.
1476 * darwin-nat.h (private_thread_info): Rename to ...
1477 (darwin_thread_info): ... this.
1478 (get_darwin_thread_info): New.
1479 * darwin-nat.c (darwin_init_thread_list): Adjust.
1480 (darwin_check_new_threads): Adjust.
1481 (thread_info_from_private_thread_info): Adjust.
1482 * linux-thread-db.c (private_thread_info): Rename to ...
1483 (thread_db_thread_info): ... this, initialize fields.
1484 (get_thread_db_thread_info): New.
1485 <dying>: Change type to bool.
1486 (update_thread_state): Adjust to type rename.
1487 (record_thread): Adjust to type rename an use of unique_ptr.
1488 (thread_db_pid_to_str): Likewise.
1489 (thread_db_extra_thread_info): Likewise.
1490 (thread_db_thread_handle_to_thread_info): Likewise.
1491 (thread_db_get_thread_local_address): Likewise.
1492 * nto-tdep.h (private_thread_info): Rename to ...
1493 (nto_thread_info): ... this, initialize fields.
1494 (get_nto_thread_info): New.
1495 <name>: Change type to std::string.
1496 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1497 use of unique_ptr.
1498 * nto-procfs.c (update_thread_private_data_name): Adjust to
1499 std::string change, allocate nto_private_thread_info with new.
1500 (update_thread_private_data): Adjust to unique_ptr.
1501 * remote.c (private_thread_info): Rename to ...
1502 (remote_thread_info): ... this, initialize data members with
1503 default values.
1504 <extra, name>: Change type to std::string.
1505 <thread_handle>: Change type to non-pointer.
1506 (free_private_thread_info): Remove.
1507 (get_private_info_thread): Rename to...
1508 (get_remote_thread_info): ... this, change return type, adjust to
1509 use of unique_ptr, use remote_thread_info constructor.
1510 (remote_add_thread): Adjust.
1511 (get_private_info_ptid): Rename to...
1512 (get_remote_thread_info): ...this, change return type.
1513 (remote_thread_name): Use get_remote_thread_info, adjust to
1514 change to std::string.
1515 (struct thread_item) <~thread_item>: Remove.
1516 <thread_handle>: Make non pointer.
1517 (start_thread): Adjust to thread_item::thread_handle type
1518 change.
1519 (remote_update_thread_list): Adjust to type name change, move
1520 strings from temporary to long-lived object instead of
1521 duplicating.
1522 (remote_threads_extra_info): Use get_remote_thread_info.
1523 (process_initial_stop_replies): Likewise.
1524 (resume_clear_thread_private_info): Likewise.
1525 (remote_resume): Adjust to type name change.
1526 (remote_commit_resume): Use get_remote_thread_info.
1527 (process_stop_reply): Adjust to type name change.
1528 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1529 (remote_stopped_by_hw_breakpoint): Likewise.
1530 (remote_stopped_by_watchpoint): Likewise.
1531 (remote_stopped_data_address): Likewise.
1532 (remote_core_of_thread): Likewise.
1533 (remote_thread_handle_to_thread_info): Use
1534 get_private_info_thread, adjust to thread_handle field type
1535 change.
1536
21fe1c75
SM
15372017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1538
1539 * remote.c (struct thread_item): Add constructor, disable copy
1540 construction and copy assignment, define default move
1541 construction and move assignment.
1542 <extra, name>: Change type to std::string.
1543 <core>: Initialize.
1544 <thread_handle>: Make non-pointer.
1545 (thread_item_t): Remove typedef.
1546 (DEF_VEC_O(thread_item_t)): Remove.
1547 (threads_listing_context) <contains_thread>: New method.
1548 <remove_thread>: New method.
1549 <items>: Change type to std::vector.
1550 (clear_threads_listing_context): Remove.
1551 (threads_listing_context_remove): Remove.
1552 (remote_newthread_step): Use thread_item constructor, adjust to
1553 change to std::vector.
1554 (start_thread): Use thread_item constructor, adjust to change to
1555 std::vector.
1556 (end_thread): Adjust to change to std::vector and std::string.
1557 (remote_get_threads_with_qthreadinfo): Use thread_item
1558 constructor, adjust to std::vector.
1559 (remote_update_thread_list): Adjust to change to std::vector and
1560 std::string, use threads_listing_context methods.
1561 (remove_child_of_pending_fork): Adjust.
1562 (remove_new_fork_children): Adjust.
1563 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1564 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1565 * unittests/rsp-low-selftests.c: New file.
1566 * common/rsp-low.h: Include common/byte-vector.h.
1567 (hex2bin): New overload.
1568 * common/rsp-low.c (hex2bin): New overload.
1569
089354bb
SM
15702017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1571
1572 * inferior.h (private_inferior): Define structure type, add
1573 virtual pure destructor.
1574 (inferior) <priv>: Change type to unique_ptr.
1575 * inferior.c (private_inferior::~private_inferior): Provide
1576 default implementation.
1577 (inferior::~inferior): Don't free priv field.
1578 (exit_inferior_1): Likewise.
1579 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1580 (darwin_exception_info): Remove typedef.
1581 (DEF_VEC_O (darwin_thread_t)); Remove.
1582 (private_inferior): Rename to ...
1583 (darwin_private_inferior): ... this, extend private_inferior.
1584 (get_darwin_inferior): New.
1585 <threads>: Change type to std::vector of darwin_thread_t pointers.
1586 * darwin-nat.c (darwin_check_new_threads): Adjust.
1587 (find_inferior_task_it): Adjust.
1588 (darwin_find_thread); Adjust.
1589 (darwin_suspend_inferior): Adjust.
1590 (darwin_resume_inferior): Adjust.
1591 (darwin_find_new_inferior): Adjust.
1592 (darwin_decode_notify_message): Adjust.
1593 (darwin_send_reply): Adjust.
1594 (darwin_resume_inferior_threads): Adjust.
1595 (darwin_suspend_inferior_threads): Adjust.
1596 (darwin_decode_message): Adjust.
1597 (darwin_wait): Adjust.
1598 (darwin_interrupt): Adjust.
1599 (darwin_deallocate_threads): Adjust.
1600 (darwin_mourn_inferior): Adjust, don't free private data.
1601 (darwin_reply_to_all_pending_messages): Adjust.
1602 (darwin_stop_inferior): Adjust.
1603 (darwin_setup_exceptions): Adjust.
1604 (darwin_kill_inferior): Adjust.
1605 (darwin_setup_request_notification): Adjust.
1606 (darwin_attach_pid): Adjust.
1607 (darwin_init_thread_list): Adjust.
1608 (darwin_setup_fake_stop_event): Adjust.
1609 (darwin_attach): Adjust.
1610 (darwin_detach): Adjust.
1611 (darwin_xfer_partial): Adjust.
1612 (set_enable_mach_exceptions): Adjust.
1613 (darwin_pid_to_exec_file): Adjust.
1614 (darwin_get_ada_task_ptid): Adjust.
1615 * darwin-nat-info.c (get_task_from_args): Adjust.
1616 (info_mach_ports_command): Adjust.
1617 (info_mach_region_command): Adjust.
1618 (info_mach_exceptions_command): Adjust.
1619 * remote.c (private_inferior): Rename to ...
1620 (remote_private_inferior): ... this, initialize fields.
1621 (get_remote_inferior); New.
1622 (remote_commit_resume): Use get_remote_inferior.
1623 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1624
d044bac8
PA
16252017-11-24 Pedro Alves <palves@redhat.com>
1626
1627 * NEWS: Mention linespecs and explicit locations, and completion
1628 improvements.
1629
e8d58cba
YQ
16302017-11-24 Yao Qi <yao.qi@linaro.org>
1631
1632 * regcache.c (regcache::dump): Remove footnote_register_size.
1633
a63f2d2f
YQ
16342017-11-24 Yao Qi <yao.qi@linaro.org>
1635
1636 * regcache.c (cooked_read_test): Add more test for readonly
1637 regcache.
1638
1b30aaa5
YQ
16392017-11-24 Yao Qi <yao.qi@linaro.org>
1640
1641 * gdbarch-selftests.c (test_target_has_registers): Move it to
1642 target.c.
1643 (test_target_has_stack): Likewise.
1644 (test_target_has_memory): Likewise.
1645 (test_target_prepare_to_store): Likewise.
1646 (test_target_store_registers): Likewise.
1647 (test_target_ops): Likewise.
1648 * regcache.c: Include selftest-arch.h and gdbthread.h.
1649 (target_ops_no_register): New class.
1650 (test_target_fetch_registers): New.
1651 (test_target_store_registers): New.
1652 (test_target_xfer_partial): New.
1653 (readwrite_regcache): New.
1654 (cooked_read_test): New.
1655 (_initialize_regcache): Register the test.
1656 * target.c: (test_target_has_registers): Moved from
1657 gdbarch-selftests.c.
1658 (test_target_has_stack): Likewise.
1659 (test_target_has_memory): Likewise.
1660 (test_target_prepare_to_store): Likewise.
1661 (test_target_store_registers): Likewise.
1662 * target.h (test_target_ops): New class.
1663
6654d750
AH
16642017-11-24 Alan Hayward <alan.hayward@arm.com>
1665
1666 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1667 selftest.
1668
49bdb7ee
AH
16692017-11-24 Alan Hayward <alan.hayward@arm.com>
1670
1671 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1672 * arch/aarch64.c (aarch64_create_target_description): Create
1673 new target description.
1674 * features/Makefile: Add new files.
1675 * features/aarch64.c: Remove file.
1676 * features/aarch64-core.c: New autogenerated file.
1677 * features/aarch64-fpu.c: New autogenerated file.
1678 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
da434ccb
AH
1679
16802017-11-24 Alan Hayward <alan.hayward@arm.com>
1681
1682 * Makefile.in: Add new files.
1683 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1684 aarch64_read_description.
1685 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1686 Call aarch64_read_description.
1687 * aarch64-tdep.c (aarch64_read_description): New function.
1688 (aarch64_gdbarch_init): Call aarch64_read_description.
1689 * aarch64-tdep.h (aarch64_read_description): New function.
1690 * arch/aarch64.c: New file.
1691 * configure.tgt: Add new files.
1692
98ead37e
YQ
16932017-11-24 Yao Qi <yao.qi@linaro.org>
1694
1695 * mi/mi-main.c (register_changed_p): Update.
1696 * value.c (value_contents_bits_eq): Change return type.
1697 (value_contents_eq): Likewise.
1698 * value.h: Update comments.
1699
62ad7ce7
YQ
17002017-11-24 Yao Qi <yao.qi@linaro.org>
1701
1702 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1703 local 'changed'. Remove error.
1704 (register_changed_p): Change return type to bool.
1705
506fe5f4
YQ
17062017-11-24 Yao Qi <yao.qi@linaro.org>
1707
1708 * arch/tic6x.c: New file.
1709 * arch/tic6x.h: New file.
1710 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1711 tic6x-core.xml and tic6x-gp.xml.
1712 * features/tic6x-c6xp.c: Generated.
1713 * features/tic6x-core.c: Generated.
1714 * features/tic6x-gp.c: Generated.
1715 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1716 "tic6x-".
1717
00ea2e2a
SM
17182017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1719
1720 * mi/mi-main.c (list_available_thread_groups): Change map value
1721 type to std::vector.
1722
f45e2a77
SM
17232017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1724
1725 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1726
bd046f64
SM
17272017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1728
1729 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1730 back to...
1731 <children_requested>: ... this.
1732 (varobj_get_num_children, varobj_update): Adjust.
1733
4c37490d
SM
17342017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1735
1736 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1737 (ada_value_has_mutated): Likewise.
1738 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1739 (c_is_path_expr_parent): Likewise.
1740 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1741 (mi_cmd_var_set_frozen): Likewise.
1742 (mi_cmd_var_update_iter): Likewise.
1743 (mi_cmd_var_update): Likewise.
1744 * varobj.c (pretty_printing): Likewise.
1745 (varobj_enable_pretty_printing): Likewise.
1746 (struct varobj_root) <floating, is_valid>: Likewise.
1747 (struct varobj_dynamic) <children_requested>: Likewise.
1748 (delete_variable): Likewise.
1749 (delete_variable_1): Likewise.
1750 (install_variable): Likewise.
1751 (update_type_if_necessary): Likewise.
1752 (install_new_value): Likewise.
1753 (value_of_root): Likewise.
1754 (is_root_p): Likewise.
1755 (varobj_create): Likewise.
1756 (varobj_delete): Likewise.
1757 (varobj_has_more): Likewise.
1758 (varobj_set_frozen): Likewise.
1759 (varobj_get_frozen): Likewise.
1760 (install_dynamic_child): Likewise.
1761 (dynamic_varobj_has_child_method): Likewise.
1762 (update_dynamic_varobj_children): Likewise.
1763 (varobj_get_num_children): Likewise.
1764 (varobj_list_children): Likewise.
1765 (is_path_expr_parent): Likewise.
1766 (varobj_default_is_path_expr_parent): Likewise.
1767 (varobj_is_dynamic_p): Likewise.
1768 (varobj_set_value): Likewise.
1769 (varobj_value_has_mutated): Likewise.
1770 (varobj_update): Likewise.
1771 (check_scope): Likewise.
1772 (value_of_root_1): Likewise.
1773 (varobj_value_get_print_value): Likewise.
1774 (varobj_editable_p): Likewise.
1775 (varobj_value_is_changeable_p): Likewise.
1776 (varobj_floating_p): Likewise.
1777 (varobj_default_value_is_changeable_p): Likewise.
1778 (varobj_invalidate_iter): Likewise.
1779 * varobj.h (struct varobj_update_result) <type_changed,
1780 children_changed, changed, value_installed>: Likewise.
1781 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1782 (struct lang_varobj_ops) <value_is_changeable_p,
1783 value_has_mutated, is_path_expr_parent>: Likewise.
1784 (varobj_delete): Likewise.
1785 (varobj_set_frozen): Likewise.
1786 (varobj_get_frozen): Likewise.
1787 (varobj_set_value): Likewise.
1788 (varobj_update): Likewise.
1789 (varobj_editable_p): Likewise.
1790 (varobj_floating_p): Likewise.
1791 (varobj_has_more): Likewise.
1792 (varobj_is_dynamic_p): Likewise.
1793 (varobj_default_value_is_changeable_p): Likewise.
1794 (varobj_value_is_changeable_p): Likewise.
1795 (varobj_is_anonymous_child): Likewise.
1796 (varobj_default_is_path_expr_parent): Likewise.
1797
9c23b42f
SDJ
17982017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1799
1800 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1801 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1802 <type_str>: Convert to 'std::string'.
1803 <expr>: Convert to 'expression_up'.
1804 (dtrace_probe_arg_s): Delete type and VEC.
1805 (dtrace_probe_enabler_s): Likewise.
1806 (struct dtrace_probe): Replace by...
1807 (class dtrace_static_probe_ops): ...this and...
1808 (class dtrace_probe): ...this.
1809 (dtrace_probe_is_linespec): Rename to...
1810 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1811 to reflect change.
1812 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1813 Adjust code. Create new instance of 'dtrace_probe'.
1814 (dtrace_build_arg_exprs): Rename to...
1815 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1816 reflect change.
1817 (dtrace_get_probes): Rename to...
1818 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1819 to reflect change.
1820 (dtrace_get_arg): Rename to...
1821 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1822 reflect change.
1823 (dtrace_probe_is_enabled): Rename to...
1824 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
1825 change.
1826 (dtrace_get_probe_address): Rename to...
1827 (dtrace_probe::get_relocated_address): ...this. Adjust code
1828 to reflect change.
1829 (dtrace_get_probe_argument_count): Rename to...
1830 (dtrace_probe::get_argument_count): ...this. Adjust code to
1831 reflect change.
1832 (dtrace_can_evaluate_probe_arguments): Rename to...
1833 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
1834 to reflect change.
1835 (dtrace_evaluate_probe_argument): Rename to...
1836 (dtrace_probe::evaluate_argument): ...this. Adjust code to
1837 reflect change.
1838 (dtrace_compile_to_ax): Rename to...
1839 (dtrace_probe::compile_to_ax): ...this. Adjust code to
1840 reflect change.
1841 (dtrace_probe_destroy): Delete.
1842 (dtrace_type_name): Rename to...
1843 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
1844 reflect change.
1845 (dtrace_probe::get_static_ops): New method.
1846 (dtrace_gen_info_probes_table_header): Rename to...
1847 (dtrace_static_probe_ops::gen_info_probes_table_header):
1848 ...this. Adjust code to reflect change.
1849 (dtrace_gen_info_probes_table_values): Rename to...
1850 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
1851 code to reflect change.
1852 (dtrace_enable_probe): Rename to...
1853 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
1854 change.
1855 (dtrace_disable_probe): Rename to...
1856 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
1857 change.
1858 (struct probe_ops dtrace_probe_ops): Delete.
1859 (info_probes_dtrace_command): Call 'info_probes_for_spops'
1860 instead of 'info_probes_for_ops'.
1861 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
1862 of 'all_probe_ops'.
1863
0e9ae10f
SDJ
18642017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1865 Simon Marchi <simark@simark.ca>
1866
1867 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
1868 variable.
1869 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
1870 <aexpr>: Change type to 'expression_up'.
1871 (stap_probe_arg_s): Delete type and VEC.
1872 (struct stap_probe): Delete. Replace by...
1873 (class stap_static_probe_ops): ...this and...
1874 (class stap_probe): ...this. Rename variables to add 'm_'
1875 prefix. Do not use 'union' for arguments anymore.
1876 (stap_get_expected_argument_type): Receive probe name instead
1877 of 'struct stap_probe'. Adjust code.
1878 (stap_parse_probe_arguments): Rename to...
1879 (stap_probe::parse_arguments): ...this. Adjust code to
1880 reflect change.
1881 (stap_get_probe_address): Rename to...
1882 (stap_probe::get_relocated_address): ...this. Adjust code
1883 to reflect change.
1884 (stap_get_probe_argument_count): Rename to...
1885 (stap_probe::get_argument_count): ...this. Adjust code
1886 to reflect change.
1887 (stap_get_arg): Rename to...
1888 (stap_probe::get_arg_by_number'): ...this. Adjust code to
1889 reflect change.
1890 (can_evaluate_probe_arguments): Rename to...
1891 (stap_probe::can_evaluate_arguments): ...this. Adjust code
1892 to reflect change.
1893 (stap_evaluate_probe_argument): Rename to...
1894 (stap_probe::evaluate_argument): ...this. Adjust code
1895 to reflect change.
1896 (stap_compile_to_ax): Rename to...
1897 (stap_probe::compile_to_ax): ...this. Adjust code to
1898 reflect change.
1899 (stap_probe_destroy): Delete.
1900 (stap_modify_semaphore): Adjust comment.
1901 (stap_set_semaphore): Rename to...
1902 (stap_probe::set_semaphore): ...this. Adjust code to reflect
1903 change.
1904 (stap_clear_semaphore): Rename to...
1905 (stap_probe::clear_semaphore): ...this. Adjust code to
1906 reflect change.
1907 (stap_probe::get_static_ops): New method.
1908 (handle_stap_probe): Adjust code to create instance of
1909 'stap_probe'.
1910 (stap_get_probes): Rename to...
1911 (stap_static_probe_ops::get_probes): ...this. Adjust code to
1912 reflect change.
1913 (stap_probe_is_linespec): Rename to...
1914 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
1915 reflect change.
1916 (stap_type_name): Rename to...
1917 (stap_static_probe_ops::type_name): ...this. Adjust code to
1918 reflect change.
1919 (stap_gen_info_probes_table_header): Rename to...
1920 (stap_static_probe_ops::gen_info_probes_table_header):
1921 ...this. Adjust code to reflect change.
1922 (stap_gen_info_probes_table_values): Rename to...
1923 (stap_probe::gen_info_probes_table_values): ...this. Adjust
1924 code to reflect change.
1925 (struct probe_ops stap_probe_ops): Delete.
1926 (info_probes_stap_command): Use 'info_probes_for_spops'
1927 instead of 'info_probes_for_ops'.
1928 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
1929 of 'all_probe_ops'.
1930
935676c9
SDJ
19312017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1932
1933 * break-catch-throw.c (fetch_probe_arguments): Use
1934 'probe.prob' instead of 'probe.probe'.
1935 * breakpoint.c (create_longjmp_master_breakpoint): Call
1936 'can_evaluate_arguments' and 'get_relocated_address' methods
1937 from probe.
1938 (create_exception_master_breakpoint): Likewise.
1939 (add_location_to_breakpoint): Use 'sal->prob' instead of
1940 'sal->probe'.
1941 (bkpt_probe_insert_location): Call 'set_semaphore' method from
1942 probe.
1943 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
1944 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
1945 of 'probe_ops'.
1946 (probe_key_free): Call 'delete' on probe.
1947 (check_exception_resume): Use 'probe.prob' instead of
1948 'probe.probe'.
1949 * location.c (string_to_event_location_basic): Call
1950 'probe_linespec_to_static_ops'.
1951 * probe.c (class any_static_probe_ops): New class.
1952 (any_static_probe_ops any_static_probe_ops): New variable.
1953 (parse_probes_in_pspace): Receive 'static_probe_ops' as
1954 argument. Adjust code to reflect change.
1955 (parse_probes): Use 'static_probe_ops' instead of
1956 'probe_ops'. Adjust code to reflect change.
1957 (find_probes_in_objfile): Call methods to get name and
1958 provider from probe.
1959 (find_probe_by_pc): Use 'result.prob' instead of
1960 'result.probe'. Call 'get_relocated_address' method from
1961 probe.
1962 (collect_probes): Adjust comment and argument list to receive
1963 'static_probe_ops' instead of 'probe_ops'. Adjust code to
1964 reflect change. Call necessary methods from probe.
1965 (compare_probes): Call methods to get name and provider from
1966 probes.
1967 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
1968 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
1969 adjust code accordingly.
1970 (print_ui_out_not_applicables): Likewise.
1971 (info_probes_for_ops): Rename to...
1972 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
1973 as argument instead of 'probe_ops'. Adjust code. Call
1974 necessary methods from probe.
1975 (info_probes_command): Use 'info_probes_for_spops'.
1976 (enable_probes_command): Pass correct argument to
1977 'collect_probes'. Call methods from probe.
1978 (disable_probes_command): Likewise.
1979 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
1980 (get_probe_argument_count): Move to
1981 'any_static_probe_ops::get_argument_count'.
1982 (can_evaluate_probe_arguments): Move to
1983 'any_static_probe_ops::can_evaluate_arguments'.
1984 (evaluate_probe_argument): Move to
1985 'any_static_probe_ops::evaluate_argument'.
1986 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
1987 'probe.probe'.
1988 (probe_linespec_to_ops): Rename to...
1989 (probe_linespec_to_static_ops): ...this. Adjust code.
1990 (probe_any_is_linespec): Rename to...
1991 (any_static_probe_ops::is_linespec): ...this.
1992 (probe_any_get_probes): Rename to...
1993 (any_static_probe_ops::get_probes): ...this.
1994 (any_static_probe_ops::type_name): New method.
1995 (any_static_probe_ops::gen_info_probes_table_header): New
1996 method.
1997 (compute_probe_arg): Use 'pc_probe.prob' instead of
1998 'pc_probe.probe'. Call methods from probe.
1999 (compile_probe_arg): Likewise.
2000 (std::vector<const probe_ops *> all_probe_ops): Delete.
2001 (std::vector<const static_probe_ops *> all_static_probe_ops):
2002 New variable.
2003 (_initialize_probe): Use 'all_static_probe_ops' instead of
2004 'all_probe_ops'.
2005 * probe.h (struct info_probe_column) <field_name>: Delete
2006 extraneous newline
2007 (info_probe_column_s): Delete type and VEC.
2008 (struct probe_ops): Delete. Replace with...
2009 (class static_probe_ops): ...this and...
2010 (clas probe): ...this.
2011 (struct bound_probe) <bound_probe>: Delete extraneous
2012 newline. Adjust constructor to receive 'probe' instead of
2013 'struct probe'.
2014 <probe>: Rename to...
2015 <prob>: ...this. Delete extraneous newline.
2016 <objfile>: Delete extraneous newline.
2017 (register_probe_ops): Delete unused prototype.
2018 (info_probes_for_ops): Rename to...
2019 (info_probes_for_spops): ...this. Adjust comment.
2020 (get_probe_address): Move to 'probe::get_address'.
2021 (get_probe_argument_count): Move to
2022 'probe::get_argument_count'.
2023 (can_evaluate_probe_arguments): Move to
2024 'probe::can_evaluate_arguments'.
2025 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
2026 * solib-svr4.c (struct svr4_info): Adjust comment.
2027 (struct probe_and_action) <probe>: Rename to...
2028 <prob>: ...this.
2029 (register_solib_event_probe): Receive 'probe' instead of
2030 'struct probe' as argument. Use 'prob' instead of 'probe'
2031 when applicable.
2032 (solib_event_probe_action): Call 'get_argument_count' method
2033 from probe. Adjust comment.
2034 (svr4_handle_solib_event): Adjust comment. Call
2035 'evaluate_argument' method from probe.
2036 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
2037 from probe.
2038 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
2039 'struct probe'. Call 'can_evaluate_arguments' from probe.
2040 * symfile.h: Forward declare 'class probe' instead of 'struct
2041 probe'.
2042 * symtab.h: Likewise.
2043 (struct symtab_and_line) <probe>: Rename to...
2044 <prob>: ...this.
2045 * tracepoint.c (start_tracing): Use 'prob' when applicable.
2046 Call probe methods.
2047 (stop_tracing): Likewise.
2048
8f6cb6c3
JB
20492017-11-22 Joel Brobecker <brobecker@adacore.com>
2050
2051 * ravenscar-thread.c (ravenscar_inferior_created): Remove
2052 trailing newline at end of string in call to warning.
2053
479f8de1
SM
20542017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2055
2056 * osdata.h: Include vector isntead of vec.h.
2057 (osdata_column_s): Remove typedef.
2058 (struct osdata_column): Add constructor.
2059 <name, value>: Change type to std::string.
2060 (DEF_VEC_O (osdata_column_s)): Remove.
2061 (osdata_item_s): Remove typedef.
2062 (struct osdata_item) <columns>: Change type to std::vector.
2063 (DEF_VEC_O (osdata_item_s)): Remove.
2064 (struct osdata): Add constructor.
2065 <type>: Change type to std::string.
2066 <items>: Change type to std::vector.
2067 (osdata_p): Remove typedef.
2068 (DEF_VEC_P (osdata_p)): Remove.
2069 (osdata_parse): Return a unique_ptr.
2070 (osdata_free): Remove.
2071 (make_cleanup_osdata_free): Remove.
2072 (get_osdata): Return a unique_ptr.
2073 (get_osdata_column): Return pointer to std::string, take a
2074 reference to osdata_item as parameter.
2075 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
2076 unique_ptr.
2077 <property_name>: Change type to std::string.
2078 (osdata_start_osdata): Allocate osdata with new and adjust.
2079 (osdata_start_item): Adjust.
2080 (osdata_start_column): Adjust.
2081 (osdata_end_column): Adjust.
2082 (clear_parsing_data): Remove.
2083 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
2084 (osdata_item_clear): Remove.
2085 (get_osdata): return a unique_ptr and adjust.
2086 (get_osdata_column): Return a pointer to std::string and adjust.
2087 (info_osdata): Adjust.
2088 * mi/mi-main.c: Include <map>.
2089 (free_vector_of_osdata_items): Remove.
2090 (list_available_thread_groups): Adjust, use std::map instead of
2091 splay tree.
2092
41bd68f5
SM
20932017-11-22 Simon Marchi <simon.marchi@ericsson.com>
2094
2095 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
2096 case in switch.
2097
7e2fd2f4
SM
20982017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2099
2100 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
2101
0604393c
SM
21022017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2103
2104 * varobj.h (struct varobj_update_result): Add constructor, add
2105 move constructor, disable copy and assign, initialize fields.
2106 <newobj>: Change type to std::vector.
2107 (varobj_update): Return std::vector.
2108 * varobj.c (install_dynamic_child): Change VEC parameters to
2109 std::vector and adjust.
2110 (update_dynamic_varobj_children): Likewise.
2111 (varobj_update): Return std::vector and adjust.
2112 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
2113
ddf0ea08
SM
21142017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2115
2116 * varobj.h (struct varobj) <parent>: Remove const.
2117 <children>: Change type to std::vector.
2118 (varobj_list_children): Return std::vector const reference.
2119 (varobj_restrict_range): Change parameter type to std::vector
2120 const reference.
2121 * varobj.c (varobj_has_more): Adjust.
2122 (varobj_restrict_range): Change parameter type to std::vector
2123 const reference and adjust.
2124 (install_dynamic_child): Adjust.
2125 (update_dynamic_varobj_children): Adjust.
2126 (varobj_list_children): Return std::vector const reference and
2127 adjust.
2128 (varobj_add_child): Adjust.
2129 (update_type_if_necessary): Adjust.
2130 (varobj_update): Adjust.
2131 (delete_variable_1): Adjust.
2132 * ada-varobj.c (ada_value_has_mutated): Adjust.
2133 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
2134
9e5b9d2b
SM
21352017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2136
2137 * varobj.h (struct varobj): Add constructor and destructor,
2138 initialize fields.
2139 * varobj.c (struct varobj_root): Initialize fields.
2140 (struct varobj_dynamic): Initialize fields.
2141 (varobj_create): Use unique_ptr instead of cleanup. Create
2142 varobj with new instead of new_root_variable.
2143 (delete_variable_1): Free variable with delete instead of
2144 free_variable.
2145 (create_child_with_value): Create variable with new instead of
2146 new_variable.
2147 (varobj::varobj): New.
2148 (varobj::~varobj): New (body mostly coming from free_variable).
2149 (new_variable): Remove.
2150 (free_variable): Remove.
2151 (do_free_variable_cleanup): Remove.
2152 (make_cleanup_free_variable): Remove.
2153
fc35dab1
UW
21542017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2155
2156 * core-regset.c: Remove file.
2157 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
2158
2400729e
UW
21592017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2160
2161 * NEWS: Document use of GNU MPFR.
2162 * README: Likewise.
2163
2164 * Makefile.in (LIBMPFR): Add define.
2165 (CLIBS): Add $(LIBMPFR).
2166 * configure.ac: Add --with-mpfr configure option.
2167 * configure: Regenerate.
2168 * config.in: Regenerate.
2169
2170 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
2171 (class mpfr_float_ops): New type.
2172 (mpfr_float_ops::from_target): Two new overloaded functions.
2173 (mpfr_float_ops::to_target): Likewise.
2174 (mpfr_float_ops::to_string): New function.
2175 (mpfr_float_ops::from_string): Likewise.
2176 (mpfr_float_ops::to_longest): Likewise.
2177 (mpfr_float_ops::from_longest): Likewise.
2178 (mpfr_float_ops::from_ulongest): Likewise.
2179 (mpfr_float_ops::to_host_double): Likewise.
2180 (mpfr_float_ops::from_host_double): Likewise.
2181 (mpfr_float_ops::convert): Likewise.
2182 (mpfr_float_ops::binop): Likewise.
2183 (mpfr_float_ops::compare): Likewise.
2184 (get_target_float_ops): Use mpfr_float_ops if available.
2185
7a26362d
UW
21862017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2187
2188 * target-float.c: Do not include <math.h>.
2189 Include <cmath> and <limits>.
2190 (DOUBLEST): Do not define.
2191 (class target_float_ops): New type.
2192 (class host_float_ops): New templated type.
2193 (class decimal_float_ops): New type.
2194
2195 (floatformat_to_doublest): Rename to ...
2196 (host_float_ops<T>::from_target): ... this. Use template type T
2197 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2198 (host_float_ops<T>::from_target): New overload using a type argument.
2199 (floatformat_from_doublest): Rename to ...
2200 (host_float_ops<T>::to_target): ... this. Use template type T
2201 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2202 (host_float_ops<T>::to_target): New overload using a type argument.
2203 (floatformat_printf_format): New function.
2204 (struct printf_length_modifier): New templated type.
2205 (floatformat_to_string): Rename to ...
2206 (host_float_ops<T>::to_string): ... this. Use type instead of
2207 floatformat argument. Use floatformat_printf_format and
2208 printf_length_modifier. Remove special handling of invalid numbers,
2209 infinities and NaN (moved to target_float_to_string).
2210 (struct scanf_length_modifier): New templated type.
2211 (floatformat_from_string): Rename to ...
2212 (host_float_ops<T>::from_string): ... this. Use type instead of
2213 floatformat argument. Use scanf_length_modifier.
2214 (floatformat_to_longest): Rename to ...
2215 (host_float_ops<T>::to_longest): ... this. Use type instead of
2216 floatformat argument. Handle out-of-range values deterministically.
2217 (floatformat_from_longest): Rename to ...
2218 (host_float_ops<T>::from_longest): ... this. Use type instead of
2219 floatformat argument.
2220 (floatformat_from_ulongest): Rename to ...
2221 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
2222 floatformat argument.
2223 (floatformat_to_host_double): Rename to ...
2224 (host_float_ops<T>::to_host_double): ... this. Use type instead of
2225 floatformat argument.
2226 (floatformat_from_host_double): Rename to ...
2227 (host_float_ops<T>::from_host_double): ... this. Use type instead of
2228 floatformat argument.
2229 (floatformat_convert): Rename to ...
2230 (host_float_ops<T>::convert): ... this. Use type instead of
2231 floatformat arguments. Remove handling of no-op conversions.
2232 (floatformat_binop): Rename to ...
2233 (host_float_ops<T>::binop): ... this. Use type instead of
2234 floatformat arguments.
2235 (floatformat_compare): Rename to ...
2236 (host_float_ops<T>::compare): ... this. Use type instead of
2237 floatformat arguments.
2238
2239 (match_endianness): Use type instead of length/byte_order arguments.
2240 (set_decnumber_context): Likewise.
2241 (decimal_from_number): Likewise. Update calls.
2242 (decimal_to_number): Likewise.
2243 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
2244 (decimal_float_ops::to_host_double): New dummy function.
2245 (decimal_float_ops::from_host_double): Likewise.
2246 (decimal_to_string): Rename to ...
2247 (decimal_float_ops::to_string): ... this. Use type instead of
2248 length/byte_order arguments. Update calls.
2249 (decimal_from_string): Rename to ...
2250 (decimal_float_ops::from_string): ... this. Use type instead of
2251 length/byte_order arguments. Update calls.
2252 (decimal_from_longest): Rename to ...
2253 (decimal_float_ops::from_longest): ... this. Use type instead of
2254 length/byte_order arguments. Update calls.
2255 (decimal_from_ulongest): Rename to ...
2256 (decimal_float_ops::from_ulongest): ... this. Use type instead of
2257 length/byte_order arguments. Update calls.
2258 (decimal_to_longest): Rename to ...
2259 (decimal_float_ops::to_longest): ... this. Use type instead of
2260 length/byte_order arguments. Update calls.
2261 (decimal_binop): Rename to ...
2262 (decimal_float_ops::binop): ... this. Use type instead of
2263 length/byte_order arguments. Update calls.
2264 (decimal_compare): Rename to ...
2265 (decimal_float_ops::compare): ... this. Use type instead of
2266 length/byte_order arguments. Update calls.
2267 (decimal_convert): Rename to ...
2268 (decimal_float_ops::convert): ... this. Use type instead of
2269 length/byte_order arguments. Update calls.
2270
2271 (target_float_same_category_p): New function.
2272 (target_float_same_format_p): Likewise.
2273 (target_float_format_length): Likewise.
2274 (enum target_float_ops_kind): New type.
2275 (get_target_float_ops_kind): New function.
2276 (get_target_float_ops): Three new overloaded functions.
2277
2278 (target_float_is_zero): Update call.
2279 (target_float_to_string): Add special handling of invalid numbers,
2280 infinities and NaN (moved from floatformat_to_string). Use
2281 target_float_ops callback.
2282 (target_float_from_string): Use target_float_ops callback.
2283 (target_float_to_longest): Likewise.
2284 (target_float_from_longest): Likewise.
2285 (target_float_from_ulongest): Likewise.
2286 (target_float_to_host_double): Likewise.
2287 (target_float_from_host_double): Likewise.
2288 (target_float_convert): Add special case for no-op conversions.
2289 Use target_float_ops callback.
2290 (target_float_binop): Use target_float_ops callback.
2291 (target_float_compare): Likewise.
2292
a9f26f60
YQ
22932017-11-22 Yao Qi <yao.qi@linaro.org>
2294
2295 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
2296
29f9a567
YQ
22972017-11-22 Yao Qi <yao.qi@linaro.org>
2298
2299 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
2300 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
2301
3b1b69bf
JG
23022017-11-21 Jerome Guitton <guitton@adacore.com>
2303
2304 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
2305 with event ptid from the lower layer before doing the
2306 ravenscar-specific update.
2307
54aa6c67
JB
23082017-11-21 Joel Brobecker <brobecker@adacore.com>
2309
2310 * ravenscar-thread.c (is_ravenscar_task): Also verify that
2311 the ptid's TID is nonzero.
2312
cf3fbed4
JB
23132017-11-21 Joel Brobecker <brobecker@adacore.com>
2314
2315 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
2316 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
2317 Make non-static. Change return type to char *. Adjust code
2318 accordingly. Rewrite the function's documentation.
2319 (read_atcb): Adjust call to get_tcb_types_info accordingly.
2320 * ravenscar-thread.c (ravenscar_inferior_created): Check that
2321 we have enough debugging information in the runtime to support
2322 Ada task debugging before we enable the ravenscar-thread layer.
2323
9edcc12f
JB
23242017-11-21 Joel Brobecker <brobecker@adacore.com>
2325
2326 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
2327 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
2328 * ravenscar-thread.c: Add into comment.
2329 (base_magic_null_ptid): Delete.
2330 (base_ptid): Change documentation.
2331 (ravenscar_active_task): Renames ravenscar_running_thread.
2332 All callers updated throughout.
2333 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
2334 (ravenscar_task_is_currently_active): Likewise.
2335 (get_base_thread_from_ravenscar_task): Ditto.
2336 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
2337 (ravenscar_runtime_initialized): Likewise.
2338 (get_running_thread_id): Add new parameter "cpu". Adjust
2339 implementation to handle this new parameter.
2340 (ravenscar_fetch_registers): Small adjustment to use
2341 is_ravenscar_task and ravenscar_task_is_currently_active in
2342 order to decide whether to use the target beneath or this
2343 module's arch_ops.
2344 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
2345 (ravenscar_stopped_by_sw_breakpoint): Use
2346 get_base_thread_from_ravenscar_task to get the underlying
2347 thread, rather than using base_ptid.
2348 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2349 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2350 Likewise.
2351 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
2352
65d40437
JB
23532017-11-21 Joel Brobecker <brobecker@adacore.com>
2354
2355 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
2356 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
2357 (get_tcb_types_info): Set fieldnos.base_cpu.
2358 (read_atcb): Set task_info->base_cpu.
2359 (info_task): Print "Base CPU" info if set by runtime.
2360
e02544b2
JB
23612017-11-21 Joel Brobecker <brobecker@adacore.com>
2362
2363 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
2364 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2365 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2366 New functions.
2367 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
2368 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
2369 to_stopped_data_address and to_core_of_thread fields of
2370 ravenscar_ops.
2371
ed0f4273
UW
23722017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
2373
2374 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
2375 (struct gdbarch_tdep): New member long_double_abi.
2376 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
2377 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
2378 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
2379 format depending on long_double_abi tdep member.
2380 (ppc_floatformat_for_type): Handle __ibm128 type.
2381
0fc76421
SM
23822017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
2383
2384 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
2385
e6b2f5ef
PA
23862017-11-21 Pedro Alves <palves@redhat.com>
2387
2388 * dwarf2read.c (mapped_index::find_name_components_bounds)
2389 <completion mode, upper bound>: Use std::lower_bound instead of
2390 std::upper_bound.
2391 (test_mapped_index_find_name_component_bounds): Remove incorrect
2392 "t1_fund" from expected symbols.
2393
5c58de74
PA
23942017-11-21 Pedro Alves <palves@redhat.com>
2395
2396 * dwarf2read.c (mapped_index::name_components_casing): New field.
2397 (mapped_index) <build_name_components,
2398 find_name_components_bounds): Declare new methods.
2399 (mapped_index::find_name_components_bounds)
2400 (mapped_index::build_name_components): New methods, factored out
2401 from dw2_expand_symtabs_matching_symbol.
2402 (check_find_bounds_finds)
2403 (test_mapped_index_find_name_component_bounds): New.
2404 (run_test): Rename to ...
2405 (test_dw2_expand_symtabs_matching_symbol): ... this.
2406 (run_test): Reimplement.
2407
e1ef7d7a
PA
24082017-11-21 Pedro Alves <palves@redhat.com>
2409
2410 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
2411 (symbol_end): Use cp_ident_is_alnum.
2412 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
2413 * dwarf2read.c (make_sort_after_prefix_name): New function.
2414 (dw2_expand_symtabs_matching_symbol): Use it.
2415 (test_symbols): Add more symbols.
2416 (run_test): Add tests.
2417
cf724bc9
TT
24182017-11-17 Tom Tromey <tom@tromey.com>
2419
2420 * symtab.h (enum symbol_subclass_kind): New.
2421 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
2422 Remove.
2423 <subclass>: New member.
2424 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
2425 * rust-lang.c (rust_get_trait_object_pointer): Update.
2426 * dwarf2read.c (read_func_scope): Update.
2427 (read_variable): Update.
2428
68e745e3
TT
24292017-11-17 Tom Tromey <tom@tromey.com>
2430
2431 * dwarf2read.c (read_func_scope): Update.
2432 * symtab.h (struct template_symbol): Derive from symbol.
2433 <base>: Remove.
2434
71a3c369
TT
24352017-11-17 Tom Tromey <tom@tromey.com>
2436
2437 * symtab.h (struct symbol) <is_rust_vtable>: New member.
2438 (struct rust_vtable_symbol): New.
2439 (find_symbol_at_address): Declare.
2440 * symtab.c (find_symbol_at_address): New function.
2441 * symfile.h (struct quick_symbol_functions)
2442 <find_compunit_symtab_by_address>: New member.
2443 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
2444 function.
2445 (debug_sym_quick_functions): Link to
2446 debug_qf_find_compunit_symtab_by_address.
2447 * rust-lang.c (rust_get_trait_object_pointer): New function.
2448 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
2449 rust_get_trait_object_pointer.
2450 * psymtab.c (psym_relocate): Clear psymbol_map.
2451 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
2452 functions.
2453 (psym_functions): Link to psym_find_compunit_symtab_by_address.
2454 * objfiles.h (struct objfile) <psymbol_map>: New member.
2455 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
2456 (process_die) <DW_TAG_variable>: New case. Call read_variable.
2457 (rust_containing_type, read_variable): New functions.
2458
7468702d
SM
24592017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2460
2461 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
2462
37269bc9
SM
24632017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2464
2465 * common/filestuff.c: Include <algorithm>.
2466 (open_fds): Change type to std::vector<int>.
2467 (do_mark_open_fd): Adjust.
2468 (unmark_fd_no_cloexec): Adjust.
2469 (do_close): Adjust.
2470
5c632425
SM
24712017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2472
2473 * breakpoint.c (output_thread_groups): Take an std::vector.
2474 (print_one_breakpoint_location): Adjust.
2475
ced9779b
JB
24762017-11-17 Joel Brobecker <brobecker@adacore.com>
2477
2478 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2479 (ada_evaluate_subexp_for_cast): New function.
2480 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2481 ada_evaluate_subexp_for_cast.
2482 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2483 eval_skip_value.
2484 * eval.c (evaluate_var_value): Make non-static.
2485 (evaluate_var_msym_value, eval_skip_value): Likewise.
2486 * value.h (evaluate_var_value, evaluate_var_msym_value)
2487 (eval_skip_value): Declare.
2488
b7e22850
JB
24892017-11-16 Joel Brobecker <brobecker@adacore.com>
2490
2491 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2492 Update all callers.
2493
9ccabccd
PA
24942017-11-16 Pedro Alves <palves@redhat.com>
2495
2496 * python/py-unwind.c (pyuw_sniffer): Translate
2497 PyExc_KeyboardInterrupt to a GDB Quit exception.
2498
d930703d
PA
24992017-11-16 Pedro Alves <palves@redhat.com>
2500
2501 * infrun.c (resume_cleanups): Delete.
2502 (resume): No longer install a resume_cleanups cleanup nor call
2503 QUIT.
2504 (proceed): Pass the terminal to the inferior.
2505 (keep_going_pass_signal): No longer install a resume_cleanups
2506 cleanup.
2507
38dc2859
PA
25082017-11-16 Pedro Alves <palves@redhat.com>
2509
2510 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2511 if the prompt is blocked.
2512
688fca4f
PA
25132017-11-16 Pedro Alves <palves@redhat.com>
2514
2515 * breakpoint.c (insert_bp_location): Replace bp_err and
2516 bp_err_message locals by a gdb_exception local.
2517
e2c33ac7
PA
25182017-11-16 Pedro Alves <palves@redhat.com>
2519
2520 * inflow.c (scoped_ignore_sigttou): New class.
2521 (child_terminal_ours_1, new_tty): Use it.
2522
d7236961
UW
25232017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2524
2525 * target-float.c (decimal_from_number): Add byte_order argument and
2526 call match_endianness. Error if unknown floating-point type.
2527 (decimal_to_number): Add byte_order argument and call match_endianness.
2528 (decimal_from_longest): Update call. Do not call match_endianness.
2529 (decimal_from_ulongest): Likewise.
2530 (decimal_binop): Likewise.
2531 (decimal_is_zero): Likewise.
2532 (decimal_compare): Likewise.
2533 (decimal_convert): Likewise.
2534
d8ae99a7
PM
25352017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2536
2537 * python/python.c (gdbpy_rbreak): New function.
2538 * NEWS: Document Python rbreak feature.
2539
c632b645
YQ
25402017-11-16 Yao Qi <yao.qi@linaro.org>
2541
2542 * features/tic6x-c62x.xml: Remove.
2543 * features/tic6x-c64x.xml: Remove.
2544 * features/tic6x-c64xp.xml: Remove.
2545
a014b87a
JB
25462017-11-15 John Baldwin <jhb@FreeBSD.org>
2547
2548 * symtab.h: Include <array>.
2549
94765011
JB
25502017-11-15 John Baldwin <jhb@FreeBSD.org>
2551
2552 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2553 (bsd_kvm_proc_cmd): Likewise.
2554
625ad440
SM
25552017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2556
2557 * tui/tui-win.c (window_name_completer): Replace VEC with
2558 std::vector.
2559
c0c11fa9
AC
25602017-11-15 Andrew Cagney <cagney@gnu.org>
2561
2562 * MAINTAINERS: Remove no-longer applicable entries.
2563
34a7ebaf
AC
25642017-11-15 Andrew Cagney <cagney@gnu.org>
2565
2566 * MAINTAINERS: Move self to Past Maintainers.
2567
5334ef39
YQ
25682017-11-15 Yao Qi <yao.qi@linaro.org>
2569
2570 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2571 * features/nios2-linux.c: Remove.
2572 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2573 initialize_tdesc_nios2_linux.
2574
a714b0d6
YQ
25752017-11-15 Yao Qi <yao.qi@linaro.org>
2576
2577 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2578 M68HC11_LAST_HARD_REG + 1.
2579
92ffd475
PC
25802017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2581
2582 PR gdb/22388
2583 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2584 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2585 Return TARGET_XFER_EOF if size of returned data is 0.
2586
07431908
SM
25872017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2588
2589 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2590 memory-map-selftests.c.
2591 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2592 * memory-map.c (memory_map_start_memory): Fix computation of hi
2593 address.
2594 * unittests/memory-map-selftests.c: New file.
2595
31432a67
JB
25962017-11-09 Joel Brobecker <brobecker@adacore.com>
2597
2598 * ada-lang.c: Fix some typos in the general command documenting
2599 how Ada expressions are being evaluated and how their result
2600 is printed.
2601
e793c052
TT
26022017-11-09 Tom Tromey <tom@tromey.com>
2603
2604 * psymtab.c (psymbol_hash): Do not hash string contents.
2605 (psymbol_compare): Add comment.
2606
7e8835c5
TT
26072017-11-09 Tom Tromey <tom@tromey.com>
2608
2609 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2610
286acbb5
JB
26112017-11-08 Joel Brobecker <brobecker@adacore.com>
2612
2613 * ada-exp.y (write_var_from_sym): Remove parameter
2614 "orig_left_context". Update all callers.
2615
b44ec619
SM
26162017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2617
2618 * tracepoint.h (class collection_list) <stringify>: Return
2619 std::vector<std::string>.
2620 (encode_actions_rsp): Change parameters to
2621 std::vector<std::string> *.
2622 * tracepoint.c (collection_list::stringify): Return
2623 std::vector<std::string> and adjust accordingly.
2624 (encode_actions_rsp): Changee parameters to
2625 std::vector<std::string> and adjust accordingly.
2626 * remote.c (free_actions_list),
2627 free_actions_list_cleanup_wrapper): Remove.
2628 (remote_download_tracepoint): Adjust to std::vector.
2629
2f4732b0
TT
26302017-11-08 Tom Tromey <tom@tromey.com>
2631
2632 * dwarf2read.c (symbolp): Remove typedef.
2633 (read_func_scope): Use std::vector.
2634 (process_structure_scope): Use std::vector.
2635
f9d67a22
PA
26362017-11-08 Pedro Alves <palves@redhat.com>
2637
2638 * ada-lang.c (ada_make_symbol_completion_list): Use
2639 completion_skip_symbol.
2640 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2641 (symbol_is_function_or_method(symbol*)): New.
2642 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2643 completion_skip_symbol.
2644 (default_collect_symbol_completion_matches_break_on): Use
2645 completion_skip_symbol. Pass down mode.
2646 (collect_file_symbol_completion_matches): Pass down mode.
2647 * symtab.h (symbol_is_function_or_method): New declarations.
2648 (completion_skip_symbol): New template function.
2649
56d87ef7
PA
26502017-11-08 Pedro Alves <palves@redhat.com>
2651
2652 * linespec.c (iterate_over_all_matching_symtabs): Add
2653 search_domain parameter. Pass it down to expand_symtabs_matching.
2654 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2655 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2656 search_domain.
2657 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2658 Pass it down.
2659 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2660 symbols.
2661 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2662 it down.
2663
1b026119
PA
26642017-11-08 Pedro Alves <palves@redhat.com>
2665
2666 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2667 text_len locals and don't pass them down.
2668 * symtab.c (completion_list_add_name): Remove
2669 sym_text/sym_text_len parameters and adjust.
2670 (completion_list_add_symbol, completion_list_add_msymbol)
2671 (completion_list_objc_symbol, completion_list_add_fields)
2672 (add_symtab_completions): Likewise.
2673 (default_collect_symbol_completion_matches_break_on)
2674 (collect_file_symbol_completion_matches): Remove sym_text_len
2675 local and don't pass it down.
2676 * symtab.h (completion_list_add_name): Remove
2677 sym_text/sym_text_len parameters.
2678
c62446b1
PA
26792017-11-08 Pedro Alves <palves@redhat.com>
2680
2681 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2682 unittests/lookup_name_info-selftests.c.
2683 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2684 * cp-support.c: Include "selftest.h".
2685 (cp_remove_params_1): Rename from cp_remove_params. Add
2686 'require_param' parameter, and handle it.
2687 (cp_remove_params): Reimplement.
2688 (cp_remove_params_if_any): New.
2689 (selftests::quote): New.
2690 (selftests::check_remove_params): New.
2691 (selftests::test_cp_remove_params): New.
2692 (_initialize_cp_support): Install
2693 selftests::test_cp_remove_params.
2694 * cp-support.h (cp_remove_params_if_any): Declare.
2695 * dwarf2read.c :Include "selftest.h".
2696 (dw2_expand_symtabs_matching_symbol): Use
2697 lookup_name_info::make_ignore_params.
2698 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2699 (selftests::dw2_expand_symtabs_matching::string_or_null)
2700 (selftests::dw2_expand_symtabs_matching::check_match)
2701 (selftests::dw2_expand_symtabs_matching::test_symbols)
2702 (selftests::dw2_expand_symtabs_matching::run_test): New.
2703 (_initialize_dwarf2_read): Register
2704 selftests::dw2_expand_symtabs_matching::run_test.
2705 * psymtab.c (psym_expand_symtabs_matching): Use
2706 lookup_name_info::make_ignore_params.
2707 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2708 If the lookup name wants to ignore parameters, strip them.
2709 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2710 code handling '('.
2711 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2712 (default_collect_symbol_completion_matches_break_on): Don't try to
2713 strip parameters.
2714 * symtab.h (lookup_name_info::lookup_name_info): Add
2715 'ignore_parameters' parameter.
2716 (lookup_name_info::ignore_parameters)
2717 (lookup_name_info::make_ignore_params): New methods.
2718 (lookup_name_info::m_ignore_parameters): New field.
2719 * unittests/lookup_name_info-selftests.c: New file.
2720
61920122
PA
27212017-11-08 Pedro Alves <palves@redhat.com>
2722
2723 * dwarf2read.c (dw2_expand_marked_cus)
2724 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2725 (dw2_expand_symtabs_matching): Move further below.
2726 (dw2_expand_marked_cus): Reindent.
2727
3f563c84
PA
27282017-11-08 Pedro Alves <palves@redhat.com>
2729
2730 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2731 (struct name_component): New.
2732 (mapped_index::name_components): New field.
2733 (mapped_index::symbol_name_at): New method.
2734 (dwarf2_read_index): Call mapped_index ctor.
2735 (dw2_map_matching_symbols): Add comment about name_components
2736 table.
2737 (dw2_expand_symtabs_matching): Factor part to...
2738 (dw2_expand_symtabs_matching_symbol): ... this new function.
2739 Build name components table, and lookup symbols in it before
2740 calling the name matcher.
2741 (dw2_expand_marked_cus): New, factored out from
2742 dw2_expand_symtabs_matching.
2743 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2744
b5ec771e
PA
27452017-11-08 Pedro Alves <palves@redhat.com>
2746
2747 * ada-lang.c (ada_encode): Rename to ..
2748 (ada_encode_1): ... this. Add throw_errors parameter and handle
2749 it.
2750 (ada_encode): Reimplement.
2751 (match_name): Delete, folded into full_name.
2752 (resolve_subexp): No longer pass the encoded name to
2753 ada_lookup_symbol_list.
2754 (should_use_wild_match): Delete.
2755 (name_match_type_from_name): New.
2756 (ada_lookup_simple_minsym): Use lookup_name_info and the
2757 language's symbol_name_matcher_ftype.
2758 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2759 (ada_add_block_renamings): Adjust to use lookup_name_info.
2760 (ada_lookup_name): New.
2761 (add_nonlocal_symbols, ada_add_all_symbols)
2762 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2763 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2764 (ada_name_for_lookup): Delete.
2765 (ada_lookup_encoded_symbol): Construct a verbatim name.
2766 (wild_match): Reverse sense of return type. Use bool.
2767 (full_match): Reverse sense of return type. Inline bits of old
2768 match_name here.
2769 (ada_add_block_symbols): Adjust to use lookup_name_info.
2770 (symbol_completion_match): Delete, folded into...
2771 (ada_lookup_name_info::matches): ... .this new method.
2772 (symbol_completion_add): Delete.
2773 (ada_collect_symbol_completion_matches): Add name_match_type
2774 parameter. Adjust to use lookup_name_info and
2775 completion_list_add_name.
2776 (get_var_value, ada_add_global_exceptions): Adjust to use
2777 lookup_name_info.
2778 (ada_get_symbol_name_cmp): Delete.
2779 (do_wild_match, do_full_match): New functions.
2780 (ada_lookup_name_info::ada_lookup_name_info): New method.
2781 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2782 functions.
2783 (ada_language_defn): Install ada_get_symbol_name_matcher.
2784 * ada-lex.l (processId): If name starts with '<', copy it
2785 verbatim.
2786 * block.c (block_iter_match_step, block_iter_match_first)
2787 (block_iter_match_next, block_lookup_symbol)
2788 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2789 lookup_name_info.
2790 * block.h (block_iter_match_first, block_iter_match_next)
2791 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2792 * c-lang.c (c_language_defn, cplus_language_defn)
2793 (asm_language_defn, minimal_language_defn): Adjust comments to
2794 refer to la_get_symbol_name_matcher.
2795 * completer.c (complete_files_symbols)
2796 (collect_explicit_location_matches, symbol_completer): Pass a
2797 symbol_name_match_type down.
2798 * completer.h (class completion_match, completion_match_result):
2799 New classes.
2800 (completion_tracker::reset_completion_match_result): New method.
2801 (completion_tracker::m_completion_match_result): New field.
2802 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2803 lookup_name_info.
2804 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2805 functions.
2806 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2807 * d-lang.c: Adjust comments to refer to
2808 la_get_symbol_name_matcher.
2809 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2810 Adjust to use lookup_name_info.
2811 (dict_iter_match_first, dict_iter_match_next)
2812 (iter_match_first_hashed, iter_match_next_hashed)
2813 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2814 with a lookup_name_info.
2815 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2816 Likewise.
2817 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2818 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2819 (gdb_index_symbol_name_matcher): New class.
2820 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2821 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2822 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2823 with a symbol_name_match_type.
2824 (f_language_defn): Adjust comments to refer to
2825 la_get_symbol_name_matcher.
2826 * go-lang.c (go_language_defn): Adjust comments to refer to
2827 la_get_symbol_name_matcher.
2828 * language.c (default_symbol_name_matcher)
2829 (language_get_symbol_name_matcher): New functions.
2830 (unknown_language_defn, auto_language_defn): Adjust comments to
2831 refer to la_get_symbol_name_matcher.
2832 * language.h (symbol_name_cmp_ftype): Delete.
2833 (language_defn) <la_collect_symbol_completion_matches>: Add match
2834 type parameter.
2835 <la_get_symbol_name_cmp>: Delete field.
2836 <la_get_symbol_name_matcher>: New field.
2837 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
2838 (default_symbol_name_matcher, language_get_symbol_name_matcher):
2839 Declare.
2840 * linespec.c (iterate_over_all_matching_symtabs)
2841 (iterate_over_file_blocks): Adjust to use lookup_name_info.
2842 (find_methods): Add language parameter, and use lookup_name_info
2843 and the language's symbol_name_matcher_ftype.
2844 (linespec_complete_function): Adjust.
2845 (lookup_prefix_sym): Use lookup_name_info.
2846 (add_all_symbol_names_from_pspace): Adjust.
2847 (find_superclass_methods): Add language parameter and pass it
2848 down.
2849 (find_method): Pass symbol language down.
2850 (find_linespec_symbols): Don't demangle or Ada encode here.
2851 (search_minsyms_for_name): Add lookup_name_info parameter.
2852 (add_matching_symbols_to_info): Add name_match_type parameter.
2853 Use lookup_name_info.
2854 * m2-lang.c (m2_language_defn): Adjust comments to refer to
2855 la_get_symbol_name_matcher.
2856 * minsyms.c: Include <algorithm>.
2857 (add_minsym_to_demangled_hash_table): Remove table parameter and
2858 add objfile parameter. Use search_name_hash, and add language to
2859 demangled languages vector.
2860 (struct found_minimal_symbols): New struct.
2861 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
2862 New functions.
2863 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
2864 input names here. Use lookup_name_info instead. Lookup up
2865 demangled names once for each language in the demangled names
2866 vector.
2867 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
2868 demangled names once for each language in the demangled names
2869 vector.
2870 (build_minimal_symbol_hash_tables): Adjust.
2871 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
2872 lookup_name_info.
2873 * objc-lang.c (objc_language_defn): Adjust comment to refer to
2874 la_get_symbol_name_matcher.
2875 * objfiles.h: Include <vector>.
2876 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
2877 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
2878 la_get_symbol_name_matcher.
2879 * p-lang.c (pascal_language_defn): Adjust comment to refer to
2880 la_get_symbol_name_matcher.
2881 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
2882 (match_partial_symbol): Use symbol_name_match_type,
2883 lookup_name_info and psymbol_name_matches.
2884 (lookup_partial_symbol): Use lookup_name_info.
2885 (map_block): Use symbol_name_match_type and lookup_name_info.
2886 (psym_map_matching_symbols): Use symbol_name_match_type.
2887 (psymbol_name_matches): New.
2888 (recursively_search_psymtabs): Use lookup_name_info and
2889 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
2890 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
2891 'kind' parameter to 'domain'.
2892 * rust-lang.c (rust_language_defn): Adjust comment to refer to
2893 la_get_symbol_name_matcher.
2894 * symfile-debug.c (debug_qf_map_matching_symbols)
2895 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
2896 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
2897 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
2898 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
2899 Adjust to use symbol_name_match_type.
2900 <expand_symtabs_matching>: Adjust to use lookup_name_info.
2901 (expand_symtabs_matching): Adjust to use lookup_name_info.
2902 * symmisc.c (maintenance_expand_symtabs): Use
2903 lookup_name_info::match_any ().
2904 * symtab.c (symbol_matches_search_name): New.
2905 (eq_symbol_entry): Adjust to use lookup_name_info and the
2906 language's matcher.
2907 (demangle_for_lookup_info::demangle_for_lookup_info): New.
2908 (lookup_name_info::match_any): New.
2909 (iterate_over_symbols, search_symbols): Use lookup_name_info.
2910 (compare_symbol_name): Add language, lookup_name_info and
2911 completion_match_result parameters, and use them.
2912 (completion_list_add_name): Make extern. Add language and
2913 lookup_name_info parameters. Use them.
2914 (completion_list_add_symbol, completion_list_add_msymbol)
2915 (completion_list_objc_symbol): Add lookup_name_info parameters and
2916 adjust. Pass down language.
2917 (completion_list_add_fields): Add lookup_name_info parameters and
2918 adjust. Pass down language.
2919 (add_symtab_completions): Add lookup_name_info parameters and
2920 adjust.
2921 (default_collect_symbol_completion_matches_break_on): Add
2922 name_match_type parameter, and use it. Use lookup_name_info.
2923 (default_collect_symbol_completion_matches)
2924 (collect_symbol_completion_matches): Add name_match_type
2925 parameter, and pass it down.
2926 (collect_symbol_completion_matches_type): Adjust.
2927 (collect_file_symbol_completion_matches): Add name_match_type
2928 parameter, and use lookup_name_info.
2929 * symtab.h: Include <string> and "common/gdb_optional.h".
2930 (enum class symbol_name_match_type): New.
2931 (class ada_lookup_name_info): New.
2932 (struct demangle_for_lookup_info): New.
2933 (class lookup_name_info): New.
2934 (symbol_name_matcher_ftype): New.
2935 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
2936 (symbol_matches_search_name): Declare.
2937 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
2938 (default_collect_symbol_completion_matches)
2939 (collect_symbol_completion_matches)
2940 (collect_file_symbol_completion_matches): Add name_match_type
2941 parameter.
2942 (iterate_over_symbols): Use lookup_name_info.
2943 (completion_list_add_name): Declare.
2944 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
2945 (strncmp_iw_with_mode): Now extern.
2946 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
2947 (strncmp_iw_with_mode): Declare.
2948
5ffa0793
PA
29492017-11-08 Keith Seitz <keiths@redhat.com>
2950 Pedro Alves <palves@redhat.com>
2951
2952 * ada-lang.c (ada_language_defn): Install
2953 default_search_name_hash.
2954 * buildsym.c (struct buildsym_compunit): <language>: New field.
2955 (finish_block_internal): Pass language when creating dictionaries.
2956 (start_buildsym_compunit, start_symtab): New language parameters.
2957 Use them.
2958 (restart_symtab): Pass down compilation unit's language.
2959 * buildsym.h (enum language): Forward declare.
2960 (start_symtab): New 'language' parameter.
2961 * c-lang.c (c_language_defn, cplus_language_defn)
2962 (asm_language_defn, minimal_language_defn): Install
2963 default_search_name_hash.
2964 * coffread.c (coff_start_symtab): Adjust.
2965 * d-lang.c (d_language_defn): Install default_search_name_hash.
2966 * dbxread.c (struct symloc): Add 'pst_language' field.
2967 (PST_LANGUAGE): Define.
2968 (start_psymtab, read_ofile_symtab): Use it.
2969 (process_one_symbol): New 'language' parameter. Pass it down.
2970 * dictionary.c (struct dictionary) <language>: New field.
2971 (DICT_LANGUAGE): Define.
2972 (dict_create_hashed, dict_create_hashed_expandable)
2973 (dict_create_linear, dict_create_linear_expandable): New parameter
2974 'language'. Set the dictionary's language.
2975 (iter_match_first_hashed): Adjust to rename.
2976 (insert_symbol_hashed): Assert we don't see mismatching
2977 languages. Adjust to rename.
2978 (dict_hash): Rename to ...
2979 (default_search_name_hash): ... this and make extern.
2980 * dictionary.h (struct language_defn): Forward declare.
2981 (dict_create_hashed): New parameter 'language'.
2982 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
2983 * f-lang.c (f_language_defn): Install default_search_name_hash.
2984 * go-lang.c (go_language_defn): Install default_search_name_hash.
2985 * jit.c (finalize_symtab): Pass compunit's language to dictionary
2986 creation.
2987 * language.c (unknown_language_defn, auto_language_defn):
2988 * language.h (language_defn::la_search_name_hash): New field.
2989 (default_search_name_hash): Declare.
2990 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
2991 * mdebugread.c (new_block): New parameter 'language'.
2992 * mdebugread.c (parse_symbol): Pass symbol language to block
2993 allocation.
2994 (psymtab_to_symtab_1): Pass down language.
2995 (new_symtab): Pass compunit's language to block allocation.
2996 * objc-lang.c (objc_language_defn): Install
2997 default_search_name_hash.
2998 * opencl-lang.c (opencl_language_defn):
2999 * p-lang.c (pascal_language_defn): Install
3000 default_search_name_hash.
3001 * rust-lang.c (rust_language_defn): Install
3002 default_search_name_hash.
3003 * stabsread.h (enum language): Forward declare.
3004 (process_one_symbol): Add 'language' parameter.
3005 * symtab.c (search_name_hash): New function.
3006 * symtab.h (search_name_hash): Declare.
3007 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
3008
2a1dde5d
PA
30092017-11-08 Pedro Alves <palves@redhat.com>
3010
3011 * cp-name-parser.y (main): Don't initialize extra_chars.
3012
95a6b0a1
TT
30132017-11-07 Tom Tromey <tom@tromey.com>
3014
3015 * event-top.h (command_handler): Constify.
3016 * record-full.c (cmd_record_full_start): Update.
3017 * thread.c (thread_apply_all_command): Update.
3018 * printcmd.c (eval_command): Update.
3019 * mi/mi-main.c (mi_execute_cli_command): Update.
3020 (mi_execute_async_cli_command): Update.
3021 * tui/tui-stack.c (tui_update_command): Update.
3022 * cli/cli-interp.c (safe_execute_command): Constify.
3023 * record.c (record_start): Update.
3024 (record_start, record_stop, cmd_record_start): Update.
3025 * record-btrace.c (cmd_record_btrace_bts_start): Update.
3026 (cmd_record_btrace_pt_start): Update.
3027 (cmd_record_btrace_start): Update.
3028 (cmd_record_btrace_start): Update.
3029 * reverse.c (exec_reverse_once): Update.
3030 * python/python.c (execute_gdb_command): Don't copy the command.
3031 * event-top.c (command_line_handler): Update.
3032 (command_handler): Constify.
3033 * defs.h (deprecated_call_command_hook): Constify.
3034 * cli/cli-script.h (execute_user_command): Constify.
3035 * cli/cli-script.c (execute_user_command): Constify.
3036 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
3037 (enum command_control_type): Update.
3038 * main.c (catch_command_errors): Remove non-const overload.
3039 (catch_command_errors_ftype): Remove.
3040 * python/py-cmd.c (cmdpy_function): Constify.
3041 * guile/scm-cmd.c (cmdscm_function): Constify.
3042 * cli/cli-dump.c (call_dump_func): Constify.
3043 * cli/cli-decode.c (do_const_cfunc): Constify.
3044 (do_sfunc): Constify.
3045 (cmd_func): Constify.
3046 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
3047 * top.h (execute_command): Constify.
3048 * top.c (execute_command): Constify.
3049 (execute_command_to_string): Constify.
3050 (deprecated_call_command_hook): Constify.
3051 * command.h (cmd_func): Constify.
3052 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
3053
eb4c3f4a
TT
30542017-11-07 Tom Tromey <tom@tromey.com>
3055
3056 * ada-lang.c (catch_ada_exception_command): Constify.
3057 (catch_assert_command): Constify.
3058 * break-catch-throw.c (catch_catch_command, catch_throw_command)
3059 (catch_rethrow_command): Constify.
3060 (catch_exception_command_1): Constify.
3061 * breakpoint.h (add_catch_command): Constify.
3062 * break-catch-syscall.c (catch_syscall_command_1): Constify.
3063 (catch_syscall_split_args): Constify.
3064 * break-catch-sig.c (catch_signal_command): Constify.
3065 (catch_signal_split_args): Constify.
3066 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
3067 cmd_const_sfunc_ftype.
3068 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
3069 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3070 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3071 (add_setshow_string_cmd, struct cmd_list_element)
3072 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3073 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3074 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
3075 Constify.
3076 (set_cmd_sfunc): Constify.
3077 (empty_sfunc): Constify.
3078 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3079 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3080 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
3081 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3082 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3083 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
3084 Constify.
3085 (set_cmd_sfunc): Constify.
3086 (cmd_sfunc_ftype): Remove.
3087 * compile/compile.c (set_compile_args): Constify.
3088 * infrun.c (set_disable_randomization): Constify.
3089 * infcmd.c (set_args_command, set_cwd_command): Constify.
3090 * breakpoint.c (set_condition_evaluation_mode): Constify.
3091 (add_catch_command): Constify.
3092 (catch_fork_command_1, catch_exec_command_1)
3093 (catch_load_command_1, catch_unload_command_1): Constify.
3094 (catch_load_or_unload): Constify.
3095 * guile/scm-param.c (pascm_set_func): Constify.
3096 (add_setshow_generic): Constify.
3097 * python/py-param.c (get_set_value): Constify.
3098 * top.h (set_verbose): Constify.
3099 * tui/tui-win.c (tui_set_var_cmd): Constify.
3100 * mi/mi-main.c (set_mi_async_command): Constify.
3101 * cli/cli-logging.c (set_logging_overwrite)
3102 (set_logging_redirect): Constify.
3103 * value.c (set_max_value_size): Constify.
3104 * valprint.c (set_input_radix, set_output_radix): Constify.
3105 * utils.c (set_width_command, set_height_command): Constify.
3106 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
3107 * tracepoint.c (set_disconnected_tracing)
3108 (set_circular_trace_buffer, set_trace_buffer_size)
3109 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
3110 * top.c (set_history_size_command, set_verbose, set_editing)
3111 (set_gdb_datadir, set_history_filename): Constify.
3112 * target.c (set_targetdebug, maint_set_target_async_command)
3113 (maint_set_target_non_stop_command, set_target_permissions)
3114 (set_write_memory_permission): Constify.
3115 (open_target): Constify.
3116 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
3117 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
3118 * symtab.c (set_symbol_cache_size_handler): Constify.
3119 * symfile.c (set_ext_lang_command): Constify.
3120 * symfile-debug.c (set_debug_symfile): Constify.
3121 * source.c (set_directories_command): Constify.
3122 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
3123 * serial.c (set_parity): Constify.
3124 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
3125 * remote.c (set_remote_exec_file, set_remotebreak)
3126 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
3127 * record.c (set_record_insn_history_size)
3128 (set_record_call_history_size): Constify.
3129 * record-full.c (set_record_full_insn_max_num): Constify.
3130 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
3131 * osabi.c (set_osabi): Constify.
3132 * mips-tdep.c (set_mips64_transfers_32bit_regs)
3133 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
3134 * maint.c (maintenance_set_profile_cmd): Constify.
3135 * linux-thread-db.c (set_libthread_db_search_path): Constify.
3136 * language.c (set_language_command, set_range_command)
3137 (set_case_command): Constify.
3138 * infrun.c (set_non_stop, set_observer_mode)
3139 (set_stop_on_solib_events, set_schedlock_func)
3140 (set_exec_direction_func): Constify.
3141 * infcmd.c (set_inferior_tty_command): Constify.
3142 * disasm.c (set_disassembler_options_sfunc): Constify.
3143 * demangle.c (set_demangling_command): Constify.
3144 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
3145 * cris-tdep.c (set_cris_version, set_cris_mode)
3146 (set_cris_dwarf2_cfi): Constify.
3147 * corefile.c (set_gnutarget_command): Constify.
3148 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
3149 (set_target_wide_charset_sfunc): Constify.
3150 * breakpoint.c (update_dprintf_commands): Constify.
3151 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
3152 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
3153 (set_disassembly_style_sfunc): Constify.
3154 * arch-utils.c (set_endian, set_architecture): Constify.
3155 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
3156 * agent.c (set_can_use_agent): Constify.
3157
5fed81ff
TT
31582017-11-07 Tom Tromey <tom@tromey.com>
3159
3160 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
3161 (go32_pde, go32_pte, go32_pte_for_address): Constify.
3162 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
3163 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
3164 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
3165 (parse_int_arg, show_thread_default_detach_sc_cmd)
3166 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
3167 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
3168 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
3169 (show_task_pause_cmd, set_task_detach_sc_cmd)
3170 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
3171 (set_noninvasive_cmd, set_thread_pause_cmd)
3172 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
3173 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
3174 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
3175 * windows-nat.c (display_selectors): Constify.
3176 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
3177 non-const "cfunc".
3178 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
3179 (cmd_cfunc_eq): Likewise.
3180 (struct cmd_list_element): Likewise.
3181 (do_cfunc): Remove.
3182 (cli_user_command_p): Update.
3183 * command.h (add_cmd): Remove non-const overload.
3184 (cmd_cfunc_ftype): Remove typedef.
3185 (cmd_cfunc_eq): Remove non-const overload.
3186 * value.c (show_values): Constify.
3187 * thread.c (thread_apply_all_command): Constify.
3188 * symfile.c (load_command): Constify.
3189 * source.c (directory_command): Constify.
3190 * maint.c (maintenance_internal_error)
3191 (maintenance_demangler_warning, maintenance_space_display)
3192 (maintenance_print_architecture, maintenance_translate_address)
3193 (maintenance_info_selftests, maintenance_internal_warning):
3194 Constify.
3195 * breakpoint.c (disable_trace_command, enable_trace_command):
3196 Constify.
3197 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
3198 Constify.
3199 (add_auto_load_safe_path): Constify.
3200 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
3201 * top.h (show_commands): Constify.
3202 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
3203 * sparc64-tdep.c (adi_examine_command): Constify.
3204 (adi_assign_command): Constify.
3205
1d12d88f
TT
32062017-11-07 Tom Tromey <tom@tromey.com>
3207
3208 * frame.h (info_locals_command, info_args_command): Constify.
3209 * auto-load.h (auto_load_info_scripts): Constify.
3210 * inferior.h (registers_info): Constify.
3211 * copying.c: Rebuild.
3212 * copying.awk: Constify generated commands.
3213 * auto-load.c (auto_load_info_scripts)
3214 (info_auto_load_gdb_scripts): Constify.
3215 * cli/cli-decode.c (struct cmd_list_element): Take a
3216 cmd_const_cfunc_ftype.
3217 * command.h (add_info): Take a cmd_const_cfunc_ftype.
3218 * tui/tui-win.c (tui_all_windows_info): Constify.
3219 * python/py-auto-load.c (info_auto_load_python_scripts):
3220 Constify.
3221 * cli/cli-cmds.c (show_command): Remove non-const overload.
3222 * tracepoint.c (info_tvariables_command, info_scope_command):
3223 Constify.
3224 (info_static_tracepoint_markers_command): Constify.
3225 * thread.c (info_threads_command): Constify.
3226 (print_thread_info_1): Constify.
3227 * target.c (info_target_command): Constify.
3228 * symtab.c (info_sources_command, info_functions_command)
3229 (info_types_command): Constify.
3230 (info_variables_command): Remove non-const overload.
3231 * symfile.c (info_ext_lang_command): Constify.
3232 * stack.c (info_frame_command, info_locals_command)
3233 (info_args_command): Constify.
3234 (backtrace_command): Remove non-const overload.
3235 * source.c (info_source_command, info_line_command): Constify.
3236 * solib.c (info_sharedlibrary_command): Constify.
3237 * skip.c (info_skip_command): Constify.
3238 * ser-go32.c (info_serial_command): Constify.
3239 * reverse.c (info_bookmarks_command): Constify.
3240 * printcmd.c (info_symbol_command, info_address_command)
3241 (info_display_command): Constify.
3242 * osdata.c (info_osdata_command): Constify.
3243 * objc-lang.c (info_selectors_command, info_classes_command):
3244 Constify.
3245 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
3246 * memattr.c (info_mem_command): Constify.
3247 * macrocmd.c (info_macro_command, info_macros_command): Constify.
3248 * linux-fork.c (info_checkpoints_command): Constify.
3249 * infrun.c (info_signals_command): Constify.
3250 * inflow.c (info_terminal_command): Constify.
3251 * inferior.c (info_inferiors_command): Constify.
3252 (print_inferior): Constify.
3253 * infcmd.c (info_program_command, info_all_registers_command)
3254 (info_registers_command, info_vector_command)
3255 (info_float_command): Constify.
3256 (registers_info): Constify.
3257 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
3258 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
3259 Constify.
3260 * f-valprint.c (info_common_command): Constify.
3261 * dcache.c (info_dcache_command): Constify.
3262 (dcache_info_1): Constify.
3263 * darwin-nat-info.c (info_mach_tasks_command)
3264 (info_mach_task_command, info_mach_ports_command)
3265 (info_mach_port_command, info_mach_threads_command)
3266 (info_mach_thread_command, info_mach_regions_command)
3267 (info_mach_regions_recurse_command, info_mach_region_command)
3268 (info_mach_exceptions_command): Constify.
3269 (get_task_from_args): Constify.
3270 * cp-support.c (info_vtbl_command): Constify.
3271 * breakpoint.c (info_watchpoints_command)
3272 (info_tracepoints_command): Constify.
3273 (info_breakpoints_command): Remove non-const overload.
3274 * avr-tdep.c (avr_io_reg_read_command): Constify.
3275 * auxv.c (info_auxv_command): Constify.
3276 * ada-tasks.c (info_tasks_command): Constify.
3277 (info_task): Constify.
3278 * ada-lang.c (info_exceptions_command): Constify.
3279
0b39b52e
TT
32802017-11-07 Tom Tromey <tom@tromey.com>
3281
3282 * solib.h (no_shared_libraries): Constify.
3283 * frame.h (return_command): Constify.
3284 * cli/cli-cmds.h (quit_command): Constify.
3285 * top.h (quit_command, execute_command): Constify.
3286 * target.h (flash_erase_command): Constify.
3287 * inferior.h (set_inferior_args, attach_command): Constify.
3288 * tracepoint.h (start_tracing, stop_tracing): Constify.
3289 * breakpoint.h (break_command, tbreak_command)
3290 (hbreak_command_wrapper, thbreak_command_wrapper)
3291 (rbreak_command_wrapper, watch_command_wrapper)
3292 (awatch_command_wrapper, rwatch_command_wrapper)
3293 (get_tracepoint_by_number): Constify.
3294 * symtab.c (info_variables_command, rbreak_command)
3295 (symtab_symbol_info): Constify.
3296 (info_variables_command): Add non-const overload.
3297 * top.c (dont_repeat_command): Constify.
3298 * breakpoint.c (ignore_command, commands_command)
3299 (condition_command, tbreak_command, hbreak_command)
3300 (thbreak_command, clear_command, break_command)
3301 (info_breakpoints_command, watch_command, rwatch_command)
3302 (awatch_command, trace_command, ftrace_command, strace_command)
3303 (trace_pass_command, break_range_command, dprintf_command)
3304 (agent_printf_command, get_tracepoint_by_number)
3305 (watch_maybe_just_location, trace_pass_command): Constify.
3306 (info_breakpoints_command): Add non-const overload.
3307 * tracefile.c (tsave_command): Constify.
3308 * infcmd.c (attach_command, disconnect_command, signal_command)
3309 (queue_signal_command, stepi_command, nexti_command)
3310 (finish_command, next_command, step_command, until_command)
3311 (advance_command, jump_command, continue_command, run_command)
3312 (start_command, starti_command, interrupt_command)
3313 (run_command_1, set_inferior_args, step_1): Constify.
3314 * inferior.c (add_inferior_command, remove_inferior_command)
3315 (clone_inferior_command): Constify.
3316 * linux-fork.c (checkpoint_command, restart_command): Constify.
3317 * windows-nat.c (signal_event_command): Constify.
3318 * guile/guile.c (guile_repl_command, guile_command): Constify.
3319 * printcmd.c (x_command, display_command, printf_command)
3320 (output_command, set_command, call_command, print_command)
3321 (eval_command): Constify.
3322 (non_const_set_command): Remove.
3323 (_initialize_printcmd): Update.
3324 * source.c (forward_search_command, reverse_search_command):
3325 Constify.
3326 * jit.c (jit_reader_load_command, jit_reader_unload_command):
3327 Constify.
3328 * infrun.c (handle_command): Constify.
3329 * memattr.c (mem_command): Constify.
3330 * stack.c (return_command, up_command, up_silently_command)
3331 (down_command, down_silently_command, frame_command)
3332 (backtrace_command, func_command, backtrace_command_1): Constify.
3333 (backtrace_command): Add non-const overload.
3334 * remote-sim.c (simulator_command): Constify.
3335 * exec.c (set_section_command): Constify.
3336 * tracepoint.c (tdump_command, trace_variable_command)
3337 (tstatus_command, tstop_command, tstart_command)
3338 (end_actions_pseudocommand, while_stepping_pseudocommand)
3339 (collect_pseudocommand, teval_pseudocommand, actions_command)
3340 (start_tracing, stop_tracing): Constify.
3341 * value.c (init_if_undefined_command): Constify.
3342 * tui/tui-stack.c (tui_update_command): Constify.
3343 * tui/tui-win.c (tui_refresh_all_command)
3344 (tui_set_tab_width_command, tui_set_win_height_command)
3345 (tui_set_focus_command, tui_scroll_forward_command)
3346 (tui_scroll_backward_command, tui_scroll_left_command)
3347 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
3348 (tui_set_win_height): Constify.
3349 * tui/tui-layout.c (tui_layout_command): Constify.
3350 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
3351 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
3352 (proc_untrace_sysexit_cmd): Constify.
3353 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
3354 (threadset_test_cmd, threadlist_update_test_cmd)
3355 (threadalive_test): Constify.
3356 * objc-lang.c (print_object_command): Constify.
3357 * command.h (add_com): Constify.
3358 * cli/cli-dump.c (restore_command): Constify.
3359 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
3360 (help_command, complete_command, shell_command, edit_command)
3361 (list_command, disassemble_command, make_command)
3362 (apropos_command, alias_command): Constify.
3363 * cli/cli-script.c (document_command, define_command)
3364 (while_command, if_command, validate_comname): Constify.
3365 * cli/cli-decode.c (struct cmd_list_element): Change type of
3366 "fun".
3367 * target.c (do_monitor_command, flash_erase_command): Constify.
3368 * regcache.c (reg_flush_command): Constify.
3369 * reverse.c (reverse_step, reverse_next, reverse_stepi)
3370 (reverse_nexti, reverse_continue, reverse_finish)
3371 (save_bookmark_command, goto_bookmark_command)
3372 (exec_reverse_once): Constify.
3373 * python/python.c (python_interactive_command, python_command):
3374 Constify.
3375 * typeprint.c (ptype_command, whatis_command, whatis_exp):
3376 Constify.
3377 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
3378 * gcore.c (gcore_command): Constify.
3379
85c4be7c
TT
33802017-11-07 Tom Tromey <tom@tromey.com>
3381
3382 * printcmd.c (x_command): Call set_repeat_arguments.
3383 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
3384 * top.c (repeat_arguments): New global.
3385 (set_repeat_arguments): New function.
3386 (execute_command): Handle repeat_arguments.
3387 (show_commands): Calls set_repeat_arguments.
3388 * command.h (set_repeat_arguments): Declare.
3389
022643b4
TT
33902017-11-07 Tom Tromey <tom@tromey.com>
3391
3392 * stack.c (backtrace_command): Use std::string.
3393 (backtrace_command_1): Make "count_exp" const.
3394
5614fb77
TT
33952017-11-07 Tom Tromey <tom@tromey.com>
3396
3397 * source.c (directory_switch, mod_path, add_path): Constify.
3398 * defs.h (add_path, mod_path, directory_switch): Constify.
3399 * mi/mi-cmd-env.c (env_mod_path): Constify.
3400
6be9a197
TT
34012017-11-07 Tom Tromey <tom@tromey.com>
3402
3403 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
3404 (run_command_1, continue_command, step_1, jump_command)
3405 (signal_command, until_command, advance_command, finish_command)
3406 (attach_command): Update.
3407
c2252c0d
TT
34082017-11-07 Tom Tromey <tom@tromey.com>
3409
3410 * command.h (set_cmd_cfunc): Don't declare.
3411 * cli/cli-decode.c (set_cmd_cfunc): Now static.
3412
1ee870c5
TT
34132017-11-07 Tom Tromey <tom@tromey.com>
3414
3415 * stack.c (select_frame_command): Constify.
3416 * cli/cli-decode.c (add_com_suppress_notification): Constify.
3417 * command.h (add_com_suppress_notification): Constify.
3418
ee7ddd71
TT
34192017-11-07 Tom Tromey <tom@tromey.com>
3420
3421 * breakpoint.c (stop_command): Constify.
3422 * cli/cli-decode.c (struct cmd_list_element): Constify.
3423 * command.h (add_abbrev_prefix_cmd): Constify.
3424
95e95a6d
PA
34252017-11-07 Pedro Alves <palves@redhat.com>
3426
3427 * breakpoint.c (extract_bp_kind): New enum.
3428 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
3429 factored out from ...
3430 (extract_bp_number_and_location): ... here.
3431 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
3432
cc638e86
PA
34332017-11-07 Pedro Alves <palves@redhat.com>
3434
3435 * breakpoint.c (extract_bp_number_and_location): Change return
3436 type to void. Throw error instead of warning.
3437 (enable_disable_command): Adjust.
3438
d0fe4701
XR
34392017-11-07 Xavier Roirand <roirand@adacore.com>
3440 Pedro Alves <palves@redhat.com>
3441
3442 * breakpoint.c (map_breakpoint_number_range): New, factored out
3443 from ...
3444 (map_breakpoint_numbers): ... here.
3445 (find_location_by_number): Change parameters from string to
3446 breakpoint number and location.
3447 (extract_bp_number_and_location): New function.
3448 (enable_disable_bp_num_loc)
3449 (enable_disable_breakpoint_location_range)
3450 (enable_disable_command): New functions, factored out ...
3451 (enable_command, disable_command): ... these functions, and
3452 adjusted to support ranges.
3453 * NEWS: Document enable/disable breakpoint location range feature.
3454
635dc5b2
LM
34552017-11-06 Luis Machado <luis.machado@linaro.org>
3456
3457 * MAINTAINERS (Write After Approval): Update my e-mail address.
3458
556e5da5
PA
34592017-11-06 Pedro Alves <palves@redhat.com>
3460
3461 * gnu-nat.c (gnu_terminal_init): Delete.
3462 (gnu_target): Don't install gnu_terminal_init.
3463 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
3464 (child_terminal_init): ... this function.
3465
d1928160
PA
34662017-11-06 Pedro Alves <palves@redhat.com>
3467
3468 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
3469 sgtty.h.
3470 * config.in, configure: Regenerate.
3471
6aa899ce
PA
34722017-11-06 Pedro Alves <palves@redhat.com>
3473
3474 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
3475 (async_init_signals): Adjust.
3476 (handle_stop_sig): Rename to ...
3477 (handle_sigtstp): ... this.
3478 (async_stop_sig): Rename to ...
3479 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3480 SIGTSTP path.
3481 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3482 instead of STOP_SIGNAL thoughout.
3483 (handle_stop_sig): Rename to ...
3484 (handle_sigtstp): ... this.
3485 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3486
a94799ac
PA
34872017-11-06 Pedro Alves <palves@redhat.com>
3488
3489 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3490 longer set flags twice in row.
3491
726e1356
PA
34922017-11-06 Pedro Alves <palves@redhat.com>
3493
3494 * Makefile.in (SER_HARDWIRE): Update comment.
3495 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3496 * common/gdb_termios.h: Delete file.
3497 * common/job-control.c: Include termios.h and unistd.h instead of
3498 gdb_termios.h.
3499 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3500 check.
3501 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3502 Remove sgtty code.
3503 * configure.ac: No longer check for termio.h and sgtty.h.
3504 * configure: Regenerate.
3505 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3506 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3507 Replace PROCESS_GROUP_TYPE references with pid_t references
3508 throughout.
3509 (gdb_getpgrp): Delete.
3510 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3511 (child_terminal_inferior): Remove comment. Remove sgtty code.
3512 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3513 gdb_getpgrp. Use serial_set_tty_state instead aof
3514 serial_noflush_set_tty_state. Remove sgtty code.
3515 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3516 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3517 (inferior_process_group): Now returns pid_t.
3518 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3519 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3520 * ser-event.c (serial_event_ops): Update.
3521 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3522 (dos_ops): Update.
3523 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3524 * ser-pipe.c (pipe_ops): Update.
3525 * ser-tcp.c (tcp_ops): Update.
3526 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3527 HAVE_TERMIOS checks.
3528 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3529 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3530 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3531 assume termios.
3532 (hardwire_noflush_set_tty_state): Delete.
3533 (hardwire_print_tty_state, hardwire_drain_output)
3534 (hardwire_flush_output, hardwire_flush_input)
3535 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3536 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3537 code, and assume termios.
3538 (hardwire_ops): Update.
3539 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3540 * serial.c (serial_noflush_set_tty_state): Delete.
3541 * serial.h (serial_noflush_set_tty_state): Delete.
3542 (serial_ops::noflush_set_tty_state): Delete.
3543
1cfb73db
UW
35442017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3545
3546 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3547 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3548 (COMMON_OBS): Remove doublest.o and dfp.o.
3549 Do not build target-float.c (instead of doublest.c)
3550 with -Wformat-nonliteral.
3551
3552 * doublest.c: Remove file.
3553 * doublest.h: Remove file.
3554 * dfp.c: Remove file.
3555 * dfp.h: Remove file.
3556
3557 * target-float.c: Do not include "doublest.h" and "dfp.h".
3558 (DOUBLEST): Move here from doublest.h.
3559 (enum float_kind): Likewise.
3560 (FLOATFORMAT_CHAR_BIT): Likewise.
3561 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3562 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3563 (floatformat_precision): Likewise.
3564 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3565 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3566 Likewise.
3567 (host_float_format, host_double_format, host_long_double_format):
3568 Likewise.
3569 (floatformat_to_string, floatformat_from_string): Likewise.
3570 (floatformat_to_doublest): Likewise. Also, inline the original
3571 convert_floatformat_to_doublest.
3572 (floatformat_from_doublest): Likewise. Also, inline the original
3573 convert_floatformat_from_doublest.
3574
3575 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3576 (MAX_DECIMAL_STRING): Move here from dfp.c.
3577 (match_endianness): Likewise.
3578 (set_decnumber_context, decimal_check_errors): Likewise.
3579 (decimal_from_number, decimal_to_number): Likewise.
3580 (decimal_to_string, decimal_from_string): Likewise. Make static.
3581 (decimal_from_longest, decimal_from_ulongest): Likewise.
3582 (decimal_to_longest): Likewise.
3583 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3584 (decimal_convert): Likewise.
3585
b07e9c46
UW
35862017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3587
3588 * doublest.c: Do not include "gdbtypes.h".
3589 (extract_typed_floating): Remove.
3590 (store_typed_floating): Remove.
3591 (convert_typed_floating): Remove.
3592 * doublest.h (struct type): Remove.
3593 (DOUBLEST_PRINT_FORMAT): Remove.
3594 (DOUBLEST_SCAN_FORMAT): Remove.
3595 (extract_typed_floating): Remove.
3596 (store_typed_floating): Remove.
3597 (convert_typed_floating): Remove.
3598
3599 * dfp.c (decimal_from_doublest): Remove.
3600 (decimal_to_doublest): Remove.
3601 * dfp.h: Do not include "doublest.h".
3602 (decimal_from_doublest): Remove.
3603 (decimal_to_doublest): Remove.
3604
3605 * value.c: Do not include "doublest.h" and "dfp.h".
3606 (value_as_double): Remove.
3607 (unpack_double): Remove.
3608 (value_from_double): Remove.
3609 (value_from_decfloat): Remove.
3610 * value.h: Do not include "doublest.h".
3611 (value_as_double): Remove.
3612 (unpack_double): Remove.
3613 (value_from_double): Remove.
3614 (value_from_decfloat): Remove.
3615
3b2ca824
UW
36162017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3617
3618 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3619 (i386_extract_return_value): Use target_float_convert.
3620 (i386_store_return_value): Likewise.
3621 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3622 (i387_value_to_register): Likewise.
3623 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3624 (ia64_register_to_value): Use target_float_convert.
3625 (ia64_value_to_register): Likewise.
3626 (ia64_extract_return_value): Likewise.
3627 (ia64_store_return_value): Likewise.
3628 (ia64_push_dummy_call): Likewise.
3629 * m68k-tdep.c: Include "target-float.h".
3630 (m68k_register_to_value): Use target_float_convert.
3631 (m68k_value_to_register): Likewise.
3632 (m68k_svr4_extract_return_value): Likewise.
3633 (m68k_svr4_store_return_value): Likewise.
3634 * ppc-sysv-tdep.c: Include "target-float.h".
3635 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3636 (do_ppc_sysv_return_value): Likewise.
3637 (ppc64_sysv_abi_push_freg): Likewise.
3638 (ppc64_sysv_abi_return_value_base): Likewise.
3639 * rs6000-aix-tdep.c: Include "target-float.h".
3640 (rs6000_push_dummy_call): Use target_float_convert.
3641 (rs6000_return_value): Likewise.
3642 * rs6000-lynx178-tdep.c: Include "target-float.h".
3643 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3644 (rs6000_lynx178_return_value): Likewise.
3645 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3646 (rs6000_register_to_value): Use target_float_convert.
3647 (rs6000_value_to_register): Likewise.
3648 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3649 (arm_extract_return_value): Use target_float_convert.
3650 (arm_store_return_value): Likewise.
3651 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3652 (sh_register_convert_to_virtual): Use target_float_convert.
3653 (sh_register_convert_to_raw): Likewise.
3654 * sh64-tdep.c: Include "target-float.h".
3655 (sh64_extract_return_value): Use target_float_convert.
3656 (sh64_register_convert_to_virtual): Likewise.
3657 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3658
14ad9311
UW
36592017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3660
3661 * target-float.c (floatformat_to_host_double): New function.
3662 (floatformat_from_host_double): Likewise.
3663 (target_float_to_host_double): Likewise.
3664 (target_float_from_host_double): Likewise.
3665 * target-float.h (target_float_to_host_double): Add prototype.
3666 (target_float_from_host_double): Likewise.
3667
3668 * guile/scm-value.c: Include "target-float.h".
3669 (gdbscm_value_to_real): Use target_float_to_host_double.
3670 Handle integer source values via value_as_long.
3671 * guile/scm-math.c: Include "target-float.h". Do not include
3672 "doublest.h", "dfp.h", and "expression.h".
3673 (vlscm_convert_typed_number): Use target_float_from_host_double.
3674 (vlscm_convert_number): Likewise.
3675
3676 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3677 (convert_value_from_python): Use target_float_from_host_double.
3678
50eff16b
UW
36792017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3680
3681 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3682 (cast_from_fixed): Likewise.
3683 (ada_scaling_type): New function.
3684 (ada_delta): Return value instead of DOUBLEST. Perform target
3685 arithmetic instead of host arithmetic.
3686 (scaling_factor): Rename to ...
3687 (ada_scaling_factor) ... this. Make non-static. Return value instead
3688 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3689 (ada_fixed_to_float): Remove.
3690 (ada_float_to_fixed): Remove.
3691 * ada-lang.h (ada_fixed_to_float): Remove.
3692 (ada_float_to_fixed): Remove.
3693 (ada_delta): Return value instead of DOUBLEST.
3694 (ada_scaling_factor): Add prototype.
3695
3696 * ada-typeprint.c: Include "target-float.h".
3697 (print_fixed_point_type): Perform target arithmetic instead of
3698 host arithmetic.
3699 * ada-valprint.c: Include "target-float.h".
3700 (ada_val_print_num): Perform target arithmetic instead of
3701 host arithmetic for fixed-point types.
3702
66c02b9e
UW
37032017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3704
3705 * target-float.c: Include <math.h>.
3706 (floatformat_binop): New function.
3707 (floatformat_compare): Likewise.
3708 (target_float_binop): Likewise.
3709 (target_float_compare): Likewise.
3710 * target-float.h: Include "expression.h".
3711 (target_float_binop): Add prototype.
3712 (target_float_compare): Likewise.
3713
3714 * valarith.c: Do not include "doublest.h" and "dfp.h".
3715 Include "common/byte-vector.h".
3716 (value_args_as_decimal): Remove, replace by ...
3717 (value_args_as_target_float): ... this function. Handle both
3718 binary and decimal target floating-point formats.
3719 (scalar_binop): Handle both binary and decimal FP using
3720 value_args_as_target_float and target_float_binop.
3721 (value_equal): Handle both binary and decimal FP using
3722 value_args_as_target_float and target_float_compare.
3723 (value_less): Likewise.
3724 (value_pos): Handle all scalar types as simple copy.
3725 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3726 * dfp.c (decimal_binop): Throw error instead of internal_error
3727 when called with an unsupported operation code.
3728
f69fdf9b
UW
37292017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3730
3731 * target-float.c (target_float_to_string): New function.
3732 (target_float_from_string): New function.
3733 * target-float.h (target_float_to_string): Add prototype.
3734 (target_float_from_string): Add prototype.
3735
3736 * valprint.c: Include "target-float.h". Do not include
3737 "doublest.h" and "dfp.h".
3738 (print_floating): Use target_float_to_string.
3739 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3740 (printf_floating): Use target_float_to_string.
3741 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3742 (print_i387_value): Use target_float_to_string.
3743 * mips-tdep.c: Include "target-float.h".
3744 (mips_print_fp_register): Use target_float_to_string.
3745 * sh64-tdep.c: Include "target-float.h".
3746 (sh64_do_fp_register): Use target_float_to_string.
3747
3748 * parse.c: Include "target-float.h". Do not include
3749 "doublest.h" and "dfp.h".
3750 (parse_float): Use target_float_from_string.
3751 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3752 (define_symbol): Use target_float_from_string.
3753 * gdbarch-selftests.c: Include "target-float.h".
3754 (register_to_value_test): Use target_float_from_string.
3755
70100014
UW
37562017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3757
3758 * Makefile.c (SFILES): Add target-float.c.
3759 (HFILES_NO_SRCDIR): Add target-float.h.
3760 (COMMON_OBS): Add target-float.o.
3761 * target-float.h: New file.
3762 * target-float.c: New file.
3763
3764 * doublest.c (floatformat_classify): Fix detection of float_zero.
3765
3766 * gdbtypes.c (is_floating_type): New function.
3767 * gdbtypes.h (is_floating_type): Add prototype.
3768
3769 * value.c: Do not include "floatformat.h".
3770 (unpack_double): Use target_float_is_valid.
3771 (is_floating_value): New function.
3772 * value.h (is_floating_value): Add prototype-
3773
3774 * valarith.c: Include "target-float.h".
3775 (value_logical_not): Use target_float_is_zero.
3776
3777 * python/py-value.c: Include "target-float.h".
3778 (valpy_nonzero): Use target_float_is_zero.
3779
ab4b1c46
TT
37802017-11-04 Tom Tromey <tom@tromey.com>
3781
3782 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3783
454dafbd
TT
37842017-11-04 Tom Tromey <tom@tromey.com>
3785
3786 * breakpoint.c (set_momentary_breakpoint): Return
3787 breakpoint_up.
3788 (until_break_command): Update.
3789 (new_until_break_fsm): Change argument types to
3790 breakpoint_up.
3791 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3792 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3793 Remove.
3794 * infcmd.c (finish_forward): Update.
3795 * breakpoint.h (set_momentary_breakpoint)
3796 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3797 (make_cleanup_delete_breakpoint): Remove.
3798 (struct breakpoint_deleter): New.
3799 (breakpoint_up): New typedef.
3800 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3801 (insert_exception_resume_breakpoint): Update.
3802 (insert_exception_resume_from_probe): Update.
3803 (insert_longjmp_resume_breakpoint): Update.
3804 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3805 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3806 * infcall.c (call_function_by_hand_dummy): Update
3807
331b71e5
TT
38082017-11-04 Tom Tromey <tom@tromey.com>
3809
3810 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3811
9f584b37
TT
38122017-11-04 Tom Tromey <tom@tromey.com>
3813
3814 * linux-tdep.c (linux_core_info_proc_mappings): Use
3815 gdb::def_vector.
3816 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3817 "size" argument.
3818 (linux_corefile_thread): Update.
3819 (linux_make_corefile_notes): Remove unused variable.
3820
779bc38e
TT
38212017-11-04 Tom Tromey <tom@tromey.com>
3822
3823 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
3824 gdb::byte_vector.
3825
ed2b3126
TT
38262017-11-04 Tom Tromey <tom@tromey.com>
3827
3828 * objfiles.c (do_free_objfile_cleanup): Remove.
3829 * compile/compile-object-load.c (compile_object_load): Update.
3830 * objfiles.h (make_cleanup_free_objfile): Remove.
3831
7f6743fd
TT
38322017-11-04 Tom Tromey <tom@tromey.com>
3833
3834 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
3835 (adi_read_versions): Change "tags" to "gdb_byte *".
3836 (adi_print_versions): Likewise.
3837
c80049d3
TT
38382017-11-04 Tom Tromey <tom@tromey.com>
3839
3840 * breakpoint.c
3841 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
3842 from start_rbreak_breakpoints.
3843 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
3844 * breakpoint.h (class scoped_rbreak_breakpoints): New.
3845 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
3846 * symtab.c (do_end_rbreak_breakpoints): Remove.
3847 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
3848
167b0be1
TT
38492017-11-04 Tom Tromey <tom@tromey.com>
3850
3851 * cp-namespace.c (reset_directive_searched): Remove.
3852 (cp_lookup_symbol_via_imports): Use scoped_restore.
3853 * cp-support.c (reset_directive_searched): Remove.
3854 (make_symbol_overload_list_using): Use scoped_restore.
3855 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
3856 (reset_directive_searched): Remove.
3857
5eae7aea
TT
38582017-11-04 Tom Tromey <tom@tromey.com>
3859
3860 * symfile.c (find_separate_debug_file_by_debuglink): Use
3861 unique_xmalloc_ptr.
3862
c6bcad5f
TT
38632017-11-04 Tom Tromey <tom@tromey.com>
3864
3865 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
3866 type of "info".
3867 (compute_stack_depth): Likewise.
3868 (do_compile_dwarf_expr_to_c): Use std::vector.
3869
20dcd8ca
TT
38702017-11-04 Tom Tromey <tom@tromey.com>
3871
3872 * compile/compile-object-load.c (link_callbacks_einfo): Use
3873 std::string.
3874
33c7c59d
TT
38752017-11-04 Tom Tromey <tom@tromey.com>
3876
3877 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3878 Use scoped_free_pendings.
3879 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
3880 scoped_free_pendings.
3881 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
3882 (xcoff_initial_scan): Likewise.
3883 * buildsym.c (reset_symtab_globals): Update comment.
3884 (scoped_free_pendings): Rename from really_free_pendings.
3885 (prepare_for_building): Update comment.
3886 (buildsym_init): Likewise.
3887 * buildsym.h (class scoped_free_pendings): New class.
3888 (really_free_pendings): Don't declare.
3889
67fa57cf
UW
38902017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
3891
3892 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
3893 output when converting a zero value to a special byteorder format.
3894
f26ae15b
YQ
38952017-11-02 Yao Qi <yao.qi@linaro.org>
3896
3897 * frame.c (do_frame_register_read): Remove aspace.
3898 * jit.c (jit_frame_sniffer): Likwise.
3899 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3900 * regcache.c (regcache::regcache): Pass nullptr.
3901 (regcache_print): Caller updated.
3902 * regcache.h (regcache::regcache): Remove one constructor
3903 parameter aspace.
3904
6c6e9412
YQ
39052017-11-02 Yao Qi <yao.qi@linaro.org>
3906
3907 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
3908
8b86c959
YQ
39092017-11-02 Yao Qi <yao.qi@linaro.org>
3910
3911 * breakpoint.c (insert_single_step_breakpoints): Update.
3912 * frame.c (struct frame_info) <aspace>: Add const.
3913 (frame_save_as_regcache): Add const.
3914 (get_frame_address_space): Return const address_space *.
3915 * frame.h (get_frame_address_space): Update declaration.
3916 * infrun.c (struct step_over_info) <aspace>: Add const.
3917 (set_step_over_info): Make aspace const.
3918 (displaced_step_prepare_throw): Change variable const.
3919 (resume): Likewise.
3920 (proceed): Likewise.
3921 (adjust_pc_after_break): Likewise.
3922 (save_waitstatus): Likewise.
3923 (handle_signal_stop): Likewise.
3924 (keep_going_pass_signal): Likewise.
3925 * jit.c (jit_frame_sniffer): Add const.
3926 * mips-tdep.c (mips_single_step_through_delay): Likewise.
3927 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3928 * record-full.c (record_full_wait_1): Likewise.
3929 * regcache.c (regcache::regcache): Change parameter to const.
3930 * regcache.h (regcache::regcache): Likewise.
3931 (regcache::aspace): Return const address_space *.
3932 (regcache) <m_aspace>: Add const.
3933
a01bda52
YQ
39342017-11-02 Yao Qi <yao.qi@linaro.org>
3935
3936 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
3937 * frame.c (create_sentinel_frame): Likewise.
3938 * infrun.c (displaced_step_prepare_throw): Likewise.
3939 (resume): Likewise.
3940 (thread_still_needs_step_over_bp): Likewise.
3941 (proceed): Likewise.
3942 (do_target_wait): Likewise.
3943 (adjust_pc_after_break): Likewise.
3944 (handle_syscall_event): Likewise.
3945 (save_waitstatus): Likewise.
3946 (handle_inferior_event_1): Likewise.
3947 (handle_signal_stop): Likewise.
3948 (keep_going_pass_signal): Likewise.
3949 * linux-nat.c (status_callback): Likewise.
3950 (save_stop_reason): Likewise.
3951 (resume_stopped_resumed_lwps): Likewise.
3952 * record-full.c (record_full_exec_insn): Likewise.
3953 (record_full_wait_1): Likewise.
3954 * regcache.c (get_regcache_aspace): Remove.
3955 * regcache.h (get_regcache_aspace): Remove.
3956
d999647b
YQ
39572017-11-02 Yao Qi <yao.qi@linaro.org>
3958
3959 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
3960 (init_regcache_descr): Use gdbarch_num_regs.
3961 (regcache::regcache): Likewise.
3962 (regcache::get_register_status): Likewise.
3963 (regcache::assert_raw_regnum): Likewise.
3964 (regcache::cooked_read): Likewise.
3965 (regcache::cooked_read_value): Likewise.
3966 (regcache::cooked_write): Likewise.
3967 (regcache::dump): Likewise.
3968 (regcache::num_raw_registers): New method.
3969 * regcache.h (class regcache) <num_raw_registers>: New.
3970
4e888c28
YQ
39712017-11-02 Yao Qi <yao.qi@linaro.org>
3972
3973 * regcache.c (regcache::assert_regnum): New method.
3974 (regcache::invalidate): Call assert_regnum.
3975 (regcache::raw_update): Likewise.
3976 (regcache::raw_write): Likewise.
3977 (regcache::raw_read_part): Likewise.
3978 (regcache::raw_write_part): Likewise.
3979 (regcache::raw_supply): Likewise.
3980 (regcache::raw_supply_integer): Likewise.
3981 (regcache::raw_supply_zeroed): Likewise.
3982 (regcache::raw_collect): Likewise.
3983 (regcache::raw_collect_integer): Likewise.
3984 * regcache.h (regcache::assert_regnum): Declare.
3985
2e1b49b3
YQ
39862017-11-02 Yao Qi <yao.qi@linaro.org>
3987
3988 * regcache.c (regcache::dump): Remove code.
3989
6c5218df
YQ
39902017-11-02 Yao Qi <yao.qi@linaro.org>
3991
3992 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
3993 Remove.
3994 <sizeof_cooked_register_status>: Remove.
3995 (init_regcache_descr): Update.
3996 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
3997 (regcache::save): Likewise.
3998 (regcache::dump): Likewise.
3999
dcc31d28
JB
40002017-11-01 James Bowman <james.bowman@ftdichip.com>
4001
4002 * ft32-tdep.c (ft32_fetch_instruction): New function.
4003 (ft32_analyze_prologue): Use ft32_fetch_instruction().
4004
3a87ae65
SM
40052017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
4006
4007 * cli/cli-script.c (execute_control_command): Rename to ...
4008 (execute_control_command_1): ... this.
4009 (execute_control_command): New function.
4010
09b847f3
SM
40112017-10-31 Simon Marchi <simon.marchi@ericsson.com>
4012
4013 * tracepoint.c (tfind_command): Remove const_cast.
4014
f871c485
MG
40152017-10-30 Mike Gulick <mgulick@mathworks.com>
4016
4017 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
4018
b020ff80
SM
40192017-10-30 Simon Marchi <simon.marchi@ericsson.com>
4020
4021 * common/common-utils.h (in_inclusive_range): New function.
4022 * arm-tdep.c (arm_record_extension_space): Use
4023 in_inclusive_range.
4024 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
4025 * cris-tdep.c (cris_spec_reg_applicable): Use
4026 in_inclusive_range.
4027
1b81856f
PA
40282017-10-30 Pedro Alves <palves@redhat.com>
4029 Simon Marchi <simon.marchi@ericsson.com>
4030
4031 * remote.c (remote_set_syscall_catchpoint): Build a std::string
4032 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
4033
31b833b3
PA
40342017-10-30 Pedro Alves <palves@redhat.com>
4035
4036 * common/common-utils.c (string_appendf, string_vappendf): New
4037 functions.
4038 * common/common-utils.h (string_appendf, string_vappendf): New
4039 declarations.
4040 * unittests/common-utils-selftests.c (string_appendf_func)
4041 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
4042 (string_vappendf_tests): New functions.
4043 (_initialize_common_utils_selftests): Register "string_appendf" and
4044 "string_vappendf tests".
4045
4a250334
PA
40462017-10-30 Pedro Alves <palves@redhat.com>
4047
4048 * unittests/common-utils-selftests.c (format_func): New typedef.
4049 (string_printf_tests, string_vprintf_tests): Tests factored out
4050 and merged to ...
4051 (test_format_func): ... this new function.
4052 (string_printf_tests, string_vprintf_tests): Reimplement on top of
4053 test_format_func.
4054
16c5c17e
SM
40552017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4056
4057 * darwin-nat.c: Remove include of gdb.h.
4058
7ca51576
SM
40592017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4060
4061 * xtensa-xtregs.c: Fix formatting issues.
4062
c1342859
SM
40632017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4064
4065 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
4066
484d8d36
MD
40672017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
4068
4069 PR python/21213
4070 * python/py-infthread.c (thpy_get_inferior): Increment reference
4071 of inferior before returning it.
4072
b5540b5f
SM
40732017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4074
4075 * unittests/common-utils-selftests.c (format): Add
4076 ATTRIBUTE_PRINTF.
4077
5a9dcda1
SM
40782017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4079
4080 * xml-syscall.c (struct syscall_desc): Add constructor.
4081 <name>: Change type to std::string.
4082 (syscall_desc_up): New typedef.
4083 (syscall_desc_p): Remove typeder.
4084 (DEF_VEC_P(syscall_desc_p)): Remove.
4085 (struct syscall_group_desc): Add constructor.
4086 <name>: Change type to std::string.
4087 <syscalls>: Change type to std::vector.
4088 (syscall_group_desc_up): New typedef.
4089 (syscall_group_desc_p): Remove typedef.
4090 (DEF_VEC_P(syscall_group_desc_p)): Remove.
4091 (struct syscalls_info) <syscalls>: Change type to std::vector of
4092 unique_ptr.
4093 <groups>: Likewise.
4094 <my_gdb_datadir>: Change type to std::string.
4095 (syscalls_info_up): New typedef.
4096 (allocate_syscalls_info): Remove.
4097 (syscalls_info_free_syscalls_desc): Remove.
4098 (syscalls_info_free_syscall_group_desc): Remove.
4099 (free_syscalls_info): Remove.
4100 (make_cleanup_free_syscalls_info): Remove.
4101 (syscall_group_create_syscall_group_desc): Adjust.
4102 (syscall_group_add_syscall): Adjust.
4103 (syscall_create_syscall_desc): Adjust.
4104 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
4105 (init_syscalls_info): Adjust.
4106 (syscall_group_get_group_by_name): Adjust.
4107 (xml_get_syscall_number): Adjust.
4108 (xml_get_syscall_name): Adjust.
4109 (xml_list_of_syscalls): Adjust.
4110 (xml_list_syscalls_by_group): Adjust.
4111 (xml_list_of_groups): Adjust.
4112
45461e0d
SM
41132017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4114
4115 * probe.h: Don't include gdb_vecs.h.
4116 (DEF_VEC_P (probe_p)): Remove.
4117 (find_probes_in_objfile): Return an std::vector.
4118 * probe.c (find_probes_in_objfile): Likewise.
4119 * breakpoint.c (breakpoint_objfile_data)
4120 <longjmp_probes>: Change type to std::vector.
4121 <exception_probes>: Likewise.
4122 (free_breakpoint_probes): Don't manually free vectors.
4123 (create_longjmp_master_breakpoint): Adjust.
4124 (create_exception_master_breakpoint): Adjust.
4125 * solib-svr4.c (svr4_create_probe_breakpoints): Change
4126 parameter type, adjust.
4127 (svr4_create_solib_event_breakpoints): Adjust.
4128
43dce439
SM
41292017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4130
4131 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
4132 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
4133 with new.
4134 (free_breakpoint_probes): Rename to ...
4135 (free_breakpoint_objfile_data): ... this, and call delete on
4136 bp_objfile_data..
4137
6a1b9516
SM
41382017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4139
4140 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
4141 (loaded_script_ptr): Remove typedef.
4142 (DEF_VEC_P (loaded_script_ptr)): Remove.
4143 (struct collect_matching_scripts_data): Add constructor.
4144 <scripts_p>: Change type to (pointer to) std::vector.
4145 (collect_matching_scripts_data): Adjust.
4146 (sort_scripts_by_name): Make suitable for std::sort.
4147 (print_scripts): Don't sort vector, adjust to std::vector.
4148 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
4149
593e3209
SM
41502017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4151
4152 * symfile.c (filename_language): Make struct, not typedef. Add
4153 constructor.
4154 <ext>: Change type to std::string.
4155 (DEF_VEC_O (filename_language)): Remove.
4156 (filename_language_table): Change type to std::vector.
4157 (add_filename_language): Adjust.
4158 (set_ext_lang_command): Adjust.
4159 (info_ext_lang_command): Adjust.
4160 (deduce_language_from_filename): Adjust.
4161 (class scoped_restore_filename_language_table): Remove.
4162 (test_filename_language): Use scoped_restore.
4163 (test_set_ext_lang_command): Use scoped_restore, adjust to
4164 std::vector change.
4165
32fa66eb
SM
41662017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4167
4168 * symfile.c: Include selftest.h.
4169 (class scoped_restore_filename_language_table): New.
4170 (test_filename_language): New test.
4171 (test_set_ext_lang_command): New test.
4172 (_initialize_symfile): Register tests.
4173
4a27f119
KS
41742017-10-27 Keith Seitz <keiths@redhat.com>
4175
4176 * breakpoint.c (print_breakpoint_location): Use the symbol saved
4177 in the bp_location, falling back to find_pc_sect_function when
4178 needed.
4179 (add_location_to_breakpoint): Save sal->symbol.
4180 * breakpoint.h (struct bp_location) <symbol>: New field.
4181 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
4182 * symtab.h (struct symtab_and_line) <symbol>: New field.
4183
a43f3893
PF
41842017-10-26 Patrick Frants <osscontribute@gmail.com>
4185
7453e6b2 4186 PR gdb/13669
a43f3893
PF
4187 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
4188 to rewind obstack.
4189
23cc4e1b
PA
41902017-10-26 Pedro Alves <palves@redhat.com>
4191
4192 * remote.c (remote_async_terminal_ours_p): Delete.
4193 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
4194 Remove references to 'remote_async_terminal_ours_p'.
4195
6abc18bb
YQ
41962017-10-26 Yao Qi <yao.qi@linaro.org>
4197
4198 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
4199
bd522513
YQ
42002017-10-26 Yao Qi <yao.qi@linaro.org>
4201
4202 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
4203 aspace const.
4204 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
4205 Likewise.
4206 * breakpoint.c (bpstat_check_location): Remove cast.
4207 (breakpoint_hit_catch_fork): Make aspce const.
4208 (breakpoint_hit_catch_solib): Likewise.
4209 (breakpoint_hit_catch_exec): Likewise.
4210 (breakpoint_hit_ranged_breakpoint): Likewise.
4211 (breakpoint_hit_watchpoint): Likewise.
4212 (base_breakpoint_breakpoint_hit): Likewise.
4213 (bkpt_breakpoint_hit): Likewise.
4214 (dprintf_breakpoint_hit): Likewise.
4215 (tracepoint_breakpoint_hit): Likewise.
4216 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
4217
accd0bcd
YQ
42182017-10-26 Yao Qi <yao.qi@linaro.org>
4219
4220 * breakpoint.c (breakpoint_location_address_match): Change
4221 "struct address_space *" to "const address_space".
4222 (breakpoint_location_address_range_overlap): Likewise.
4223 (breakpoint_here_p): Likewise.
4224 (breakpoint_in_range_p): Likewise.
4225 (moribund_breakpoint_here_p): Likewise.
4226 (bp_location_inserted_here_p): Likewise.
4227 (software_breakpoint_inserted_here_p): Likewise.
4228 (hardware_breakpoint_inserted_here_p): Likewise.
4229 (hardware_watchpoint_inserted_in_range): Likewise.
4230 (bpstat_check_location): Likewise.
4231 (bpstat_stop_status): Likewise.
4232 (breakpoint_address_match): Likewise.
4233 (breakpoint_address_match_range): Likewise.
4234 (breakpoint_location_address_match): Likewise.
4235 (breakpoint_location_address_range_overlap): Likewise.
4236 (insert_single_step_breakpoint): Likewise.
4237 (breakpoint_has_location_inserted_here): Likewise.
4238 (single_step_breakpoint_inserted_here_p): Likewise.
4239 (pc_at_non_inline_function): Likewise.
4240 * breakpoint.h (bpstat_stop_status): Update declaration.
4241 (breakpoint_here_p): Likewise.
4242 (breakpoint_in_range_p): Likewise.
4243 (moribund_breakpoint_here_p): Likewise.
4244 (breakpoint_inserted_here_p): Likewise.
4245 (software_breakpoint_inserted_here_p): Likewise.
4246 (hardware_breakpoint_inserted_here_p): Likewise.
4247 (breakpoint_has_location_inserted_here): Likewise.
4248 (single_step_breakpoint_inserted_here_p): Likewise.
4249 (hardware_watchpoint_inserted_in_range): Likewise.
4250 (breakpoint_address_match): Likewise.
4251 (insert_single_step_breakpoint): Likewise.
4252 (pc_at_non_inline_function): Likewise.
4253 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
4254 * record.c (record_check_stopped_by_breakpoint): Likewise.
4255 * record.h (record_check_stopped_by_breakpoint): Likewise.
4256 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
4257
ac7936df
YQ
42582017-10-25 Yao Qi <yao.qi@linaro.org>
4259
4260 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
4261 regcache->arch () instead get_regcache_arch.
4262 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
4263 Likewise.
4264 (aarch64_fbsd_store_inferior_registers): Likewise.
4265 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
4266 (store_gregs_to_thread): Likewise.
4267 (fetch_fpregs_from_thread): Likewise.
4268 (store_fpregs_to_thread): Likewise.
4269 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
4270 (aarch64_store_return_value): Likewise.
4271 (aarch64_software_single_step): Likewise.
4272 * aix-thread.c (aix_thread_wait): Likewise.
4273 (supply_reg32): Likewise.
4274 (supply_sprs64): Likewise.
4275 (supply_sprs32): Likewise.
4276 (fill_gprs64): Likewise.
4277 (fill_gprs32): Likewise.
4278 (fill_sprs64): Likewise.
4279 (fill_sprs32): Likewise.
4280 (store_regs_user_thread): Likewise.
4281 (store_regs_kernel_thread): Likewise.
4282 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
4283 (alphabsd_store_inferior_registers): Likewise.
4284 * alpha-tdep.c (alpha_extract_return_value): Likewise.
4285 (alpha_store_return_value): Likewise.
4286 (alpha_deal_with_atomic_sequence): Likewise.
4287 (alpha_next_pc): Likewise.
4288 (alpha_software_single_step): Likewise.
4289 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
4290 (amd64bsd_store_inferior_registers): Likewise.
4291 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
4292 Likewise.
4293 (amd64_linux_store_inferior_registers): Likewise.
4294 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
4295 (amd64_collect_native_gregset): Likewise.
4296 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
4297 (amd64obsd_collect_uthread): Likewise.
4298 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
4299 (amd64_collect_fpregset): Likewise.
4300 (amd64_supply_fxsave): Likewise.
4301 (amd64_supply_xsave): Likewise.
4302 (amd64_collect_fxsave): Likewise.
4303 (amd64_collect_xsave): Likewise.
4304 * arc-tdep.c (arc_write_pc): Likewise.
4305 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
4306 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
4307 (arm_fbsd_store_inferior_registers): Likewise.
4308 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
4309 (store_vfp_regs): Likewise.
4310 (arm_linux_fetch_inferior_registers): Likewise.
4311 (arm_linux_store_inferior_registers): Likewise.
4312 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
4313 (arm_linux_sigreturn_next_pc): Likewise.
4314 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
4315 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
4316 (fetch_register): Likewise.
4317 (store_register): Likewise.
4318 * arm-tdep.c (arm_is_thumb): Likewise.
4319 (displaced_in_arm_mode): Likewise.
4320 (bx_write_pc): Likewise.
4321 (arm_get_next_pcs_addr_bits_remove): Likewise.
4322 (arm_software_single_step): Likewise.
4323 (arm_extract_return_value): Likewise.
4324 (arm_store_return_value): Likewise.
4325 (arm_write_pc): Likewise.
4326 * bfin-tdep.c (bfin_extract_return_value): Likewise.
4327 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
4328 (bsd_uthread_store_registers): Likewise.
4329 * core-regset.c (fetch_core_registers): Likewise.
4330 * corelow.c (get_core_registers): Likewise.
4331 * cris-tdep.c (cris_store_return_value): Likewise.
4332 (cris_extract_return_value): Likewise.
4333 (find_step_target): Likewise.
4334 (find_step_target): Likewise.
4335 (cris_software_single_step): Likewise.
4336 * ctf.c (ctf_fetch_registers): Likewise.
4337 * darwin-nat.c (cancel_breakpoint): Likewise.
4338 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
4339 * frv-tdep.c (frv_extract_return_value): Likewise.
4340 * ft32-tdep.c (ft32_store_return_value): Likewise.
4341 (ft32_extract_return_value): Likewise.
4342 * go32-nat.c (fetch_register): Likewise.
4343 (go32_fetch_registers): Likewise.
4344 (go32_store_registers): Likewise.
4345 (store_register): Likewise.
4346 * h8300-tdep.c (h8300_extract_return_value): Likewise.
4347 (h8300_store_return_value): Likewise.
4348 * hppa-linux-nat.c (fetch_register): Likewise.
4349 (store_register): Likewise.
4350 (hppa_linux_fetch_inferior_registers): Likewise.
4351 (hppa_linux_store_inferior_registers): Likewise.
4352 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
4353 (i386_darwin_store_inferior_registers): Likewise.
4354 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
4355 (gnu_store_registers): Likewise.
4356 * i386-linux-nat.c (fetch_register): Likewise.
4357 (store_register): Likewise.
4358 (supply_gregset): Likewise.
4359 (fill_gregset): Likewise.
4360 (i386_linux_fetch_inferior_registers): Likewise.
4361 (i386_linux_store_inferior_registers): Likewise.
4362 (i386_linux_resume): Likewise.
4363 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
4364 Likewise.
4365 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
4366 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
4367 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
4368 (i386obsd_collect_uthread): Likewise.
4369 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4370 (i386_supply_gregset): Likewise.
4371 (i386_collect_gregset): Likewise.
4372 (i386_supply_fpregset): Likewise.
4373 (i386_collect_fpregset): Likewise.
4374 (i386_mpx_bd_base): Likewise.
4375 * i386-v4-nat.c (supply_fpregset): Likewise.
4376 (fill_fpregset): Likewise.
4377 * i387-tdep.c (i387_supply_fsave): Likewise.
4378 (i387_collect_fsave): Likewise.
4379 (i387_supply_fxsave): Likewise.
4380 (i387_collect_fxsave): Likewise.
4381 (i387_supply_xsave): Likewise.
4382 (i387_collect_xsave): Likewise.
4383 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
4384 (ia64_linux_store_registers): Likewise.
4385 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
4386 (ia64_extract_return_value): Likewise.
4387 (ia64_store_return_value): Likewise.
4388 (find_func_descr): Likewise.
4389 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
4390 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
4391 (inf_ptrace_store_registers): Likewise.
4392 * infrun.c (use_displaced_stepping): Likewise.
4393 (displaced_step_prepare_throw): Likewise.
4394 (resume): Likewise.
4395 (proceed): Likewise.
4396 (do_target_wait): Likewise.
4397 (adjust_pc_after_break): Likewise.
4398 (handle_inferior_event_1): Likewise.
4399 (handle_signal_stop): Likewise.
4400 (save_infcall_suspend_state): Likewise.
4401 (restore_infcall_suspend_state): Likewise.
4402 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
4403 * jit.c (jit_frame_prev_register): Likewise.
4404 * linux-nat.c (save_stop_reason): Likewise.
4405 (linux_nat_wait_1): Likewise.
4406 (resume_stopped_resumed_lwps): Likewise.
4407 * linux-record.c (record_linux_sockaddr): Likewise.
4408 (record_linux_msghdr): Likewise.
4409 (record_linux_system_call): Likewise.
4410 * linux-tdep.c (linux_collect_thread_registers): Likewise.
4411 * lm32-tdep.c (lm32_extract_return_value): Likewise.
4412 (lm32_store_return_value): Likewise.
4413 * m32c-tdep.c (m32c_read_flg): Likewise.
4414 (m32c_pseudo_register_read): Likewise.
4415 (m32c_pseudo_register_write): Likewise.
4416 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
4417 (m32r_linux_collect_gregset): Likewise.
4418 * m32r-tdep.c (m32r_store_return_value): Likewise.
4419 (m32r_extract_return_value): Likewise.
4420 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
4421 (m68kbsd_collect_fpregset): Likewise.
4422 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
4423 * m68k-linux-nat.c (fetch_register): Likewise.
4424 (old_fetch_inferior_registers): Likewise.
4425 (old_store_inferior_registers): Likewise.
4426 (store_regs): Likewise.
4427 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
4428 (m68k_svr4_store_return_value): Likewise.
4429 * m88k-tdep.c (m88k_store_arguments): Likewise.
4430 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
4431 (mi_cmd_data_write_register_values): Likewise.
4432 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
4433 (mips_fbsd_store_inferior_registers): Likewise.
4434 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
4435 (mips_fbsd_supply_gregs): Likewise.
4436 (mips_fbsd_collect_fpregs): Likewise.
4437 (mips_fbsd_collect_gregs): Likewise.
4438 (mips_fbsd_supply_fpregset): Likewise.
4439 (mips_fbsd_collect_fpregset): Likewise.
4440 (mips_fbsd_supply_gregset): Likewise.
4441 (mips_fbsd_collect_gregset): Likewise.
4442 * mips-linux-nat.c (supply_gregset): Likewise.
4443 (fill_gregset): Likewise.
4444 (supply_fpregset): Likewise.
4445 (fill_fpregset): Likewise.
4446 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
4447 (mips_fill_gregset): Likewise.
4448 (mips_supply_fpregset): Likewise.
4449 (mips_fill_fpregset): Likewise.
4450 (mips64_supply_gregset): Likewise.
4451 (micromips_linux_sigframe_validate): Likewise.
4452 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
4453 (mipsnbsd_fetch_inferior_registers): Likewise.
4454 (mipsnbsd_store_inferior_registers): Likewise.
4455 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
4456 (mipsnbsd_supply_gregset): Likewise.
4457 (mipsnbsd_iterate_over_regset_sections): Likewise.
4458 (mipsnbsd_supply_reg): Likewise.
4459 (mipsnbsd_supply_fpreg): Likewise.
4460 * mips-tdep.c (mips_in_frame_stub): Likewise.
4461 (mips_dummy_id): Likewise.
4462 (is_octeon_bbit_op): Likewise.
4463 (micromips_bc1_pc): Likewise.
4464 (extended_mips16_next_pc): Likewise.
4465 (mips16_next_pc): Likewise.
4466 (deal_with_atomic_sequence): Likewise.
4467 * moxie-tdep.c (moxie_process_readu): Likewise.
4468 * nios2-tdep.c (nios2_get_next_pc): Likewise.
4469 * nto-procfs.c (procfs_store_registers): Likewise.
4470 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
4471 (ppcfbsd_store_inferior_registers): Likewise.
4472 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
4473 (fetch_altivec_register): Likewise.
4474 (get_spe_registers): Likewise.
4475 (fetch_spe_register): Likewise.
4476 (fetch_altivec_registers): Likewise.
4477 (fetch_all_gp_regs): Likewise.
4478 (fetch_all_fp_regs): Likewise.
4479 (store_vsx_register): Likewise.
4480 (store_altivec_register): Likewise.
4481 (set_spe_registers): Likewise.
4482 (store_spe_register): Likewise.
4483 (store_altivec_registers): Likewise.
4484 (store_all_gp_regs): Likewise.
4485 (store_all_fp_regs): Likewise.
4486 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4487 (ppc_linux_collect_gregset): Likewise.
4488 (ppc_canonicalize_syscall): Likewise.
4489 (ppc_linux_record_signal): Likewise.
4490 (ppu2spu_prev_register): Likewise.
4491 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4492 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4493 (ppcobsd_store_registers): Likewise.
4494 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4495 Likewise.
4496 (ppc_ravenscar_generic_store_registers): Likewise.
4497 * procfs.c (procfs_fetch_registers): Likewise.
4498 (procfs_store_registers): Likewise.
4499 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4500 (ravenscar_store_registers): Likewise.
4501 (ravenscar_prepare_to_store): Likewise.
4502 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4503 * record-full.c (record_full_wait_1): Likewise.
4504 (record_full_registers_change): Likewise.
4505 (record_full_store_registers): Likewise.
4506 (record_full_core_fetch_registers): Likewise.
4507 (record_full_save): Likewise.
4508 (record_full_goto_insn): Likewise.
4509 * regcache.c (regcache_register_size): Likewise.
4510 (get_regcache_arch): Remove.
4511 (regcache_read_pc): Likewise.
4512 * regcache.h (get_regcache_arch): Remove.
4513 * remote-sim.c (gdbsim_fetch_register): Likewise.
4514 (gdbsim_store_register): Likewise.
4515 * remote.c (fetch_register_using_p): Likewise.
4516 (send_g_packet): Likewise.
4517 (remote_prepare_to_store): Likewise.
4518 (store_registers_using_G): Likewise.
4519 * reverse.c (save_bookmark_command): Likewise.
4520 (goto_bookmark_command): Likewise.
4521 * rs6000-aix-tdep.c (branch_dest): Likewise.
4522 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4523 (fetch_register): Likewise.
4524 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4525 (ppc_collect_reg): Likewise.
4526 (ppc_collect_gregset): Likewise.
4527 (ppc_collect_fpregset): Likewise.
4528 (ppc_collect_vsxregset): Likewise.
4529 (ppc_collect_vrregset): Likewise.
4530 (ppc_displaced_step_hw_singlestep): Likewise.
4531 (rs6000_pseudo_register_read): Likewise.
4532 (rs6000_pseudo_register_write): Likewise.
4533 * s390-linux-nat.c (supply_gregset): Likewise.
4534 (fill_gregset): Likewise.
4535 (s390_linux_fetch_inferior_registers): Likewise.
4536 * s390-linux-tdep.c (s390_write_pc): Likewise.
4537 (s390_software_single_step): Likewise.
4538 (s390_all_but_pc_registers_record): Likewise.
4539 (s390_linux_syscall_record): Likewise.
4540 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4541 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4542 (shnbsd_store_inferior_registers): Likewise.
4543 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4544 (sh_extract_return_value_fpu): Likewise.
4545 (sh_store_return_value_nofpu): Likewise.
4546 (sh_corefile_supply_regset): Likewise.
4547 (sh_corefile_collect_regset): Likewise.
4548 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4549 (sh64_store_return_value): Likewise.
4550 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4551 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4552 (sparc_store_inferior_registers): Likewise.
4553 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4554 (sparc_ravenscar_prepare_to_store): Likewise.
4555 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4556 (sparc_analyze_control_transfer): Likewise.
4557 (sparc_step_trap): Likewise.
4558 (sparc_software_single_step): Likewise.
4559 (sparc32_gdbarch_init): Likewise.
4560 (sparc_supply_rwindow): Likewise.
4561 (sparc_collect_rwindow): Likewise.
4562 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4563 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4564 (sparc64nbsd_collect_gregset): Likewise.
4565 (sparc64nbsd_supply_fpregset): Likewise.
4566 (sparc64nbsd_collect_fpregset): Likewise.
4567 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4568 (sparc64_supply_gregset): Likewise.
4569 (sparc64_collect_gregset): Likewise.
4570 (sparc64_supply_fpregset): Likewise.
4571 (sparc64_collect_fpregset): Likewise.
4572 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4573 * spu-tdep.c (spu_unwind_sp): Likewise.
4574 (spu2ppu_prev_register): Likewise.
4575 (spu_memory_remove_breakpoint): Likewise.
4576 * stack.c (return_command): Likewise.
4577 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4578 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4579 * tracefile.c (trace_save_ctf): Likewise.
4580 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4581 (do_windows_store_inferior_registers): Likewise.
4582 (windows_resume): Likewise.
4583 * xtensa-linux-nat.c (fill_gregset): Likewise.
4584 (supply_gregset_reg): Likewise.
4585 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4586 (xtensa_register_read_masked): Likewise.
4587 (xtensa_supply_gregset): Likewise.
4588 (xtensa_extract_return_value): Likewise.
4589 (xtensa_store_return_value): Likewise.
4590
edd079d9
UW
45912017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4592
4593 * doublest.c (floatformat_from_string): New function.
4594 * doublest.h (floatformat_from_string): Add prototype.
4595
4596 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4597 (OP_FLOAT): ... this.
4598 * expression.h: Do not include "doublest.h".
4599 (union exp_element): Replace doubleconst and decfloatconst by
4600 new element floatconst.
4601 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4602 (ada_evaluate_subexp): Likewise.
4603 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4604 OP_DOUBLE and OP_DECFLOAT.
4605 * expprint.c (print_subexp_standard): Likewise.
4606 (dump_subexp_body_standard): Likewise.
4607 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4608
4609 * parse.c: Include "dfp.h".
4610 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4611 (write_exp_elt_floatcst): New function.
4612 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4613 and OP_DECFLOAT.
4614 (operator_check_standard): Likewise.
4615 (parse_float): Do not accept suffix. Take type as input. Return bool.
4616 Return target format buffer instead of host DOUBLEST.
4617 Use floatformat_from_string and decimal_from_string to parse
4618 either binary or decimal floating-point types.
4619 (parse_c_float): Remove.
4620 * parser-defs.h: Do not include "doublest.h".
4621 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4622 (write_exp_elt_floatcst): Add prototype.
4623 (parse_float): Update prototype.
4624 (parse_c_float): Remove.
4625
4626 * c-exp.y: Do not include "dfp.h".
4627 (typed_val_float): Use byte buffer instead of DOUBLEST.
4628 (typed_val_decfloat): Remove.
4629 (DECFLOAT): Remove.
4630 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4631 (parse_number): Update to new parse_float interface.
4632 Parse suffixes and determine type before calling parse_float.
4633 Handle decimal and binary FP types the same way.
4634
4635 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4636 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4637 (parse_number): Update to new parse_float interface.
4638 Parse suffixes and determine type before calling parse_float.
4639
4640 * f-exp.y: Replace dval by typed_val_float.
4641 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4642 (parse_number): Use parse_float instead of atof.
4643
4644 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4645 (parse_go_float): Remove.
4646 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4647 (parse_number): Call parse_float instead of parse_go_float.
4648 Parse suffixes and determine type before calling parse_float.
4649
4650 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4651 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4652 (parse_number): Update to new parse_float interface.
4653 Parse suffixes and determine type before calling parse_float.
4654
4655 * m2-exp.y: Replace dval by byte buffer val.
4656 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4657 (parse_number): Call parse_float instead of atof.
4658
4659 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4660 (lex_number): Call parse_float instead of strtod.
4661 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4662 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4663 Use write_exp_elt_floatcst.
4664 (unit_testing): Remove static variable.
4665 (rust_type): Do not check unit_testing.
4666 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4667
4668 * ada-exp.y (type_float, type_double): Remove.
4669 (typed_val_float): Use byte buffer instead of DOUBLEST.
4670 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4671 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4672
cc628f3d
AH
46732017-10-25 Alan Hayward <alan.hayward@arm.com>
4674
4675 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4676 * arch/aarch64.h: New file.
4677
09a7c6aa
UW
46782017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4679
4680 * dfp.h (decimal_from_string): Use const reference for argument.
4681 * dfp.c (decimal_from_string): Likewise.
4682
8ba0dd51
UW
46832017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4684
4685 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4686 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4687 * mips-tdep.c (mips_print_fp_register): Likewise.
4688
16e812b2
UW
46892017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4690
4691 * common/format.h (enum argclass): Replace decfloat_arg by
4692 dec32float_arg, dec64float_arg, and dec128float_arg.
4693 * common/format.c (parse_format_string): Update to return
4694 new decimal float argument classes.
4695
4696 * printcmd.c (printf_decfloat): Rename to ...
4697 (printf_floating): ... this. Add argclass argument, and use it
4698 instead of parsing the format string again. Add support for
4699 binary floating-point values, using floatformat_to_string.
4700 Convert value to the target format if it doesn't already match.
4701 (ui_printf): Call printf_floating instead of printf_decfloat,
4702 also for double_arg / long_double_arg. Pass argclass.
4703
4704 * dfp.c (decimal_to_string): Add format string argument.
4705 * dfp.h (decimal_to_string): Likewise.
4706
4707 * doublest.c (floatformat_to_string): Add format string argument.
4708 * doublest.h (floatformat_to_string): Likewise.
4709
fdf0cbc2
UW
47102017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4711
4712 * doublest.c (floatformat_precision): New routine.
4713 (floatformat_to_string): Likewise.
4714 * doublest.c (floatformat_to_string): Add prototype.
4715
4716 * printcmd.c (print_scalar_formatted): Only call print_floating
4717 on floating-point types.
4718 * valprint.c: Do not include "floatformat.h".
4719 (generic_val_print_decfloat): Remove.
4720 (generic_val_print): Call generic_val_print_float for both
4721 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4722 (print_floating): Use floatformat_to_string. Handle decimal float.
4723 (print_decimal_floating): Remove, merge into floatformat_to_string.
4724 * value.h (print_decimal_floating): Remove.
4725
4726 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4727
5033013f
UW
47282017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4729
4730 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4731
a664f67e
SM
47322017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4733
4734 * memattr.h: Don't include vec.h.
4735 (struct mem_attrib): Initialize fields.
4736 <unknown>: New static method.
4737 (struct mem_region): Add constructors, operator<, initialize
4738 fields.
4739 * memattr.c: Include algorithm.
4740 (default_mem_attrib, unknown_mem_attrib): Remove.
4741 (user_mem_region_list): New global.
4742 (target_mem_region_list, mem_region_list): Change type to
4743 std::vector<mem_region>.
4744 (mem_use_target): Now a function.
4745 (target_mem_regions_valid): Change type to bool.
4746 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4747 (require_user_regions): Adjust.
4748 (require_target_regions): Adjust.
4749 (create_mem_region): Adjust.
4750 (lookup_mem_region): Adjust.
4751 (invalidate_target_mem_regions): Adjust.
4752 (mem_clear): Rename to...
4753 (user_mem_clear): ... this, and adjust.
4754 (mem_command): Adjust.
4755 (info_mem_command): Adjust.
4756 (mem_enable, enable_mem_command, mem_disable,
4757 disable_mem_command): Adjust.
4758 (mem_delete): Adjust.
4759 (delete_mem_command): Adjust.
4760 * memory-map.h (parse_memory_map): Return an std::vector.
4761 * memory-map.c (parse_memory_map): Likewise.
4762 (struct memory_map_parsing_data): Add constructor.
4763 <memory_map>: Point to std::vector.
4764 (memory_map_start_memory): Adjust.
4765 (memory_map_end_memory): Adjust.
4766 (memory_map_end_property): Adjust.
4767 (clear_result): Remove.
4768 * remote.c (remote_memory_map): Return an std::vector.
4769 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4770 Remove.
4771 (target_debug_print_mem_region_vector): New.
4772 * target-delegates.c: Regenerate.
4773 * target.h (mem_region_vector): New typedef.
4774 (to_memory_map): Return mem_region_vector.
4775 (target_memory_map): Return an std::vector.
4776 * target.c (target_memory_map): Return an std::vector.
4777 (flash_erase_command): Adjust.
4778
6e17c565
SM
47792017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4780
4781 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4782 Change type to std::string.
4783 (memory_map_start_property): Adjust.
4784 (memory_map_end_property): Adjust.
4785
cfba9872
SM
47862017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4787
4788 * infrun.h: Include common/byte-vector.h.
4789 (struct displaced_step_closure): New struct.
4790 (struct buf_displaced_step_closure): New struct.
4791 * infrun.c (displaced_step_closure::~displaced_step_closure):
4792 Provide default implementation.
4793 (displaced_step_clear): Deallocate step closure with delete.
4794 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4795 (aarch64_displaced_step_closure): ... this, extend
4796 displaced_step_closure.
4797 (aarch64_displaced_step_data) <dsc>: Change type to
4798 aarch64_displaced_step_closure.
4799 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4800 unique_ptr.
4801 (aarch64_displaced_step_fixup): Add cast for displaced step
4802 closure.
4803 * amd64-tdep.c (displaced_step_closure): Rename to ...
4804 (amd64_displaced_step_closure): ... this, extend
4805 displaced_step_closure.
4806 <insn_buf>: Change type to std::vector<gdb_byte>.
4807 <max_len>: Remove.
4808 (fixup_riprel): Change type of DSC parameter, adjust to type
4809 change of insn_buf.
4810 (fixup_displaced_copy): Change type of DSC parameter.
4811 (amd64_displaced_step_copy_insn): Instantiate
4812 amd64_displaced_step_closure.
4813 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4814 to type change of insn_buf.
4815 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4816 parameter DSC.
4817 (arm_linux_copy_svc): Likewise.
4818 (cleanup_kernel_helper_return): Likewise.
4819 (arm_catch_kernel_helper_return): Likewise.
4820 (arm_linux_displaced_step_copy_insn): Instantiate
4821 arm_displaced_step_closure.
4822 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4823 (displaced_read_reg): Change type of parameter DSC.
4824 (branch_write_pc): Likewise.
4825 (load_write_pc): Likewise.
4826 (alu_write_pc): Likewise.
4827 (displaced_write_reg): Likewise.
4828 (arm_copy_unmodified): Likewise.
4829 (thumb_copy_unmodified_32bit): Likewise.
4830 (thumb_copy_unmodified_16bit): Likewise.
4831 (cleanup_preload): Likewise.
4832 (install_preload): Likewise.
4833 (arm_copy_preload): Likewise.
4834 (thumb2_copy_preload): Likewise.
4835 (install_preload_reg): Likewise.
4836 (arm_copy_preload_reg): Likewise.
4837 (cleanup_copro_load_store): Likewise.
4838 (install_copro_load_store): Likewise.
4839 (arm_copy_copro_load_store) Likewise.
4840 (thumb2_copy_copro_load_store): Likewise.
4841 (cleanup_branch): Likewise.
4842 (install_b_bl_blx): Likewise.
4843 (arm_copy_b_bl_blx): Likewise.
4844 (thumb2_copy_b_bl_blx): Likewise.
4845 (thumb_copy_b): Likewise.
4846 (install_bx_blx_reg): Likewise.
4847 (arm_copy_bx_blx_reg): Likewise.
4848 (thumb_copy_bx_blx_reg): Likewise.
4849 (cleanup_alu_imm): Likewise.
4850 (arm_copy_alu_imm): Likewise.
4851 (thumb2_copy_alu_imm): Likewise.
4852 (cleanup_alu_reg): Likewise.
4853 (install_alu_reg): Likewise.
4854 (arm_copy_alu_reg): Likewise.
4855 (thumb_copy_alu_reg): Likewise.
4856 (cleanup_alu_shifted_reg): Likewise.
4857 (install_alu_shifted_reg): Likewise.
4858 (arm_copy_alu_shifted_reg): Likewise.
4859 (cleanup_load): Likewise.
4860 (cleanup_store): Likewise.
4861 (arm_copy_extra_ld_st): Likewise.
4862 (install_load_store): Likewise.
4863 (thumb2_copy_load_literal): Likewise.
4864 (thumb2_copy_load_reg_imm): Likewise.
4865 (arm_copy_ldr_str_ldrb_strb): Likewise.
4866 (cleanup_block_load_all): Likewise.
4867 (cleanup_block_store_pc): Likewise.
4868 (cleanup_block_load_pc): Likewise.
4869 (arm_copy_block_xfer): Likewise.
4870 (thumb2_copy_block_xfer): Likewise.
4871 (cleanup_svc): Likewise.
4872 (install_svc): Likewise.
4873 (arm_copy_svc): Likewise.
4874 (thumb_copy_svc): Likewise.
4875 (arm_copy_undef): Likewise.
4876 (thumb_32bit_copy_undef): Likewise.
4877 (arm_copy_unpred): Likewise.
4878 (arm_decode_misc_memhint_neon): Likewise.
4879 (arm_decode_unconditional): Likewise.
4880 (arm_decode_miscellaneous): Likewise.
4881 (arm_decode_dp_misc): Likewise.
4882 (arm_decode_ld_st_word_ubyte): Likewise.
4883 (arm_decode_media): Likewise.
4884 (arm_decode_b_bl_ldmstm): Likewise.
4885 (arm_decode_ext_reg_ld_st): Likewise.
4886 (thumb2_decode_dp_shift_reg): Likewise.
4887 (thumb2_decode_ext_reg_ld_st): Likewise.
4888 (arm_decode_svc_copro): Likewise.
4889 (thumb2_decode_svc_copro): Likewise.
4890 (install_pc_relative): Likewise.
4891 (thumb_copy_pc_relative_16bit): Likewise.
4892 (thumb_decode_pc_relative_16bit): Likewise.
4893 (thumb_copy_pc_relative_32bit): Likewise.
4894 (thumb_copy_16bit_ldr_literal): Likewise.
4895 (thumb_copy_cbnz_cbz): Likewise.
4896 (thumb2_copy_table_branch): Likewise.
4897 (cleanup_pop_pc_16bit_all): Likewise.
4898 (thumb_copy_pop_pc_16bit): Likewise.
4899 (thumb_process_displaced_16bit_insn): Likewise.
4900 (decode_thumb_32bit_ld_mem_hints): Likewise.
4901 (thumb_process_displaced_32bit_insn): Likewise.
4902 (thumb_process_displaced_insn): Likewise.
4903 (arm_process_displaced_insn): Likewise.
4904 (arm_displaced_init_closure): Likewise.
4905 (arm_displaced_step_fixup): Add cast for closure.
4906 * arm-tdep.h: Include infrun.h.
4907 (displaced_step_closure): Rename to ...
4908 (arm_displaced_step_closure): ... this, extend
4909 displaced_step_closure.
4910 <u::svc::copy_svc_os>: Change type of parameter DSC.
4911 <cleanup>: Likewise.
4912 (arm_process_displaced_insn): Likewise.
4913 (arm_displaced_init_closure): Likewise.
4914 (displaced_read_reg): Likewise.
4915 (displaced_write_reg): Likewise.
4916 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4917 Adjust.
4918 * i386-tdep.h: Include infrun.h.
4919 (i386_displaced_step_closure): New typedef.
4920 * i386-tdep.c (i386_displaced_step_copy_insn): Use
4921 i386_displaced_step_closure.
4922 (i386_displaced_step_fixup): Adjust.
4923 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
4924 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
4925 and unique_ptr.
4926 (ppc_displaced_step_fixup): Adjust.
4927 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
4928 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
4929 and unique_ptr.
4930 (s390_displaced_step_fixup): Adjust.
4931
b392b304
SM
49322017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4933
4934 * interps.h (interp_resume, interp_suspend, interp_set_temp):
4935 Remove declarations.
4936
d5833c62
TT
49372017-10-20 Tom Tromey <tom@tromey.com>
4938
4939 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
4940 std::vector.
4941 (gdb_bfd_record_inclusion): Update.
4942 (bfdp): Remove typedef.
4943
06d5bbc8
TT
49442017-10-20 Tom Tromey <tom@tromey.com>
4945
4946 * gdb_bfd.c (gdb_bfd_ref): Use new.
4947 (struct gdb_bfd_data): Add constructor, destructor, and member
4948 initializers.
4949 (gdb_bfd_unref): Use delete.
4950
2712ce2e
TT
49512017-10-20 Tom Tromey <tom@tromey.com>
4952
4953 * exec.c (exec_file_attach): Use new_bfd_ref.
4954 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
4955 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4956 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
4957 new_bfd_ref.
4958 * gdb_bfd.h (new_bfd_ref): New function.
4959
fcc8fb2f
PA
49602017-10-20 Pedro Alves <palves@redhat.com>
4961
4962 * main.c (captured_command_loop): Add attribute noinline.
4963
4c2287b0
SM
49642017-10-19 Simon Marchi <simon.marchi@ericsson.com>
4965
4966 * interps.c (struct interp_factory): Add constructor.
4967 (interp_factory_p): Remove typedef.
4968 (DEF_VEC_P(interp_factory_p)): Remove.
4969 (interpreter_factories): Change type to std::vector.
4970 (interp_factory_register): Adjust.
4971 (interp_lookup): Adjust.
4972 (interpreter_completer): Adjust.
4973
3d415c26
TT
49742017-10-19 Tom Tromey <tom@tromey.com>
4975
4976 * break-catch-syscall.c (catch_syscall_completer): Use
4977 std::string, gdb::unique_xmalloc_ptr.
4978
395423c4
TT
49792017-10-19 Tom Tromey <tom@tromey.com>
4980
4981 * infcall.c (call_function_by_hand_dummy): Use std::string.
4982
54f70bc1
TT
49832017-10-19 Tom Tromey <tom@tromey.com>
4984
4985 * mi/mi-main.c (mi_cmd_execute): Update.
4986 * top.h (prepare_execute_command): Return scoped_value_mark.
4987 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
4988 Add move constructor.
4989 * top.c (prepare_execute_command): Return scoped_value_mark.
4990 (execute_command): Update.
4991
63929e84
PA
49922017-10-19 Pedro Alves <palves@redhat.com>
4993
4994 * xml-support.c (xml_fetch_content_from_file): Check fread's
4995 return.
4996
a75868f5
PA
49972017-10-19 Pedro Alves <palves@redhat.com>
4998
4999 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
5000 async.
5001 (handle_error_fd): New function.
5002 (ser_base_async): Add/delete an event loop file handler for
5003 error_fd.
5004
2edf834e
PA
50052017-10-19 Pedro Alves <palves@redhat.com>
5006
5007 * xml-support.c (xml_fetch_content_from_file): Don't read in
5008 chunks. Instead use fseek to determine the file's size, and read
5009 it in one go.
5010
c8ba13ad
KS
50112017-11-18 Keith Seitz <keiths@redhat.com>
5012
5013 * c-exp.y (oper): Canonicalize conversion operators of user-defined
5014 types.
5015 Add whitespace to front of type name.
5016
37534686
KS
50172017-10-18 Keith Seitz <keiths@redhat.com>
5018
5019 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
5020 DW_AT_accessibility.
5021
28c7c158
YQ
50222017-10-18 Yao Qi <yao.qi@linaro.org>
5023
5024 * features/tic6x-c62x-linux.c: Remove.
5025
30f0b101
TT
50262017-10-17 Tom Tromey <tom@tromey.com>
5027
5028 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
5029 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
5030 (do_mixed_source_and_assembly): Likewise.
5031
57e12da9
TT
50322017-10-17 Tom Tromey <tom@tromey.com>
5033
5034 * regcache.c (regcache::xfer_part): Remove assertion.
5035
7b700999
PA
50362017-10-17 Pedro Alves <palves@redhat.com>
5037
5038 * xml-support.c (xml_fetch_content_from_file): Call
5039 unique_ptr::release() instead unique_ptr::get() when passing
5040 through xrealloc.
5041
d3037ba6
YQ
50422017-10-17 Yao Qi <yao.qi@linaro.org>
5043
5044 * regcache.c (regcache::xfer_part): Remove parameters read and
5045 write, add parameter is_raw. All callers are updated.
5046
83d5a34d
KS
50472017-10-16 Keith Seitz <keiths@redhat.com>
5048
5049 * c-typeprint.c (enum access_specifier): Moved here from
5050 c_type_print_base.
5051 (output_access_specifier): New function.
5052 (c_type_print_base): Consider typedefs when assessing
5053 whether access labels are needed.
5054 Use output_access_specifier as needed.
5055 Output access specifier for typedefs, if needed.
5056 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
5057 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
5058 fields.
5059 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
5060 accessor macros.
5061
87028b87
TT
50622017-10-16 Tom Tromey <tom@tromey.com>
5063
5064 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
5065 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
5066 * target.c (target_fileio_read_stralloc): Update.
5067 * sparc64-tdep.c (adi_is_addr_mapped): Update.
5068 * target.h (target_fileio_read_stralloc): Return
5069 unique_xmalloc_ptr.
5070
b7b030ad
TT
50712017-10-16 Tom Tromey <tom@tromey.com>
5072
5073 * xml-syscall.c (xml_init_syscalls_info): Update.
5074 * xml-support.c (xinclude_start_include): Update.
5075 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
5076 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
5077 (xml_fetch_content_from_file): Likewise.
5078 * osdata.c (get_osdata): Update.
5079 * target.h (target_read_stralloc, target_get_osdata): Return
5080 unique_xmalloc_ptr.
5081 * solib-aix.c (solib_aix_get_library_list): Update.
5082 * solib-target.c (solib_target_current_sos): Update.
5083 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
5084 * xml-tdesc.c (fetch_available_features_from_target): Update.
5085 (target_fetch_description_xml): Update.
5086 (file_read_description_xml): Update.
5087 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
5088 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
5089 (remote_pid_to_exec_file): Update.
5090 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
5091 (target_get_osdata): Likewise.
5092
b80406ac
TT
50932017-10-16 Tom Tromey <tom@tromey.com>
5094
5095 * remote.c (remote_register_number_and_offset): Use std::vector.
5096 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
5097 (putpkt_binary): Use gdb::def_vector.
5098 (compare_sections_command): Use gdb::byte_vector.
5099
a90ecff8
TT
51002017-10-16 Tom Tromey <tom@tromey.com>
5101
5102 * ppc-linux-nat.c (hwdebug_insert_point): Use
5103 gdb::unique_xmalloc_ptr, XDUP.
5104
2dc0e219
TT
51052017-10-16 Tom Tromey <tom@tromey.com>
5106
5107 * probe.c (parse_probes): Use std::string.
5108 (info_probes_for_ops, enable_probes_command)
5109 (disable_probes_command): Remove cleanups.
5110
b05628f0
TT
51112017-10-16 Tom Tromey <tom@tromey.com>
5112
5113 * buildsym.c (block_compar): Remove.
5114 (end_symtab_get_static_block): Use std::vector.
5115
a79b1bc6
SM
51162017-10-16 Simon Marchi <simon.marchi@ericsson.com>
5117
5118 * memrange.h (struct mem_range): Define operator< and operator==.
5119 (mem_range_s): Remove.
5120 (DEF_VEC_O (mem_range_s)): Remove.
5121 (normalize_mem_ranges): Change parameter type to std::vector.
5122 * memrange.c (compare_mem_ranges): Remove.
5123 (normalize_mem_ranges): Change parameter type to std::vector,
5124 adjust to vector change.
5125 * exec.c (section_table_available_memory): Return vector, remove
5126 parameter.
5127 (section_table_read_available_memory): Adjust to std::vector
5128 change.
5129 * remote.c (remote_read_bytes): Adjust to std::vector
5130 change.
5131 * tracepoint.h (traceframe_available_memory): Change parameter
5132 type to std::vector.
5133 * tracepoint.c (traceframe_available_memory): Change parameter
5134 type to std::vector, adjust.
5135 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
5136 std::vector change.
5137 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5138 unittests/memrange-selftests.c.
5139 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
5140 * gdb/unittests/memrange-selftests.c: New file.
5141
63f0e930
PA
51422017-10-16 Pedro Alves <palves@redhat.com>
5143
5144 * elfread.c (probe_key_free): Rename range-for variable.
5145 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
5146 (find_probe_by_pc, collect_probes): Rename range-for variable.
5147
c40c7bfc
YQ
51482017-10-16 Yao Qi <yao.qi@linaro.org>
5149
5150 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
5151 * features/tic6x-c62x.c: Remove.
5152 * features/tic6x-c64x-linux.c: Remove.
5153 * features/tic6x-c64x.c: Remove.
5154 * features/tic6x-c64xp-linux.c: Remove.
5155 * features/tic6x-c64xp.c: Remove.
5156 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
5157 initialize_tdesc_tic6x_*_linux functions.
5158 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
5159 initialize_tdesc_tic6x_* functions.
5160
df27ae6a
YQ
51612017-10-16 Yao Qi <yao.qi@linaro.org>
5162
5163 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
5164 tic6x-c62x.
5165 * regformats/tic6x-c62x.dat: Remove.
5166 * regformats/tic6x-c64x.dat: Remove.
5167 * regformats/tic6x-c64xp.dat: Remove.
5168
86766165
SM
51692017-10-15 Simon Marchi <simon.marchi@ericsson.com>
5170
5171 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
5172 (the !HAVE_LIBEXPAT version).
5173
824dfcc3
SM
51742017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5175
5176 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
5177 const.
5178
2098b393
SM
51792017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5180
5181 * target.h: Include tracepoint.h.
5182 (enum trace_find_type): Move to tracepoint.h.
5183 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
5184 * tracepoint.h: Don't include target.h
5185 (enum trace_find_type): Move from target.h.
5186 (parse_traceframe_info): Return a unique ptr.
5187 * tracepoint.c (current_traceframe_info): Change type to unique
5188 ptr.
5189 (free_traceframe_info): Remove.
5190 (clear_traceframe_info): Don't manually free
5191 current_traceframe_info.
5192 (free_result): Remove.
5193 (parse_traceframe_info): Return a unique ptr.
5194 (get_traceframe_info): Adjust to unique ptr.
5195 * ctf.c (ctf_traceframe_info): Return a unique ptr.
5196 * remote.c (remote_traceframe_info): Return a unique ptr.
5197 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
5198 ptr.
5199 * target-debug.h (target_debug_print_traceframe_info_up): New
5200 macro.
5201 * target-delegates.c: Regenerate.
5202
4cdd21a8
SM
52032017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5204
5205 * memrange.h (struct mem_range): Add constructors.
5206 * tracepoint.h (struct traceframe_info) <memory>: Change type to
5207 std::vector<mem_range>.
5208 * tracepoint.c (free_traceframe_info): Don't manually free
5209 vector.
5210 (traceframe_info_start_memory): Adjust to vector change.
5211 (traceframe_available_memory): Likewise.
5212 * tracefile-tfile.c (build_traceframe_info): Likewise.
5213 * ctf.c (ctf_traceframe_info): Likewise.
5214
d0d292a2
SM
52152017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5216
5217 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
5218 std::vector<int>.
5219 * tracepoint.c (free_traceframe_info): Deallocate with delete.
5220 (traceframe_info_start_tvar): Adjust to vector change.
5221 (parse_traceframe_info): Allocate with new.
5222 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
5223 vector change.
5224 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
5225 change.
5226 tfile_traceframe_info): Allocate with new.
5227 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
5228 change.
5229
8d3c73ef
SM
52302017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5231
5232 * tracepoint.c (traceframe_info): Rename to...
5233 (current_traceframe_info): ...this.
5234 (clear_traceframe_info): Adjust.
5235 (get_traceframe_info): Adjust.
5236
b129dcac
SM
52372017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5238
5239 * nat/linux-osdata.c: Include algorithm.
5240 (compare_processes): Remove.
5241 (struct pid_pgid_entry): New struct.
5242 (linux_xfer_osdata_processgroups): Use std::vector instead of
5243 XNEWVEC.
5244
af5bf4ad
SM
52452017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5246
5247 * objfiles.h: Don't include symfile.h.
5248 (struct partial_symbol): Remove forward-declaration.
5249 (struct objfile) <global_psymbols, static_psymbols>: Change type
5250 to std::vector<partial_symbol *>.
5251 * objfiles.c (objfile::objfile): Don't memset those fields.
5252 (objfile::~objfile): Don't free those fields.
5253 * psympriv.h (struct psymbol_allocation_list): Remove
5254 forward-declaration.
5255 (add_psymbol_to_list): Change psymbol_allocation_list parameter
5256 to std::vector.
5257 (start_psymtab_common): Change parameters to std::vector.
5258 * psymtab.c: Include algorithm.
5259 (require_partial_symbols): Call shrink_to_fit.
5260 (find_pc_sect_psymbol): Adjust to vector change.
5261 (match_partial_symbol): Likewise.
5262 (lookup_partial_symbol): Likewise.
5263 (psym_relocate): Likewise.
5264 (dump_psymtab): Likewise.
5265 (recursively_search_psymtabs): Likewise.
5266 (compare_psymbols): Remove.
5267 (sort_pst_symbols): Adjust to vector change.
5268 (start_psymtab_common): Likewise.
5269 (end_psymtab_common): Likewise.
5270 (psymbol_bcache_full): De-constify return value.
5271 (add_psymbol_to_bcache): Likewise.
5272 (extend_psymbol_list): Remove.
5273 (append_psymbol_to_list): Adjust to vector change.
5274 (add_psymbol_to_list): Likewise.
5275 (init_psymbol_list): Likewise.
5276 (maintenance_info_psymtabs): Likewise.
5277 (maintenance_check_psymtabs): Likewise.
5278 * symfile.h (struct psymbol_allocation_list): Remove.
5279 * symfile.c (reread_symbols): Adjust to vector change.
5280 * dbxread.c (start_psymtab): Change type of parameters.
5281 (dbx_symfile_read): Adjust to vector change.
5282 (read_dbx_symtab): Likewise.
5283 (start_psymtab): Change type of parameters.
5284 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
5285 (create_partial_symtab): Likewise.
5286 (add_partial_symbol): Likewise.
5287 (write_one_signatured_type): Likewise.
5288 (recursively_write_psymbols): Likewise.
5289 * mdebugread.c (parse_partial_symbols): Likewise.
5290 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
5291 (scan_xcoff_symtab): Adjust to vector change.
5292 (xcoff_initial_scan): Likewise.
5293
3ec5942f
SM
52942017-10-13 Simon Marchi <simon.marchi@ericsson.com>
5295
5296 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
5297
2399fe6a
YQ
52982017-10-13 Yao Qi <yao.qi@linaro.org>
5299
5300 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
5301 Remove s390x-*-expedite, add s390x-expedite.
5302
4bf3f4a8
YQ
53032017-10-13 Yao Qi <yao.qi@linaro.org>
5304
5305 * features/s390-gs-linux64.c: Regenerated.
5306 * features/s390x-gs-linux64.c: Regenerated.
5307
9e86da07
TT
53082017-10-13 Tom Tromey <tom@tromey.com>
5309
5310 * compile/compile-object-run.c (do_module_cleanup): Use delete.
5311 * solib.c (update_solib_list, reload_shared_libraries_1): Use
5312 delete.
5313 * symfile.c (symbol_file_add_with_addrs): Use new.
5314 (symbol_file_add_separate): Update comment.
5315 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
5316 * jit.c (jit_object_close_impl): Use new.
5317 (jit_unregister_code): Use delete.
5318 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
5319 (~objfile): Rename from free_objfile.
5320 (free_objfile_separate_debug, do_free_objfile_cleanup)
5321 (free_all_objfiles, objfile_purge_solibs): Use delete.
5322 * objfiles.h (struct objfile): Add constructor and destructor.
5323 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
5324 (allocate_objfile, free_objfile): Don't declare.
5325 (struct objstats): Add initializers.
5326
c2508e90
SM
53272017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5328
5329 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
5330 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
5331 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
5332 * gdbarch.h: Regenerate.
5333 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5334 Adjust comment.
5335 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
5336 (i386_displaced_step_fixup): Adjust comment.
5337 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
5338
a900ff72
TT
53392017-10-12 Tom Tromey <tom@tromey.com>
5340
5341 * prologue-value.h (pv_area::store_would_trash): Return bool.
5342 (pv_area::find_reg): Likewise.
5343 * prologue-value.c (pv_area::store_would_trash): Return bool.
5344 (pv_area::find_reg): Likewise.
5345
f7b7ed97
TT
53462017-10-12 Tom Tromey <tom@tromey.com>
5347
5348 * s390-linux-tdep.c (s390_store, s390_load)
5349 (s390_check_for_saved, s390_analyze_prologue): Update.
5350 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
5351 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
5352 * prologue-value.h (class pv_area): Move from prologue-value.c.
5353 Change names of members. Add constructor, destructor, member
5354 functions.
5355 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
5356 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
5357 (pv_area_fetch, pv_area_scan): Don't declare.
5358 * prologue-value.c (struct pv_area::area_entry): Now member of
5359 pv_area.
5360 (struct pv_area): Move to prologue-value.h.
5361 (pv_area::pv_area): Rename from make_pv_area.
5362 (pv_area::~pv_area): Rename from free_pv_area.
5363 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
5364 (clear_entries, find_entry, overlaps, store_would_trash, store)
5365 (fetch, find_reg, scan): Now member of pv_area.
5366 Remove "area" argument. Update.
5367 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
5368 Update.
5369 * mn10300-tdep.c (push_reg, check_for_saved)
5370 (mn10300_analyze_prologue): Update.
5371 * mep-tdep.c (is_arg_spill, check_for_saved)
5372 (mep_analyze_prologue): Update.
5373 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
5374 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
5375 (m32c_is_struct_return, m32c_analyze_prologue): Update.
5376 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
5377 Update.
5378 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
5379 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
5380
466eecee
SM
53812017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5382
5383 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
5384 * linux-nat.c (linux_nat_delete_thread): New variable.
5385 (lwp_free): Invoke linux_nat_delete_thread if set.
5386 (linux_nat_set_delete_thread): New function.
5387 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
5388 thread delete callback.
5389 * arm-linux-nat.c (arm_linux_delete_thread): New function.
5390 (_initialize_arm_linux_nat): Assign thread delete callback.
5391 * s390-linux-nat.c (s390_delete_thread): New function.
5392 (_initialize_s390_nat): Assign thread delete callback.
5393 * x86-linux-nat.c (x86_linux_add_target): Likewise.
5394 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
5395 function.
5396 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
5397 declaration.
5398 * nat/x86-linux.c (x86_linux_delete_thread): New function.
5399 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
5400
f71c8822
TT
54012017-10-09 Tom Tromey <tom@tromey.com>
5402
5403 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
5404 std::string.
5405 * tui/tui-layout.c (enum tui_status): Use std::string.
5406
981a3fb3
TT
54072017-10-11 Tom Tromey <tom@tromey.com>
5408
5409 * gdbthread.h (thread_command): Constify.
5410 * inferior.h (detach_command): Constify.
5411 * top.h (set_history, show_history): Constify.
5412 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
5413 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
5414 * bsd-kvm.c (bsd_kvm_cmd): Constify.
5415 * printcmd.c (set_command): Constify.
5416 (non_const_set_command): New function.
5417 * dcache.c (set_dcache_command, show_dcache_command): Constify.
5418 * breakpoint.c (enable_command, disable_command, delete_command)
5419 (catch_command, tcatch_command, set_breakpoint_cmd)
5420 (show_breakpoint_cmd): Constify.
5421 * macrocmd.c (macro_command): Constify.
5422 * infcmd.c (unset_command, kill_command, detach_command)
5423 (info_proc_cmd): Constify.
5424 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
5425 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
5426 (info_auto_load_cmd): Constify.
5427 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5428 (unset_tdesc_cmd): Constify.
5429 * ada-lang.c (set_ada_command, show_ada_command)
5430 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
5431 * guile/guile.c (set_guile_command, show_guile_command)
5432 (info_guile_command): Constify.
5433 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
5434 Constify.
5435 * skip.c (skip_command): Constify.
5436 * compile/compile.c (_initialize_compile): Constify.
5437 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
5438 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5439 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5440 (maint_btrace_pt_show_cmd): Constify.
5441 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
5442 Constify.
5443 * python/python.c (user_show_python, user_set_python): Constify.
5444 * mips-tdep.c (set_mips_command, show_mips_command)
5445 (set_mipsfpu_command): Constify.
5446 * record-btrace.c (cmd_record_btrace_start)
5447 (cmd_set_record_btrace, cmd_show_record_btrace)
5448 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
5449 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
5450 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
5451 Constify.
5452 * symfile.c (overlay_command): Constify.
5453 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
5454 * cli/cli-logging.c (set_logging_command, show_logging_command):
5455 Constify.
5456 * cli/cli-dump.c (dump_command, append_command)
5457 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5458 (tekhex_dump_command, binary_dump_command)
5459 (binary_append_command): Constify.
5460 * cli/cli-decode.c (struct cmd_list_element): Change type of
5461 "fun".
5462 * cli/cli-cmds.c (info_command, show_command, set_debug)
5463 (show_debug): Constify.
5464 (show_command): Add non-const overload.
5465 * top.c (set_history, show_history): Constify.
5466 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
5467 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
5468 * target.c (target_command): Constify.
5469 * sparc64-tdep.c (info_adi_command): Constify.
5470 * record-full.c (cmd_record_full_start): Constify.
5471 (set_record_full_command): Constify. Fix typo.
5472 (show_record_full_command): Constify.
5473 * thread.c (thread_command, thread_apply_command): Constify.
5474 * memattr.c (dummy_cmd): Constify.
5475 * value.c (function_command): Constify.
5476 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
5477 * probe.c (info_probes_command): Constify.
5478 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5479 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5480 (show_thread_cmd, set_thread_default_cmd)
5481 (show_thread_default_cmd): Constify.
5482 (check_empty): Constify.
5483 * tracepoint.c (tfind_command): Constify.
5484 * cp-support.c (maint_cplus_command): Constify.
5485 * windows-tdep.c (info_w32_command): Constify.
5486 * record.c (cmd_record_start, set_record_command)
5487 (show_record_command, info_record_command, cmd_record_goto):
5488 Constify.
5489 * ravenscar-thread.c (set_ravenscar_command)
5490 (show_ravenscar_command): Constify.
5491 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5492 Constify.
5493 (add_internal_problem_command): Remove casts.
5494 * arc-tdep.c (maintenance_print_arc_command): Constify.
5495 * valprint.c (set_print, show_print, set_print_raw)
5496 (show_print_raw): Constify.
5497 * maint.c (maintenance_command, maintenance_info_command)
5498 (maintenance_print_command, maintenance_set_cmd)
5499 (maintenance_show_cmd, set_per_command_cmd)
5500 (show_per_command_cmd, maintenance_check_command): Constify.
5501 * language.c (set_check, show_check): Constify.
5502 * typeprint.c (show_print_type, set_print_type): Constify.
5503 * go32-nat.c (go32_info_dos_command): Constify.
5504
fdf44873
TT
55052017-10-11 Tom Tromey <tom@tromey.com>
5506
5507 * breakpoint.c (prepare_re_set_context): Remove.
5508 (breakpoint_re_set_one): Update. Don't use cleanups.
5509 (breakpoint_re_set): Use scoped_restore, std::string, and
5510 scoped_restore_current_language.
5511
81b1e71c
TT
55122017-10-11 Tom Tromey <tom@tromey.com>
5513
5514 * breakpoint.c (commands_command_1): Use std::string.
5515 (cleanup_executing_breakpoints): Remove.
5516 (bpstat_do_actions_1): Use scoped_restore.
5517 (bpstat_check_watchpoint): Use std::string.
5518 (decode_static_tracepoint_spec): Likewise.
5519 (break_range_command): Likewise.
5520 (watch_command_1): Likewise.
5521 (compare_breakpoints): Change argument types.
5522 (clear_command): Use std::vector.
5523 (cleanup_executing_breakpoints): Remove.
5524 (update_global_location_list): Use unique_xmalloc_ptr.
5525 (strace_command): Remove unused declaration.
5526
4f9d9906
JB
55272017-10-11 John Baldwin <jhb@FreeBSD.org>
5528
5529 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5530 * NEWS: Mention new FreeBSD/arm native configuration.
5531 * configure.host: Add arm*-*-freebsd*.
5532 * configure.nat: Likewise.
5533 * arm-fbsd-nat.c: New file.
5534
7176dfd2
JB
55352017-10-11 John Baldwin <jhb@FreeBSD.org>
5536
5537 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5538 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5539 * NEWS: Mention new FreeBSD/arm target.
5540 * configure.tgt: Add arm*-*-freebsd*.
5541 * arm-fbsd-tdep.c: New file.
5542 * arm-fbsd-tdep.h: New file.
5543
fe220226
MR
55442017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5545
5546 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5547 `gdbarch_elfcore_write_linux_prpsinfo'.
5548 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5549 method.
5550 (elf_internal_linux_prpsinfo): Remove declaration.
5551 * gdbarch.h: Regenerate.
5552 * gdbarch.c: Regenerate.
5553
a2f63b2e
MR
55542017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5555
5556 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5557 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5558
458ca1d0
PA
55592017-10-11 Pedro Alves <palves@redhat.com>
5560
5561 * breakpoint.c (reattach_breakpoints): Delete.
5562 * breakpoint.h (reattach_breakpoints): Delete.
5563
905014d7
SM
55642017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5565
5566 * symfile.c (registered_sym_fns): Make struct, not typedef.
5567 (DEF_VEC_O (registered_sym_fns)): Remove.
5568 (symtab_fns): Change type to std::vector.
5569 (add_symtab_fns): Adjust.
5570 (find_sym_fns): Adjust.
5571
56d704da
AK
55722017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5573
5574 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5575 * arc-tdep.h (arc_arch_is_em): New function.
5576 (arc_arch_is_hs): Likewise.
5577
7fa29be9
EB
55782017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5579
5580 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5581 parentheses in the declaration.
5582 (macro_lookup_inclusion): Likewise.
5583 (macro_lookup_definition): Likewise.
5584 * p-lang.h (pascal_builtin_types): Likewise.
5585 * tui/tui-data.c (tui_win_list): Likewise.
5586 * tui/tui-data.h (tui_win_list): Likewise.
5587 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5588
d9b477e3
KB
55892017-10-11 Mark Rages <markrages@gmail.com>
5590
5591 * target-memory.c (block_boundaries): Fix for block address not
5592 aligned on block size.
5593
65630365
PA
55942017-10-10 Pedro Alves <palves@redhat.com>
5595 Tom Tromey <tom@tromey.com>
5596
5597 * breakpoint.c (struct captured_breakpoint_query_args)
5598 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5599 (print_breakpoint): New.
5600 * breakpoint.h (print_breakpoint): Declare.
5601 * common/common-exceptions.h (enum return_reason): Remove
5602 references to catch_exceptions.
5603 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5604 Delete.
5605 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5606 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5607 * gdb.h: Delete.
5608 * gdbthread.h (thread_select): Declare.
5609 * mi/mi-cmd-break.c: Don't include gdb.h.
5610 (breakpoint_notify): Use print_breakpoint.
5611 * mi/mi-cmd-catch.c: Don't include gdb.h.
5612 * mi/mi-interp.c: Don't include gdb.h.
5613 (mi_print_breakpoint_for_event): New.
5614 (mi_breakpoint_created, mi_breakpoint_modified): Use
5615 mi_print_breakpoint_for_event.
5616 * mi/mi-main.c: Don't include gdb.h.
5617 (mi_cmd_thread_select): Parse the global thread ID here. Use
5618 thread_select instead of gdb_thread_select.
5619 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5620 of using gdb_list_thread_ids.
5621 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5622 FILEIO_ENOSYS here.
5623 (remote_fileio_request): Use TRY/CATCH instead of
5624 catch_exceptions.
5625 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5626 (symbol_file_add_from_memory_wrapper): Delete.
5627 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5628 * thread.c: Don't include gdb.h.
5629 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5630 (thread_alive): Use thread_select.
5631 (do_captured_thread_select): Delete, parts salvaged as ...
5632 (thread_select): ... this new function.
5633 (gdb_thread_select): Delete.
5634
bf469271
PA
56352017-10-10 Pedro Alves <palves@redhat.com>
5636 Tom Tromey <tom@tromey.com>
5637
5638 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5639 and reverse logic.
5640 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5641 No longer macros. Instead ...
5642 (enum wp_check_result): They're now values of this new
5643 enumeration.
5644 (watchpoint_check): Change return type to wp_check_result and
5645 parameter type to bpstat.
5646 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5647 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5648 catch_errors. Reverse logic of watchpoint_check call.
5649 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5650 pointer as parameter.
5651 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5652 * common/common-exceptions.c (throw_exception_sjlj): Update
5653 comments to avoid mentioning catch_errors.
5654 * exceptions.c (catch_errors): Delete.
5655 * exceptions.h: Update comments to avoid mentioning catch_errors.
5656 (catch_errors_ftype, catch_errors): Delete.
5657 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5658 (hook_stop_stub): Delete.
5659 (restore_selected_frame): Change return type to void, and
5660 parameter type to const frame_id &.
5661 (restore_infcall_control_state): Use TRY/CATCH instead of
5662 catch_errors.
5663 * main.c (captured_command_loop): Return void and remove
5664 parameter. Remove references to catch_errors.
5665 (captured_main): Use TRY/CATCH instead of catch_errors.
5666 * objc-lang.c (objc_submethod_helper_data)
5667 (find_objc_msgcall_submethod_helper): Delete.
5668 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5669 catch_errors.
5670 * record-full.c (record_full_message): Return void.
5671 (record_full_message_args, record_full_message_wrapper): Delete.
5672 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5673 instead of catch_errors.
5674 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5675 parameter type to int.
5676 * solib-darwin.c (open_symbol_file_object): Ditto.
5677 * solib-dsbt.c (open_symbol_file_object): Ditto.
5678 * solib-frv.c (open_symbol_file_object): Ditto.
5679 * solib-svr4.c (open_symbol_file_object): Ditto.
5680 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5681 * solib.c (update_solib_list): Use TRY/CATCH instead of
5682 catch_errors.
5683 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5684 Change type.
5685 * symmisc.c (struct print_symbol_args): Remove.
5686 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5687 (print_symbol): Change type.
5688 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5689 and remove parameters.
5690 (catch_errors): New.
5691 (get_windows_debug_event): Adjust.
5692
1a56bfa5
TT
56932017-10-09 Tom Tromey <tom@tromey.com>
5694
5695 * mi/mi-main.c (free_splay_tree): Remove.
5696 (list_available_thread_groups): Use splay_tree_up.
5697 * common/gdb_splay_tree.h: New file.
5698
0c478e2d
TT
56992017-10-09 Tom Tromey <tom@tromey.com>
5700
5701 * mi/mi-main.c (do_nothing): Remove.
5702 (list_available_thread_groups): Update.
5703
cbd2b4e3
PA
57042017-10-09 Pedro Alves <palves@redhat.com>
5705
5706 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5707 reading registers when switching context.
5708
a181c0bf
JB
57092017-10-09 John Baldwin <jhb@FreeBSD.org>
5710
5711 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5712 (fbsd_convert_siginfo): Likewise.
5713 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5714
6e66f753
SM
57152017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5716
5717 * configure.ac (try_guile_versions): Remove guile-2.2.
5718 * configure: Regenerate.
5719
890e9790
TT
57202017-10-09 Tom Tromey <tom@tromey.com>
5721
5722 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5723 (COMPILE.pre): Use $(CXX).
5724
109483d9
PA
57252017-10-09 Pedro Alves <palves@redhat.com>
5726
5727 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5728 Use bool.
5729 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5730 * cp-support.h (cp_remove_params): Now returns a
5731 gdb::unique_xmalloc_ptr.
5732 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5733 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5734 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5735 returning a gdb::unique_xmalloc_ptr.
5736 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5737 * stack.c (find_frame_funname): Adjust to cp_remove_params
5738 returning a gdb::unique_xmalloc_ptr.
5739
791afaa2
TT
57402017-10-08 Tom Tromey <tom@tromey.com>
5741
5742 * dwarf2read.c (dwarf2_get_dwz_file): Use
5743 gdb::unique_xmalloc_ptr.
5744 (find_slot_in_mapped_hash): Likewise.
5745 (dwarf2_physname): Likewise.
5746 (create_dwo_unit_in_dwp_v1): Use std::string.
5747 (create_dwo_unit_in_dwp_v2): Likewise.
5748 (lookup_dwo_cutu): Likewise.
5749 (inherit_abstract_dies): Use std::vector.
5750 (read_array_type): Likewise.
5751 (dwarf_decode_macros): Remove unused declaration.
5752 (unsigned_int_compar): Remove.
5753 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5754 (psymtabs_addrmap_cleanup): Remove.
5755
30a9c02f
TT
57562017-10-08 Tom Tromey <tom@tromey.com>
5757
5758 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5759 * frame.h (frame_cleanup_after_sniffer): Declare.
5760 (frame_prepare_for_sniffer): Return void.
5761 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5762 type of argument.
5763 (frame_prepare_for_sniffer): Return void.
5764
757325a3
TT
57652017-10-08 Tom Tromey <tom@tromey.com>
5766
5767 * utils.h (make_cleanup_value_free): Remove.
5768 * utils.c (do_value_free, struct cleanup): Remove.
5769 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5770 Use gdb_value_up.
5771 * value.h (struct value_deleter): New.
5772 (gdb_value_up): New typedef.
5773
b9c04fb2
TT
57742017-10-08 Tom Tromey <tom@tromey.com>
5775
5776 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5777 (make_cleanup_free_search_symbols): Remove.
5778 (search_symbols): Return std::vector.
5779 (symbol_search::compare_search_syms): Now member of
5780 symbol_search. Change arguments.
5781 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5782 (symtab_symbol_info, rbreak_command): Update.
5783 * symtab.h (struct symbol_search) <next>: Remove.
5784 Add constructors.
5785 (symbol_search::operator<): New function.
5786 (symbol_search::operator==): New function.
5787 (search_symbols): Remove std::vector.
5788 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5789 (symbol_search::compare_search_syms): Declare.
5790
0d28b0a5
YQ
57912017-10-06 Yao Qi <yao.qi@linaro.org>
5792
5793 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5794 arch/aarch64-insn.o.
5795 Remove one rule.
5796 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5797
71917808
YQ
57982017-10-06 Yao Qi <yao.qi@linaro.org>
5799
5800 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5801 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5802 arch/arm-linux.o respectively.
5803 * configure.tgt: Likewise.
5804
2081b2b2
YQ
58052017-10-06 Yao Qi <yao.qi@linaro.org>
5806
5807 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5808 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5809
a1b85d28
PA
58102017-10-06 Pedro Alves <palves@redhat.com>
5811
5812 * windows-nat.c: Include <algorithm>.
5813
d97987e2
YQ
58142017-10-06 Yao Qi <yao.qi@linaro.org>
5815
5816 * configure.tgt (i386_tobjs): New variable.
5817 (amd64_tobjs): New variable.
5818 Set $cpu_obs and $os_obs.
5819
f38307f5
YQ
58202017-10-06 Yao Qi <yao.qi@linaro.org>
5821
5822 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5823 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
5824 (clean): Remove object files and dependency files.
5825 (distclean): Remove the directory.
5826 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5827 * configure: Re-generated.
5828 * configure.tgt: Replace amd64.o with arch/amd64.o.
5829
2f924de6
JM
58302017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
5831
5832 PR build/22188
5833 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
5834 and SETEND.
5835
2fd9d7ca
PA
58362017-10-05 Pedro Alves <palves@redhat.com>
5837
5838 * linux-nat.c (linux_child_follow_fork): When following the parent
5839 and detaching the child, consult the parent thread's architecture
5840 instead of the child's.
5841
d13b8493
UW
58422017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5843
5844 * ax.h: Do not include "doublest.h".
5845 (union agent_val): Remove.
5846
3b4b2f16
UW
58472017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5848
5849 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
5850 (decimal_to_string): Return std::string object.
5851 (decimal_from_string): Accept std::string object. Return bool.
5852 (decimal_from_integral, decimal_from_doublest): Remove.
5853 (decimal_from_longest): Add prototype.
5854 (decimal_from_ulongest): Likewise.
5855 (decimal_to_longest): Likewise.
5856 (decimal_from_doublest): Likewise.
5857 * dfp.c: Do not include "gdbtypes.h" or "value.h".
5858 (MAX_DECIMAL_STRING): Move here.
5859 (decimal_to_string): Return std::string object.
5860 (decimal_from_string): Accept std::string object. Return bool.
5861 (decimal_from_integral): Remove, replace by ...
5862 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
5863 (decimal_to_longest): New function.
5864 (decimal_from_floating): Remove, replace by ...
5865 (decimal_from_doublest): ... this new function.
5866 (decimal_to_doublest): Update to new decimal_to_string interface.
5867
5868 * value.c (unpack_long): Use decimal_to_longest.
5869 * valops.c (value_cast): Use decimal_from_doublest instead of
5870 decimal_from_floating. Use decimal_from_[u]longest isntead of
5871 decimal_from_integral.
5872 * valarith.c (value_args_as_decimal): Likewise.
5873 * valprint.c (print_decimal_floating): Update to new
5874 decimal_to_string interface.
5875 * printcmd.c (printf_decfloat): Likewise.
5876 * c-exp.y (parse_number): Update to new decimal_from_string interface.
5877
1841ee5d
UW
58782017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5879
5880 * doublest.h: Do not include "floatformat.h". Remove stale comments.
5881 * gdbtypes.c: Include "floatformat.h".
5882 * value.c: Likewise.
5883 * m68k-tdep.c: Likewise.
5884
5885 * findvar.c: Do not include "floatformat.h".
5886 * amd64-darwin-tdep.c: Likewise.
5887 * arm-linux-tdep.c: Likewise.
5888 * i386-darwin-tdep.c: Likewise.
5889 * i387-tdep.c: Likewise.
5890 * m68k-linux-tdep.c: Likewise.
5891 * mep-tdep.c: Likewise.
5892 * mips-tdep.c: Likewise.
5893 * nios2-tdep.c: Likewise.
5894 * s390-linux-tdep.c: Likewise.
5895 * sparc-obsd-tdep.c: Likewise.
5896 * sparc-tdep.c: Likewise.
5897 * sparc64-tdep.c: Likewise.
5898 * spu-tdep.c: Likewise.
5899 * tic6x-tdep.c: Likewise.
5900 * tilegx-tdep.c: Likewise.
5901 * vax-tdep.c: Likewise.
5902 * xstormy16-tdep.c: Likewise.
5903 * xtensa-tdep.c: Likewise.
5904
5905 * top.c: Do not include "doublest.h".
5906 * aarch64-tdep.c: Likewise.
5907 * alpha-tdep.c: Likewise.
5908 * arm-linux-tdep.c: Likewise.
5909 * m68k-linux-tdep.c: Likewise.
5910 * tilegx-tdep.c: Likewise.
5911 * xstormy16-tdep.c: Likewise.
5912
a80a6471
JB
59132017-10-05 John Baldwin <jhb@FreeBSD.org>
5914
5915 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
5916 (mipsn32_fbsd_sigframe): Define.
5917 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
5918 for FreeBSD/mipsn32.
5919
12c4bd7f
JB
59202017-10-05 John Baldwin <jhb@FreeBSD.org>
5921
5922 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
5923 AT_HWCAP.
5924
c91933e9
TG
59252017-10-05 Tristan Gingold <tgingold@free.fr>
5926
5927 * MAINTAINERS (Misc): Update my email address.
5928
5cd63fda
PA
59292017-10-04 Pedro Alves <palves@redhat.com>
5930
5931 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
5932 it instead of target_gdbarch.
5933 (get_remote_state, get_remote_packet_size): Adjust
5934 get_remote_arch_state calls, passing down target_gdbarch
5935 explicitly.
5936 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
5937 'gdbarch' and use it instead of target_gdbarch.
5938 (get_memory_packet_size): Adjust get_remote_arch_state calls,
5939 passing down target_gdbarch explicitly.
5940 (struct stop_reply) <arch>: New field.
5941 (remote_parse_stop_reply): Use the stopped thread's architecture,
5942 not the current inferior's. Save the architecture in the
5943 stop_reply.
5944 (process_stop_reply): Use the stop reply's architecture.
5945 (process_g_packet, remote_fetch_registers)
5946 (remote_prepare_to_store, store_registers_using_G)
5947 (remote_store_registers): Adjust get_remote_arch_state calls,
5948 using the regcache's architecture.
5949 (remote_get_trace_status): Adjust get_remote_arch_state calls,
5950 passing down target_gdbarch explicitly.
5951 * spu-multiarch.c (spu_thread_architecture): Defer to the target
5952 beneath instead of calling target_gdbarch.
5953 * target.c (default_thread_architecture): Use the specified
5954 inferior's architecture, instead of the current inferior's
5955 architecture (via target_gdbarch).
5956
ed4227b7
PA
59572017-10-04 Pedro Alves <palves@redhat.com>
5958
5959 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
5960 case.
5961 (regcache_print): Handle !target_has_registers here instead.
5962
55b11ddf
PA
59632017-10-04 Pedro Alves <palves@redhat.com>
5964
5965 * frame.c (create_test_frame): Delete.
5966 * frame.h (create_test_frame): Delete.
5967 * gdbarch-selftests.c: Include gdbthread.h and target.h.
5968 (class regcache_test): Delete.
5969 (test_target_has_registers, test_target_has_stack)
5970 (test_target_has_memory, test_target_prepare_to_store)
5971 (test_target_store_registers): New functions.
5972 (test_target_ops): New class.
5973 (register_to_value_test): Error out if there's already a
5974 process_stratum (or higher) target pushed. Create a fuller mock
5975 environment, with mock target_ops, inferior, address space, thread
5976 and inferior_ptid.
5977 * progspace.c (struct address_space): Move to ...
5978 * progspace.h (struct address_space): ... here.
5979 * regcache.h (regcache::~regcache, regcache::raw_write)
5980 [GDB_SELF_TEST]: No longer virtual.
5981
4c71c105
SM
59822017-10-04 Simon Marchi <simon.marchi@ericsson.com>
5983
5984 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
5985
73dcd72d
PA
59862017-10-04 Pedro Alves <palves@redhat.com>
5987
5988 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
5989 out of 'between TRY and CATCH'.
5990
44704526
PA
59912017-10-04 Pedro Alves <palves@redhat.com>
5992
5993 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
5994 * common/common-exceptions.h (TRY): Open an outermost scope.
5995 Expand intro comment.
5996 (CATCH): Reindent.
5997 (END_CATCH): Close the outermost scope.
5998 * completer.c (complete_line_internal): Add missing END_CATCH.
5999
bc3b087d
SDJ
60002017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6001
6002 * NEWS (Changes since GDB 8.0): Add entry about new
6003 'set-cwd-on-gdbserver' feature.
6004 (New remote packets): Add entry for QSetWorkingDir.
6005 * common/common-inferior.h (set_inferior_cwd): New prototype.
6006 * infcmd.c (set_inferior_cwd): Remove "static".
6007 (show_cwd_command): Expand text to include remote debugging.
6008 * remote.c: Add PACKET_QSetWorkingDir.
6009 (remote_protocol_features) <QSetWorkingDir>: New entry for
6010 PACKET_QSetWorkingDir.
6011 (extended_remote_set_inferior_cwd): New function.
6012 (extended_remote_create_inferior): Call
6013 "extended_remote_set_inferior_cwd".
6014 (_initialize_remote): Call "add_packet_config_cmd" for
6015 QSetWorkingDir.
6016
d092c5a2
SDJ
60172017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6018
6019 * NEWS (New commands): Mention "set/show cwd".
6020 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
6021 "cd" command's help text.
6022 * common/common-inferior.h (get_inferior_cwd): New prototype.
6023 * infcmd.c (inferior_cwd_scratch): New global variable.
6024 (set_inferior_cwd): New function.
6025 (get_inferior_cwd): Likewise.
6026 (set_cwd_command): Likewise.
6027 (show_cwd_command): Likewise.
6028 (_initialize_infcmd): Add "set/show cwd" commands.
6029 * inferior.h (class inferior) <cwd>: New field.
6030 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
6031 (fork_inferior): Change inferior's cwd before its execution.
6032 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
6033 to CreateProcess.
6034
7da0a886
SDJ
60352017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6036
6037 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
6038 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
6039 (COMMON_OBS): Add gdb_tilde_expand.o.
6040 * common/gdb_tilde_expand.c: New file.
6041 * common/gdb_tilde_expand.h: Likewise.
6042
db8dd160
MR
60432017-10-03 Maciej W. Rozycki <macro@imgtec.com>
6044
6045 * gdbarch.sh (objfile): Remove duplicate declaration.
6046 * gdbarch.h: Regenerate.
6047
f8bfbf22
TT
60482017-10-03 Tom Tromey <tom@tromey.com>
6049
6050 * utils.c (internal_vproblem): Use string_vprintf.
6051
5178ed48
TT
60522017-10-03 Tom Tromey <tom@tromey.com>
6053
6054 * printcmd.c (info_symbol_command): Use std::string.
6055
8cff8730
TT
60562017-10-03 Tom Tromey <tom@tromey.com>
6057
6058 * top.c (gdb_safe_append_history): Use std::string.
6059
895b8f30
TT
60602017-10-03 Tom Tromey <tom@tromey.com>
6061
6062 * event-top.c (stdin_event_handler): Update.
6063 * main.c (captured_main_1): Update.
6064 * top.h (make_delete_ui_cleanup): Remove.
6065 (struct ui): Add constructor and destructor.
6066 (new_ui, delete_ui): Remove.
6067 * top.c (make_delete_ui_cleanup): Remove.
6068 (new_ui_command): Use std::unique_ptr.
6069 (delete_ui_cleanup): Remove.
6070 (ui::ui): Rename from new_ui. Update.
6071 (free_ui): Remove.
6072 (ui::~ui): Rename from delete_ui. Update.
6073
0efef640
TT
60742017-10-03 Tom Tromey <tom@tromey.com>
6075
6076 * symfile.c (load_progress): Use gdb::byte_vector.
6077
245ad7d3
TT
60782017-10-03 Tom Tromey <tom@tromey.com>
6079
6080 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
6081 declaration.
6082 * printcmd.c (x_command): Remove unused declaration.
6083 * symfile.c (symbol_file_command): Remove unused declaration.
6084
e05550d7
TT
60852017-10-03 Tom Tromey <tom@tromey.com>
6086
6087 * utils.c (internal_vproblem): Use std::string.
6088 (defaulted_query): Likewise.
6089
b95de2b7
TT
60902017-10-03 Tom Tromey <tom@tromey.com>
6091
6092 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
6093 * top.c (execute_command_to_string): Update.
6094 * utils.c (make_cleanup_restore_page_info): Remove.
6095 (do_restore_page_info_cleanup): Remove.
6096 (set_batch_flag_and_restore_page_info):
6097 New.
6098 (make_cleanup_restore_page_info): Remove.
6099 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6100 (~set_batch_flag_and_restore_page_info): New
6101 (make_cleanup_restore_uinteger): Remove.
6102 (make_cleanup_restore_integer): Remove.
6103 (struct restore_integer_closure): Remove.
6104 (restore_integer): Remove.
6105 * utils.h (struct set_batch_flag_and_restore_page_info): New
6106 class.
6107 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6108 (make_cleanup_restore_page_info): Remove.
6109 (make_cleanup_restore_uinteger) Remove.
6110 (make_cleanup_restore_integer) Remove.
6111
07036511
TT
61122017-10-03 Tom Tromey <tom@tromey.com>
6113
6114 * record-full.h (record_full_gdb_operation_disable_set): Return
6115 scoped_restore_tmpl<int>.
6116 * infrun.c (adjust_pc_after_break): Update.
6117 (handle_signal_stop): Update.
6118 * record-full.c (record_full_gdb_operation_disable_set): Return
6119 scoped_restore_tmpl<int>.
6120 (record_full_wait_1, record_full_insert_breakpoint)
6121 (record_full_remove_breakpoint, record_full_save)
6122 (record_full_goto_insn): Update.
6123
45320ffa
TT
61242017-10-02 Tom Tromey <tom@tromey.com>
6125
6126 PR rust/22236:
6127 * rust-lang.c (rust_val_print_str): New function.
6128 (val_print_struct): Call it.
6129 (rust_subscript): Preserve name of slice type.
6130
b3e3859b
TT
61312017-10-02 Tom Tromey <tom@tromey.com>
6132
6133 * rust-lang.c (rust_subscript): Handle slices in
6134 EVAL_AVOID_SIDE_EFFECTS case.
6135
01af5e0d
TT
61362017-10-02 Tom Tromey <tom@tromey.com>
6137
6138 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
6139
888e3ddb
TT
61402017-10-02 Tom Tromey <tom@tromey.com>
6141
6142 * rust-lang.h (rust_slice_type): Add "extern".
6143
cc536b21
PA
61442017-10-02 Tom Tromey <tom@tromey.com>
6145 Pedro Alves <palves@redhat.com>
6146
6147 * ada-lang.h (ada_exc_info::operator<): Make const.
6148 (ada_exc_info::operator==): Make const.
6149 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
6150 Make const.
6151
386c8614
TT
61522017-09-29 Tom Tromey <tom@tromey.com>
6153
6154 * target.c (read_whatever_is_readable): Change type of "result".
6155 Update.
6156 (free_memory_read_result_vector): Remove.
6157 (read_memory_robust): Change return type. Update.
6158 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
6159 bin2hex, std::string.
6160 * target.h (memory_read_result_s): Remove typedef.
6161 (free_memory_read_result_vector): Remove.
6162 (read_memory_robust): Return std::vector.
6163
789c4b5e
TT
61642017-09-29 Tom Tromey <tom@tromey.com>
6165
6166 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
6167
ab816a27
TT
61682017-09-29 Tom Tromey <tom@tromey.com>
6169
6170 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
6171 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
6172 operator< and operator==.
6173 (ada_exceptions_list): Return a std::vector.
6174 * ada-lang.c (ada_exc_info::operator<): Rename from
6175 compare_ada_exception_info.
6176 (ada_exc_info::operator==): New.
6177 (sort_remove_dups_ada_exceptions_list): Change type of
6178 "exceptions".
6179 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
6180 (ada_add_global_exceptions): Likewise.
6181 (ada_exceptions_list_1): Return a std::vector.
6182 (ada_exceptions_list): Likewise.
6183
52f9abe4
TT
61842017-09-29 Tom Tromey <tom@tromey.com>
6185
6186 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
6187 'std::set *'.
6188 (print_one_inferior): Update.
6189 (free_vector_of_ints): Remove.
6190 (list_available_thread_groups): Change "ids" to std::set.
6191 (mi_cmd_list_thread_groups): Update.
6192 (struct collect_cores_data) <core>: Now a std::set.
6193 (collect_cores): Update.
6194 (unique): Remove.
6195 (print_one_inferior): Update.
6196
dcd5ddcc
TT
61972017-09-29 Tom Tromey <tom@tromey.com>
6198
6199 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
6200 (mi_execute_async_cli_command): Likewise.
6201 (mi_cmd_trace_frame_collected): Use field_fmt.
6202
45d288cc
TT
62032017-09-29 Tom Tromey <tom@tromey.com>
6204
6205 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
6206 gdb::byte_vector.
6207
6afe2f4a
TT
62082017-09-29 Tom Tromey <tom@tromey.com>
6209
6210 * mi/mi-parse.c (mi_parse): Remove unused declaration.
6211
9813429a
TT
62122017-09-29 Tom Tromey <tom@tromey.com>
6213
6214 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
6215
2d6960b4
TT
62162017-09-29 Tom Tromey <tom@tromey.com>
6217
6218 * varobj.h (varobj_gen_name): Return std::string.
6219 * varobj.c (varobj_gen_name): Return std::string.
6220 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
6221 (mi_cmd_var_delete): Don't copy "name".
6222
784c453a
TT
62232017-09-29 Tom Tromey <tom@tromey.com>
6224
6225 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
6226 (mi_cmd_break_insert_1): Update.
6227
a9bc57b9
TT
62282017-09-29 Tom Tromey <tom@tromey.com>
6229
6230 * target.h (make_scoped_defer_target_commit_resume): Update.
6231 * target.c (make_scoped_defer_target_commit_resume): Rename from
6232 make_cleanup_defer_target_commit_resume. Return a
6233 scoped_restore.
6234 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
6235
9754d8c4
TT
62362017-09-29 Tom Tromey <tom@tromey.com>
6237
6238 * main.c (captured_main_1): Remove unused declaration.
6239 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
6240
99ef965c
TT
62412017-09-29 Tom Tromey <tom@tromey.com>
6242
6243 * symtab.c (search_symbols): Remove unused outer cleanup.
6244 (make_source_files_completion_list): Remove unused declaration.
6245
42518ba7
TT
62462017-09-29 Tom Tromey <tom@tromey.com>
6247
6248 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
6249
726b2169
TT
62502017-09-29 Tom Tromey <tom@tromey.com>
6251
6252 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
6253 gdb::byte_vector.
6254
55b06432
TT
62552017-09-29 Tom Tromey <tom@tromey.com>
6256
6257 * complaints.c (vcomplaint): Use std::string.
6258
8abcee91
TT
62592017-09-29 Tom Tromey <tom@tromey.com>
6260
6261 * tracepoint.c (trace_variable_command): Use std::string.
6262 (encode_actions_1): Remove unused declarations.
6263 (create_tsv_from_upload): Use std::string.
6264
6ad94bc7
TT
62652017-09-29 Tom Tromey <tom@tromey.com>
6266
6267 * cp-support.c (gdb_demangle): Use std::string.
6268
2003f3d8
TT
62692017-09-29 Tom Tromey <tom@tromey.com>
6270
6271 * stack.c (parse_frame_specification): Use std::string
6272 (info_frame_command): Use gdb::unique_xmalloc_ptr.
6273
8f8accb5
TT
62742017-09-29 Tom Tromey <tom@tromey.com>
6275
6276 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
6277
200aa7b1
TT
62782017-09-29 Tom Tromey <tom@tromey.com>
6279
6280 * utils.c (vfprintf_maybe_filtered): Use std::string.
6281 (vfprintf_unfiltered): Likewise.
6282
606aae8a
TT
62832017-09-29 Tom Tromey <tom@tromey.com>
6284
6285 * event-top.c (top_level_prompt): Return std::string.
6286 (display_gdb_prompt): Update.
6287
bd413795
TT
62882017-09-29 Tom Tromey <tom@tromey.com>
6289
6290 * unittests/common-utils-selftests.c (format): New function.
6291 (string_vprintf_tests): New function.
6292 (_initialize_common_utils_selftests): Register new tests.
6293 * common/common-utils.c (string_vprintf): New function.
6294 * common/common-utils.h (string_vprintf): Declare.
6295
256642e8
PA
62962017-09-29 Pedro Alves <palves@redhat.com>
6297
6298 * common/rsp-low.c (unpack_varlen_hex): Constify.
6299 * common/rsp-low.h (unpack_varlen_hex): Constify.
6300 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6301 Constify.
6302 * remote.c (remote_set_permissions, read_ptid)
6303 (remote_current_thread, remote_get_threads_with_qthreadinfo)
6304 (remote_static_tracepoint_marker_at)
6305 (remote_static_tracepoint_markers_by_strid)
6306 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
6307 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
6308 (parse_tracepoint_definition, parse_tsv_definition)
6309 (parse_static_tracepoint_marker_definition): Constify.
6310 * tracepoint.h (parse_static_tracepoint_marker_definition)
6311 (parse_trace_status, parse_tracepoint_status)
6312 (parse_tracepoint_definition, parse_tsv_definition): Constify.
6313
b6bb3468
PA
63142017-09-29 Pedro Alves <palves@redhat.com>
6315
6316 * remote.c (target_buf, target_buf_size): Delete.
6317 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
6318 Use the connection's packet buffer instead.
6319 All callers adjusted.
6320 (_initialize_remote): Remove references to target_buf and
6321 target_buf_size.
6322
b2f8eb7a
PA
63232017-09-28 Pedro Alves <palves@redhat.com>
6324
6325 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6326 unittests/common-utils-selftests.c.
6327 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
6328 (COMMON_OBS): Remove utils-selftests.o.
6329 * utils-selftests.c: Move to ...
6330 * unittests/common-utils-selftests.c: ... here and rename self
6331 test to "string_printf".
6332
08302ed2
DE
63332017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
6334
6335 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
6336 having NULL cus or tus.
6337
96a5a1d3
UW
63382017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6339
6340 * arm-tdep.c: (convert_from_extended): Remove.
6341 (convert_to_extended): Likewise.
6342 (arm_extract_return_value): Use convert_typed_floating.
6343 (arm_store_return_value): Likewise.
6344
6345 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6346 * sh-tdep.c: Do not include "floatformat.h".
6347 (sh_littlebyte_bigword_type): New function.
6348 (sh_register_convert_to_virtual): Use convert_typed_floating.
6349 (sh_register_convert_to_raw): Likewise.
6350 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6351 (sh64_littlebyte_bigword_type): New function.
6352 (sh64_extract_return_value): Use convert_typed_floating.
6353 (sh64_register_convert_to_virtual): Likewise.
6354 (sh64_register_convert_to_raw): Likewise.
6355
0db7851f
UW
63562017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6357
6358 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
6359 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
6360
6361 * gdbtypes.h (union type_specific): Make field floatformat hold
6362 just a single struct floatformat, not an array.
6363 (floatformat_from_type): Move here.
6364 * gdbtypes.c (floatformat_from_type): Move here. Update to
6365 changed TYPE_FLOATFORMAT definition.
6366 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
6367 (recursive_dump_type): Likewise.
6368 (init_float_type): Install correct floatformat for byte order.
6369 (arch_float_type): Likewise.
6370
77b7c781
UW
63712017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6372
6373 * gdbtypes.c (init_type): Change incoming argument from
6374 length-in-bytes to length-in-bits. Assert length is a
6375 multiple of TARGET_CHAR_BITS.
6376 (arch_type, arch_flags_type): Likewise.
6377 (init_integer_type): Update call to init_type.
6378 (init_character_type): Likewise.
6379 (init_boolean_type): Likewise.
6380 (init_float_type): Likewise.
6381 (init_decfloat_type): Likewise.
6382 (init_complex_type): Likewise.
6383 (init_pointer_type): Likewise.
6384 (objfile_type): Likewise.
6385 (arch_integer_type): Update call to arch_type.
6386 (arch_character_type): Likewise.
6387 (arch_boolean_type): Likewise.
6388 (arch_float_type): Likewise.
6389 (arch_decfloat_type): Likewise.
6390 (arch_complex_type): Likewise.
6391 (arch_pointer_type): Likewise.
6392 (gdbtypes_post_init): Likewise.
6393
6394 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
6395 (read_base_type): Likewise.
6396 * mdebugread.c (basic_type): Likewise.
6397 * stabsread.c (dbx_init_float_type): Likewise.
6398 (rs6000_builtin_type): Likewise.
6399 (read_range_type): Likewise. Also, fix call to init_integer_type
6400 with erroneous length argument.
6401
6402 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
6403 * d-lang.c (build_d_types): Likewise.
6404 * f-lang.c (build_fortran_types): Likewise.
6405 * go-lang.c (build_go_types): Likewise.
6406 * opencl-lang.c (build_opencl_types): Likewise.
6407 * jit.c (finalize_symtab): Likewise.
6408 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
6409 (build_std_type_info_type): Likewise.
6410 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
6411 update call to arch_flags_type.
6412
6413 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
6414 arch_type.
6415 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
6416 * windows-tdep.c (windows_get_tlb_type): Likewise.
6417
6418 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
6419 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6420 * m32c-tdep.c (make_types): Likewise.
6421 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
6422 (rl78_psw_type): Update call to arch_flags_type.
6423 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
6424 * rx-tdep.c (rx_psw_type): Likewise.
6425 (rx_fpsw_type): Likewise.
6426 * sparc-tdep.c (sparc_psr_type): Likewise.
6427 (sparc_fsr_type): Likewise.
6428 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
6429 (sparc64_ccr_type): Likewise.
6430 (sparc64_fsr_type): Likewise.
6431 (sparc64_fprs_type): Likewise.
6432
f21b4d5c
TT
64332017-09-27 Tom Tromey <tom@tromey.com>
6434
6435 * findcmd.c (find_command): Constify.
6436
643c2ffa
TT
64372017-09-27 Tom Tromey <tom@tromey.com>
6438
6439 * ada-tasks.c (task_command_1, task_command): Constify.
6440
510e5e56
TT
64412017-09-27 Tom Tromey <tom@tromey.com>
6442
6443 * symtab.c (maintenance_print_symbol_cache)
6444 (maintenance_flush_symbol_cache)
6445 (maintenance_print_symbol_cache_statistics): Constify.
6446
e503b191
TT
64472017-09-27 Tom Tromey <tom@tromey.com>
6448
6449 * inferior.c (detach_inferior_command, kill_inferior_command)
6450 (inferior_command): Constify.
6451
4e001312
TT
64522017-09-27 Tom Tromey <tom@tromey.com>
6453
6454 * regcache.c (regcache_print, maintenance_print_registers)
6455 (maintenance_print_raw_registers)
6456 (maintenance_print_cooked_registers)
6457 (maintenance_print_register_groups)
6458 (maintenance_print_remote_registers): Constify.
6459
77763700
TT
64602017-09-27 Tom Tromey <tom@tromey.com>
6461
6462 * printcmd.c (map_display_numbers, undisplay_command)
6463 (enable_disable_display_command, enable_display_command)
6464 (disable_display_command): Constify.
6465
4495129a
TT
64662017-09-27 Tom Tromey <tom@tromey.com>
6467
6468 * breakpoint.h (delete_command): Don't declare.
6469 * breakpoint.c (delete_command, enable_once_command)
6470 (enable_count_command, enable_delete_command, breakpoint_1)
6471 (maintenance_info_breakpoints, stopin_command, stopat_command)
6472 (delete_command, delete_trace_command, save_breakpoints)
6473 (save_breakpoints_command, save_tracepoints_command): Constify.
6474
3088cf40
TT
64752017-09-27 Tom Tromey <tom@tromey.com>
6476
6477 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6478 (skip_ws, extract_identifier, macro_define_command)
6479 (macro_undef_command, macro_list_command): Constify.
6480
69f476a3
TT
64812017-09-27 Tom Tromey <tom@tromey.com>
6482
6483 * infcmd.c (environment_info, set_environment_command)
6484 (unset_environment_command, path_info, info_proc_cmd_1)
6485 (info_proc_cmd_mappings, info_proc_cmd_stat)
6486 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6487 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6488
c4a3e68e
TT
64892017-09-27 Tom Tromey <tom@tromey.com>
6490
6491 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6492 Constify.
6493
c9d31bd6
TT
64942017-09-27 Tom Tromey <tom@tromey.com>
6495
6496 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6497
1f3f85eb
TT
64982017-09-27 Tom Tromey <tom@tromey.com>
6499
6500 * demangle.c (demangle_command): Constify.
6501
9c504b5d
TT
65022017-09-27 Tom Tromey <tom@tromey.com>
6503
6504 * progspace.c (maintenance_info_program_spaces_command):
6505 Constify.
6506
6663cf91
TT
65072017-09-27 Tom Tromey <tom@tromey.com>
6508
6509 * compile/compile.c (check_raw_argument, compile_file_command)
6510 (compile_code_command, compile_print_command): Constify.
6511
34e5fa26
TT
65122017-09-27 Tom Tromey <tom@tromey.com>
6513
6514 * reggroups.c (maintenance_print_reggroups): Constify.
6515
8384c356
TT
65162017-09-27 Tom Tromey <tom@tromey.com>
6517
6518 * dwarf2read.c (save_gdb_index_command): Constify.
6519
884beb0c
TT
65202017-09-27 Tom Tromey <tom@tromey.com>
6521
6522 * stap-probe.c (info_probes_stap_command): Constify.
6523
e0b2930c
TT
65242017-09-27 Tom Tromey <tom@tromey.com>
6525
6526 * fork-child.c (unset_exec_wrapper_command): Constify.
6527
f938677d
TT
65282017-09-27 Tom Tromey <tom@tromey.com>
6529
6530 * btrace.c (get_uint, get_context_size, no_chunk)
6531 (maint_btrace_packet_history_cmd)
6532 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6533 (maint_info_btrace_cmd): Constify.
6534
8949cb87
TT
65352017-09-27 Tom Tromey <tom@tromey.com>
6536
6537 * reverse.c (delete_bookmark_command): Constify.
6538
ac88e2de
TT
65392017-09-27 Tom Tromey <tom@tromey.com>
6540
6541 * remote.c (set_memory_packet_size)
6542 (set_memory_write_packet_size, show_memory_write_packet_size)
6543 (set_memory_read_packet_size, show_memory_read_packet_size)
6544 (compare_sections_command, packet_command, remote_put_command)
6545 (remote_get_command, remote_delete_command): Constify.
6546
bd4c9dfe
TT
65472017-09-27 Tom Tromey <tom@tromey.com>
6548
6549 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6550 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6551 (set_mipsfpu_auto_command): Constify.
6552
5e93d4c6
TT
65532017-09-27 Tom Tromey <tom@tromey.com>
6554
6555 * cli/cli-cmds.h (cd_command): Constify.
6556 * cli/cli-cmds.c (cd_command): Constify.
6557
fc41a75b
TT
65582017-09-27 Tom Tromey <tom@tromey.com>
6559
6560 * thread.c (thread_name_command, thread_find_command): Constify.
6561
67810076
TT
65622017-09-27 Tom Tromey <tom@tromey.com>
6563
6564 * probe.c (enable_probes_command, disable_probes_command):
6565 Constify.
6566
1d8b34a7
TT
65672017-09-27 Tom Tromey <tom@tromey.com>
6568
6569 * symfile.c (symbol_file_command): Constify.
6570 * gdbcore.h (deprecated_file_changed_hook): Constify.
6571 * exec.c (deprecated_file_changed_hook, exec_file_command)
6572 (file_command): Constify.
6573 * defs.h (symbol_file_command): Constify.
6574
442019e1
TT
65752017-09-27 Tom Tromey <tom@tromey.com>
6576
6577 * remote-fileio.c (set_system_call_allowed)
6578 (show_system_call_allowed): Constify.
6579
2983f7cb
TT
65802017-09-27 Tom Tromey <tom@tromey.com>
6581
6582 * tracepoint.c (delete_trace_variable_command)
6583 (tfind_end_command, tfind_start_command, tfind_pc_command)
6584 (tfind_tracepoint_command, tfind_line_command)
6585 (tfind_range_command, tfind_outside_command): Constify.
6586
4fd41b24
TT
65872017-09-27 Tom Tromey <tom@tromey.com>
6588
6589 * ax-gdb.c (maint_agent_printf_command, agent_command)
6590 (agent_eval_command): Constify.
6591
f2fc3015
TT
65922017-09-27 Tom Tromey <tom@tromey.com>
6593
6594 * tracepoint.c (info_scope_command): Constify.
6595 * python/python.c (gdbpy_decode_line): Constify.
6596 * python/py-breakpoint.c (bppy_init): Constify.
6597 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6598 * location.h: (new_linespec_location)
6599 (string_to_event_location_basic, string_to_event_location):
6600 Constify.
6601 * location.c (new_linespec_location)
6602 (string_to_event_location_basic, string_to_event_location):
6603 Constify.
6604 * linespec.h (decode_line_with_current_source)
6605 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6606 * linespec.c (linespec_lex_to_end)
6607 (decode_line_with_current_source)
6608 (decode_line_with_last_displayed): Constify.
6609 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6610 Constify.
6611 * cli/cli-cmds.c (edit_command, list_command): Constify.
6612 * breakpoint.h (until_break_command, watch_command_wrapper)
6613 (awatch_command_wrapper, rwatch_command_wrapper)
6614 (init_ada_exception_breakpoint): Constify.
6615 * breakpoint.c (break_command_1, dprintf_command)
6616 (break_range_command, watch_command_wrapper)
6617 (rwatch_command_wrapper, awatch_command_wrapper)
6618 (until_break_command, init_ada_exception_breakpoint)
6619 (strace_marker_create_sals_from_location, trace_command)
6620 (ftrace_command, strace_command, struct tracepoint): Constify.
6621 * ax-gdb.c (agent_command_1): Constify.
6622 * ada-lang.c (ada_exception_sal): Constify.
6623
8c2f95f4
TT
66242017-09-27 Tom Tromey <tom@tromey.com>
6625
6626 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6627 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6628 (get_context_size, no_chunk, get_insn_history_modifiers)
6629 (cmd_record_insn_history, get_call_history_modifiers)
6630 (cmd_record_call_history): Constify.
6631
a0d65762
TT
66322017-09-27 Tom Tromey <tom@tromey.com>
6633
6634 * source.c (show_substitute_path_command)
6635 (unset_substitute_path_command, set_substitute_path_command):
6636 Constify.
6637
58971144
TT
66382017-09-27 Tom Tromey <tom@tromey.com>
6639
6640 * typeprint.c (maintenance_print_type): Constify.
6641 * maint.c (maintenance_dump_me, maintenance_demangle)
6642 (maintenance_time_display, maintenance_info_sections)
6643 (maintenance_print_statistics, maintenance_deprecate)
6644 (maintenance_undeprecate): Constify.
6645 (maintenance_do_deprecate): Constify. Use std::string.
6646 (maintenance_selftest): Constify.
6647 * gdbtypes.h (maintenance_print_type): Constify.
6648
c482f52c
TT
66492017-09-27 Tom Tromey <tom@tromey.com>
6650
6651 * hppa-tdep.c (unwind_command): Constify.
6652
e100df1a
TT
66532017-09-27 Tom Tromey <tom@tromey.com>
6654
6655 * target-descriptions.c (unset_tdesc_filename_cmd)
6656 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6657 Constify.
6658
31d56ade
TT
66592017-09-27 Tom Tromey <tom@tromey.com>
6660
6661 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6662
b961da0b
TT
66632017-09-27 Tom Tromey <tom@tromey.com>
6664
6665 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6666
e2d8ae16
TT
66672017-09-27 Tom Tromey <tom@tromey.com>
6668
6669 * tui/tui-regs.c (tui_reg_command): Constify.
6670
863779b0
TT
66712017-09-27 Tom Tromey <tom@tromey.com>
6672
6673 * skip.c (skip_file_command, skip_function_command)
6674 (skip_enable_command, skip_disable_command, skip_delete_command):
6675 Constify.
6676
cdb34d4a
TT
66772017-09-27 Tom Tromey <tom@tromey.com>
6678
6679 * record-btrace.c (cmd_record_btrace_bts_start)
6680 (cmd_record_btrace_pt_start): Constify.
6681
e99c83e7
TT
66822017-09-27 Tom Tromey <tom@tromey.com>
6683
6684 * symmisc.c (maintenance_print_symbols)
6685 (maintenance_print_msymbols, maintenance_print_objfiles)
6686 (maintenance_info_symtabs, maintenance_check_symtabs)
6687 (maintenance_expand_symtabs, maintenance_info_line_tables):
6688 Constify.
6689
32faf971
TT
66902017-09-27 Tom Tromey <tom@tromey.com>
6691
6692 * top.c (new_ui_command): Constify.
6693
2cf311eb
TT
66942017-09-27 Tom Tromey <tom@tromey.com>
6695
6696 * symfile.c (add_symbol_file_command)
6697 (remove_symbol_file_command, list_overlays_command)
6698 (map_overlay_command, unmap_overlay_command)
6699 (overlay_auto_command, overlay_manual_command)
6700 (overlay_off_command, overlay_load_command): Constify.
6701
e6738699
TT
67022017-09-27 Tom Tromey <tom@tromey.com>
6703
6704 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6705 (info_spu_mailbox_command, info_spu_dma_command)
6706 (info_spu_proxydma_command): Constify.
6707
aa360cd5
TT
67082017-09-27 Tom Tromey <tom@tromey.com>
6709
6710 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6711
898241a5
TT
67122017-09-27 Tom Tromey <tom@tromey.com>
6713
6714 * cli/cli-script.c (user_defined_command): Constify.
6715
2d0ac106
TT
67162017-09-27 Tom Tromey <tom@tromey.com>
6717
6718 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6719 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6720 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6721 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6722 (dump_binary_value, append_binary_memory, append_binary_value):
6723 Constify.
6724 (struct dump_context) <func>: Constify.
6725 (add_dump_command): Update.
6726
dede02ce
TT
67272017-09-27 Tom Tromey <tom@tromey.com>
6728
6729 * cli/cli-cmds.c (show_version, show_configuration)
6730 (source_command, show_user): Constify.
6731
d3cb6b99
TT
67322017-09-27 Tom Tromey <tom@tromey.com>
6733
6734 * target.c (maintenance_print_target_stack): Constify.
6735
1970a12f
TT
67362017-09-27 Tom Tromey <tom@tromey.com>
6737
6738 * interps.c (interpreter_exec_cmd): Constify.
6739
41243651
TT
67402017-09-27 Tom Tromey <tom@tromey.com>
6741
6742 * record-full.c (cmd_record_full_restore): Constify.
6743
4465d9db
TT
67442017-09-27 Tom Tromey <tom@tromey.com>
6745
6746 * memattr.c (enable_mem_command, disable_mem_command)
6747 (delete_mem_command): Constify.
6748
ad25e423
TT
67492017-09-27 Tom Tromey <tom@tromey.com>
6750
6751 * value.c (show_convenience): Constify.
6752
d64097b1
TT
67532017-09-27 Tom Tromey <tom@tromey.com>
6754
6755 * gdbcore.h (core_file_command): Update.
6756 * corefile.c (core_file_command): Constify.
6757
4d4589ef
TT
67582017-09-27 Tom Tromey <tom@tromey.com>
6759
6760 * user-regs.c (maintenance_print_user_registers): Constify.
6761
32a7bf17
TT
67622017-09-27 Tom Tromey <tom@tromey.com>
6763
6764 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6765
4a475551
TT
67662017-09-27 Tom Tromey <tom@tromey.com>
6767
6768 * cp-support.c (first_component_command): Constify.
6769
990b9f9f
TT
67702017-09-27 Tom Tromey <tom@tromey.com>
6771
6772 * psymtab.c (maintenance_print_psymbols)
6773 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6774 Constify.
6775
c281872e
TT
67762017-09-27 Tom Tromey <tom@tromey.com>
6777
6778 * windows-tdep.c (display_tib): Constify.
6779
5b64bf74
TT
67802017-09-27 Tom Tromey <tom@tromey.com>
6781
6782 * linux-fork.c (delete_checkpoint_command)
6783 (detach_checkpoint_command): Constify.
6784
4ada038f
TT
67852017-09-27 Tom Tromey <tom@tromey.com>
6786
6787 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6788
57f5a81b
TT
67892017-09-27 Tom Tromey <tom@tromey.com>
6790
6791 * arc-tdep.c (dump_arc_instruction_command): Constify.
6792
b0a8e6c4
TT
67932017-09-27 Tom Tromey <tom@tromey.com>
6794
6795 * valprint.c (set_radix, show_radix): Constify.
6796
8d97dc1c
TT
67972017-09-27 Tom Tromey <tom@tromey.com>
6798
6799 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6800
eb7c454d
TT
68012017-09-27 Tom Tromey <tom@tromey.com>
6802
6803 * command.h (not_just_help_class_command): Update.
6804 * cli/cli-decode.h (not_just_help_class_command): Update.
6805 * cli/cli-decode.c (not_just_help_class_command): Constify.
6806
e4e33335
TT
68072017-09-27 Tom Tromey <tom@tromey.com>
6808
6809 * gdb_bfd.c (maintenance_info_bfds): Constify.
6810
0450cc4c
TT
68112017-09-27 Tom Tromey <tom@tromey.com>
6812
6813 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6814 overloads.
6815 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6816 (do_const_cfunc): New function.
6817 (cmd_cfunc_eq): New overload.
6818 (cli_user_command_p): Check do_const_cfunc.
6819 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6820 const_cfunc.
6821 * command.h (add_cmd): Add const overload and no-function
6822 overload.
6823 (set_cmd_cfunc): Add const overload.
6824 (cmd_const_cfunc_ftype): Declare.
6825 (cmd_cfunc_eq): Add const overload.
6826 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
6827 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
6828 overload.
6829
a9bbfbd8
TT
68302017-09-27 Tom Tromey <tom@tromey.com>
6831
6832 * macroexp.c (get_next_token_for_substitution): New function.
6833 (substitute_args): Call it. Check for __VA_OPT__.
6834
5230b05a
WT
68352017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6836 Pedro Alves <palves@redhat.com>
6837
6838 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
6839 producer_is_icc_lt_14.
6840 (producer_is_icc_lt_14): New function.
6841 (check_producer): Add code for checking version of ICC.
6842 (producer_is_icc): Move to producer.c.
6843 (read_structure_type): Restrict ICC workaround to ICC<14.
6844 * producer.c: Include selftest.h.
6845 (producer_is_icc, producer_parsing_tests, _initialize_producer):
6846 New functions.
6847 * producer.h (producer_is_icc): New declaration.
6848
b32b108a
WT
68492017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6850
6851 * Makefile.in (SFILES): Add producer.c.
6852 (COMMON_OBS): Add producer.o
6853 * amd64-tdep.c (producer.h): Add new include.
6854 * dwarf2read.c (producer.h): Add new include.
6855 * producer.c: New file.
6856 * producer.h: New file.
6857 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
6858 producer.c.
6859 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
6860 producer.h.
6861
5007d765
MK
68622017-09-26 Matthias Klose <doko@ubuntu.com>
6863
6864 * configure.ac: Search ncursesw before ncurses.
6865 Check ncursesw/ncurses.h before ncurses/ncurses.h.
6866 * gdb_curses.h: Include <ncursesw/ncurses.h>
6867 * config.in, configure: Regenerate.
6868
281c4447
RO
68692017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6870
6871 PR gdb/22185
6872 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
6873 obsolete.
6874 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
6875 Remove i386sol2 support.
6876 * configure.nat <i386sol2>: Remove.
6877 <sol2-64>: Fold into ...
6878 <sol2>: ... this.
6879 Move common settings to default section.
6880 Add sol-thread.o.
6881 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
6882 x86_64-*-solaris2.1[0-9]*>: Rename to ...
6883 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
6884 <i[34567]86-*-solaris*>: Remove.
6885 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
6886
6887 * configure.ac: Remove wctype in libw check.
6888 (_MSE_INT_H): Don't define on Solaris 7-9.
6889 <solaris*>: Remove libthread_db.so.1 check.
6890 * configure: Regenerate.
6891 * config.in: Regenerate.
6892
6893 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
6894 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
6895 (gdb_ps_size_t): Remove.
6896 Use base types in users.
6897 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
6898
6899 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
6900
39b06c20
RO
69012017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6902
6903 PR build/22206
6904 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
6905 (adi_is_addr_mapped): Likewise.
6906 (PSR_ICC): Don't redefine.
6907 (PSR_IMPL): Likewise.
6908
6c3e20f1
TT
69092017-09-25 Tom Tromey <tom@tromey.com>
6910
6911 * regcache.c (regcache::dump): Use string_printf.
6912
b292235f
TT
69132017-09-25 Tom Tromey <tom@tromey.com>
6914
6915 * regcache.c (class regcache_invalidator): New.
6916 (struct register_to_invalidate): Remove.
6917 (make_cleanup_regcache_invalidate): Remove.
6918 (regcache::raw_write): Use regcache_invalidator.
6919
9ac86b52
TT
69202017-09-25 Tom Tromey <tom@tromey.com>
6921
6922 * spu-tdep.c (spu2ppu_sniffer): Update.
6923 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
6924 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
6925 Remove.
6926 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
6927 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
6928 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
6929 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
6930 (frame_pop): Update.
6931
c0e383c6
TT
69322017-09-25 Tom Tromey <tom@tromey.com>
6933
6934 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
6935 * regcache.h (regcache_xfree): Don't declare.
6936 * regcache.c (regcache_xfree): Remove.
6937 (do_regcache_xfree): Use delete.
6938 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
6939 * linux-fork.c (free_fork): Use delete.
6940 (fork_save_infrun_state): Likewise.
6941 * jit.c (jit_dealloc_cache): Use delete.
6942 * infrun.c (discard_infcall_suspend_state): Use delete.
6943
791199cc
TT
69442017-09-25 Tom Tromey <tom@tromey.com>
6945
6946 * regcache.h (regcache_xmalloc): Don't declare.
6947 (regcache_raw_set_cached_value): Update comment.
6948 * regcache.c (regcache_xmalloc): Remove.
6949 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
6950 * jit.c (jit_frame_sniffer): Use new.
6951 * frame.c (frame_save_as_regcache): Use new.
6952
289e23aa
AA
69532017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6954
6955 * NEWS: Advertise support for guarded-storage registers on IBM z.
6956
1b63490c
AA
69572017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6958
6959 * s390-linux-nat.c (have_regset_gs): New static variable.
6960 (s390_linux_fetch_inferior_registers): Handle guarded-storage
6961 control block and guarded-storage broadcast control regsets.
6962 (s390_read_description): Detect whether the target has
6963 guarded-storage support, return appropriate tdesc.
6964 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
6965 (features/s390x-gs-linux64.c): Likewise.
6966 (struct gdbarch_tdep) <have_gs>: New field.
6967 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
6968 (s390_gsbc_regset): New variables.
6969 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
6970 and s390_gsbc_regset, if applicable.
6971 (s390_core_read_description): Check whether core file was from a
6972 target with guarded-storage support; include appropriate regsets.
6973 (s390_gdbarch_init): Add registers for guarded-storage support.
6974 (_initialize_s390_tdep): Initialize new target descriptions that
6975 include registers for guarded-storage support.
6976 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
6977 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
6978 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
6979 (S390_NUM_REGS): Adjust macro definition.
6980 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
6981 (tdesc_s390x_gs_linux64): New declarations.
6982
96235dc1
AA
69832017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6984
6985 * features/s390-gs-linux64.xml: New file.
6986 * features/s390-gs.xml: New file.
6987 * features/s390-gsbc.xml: New file.
6988 * features/s390x-gs-linux64.xml: New file.
6989 * features/Makefile (WHICH): Add s390-gs-linux64 and
6990 s390x-gs-linux64.
6991 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
6992 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
6993 * features/s390-gs-linux64.c: New generated file.
6994 * features/s390x-gs-linux64.c: New file.
6995 * regformats/s390-gs-linux64.dat: New file.
6996 * regformats/s390x-gs-linux64.dat: New file.
6997
b4a7c699
TT
69982017-09-23 Tom Tromey <tom@tromey.com>
6999
7000 * defs.h (make_cleanup_override_quit_handler): Don't declare.
7001
c2f97536
TT
70022017-09-22 Tom Tromey <tom@tromey.com>
7003
7004 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
7005 type to scoped_restore_tmpl.
7006 <scoped_input_handler>: Initialize m_quit_handler directly.
7007
43573013
SDJ
70082017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
7009
7010 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
7011 (cd_command): Likewise. Free "current_directory" before
7012 assigning to it.
7013 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
7014 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
7015 * top.c (gdb_dirbuf): Remove global declaration.
7016 * top.h (gdb_dirbuf): Likewise.
7017
6ec2e0f5
SDJ
70182017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
7019
7020 * gnulib/aclocal.m4: Regenerate.
7021 * gnulib/config.in: Regenerate.
7022 * gnulib/configure: Regenerate.
7023 * gnulib/import/Makefile.am: Regenerate.
7024 * gnulib/import/Makefile.in: Regenerate.
7025 * gnulib/import/assure.h: New file.
7026 * gnulib/import/at-func.c: Likewise
7027 * gnulib/import/chdir-long.c: New file.
7028 * gnulib/import/chdir-long.h: New file.
7029 * gnulib/import/cloexec.c: New file.
7030 * gnulib/import/cloexec.h: New file.
7031 * gnulib/import/close.c: New file.
7032 * gnulib/import/closedir.c: New file.
7033 * gnulib/import/dirent-private.h: New file.
7034 * gnulib/import/dup-safer.c: New file.
7035 * gnulib/import/dup.c: New file.
7036 * gnulib/import/dup2.c: New file.
7037 * gnulib/import/error.c: New file.
7038 * gnulib/import/error.h: New file.
7039 * gnulib/import/exitfail.c: New file.
7040 * gnulib/import/exitfail.h: New file.
7041 * gnulib/import/fchdir.c: New file.
7042 * gnulib/import/fcntl.c: New file.
7043 * gnulib/import/fcntl.in.h: New file.
7044 * gnulib/import/fd-hook.c: New file.
7045 * gnulib/import/fd-hook.h: New file.
7046 * gnulib/import/fd-safer.c: New file.
7047 * gnulib/import/fdopendir.c: New file.
7048 * gnulib/import/filename.h: New file.
7049 * gnulib/import/filenamecat-lgpl.c: New file.
7050 * gnulib/import/filenamecat.h: New file.
7051 * gnulib/import/fstat.c: New file.
7052 * gnulib/import/fstatat.c: New file.
7053 * gnulib/import/getcwd-lgpl.c: New file.
7054 * gnulib/import/getcwd.c: New file.
7055 * gnulib/import/getdtablesize.c: New file.
7056 * gnulib/import/getlogin_r.c: New file.
7057 * gnulib/import/getprogname.c: New file.
7058 * gnulib/import/getprogname.h: New file.
7059 * gnulib/import/gettext.h: New file.
7060 * gnulib/import/glob-libc.h: New file.
7061 * gnulib/import/glob.c: New file.
7062 * gnulib/import/glob.in.h: New file.
7063 * gnulib/import/intprops.h: New file.
7064 * gnulib/import/m4/chdir-long.m4: New file.
7065 * gnulib/import/m4/close.m4: New file.
7066 * gnulib/import/m4/closedir.m4: New file.
7067 * gnulib/import/m4/d-ino.m4: New file.
7068 * gnulib/import/m4/d-type.m4: New file.
7069 * gnulib/import/m4/dup.m4: New file.
7070 * gnulib/import/m4/dup2.m4: New file.
7071 * gnulib/import/m4/error.m4: New file.
7072 * gnulib/import/m4/fchdir.m4: New file.
7073 * gnulib/import/m4/fcntl.m4: New file.
7074 * gnulib/import/m4/fcntl_h.m4: New file.
7075 * gnulib/import/m4/fdopendir.m4: New file.
7076 * gnulib/import/m4/filenamecat.m4: New file.
7077 * gnulib/import/m4/fstat.m4: New file.
7078 * gnulib/import/m4/fstatat.m4: New file.
7079 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
7080 * gnulib/import/m4/getcwd-path-max.m4: New file.
7081 * gnulib/import/m4/getcwd.m4: New file.
7082 * gnulib/import/m4/getdtablesize.m4: New file.
7083 * gnulib/import/m4/getlogin_r.m4: New file.
7084 * gnulib/import/m4/getprogname.m4: New file.
7085 * gnulib/import/m4/glob.m4: New file.
7086 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7087 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7088 * gnulib/import/m4/mempcpy.m4: New file.
7089 * gnulib/import/m4/memrchr.m4: New file.
7090 * gnulib/import/m4/mode_t.m4: New file.
7091 * gnulib/import/m4/msvc-inval.m4: New file.
7092 * gnulib/import/m4/msvc-nothrow.m4: New file.
7093 * gnulib/import/m4/open.m4: New file.
7094 * gnulib/import/m4/openat.m4: New file.
7095 * gnulib/import/m4/opendir.m4: New file.
7096 * gnulib/import/m4/readdir.m4: New file.
7097 * gnulib/import/m4/realloc.m4: New file.
7098 * gnulib/import/m4/rewinddir.m4: New file.
7099 * gnulib/import/m4/save-cwd.m4: New file.
7100 * gnulib/import/m4/strdup.m4: New file.
7101 * gnulib/import/m4/strerror.m4: New file.
7102 * gnulib/import/m4/unistd-safer.m4: New file.
7103 * gnulib/import/mempcpy.c: New file.
7104 * gnulib/import/memrchr.c: New file.
7105 * gnulib/import/msvc-inval.c: New file.
7106 * gnulib/import/msvc-inval.h: New file.
7107 * gnulib/import/msvc-nothrow.c: New file.
7108 * gnulib/import/msvc-nothrow.h: New file.
7109 * gnulib/import/open.c: New file.
7110 * gnulib/import/openat-die.c: New file.
7111 * gnulib/import/openat-priv.h: New file.
7112 * gnulib/import/openat-proc.c: New file.
7113 * gnulib/import/openat.c: New file.
7114 * gnulib/import/openat.h: New file.
7115 * gnulib/import/opendir.c: New file.
7116 * gnulib/import/pipe-safer.c: New file.
7117 * gnulib/import/readdir.c: New file.
7118 * gnulib/import/realloc.c: New file.
7119 * gnulib/import/rewinddir.c: New file.
7120 * gnulib/import/save-cwd.c: New file.
7121 * gnulib/import/save-cwd.h: New file.
7122 * gnulib/import/strdup.c: New file.
7123 * gnulib/import/strerror-override.c: New file.
7124 * gnulib/import/strerror-override.h: New file.
7125 * gnulib/import/strerror.c: New file.
7126 * gnulib/import/unistd--.h: New file.
7127 * gnulib/import/unistd-safer.h: New file.
7128 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
7129 "getcwd" and "glob".
7130 * ser-tcp.c: Undefine "close" before redefining it.
7131
432ae719
SM
71322017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7133
7134 * guile/scm-value.c (gdbscm_value_address): Initialize address,
7135 get rid of res_val.
7136
4fa7574e
RO
71372017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7138
7139 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
7140 <sol2,sparc>: Likewise.
7141 <sol2-64,i386>: Likewise.
7142
7143 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
7144 -Wdeprecated-declarations on *-*-solaris*.
7145 * configure: Regenerate.
7146
7147 * procfs.c: Include "nat/inferior.h".
7148 (procfs_info_proc): Fix typo.
7149
f6327dcb
KB
71502017-09-21 Kevin Buettner <kevinb@redhat.com>
7151
7152 * remote.c (vector): Include.
7153 (struct private_thread_info): Add field, thread_handle.
7154 (free_private_thread_info): Deallocate storage associated with
7155 thread handle.
7156 (get_private_info_thread): Initialize `thread_handle' field.
7157 (struct thread_item): Add field, thread_handle.
7158 (clear_threads_listing_context): Deallocate storage associated
7159 with thread handle.
7160 (start_thread): Add support for "handle" attribute.
7161 (thread_attributes): Add "handle".
7162 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
7163 field.
7164 (remote_update_thread_list): Update thread_handle.
7165 (remote_thread_handle_to_thread_info): New function.
7166 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
7167
fbbe5337
KB
71682017-09-21 Kevin Buettner <kevinb@redhat.com>
7169
7170 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
7171 function.
7172 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
7173 * python/python-internal.h (thread_object_type): Declare.
7174
e04ee09e
KB
71752017-09-21 Kevin Buettner <kevinb@redhat.com>
7176
7177 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
7178 (target_thread_handle_to_thread_info): Declare.
7179 * target.c (target_thread_handle_to_thread_info): New function.
7180 * target-delegates.c: Regenerate.
7181 * gdbthread.h (find_thread_by_handle): Declare.
7182 * thread.c (find_thread_by_handle): New function.
7183 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
7184 function.
7185 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
7186
1e5b66ed
SM
71872017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7188
7189 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
7190
ebe48ba0
SM
71912017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7192
7193 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
7194
0a0bf5dc
YQ
71952017-09-21 Yao Qi <yao.qi@linaro.org>
7196
7197 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
7198 to gdb_target_obs.
7199
d1b0a7bf
TT
72002017-09-20 Tom Tromey <tom@tromey.com>
7201
7202 * breakpoint.c (struct counted_command_line): Remove.
7203 (breakpoint_commands): Update.
7204 (alloc_counted_command_line, incref_counted_command_line)
7205 (decref_counted_command_line, do_cleanup_counted_command_line)
7206 (make_cleanup_decref_counted_command_line): Remove.
7207 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
7208 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
7209 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
7210 (save_breakpoints): Update.
7211 * breakpoint.h (counted_command_line): Now a typedef to
7212 shared_ptr.
7213 (struct breakpoint) <commands>: Now a counted_command_line.
7214 (struct bpstats) <command>: Likewise.
7215
48649e1b
TT
72162017-09-20 Tom Tromey <tom@tromey.com>
7217
7218 * breakpoint.c (struct commands_info, do_map_commands_command):
7219 Remove.
7220 (commands_command_1): Update.
7221 (iterate_over_related_breakpoints): Take a function_view.
7222 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
7223 (delete_command): Update.
7224 (map_breakpoint_numbers): Take a function_view.
7225 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
7226 (disable_command): Update.
7227 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
7228 (enable_command): Update.
7229 (struct disp_data, do_enable_breakpoint_disp)
7230 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
7231 (do_map_enable_delete_breakpoint): Remove.
7232 (enable_once_command, enable_count_command, enable_delete_command)
7233 (delete_trace_variable_command): Update.
7234
04afa70c
TT
72352017-09-20 Tom Tromey <tom@tromey.com>
7236
7237 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
7238 (bpstat_clear): Use delete.
7239 (bpstats): New constructors.
7240 (bpstat_copy, bpstat_stop_status): Use new.
7241 (dprintf_after_condition_true): Update.
7242 * breakpoint.h (bpstats::bpstats): Add constructors.
7243 (bpstats::~bpstats): Add destructor.
7244
c83833f4
PA
72452017-09-20 Pedro Alves <palves@redhat.com>
7246
7247 * eval.c (make_params): Delete, refactored as ...
7248 (class fake_method): ... this new type's ctor.
7249 (fake_method::~fake_method): New.
7250 (evaluate_subexp_standard): Use 'fake_method'.
7251
223ffa71
TT
72522017-09-20 Tom Tromey <tom@tromey.com>
7253
7254 * windows-nat.c (get_windows_debug_event, windows_wait)
7255 (do_initial_windows_stuff, windows_attach): Update.
7256 * utils.c (vwarning, internal_vproblem): Update.
7257 (ui_unregister_input_event_handler_cleanup)
7258 (prepare_to_handle_input): Remove.
7259 (class scoped_input_handler): New.
7260 (defaulted_query, prompt_for_continue): Update.
7261 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
7262 Update.
7263 * top.c (undo_terminal_modifications_before_exit): Update.
7264 * target/target.h (target_terminal_init, target_terminal_inferior)
7265 (target_terminal_ours): Don't declare.
7266 (class target_terminal): New.
7267 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
7268 (target_terminal_ours_for_output)
7269 (make_cleanup_restore_target_terminal): Don't declare.
7270 (target_terminal_info): Remove.
7271 * target.c (enum terminal_state, terminal_state): Remove.
7272 (target_terminal::terminal_state): Define.
7273 (target_terminal::init): Rename from target_terminal_init.
7274 (target_terminal::inferior): Rename from
7275 target_terminal_inferior.
7276 (target_terminal::ours): Rename from target_terminal_ours.
7277 (target_terminal::ours_for_output): Rename from
7278 target_terminal_ours_for_output.
7279 (target_terminal::info): New method.
7280 (cleanup_restore_target_terminal)
7281 (make_cleanup_restore_target_terminal): Remove.
7282 * solib.c (handle_solib_event): Update.
7283 * remote.c (remote_serial_quit_handler): Update.
7284 (remote_terminal_inferior, remote_wait_as): Update.
7285 * record-full.c (record_full_wait_1): Update.
7286 * nto-procfs.c (procfs_create_inferior): Update.
7287 * nat/fork-inferior.c (startup_inferior): Update.
7288 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
7289 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
7290 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
7291 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
7292 (mi_breakpoint_created, mi_breakpoint_deleted)
7293 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
7294 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7295 (mi_user_selected_context_changed, report_initial_inferior):
7296 Update.
7297 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
7298 (linux_nat_terminal_inferior): Update.
7299 * infrun.c (follow_fork_inferior)
7300 (handle_vfork_child_exec_or_exit, do_target_resume)
7301 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
7302 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
7303 Update.
7304 * inflow.c (child_terminal_init, info_terminal_command): Update.
7305 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
7306 (attach_command): Update.
7307 * infcall.c (call_thread_fsm_should_stop): Update.
7308 * gnu-nat.c (gnu_attach): Update.
7309 * extension.c (struct active_ext_lang_state)
7310 (restore_active_ext_lang): Update.
7311 * exceptions.c (print_flush): Update.
7312 * event-top.c (async_enable_stdin, default_quit_handler): Update.
7313 (struct quit_handler_cleanup_data, restore_quit_handler)
7314 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
7315 Remove.
7316 * cp-support.c (gdb_demangle): Update.
7317 * breakpoint.c (update_inserted_breakpoint_locations)
7318 (insert_breakpoint_locations, handle_jit_event)
7319 (disable_breakpoints_in_unloaded_shlib): Update.
7320 * annotate.c (annotate_breakpoints_invalid)
7321 (annotate_frames_invalid): Update.
7322
013af3fc
TT
73232017-09-20 Tom Tromey <tom@tromey.com>
7324
7325 * main.c (catch_command_errors): Rename from
7326 catch_command_errors_const.
7327 (captured_main_1): Update.
7328
06871ae8
PA
73292017-09-20 Pedro Alves <palves@redhat.com>
7330
7331 * cli/cli-cmds.c (list_command): Use print_sal_location.
7332 (print_sal_location): New function.
7333 (ambiguous_line_spec): Use print_sal_location.
7334 * linespec.c (symbol_to_sal): Record the symbol in the sal.
7335 * symtab.c (find_function_start_sal): Likewise.
7336 * symtab.h (symtab_and_line::symbol): New field.
7337
e5f25bc5
PA
73382017-09-20 Pedro Alves <palves@redhat.com>
7339
7340 * linespec.c (minsym_found): Handle non-text minsyms.
7341 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
7342
1b7fa39e
WT
73432017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7344
7345 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
7346 backslash.
7347
37dd0825
WT
73482017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7349
7350 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
7351 vmovups instead vmovaps.
7352 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
7353
4e5a4f58
JB
73542017-09-19 John Baldwin <jhb@FreeBSD.org>
7355
7356 * NEWS (Changes since GDB 8.0): Add starti.
7357 * infcmd.c (enum run_break): New.
7358 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
7359 case.
7360 (run_command): Use enum run_how.
7361 (start_command): Likewise.
7362 (starti_command): New function.
7363 (RUN_ARGS_HELP): New macro.
7364 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
7365 commands. Add starti command.
7366
aa70c9f1
YQ
73672017-09-19 Yao Qi <yao.qi@linaro.org>
7368
7369 * Makefile.in (monitor.o): Remove the rule.
7370
d6541620
YQ
73712017-09-19 Yao Qi <yao.qi@linaro.org>
7372
7373 * annotate.h (struct annotate_arg_emitter): Use
7374 DISABLE_COPY_AND_ASSIGN.
7375 * common/refcounted-object.h (refcounted_object): Likewise.
7376 * completer.h (struct completion_result): Likewise.
7377 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
7378 * filename-seen-cache.h (filename_seen_cache): Likewise.
7379 * gdbcore.h (thread_section_name): Likewise.
7380 * gdb_regex.h (compiled_regex): Likewise.
7381 * gdbthread.h (scoped_restore_current_thread): Likewise.
7382 * inferior.h (scoped_restore_current_inferior): Likewise.
7383 * jit.c (jit_reader): Likewise.
7384 * linespec.h (struct linespec_result): Likewise.
7385 * mi/mi-parse.h (struct mi_parse): Likewise.
7386 * nat/fork-inferior.c (execv_argv): Likewise.
7387 * progspace.h (scoped_restore_current_program_space): Likewise.
7388 * python/python-internal.h (class gdbpy_enter): Likewise.
7389 * regcache.h (regcache): Likewise.
7390 * target-descriptions.c (struct tdesc_reg): Likewise.
7391 (struct tdesc_type): Likewise.
7392 (struct tdesc_feature): Likewise.
7393 * ui-out.h (ui_out_emit_type): Likewise.
7394
0615127c
SM
73952017-09-18 Simon Marchi <simon.marchi@ericsson.com>
7396
7397 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
7398 label abort_expression.
7399
5e187554
SM
74002017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7401
7402 * common/buffer.c (buffer_xml_printf): Adjust.
7403 * common/xml-utils.c (xml_escape_text): Change return type to
7404 std::string, update code accordingly.
7405 * common/xml-utils.h (xml_escape_text): Change return type to
7406 std::string.
7407 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
7408 * windows-tdep.c (windows_xfer_shared_library): Adjust.
7409 * unittests/xml-utils-selftests.c (test_xml_escape_text):
7410 Adjust.
7411
c3d7b541
SM
74122017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7413
7414 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
7415 (SUBDIR_UNITTESTS_OBS): Add new object file.
7416 * unittests/xml-utils-selftests.c: New file.
7417
1526853e
SM
74182017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7419
7420 * common/selftest.h (selftest): New struct/interface.
7421 (register_test): Add name parameter, add new overload.
7422 (run_tests): Add filter parameter.
7423 (for_each_selftest_ftype): New typedef.
7424 (for_each_selftest): New declaration.
7425 * common/selftest.c (tests): Change type to
7426 map<string, unique_ptr<selftest>>.
7427 (simple_selftest): New struct.
7428 (register_test): New function.
7429 (register_test): Add name parameter and use it.
7430 (run_tests): Add filter parameter and use it. Add prints.
7431 Adjust to vector -> map change.
7432 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
7433 registering selftests.
7434 * arm-tdep.c (_initialize_arm_tdep): Likewise.
7435 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
7436 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
7437 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
7438 * findvar.c (_initialize_findvar): Likewise.
7439 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
7440 * maint.c (maintenance_selftest): Update call to run_tests.
7441 (maintenance_info_selftests): New function.
7442 (_initialize_maint_cmds): Register "maintenance info selftests"
7443 command. Update "maintenance selftest" doc.
7444 * regcache.c (_initialize_regcache): Add names when registering
7445 selftests.
7446 * rust-exp.y (_initialize_rust_exp): Likewise.
7447 * selftest-arch.c (gdbarch_selftest): New struct.
7448 (gdbarch_tests): Remove.
7449 (register_test_foreach_arch): Add name parameter. Call
7450 register_test.
7451 (tests_with_arch): Remove, move most content to
7452 gdbarch_selftest::operator().
7453 (_initialize_selftests_foreach_arch): Remove.
7454 * selftest-arch.h (register_test_foreach_arch): Add name
7455 parameter.
7456 (run_tests_with_arch): New declaration.
7457 * utils-selftests.c (_initialize_utils_selftests): Add names
7458 when registering selftests.
7459 * utils.c (_initialize_utils): Likewise.
7460 * unittests/array-view-selftests.c
7461 (_initialize_array_view_selftests): Likewise.
7462 * unittests/environ-selftests.c (_initialize_environ_selftests):
7463 Likewise.
7464 * unittests/function-view-selftests.c
7465 (_initialize_function_view_selftests): Likewise.
7466 * unittests/offset-type-selftests.c
7467 (_initialize_offset_type_selftests): Likewise.
7468 * unittests/optional-selftests.c
7469 (_initialize_optional_selftests): Likewise.
7470 * unittests/scoped_restore-selftests.c
7471 (_initialize_scoped_restore_selftests): Likewise.
7472 * NEWS: Document "maintenance selftest" and "maint info
7473 selftests".
7474
5846367a
SM
74752017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7476
7477 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7478 scoped_restore.
7479
bd77e8ff
SM
74802017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7481
7482 * mi/mi-main.c (mi_load_progress): Make uiout variable
7483 a unique_ptr.
7484
26a67918
PA
74852017-09-15 Pedro Alves <palves@redhat.com>
7486
7487 * compile/compile-c-types.c (convert_enum, convert_int)
7488 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7489
3f8a7804
SM
74902017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7491
7492 * dwarf2read.c (copy_string): Remove.
7493 (parse_macro_definition): Replace copy_string with savestring.
7494
8d200706
YQ
74952017-09-15 Yao Qi <yao.qi@linaro.org>
7496
7497 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7498 gdb_target_obs.
7499 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7500 Likewise.
7501 (i[34567]86-*-linux*): Likewise.
7502
d185219d
SM
75032017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7504
7505 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7506 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7507 <stack>: Change type to std::vector.
7508 <stack_len, stack_allocated>: Remove.
7509 <grow_stack>: Remove.
7510 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7511 (dwarf_expr_context::~dwarf_expr_context): Remove.
7512 (dwarf_expr_context::grow_stack): Remove.
7513 (dwarf_expr_context::push): Adjust.
7514 (dwarf_expr_context::pop): Adjust.
7515 (dwarf_expr_context::fetch): Adjust.
7516 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7517 (dwarf_expr_context::stack_empty_p): Adjust.
7518 (dwarf_expr_context::execute_stack_op): Adjust.
7519
eccd80d6
SM
75202017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7521
7522 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7523 return type to bool.
7524 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7525
69009882
SM
75262017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7527
7528 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7529 Change type to bool.
7530 (dwarf_stack_value) <in_stack_memory>: Likewise.
7531 (dwarf_expr_context) <push_address>: Change parameter type to
7532 bool.
7533 <fetch_in_stack_memory>: Change return type to bool.
7534 <push>: Change parameter type to bool.
7535 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7536 to bool.
7537 (dwarf_expr_context::push_address): Likewise.
7538 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7539 to bool.
7540 (dwarf_expr_context::execute_stack_op): Adjust.
7541 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7542
1e467161
SM
75432017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7544
7545 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7546 (struct dwarf_expr_context) <n_pieces>: Remove.
7547 <pieces>: Change type to std::vector.
7548 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7549 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7550 pieces.
7551 (dwarf_expr_context::add_piece): Adjust.
7552 * dwarf2loc.c (struct piece_closure): Initialize fields.
7553 <n_pieces>: Remove.
7554 <pieces>: Change type to std::vector.
7555 (allocate_piece_closure): Adjust, change parameter to
7556 std::vector rvalue and std::move it to piece_closure.
7557 (rw_pieced_value): Adjust.
7558 (check_pieced_synthetic_pointer): Adjust.
7559 (indirect_synthetic_pointer): Adjust.
7560 (coerce_pieced_ref): Adjust.
7561 (free_pieced_value_closure): Adjust. Use delete to free
7562 piece_closure.
7563 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7564 to allocate_piece_closure.
7565 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7566
0782db84
SM
75672017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7568
7569 * probe.h (probe_ops_cp): Remove typedef.
7570 (DEF_VEC_P (probe_ops_cp)): Remove.
7571 (all_probe_ops): Change type to std::vector.
7572 * probe.c (info_probes_for_ops): Adjust to vector change.
7573 (probe_linespec_to_ops): Likewise.
7574 (all_probe_ops): Change type to std::vector.
7575 (_initialize_probe): Adjust to vector change.
7576 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7577 * elfread.c (elf_get_probes): Likewise.
7578 * stap-probe.c (_initialize_stap_probe): Likewise.
7579
1eac6bea
SM
75802017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7581
7582 * probe.h (struct bound_probe): Define constructors.
7583 * probe.c (bound_probe_s): Remove typedef.
7584 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7585 (collect_probes): Change return type to std::vector, remove
7586 cleanup.
7587 (compare_probes): Return bool, change parameter type. Change
7588 semantic to "less than".
7589 (gen_ui_out_table_header_info): Change parameter to std::vector
7590 and update.
7591 (exists_probe_with_pops): Likewise.
7592 (info_probes_for_ops): Update to std::vector change.
7593 (enable_probes_command): Likewise.
7594 (disable_probes_command): Likewise.
7595
aaa63a31
SM
75962017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7597
7598 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7599 vec to std::vector.
7600 * probe.c (parse_probes_in_pspace): Update.
7601 (find_probes_in_objfile): Update.
7602 (find_probe_by_pc): Update.
7603 (collect_probes): Update.
7604 (probe_any_get_probes): Update.
7605 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7606 return type to reference to std::vector.
7607 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7608 std::vector and update.
7609 (dtrace_process_dof): Likewise.
7610 (dtrace_get_probes): Likewise.
7611 * elfread.c (elf_get_probes): Change return type to std::vector,
7612 store an std::vector in bfd_data.
7613 (probe_key_free): Update to std::vector.
7614 * stap-probe.c (handle_stap_probe): Change parameter to
7615 std::vector and update.
7616 (stap_get_probes): Likewise.
7617 * symfile-debug.c (debug_sym_get_probes): Change return type to
7618 std::vector and update.
7619
cb85b21b
TT
76202017-09-11 Tom Tromey <tom@tromey.com>
7621
7622 * breakpoint.c (program_breakpoint_here_p): Update.
7623 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7624 from make_show_memory_breakpoints_cleanup. Return a
7625 scoped_restore_tmpl<int>.
7626 (restore_show_memory_breakpoints): Remove.
7627 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7628 * mem-break.c (memory_validate_breakpoint): Update.
7629 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7630 (ia64_memory_remove_breakpoint): Update.
7631 (ia64_breakpoint_from_pc): Update.
7632 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7633 from make_show_memory_breakpoints_cleanup.
7634
8fbc99ef
TT
76352017-09-11 Tom Tromey <tom@tromey.com>
7636
7637 * d-namespace.c (d_lookup_symbol): Use std::string.
7638 (find_symbol_in_baseclass): Likewise.
7639
50feb4bd
TT
76402017-09-11 Tom Tromey <tom@tromey.com>
7641
7642 * ctf.c (ctf_start): Use std::string.
7643
c6dc63a1
TT
76442017-09-11 Tom Tromey <tom@tromey.com>
7645
7646 * ada-lang.c (is_known_support_routine): Update.
7647 (ada_unhandled_exception_name_addr_from_raise): Update.
7648 * guile/scm-frame.c (gdbscm_frame_name): Update.
7649 * python/py-frame.c (frapy_name): Update.
7650 (frapy_function): Update.
7651 * stack.h (find_frame_funname): Update.
7652 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7653 (print_frame): Update.
7654
d6b9b80f
TT
76552017-09-11 Tom Tromey <tom@tromey.com>
7656
7657 * findcmd.c (put_bits): Take a gdb::byte_vector.
7658 (parse_find_args): Return gdb::byte_vector. "args" now const.
7659 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7660 cleanups.
7661 (find_command): Update.
7662
a9921622
TT
76632017-09-11 Tom Tromey <tom@tromey.com>
7664
7665 * cli/cli-script.c (class scoped_restore_hook_in): New.
7666 (clear_hook_in_cleanup): Remove.
7667 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7668 scoped_restore_hook_in.
7669
be0d7abb
TT
76702017-09-11 Tom Tromey <tom@tromey.com>
7671
7672 * cli/cli-script.c (restore_interp): Remove.
7673 (read_command_lines): Use scoped_restore_interp.
7674 * interps.c (scoped_restore_interp::set_temp): Rename from
7675 interp_set_temp.
7676 * interps.h (class scoped_restore_interp): New.
7677 (interp_set_temp): Remove.
7678
00f675ff
TT
76792017-09-11 Tom Tromey <tom@tromey.com>
7680
7681 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7682 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7683 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7684 scoped_restore.
7685 (mi_cmd_break_insert_1): Update.
7686 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7687 scoped_restore.
7688
cb791d59
TT
76892017-09-11 Tom Tromey <tom@tromey.com>
7690
7691 * demangle.c (demangle_command): Update.
7692 * breakpoint.c (disable_command): Update.
7693 (enable_command): Update.
7694 (find_location_by_number): Make "number" const. Use
7695 get_number_trailer.
7696 * cli/cli-utils.c (extract_arg): Return std::string.
7697 * probe.c (parse_probe_linespec): Update. Change types.
7698 (collect_probes): Take string arguments.
7699 (parse_probe_linespec): Likewise.
7700 (info_probes_for_ops): Update.
7701 (enable_probes_command): Update.
7702 (disable_probes_command): Update.
7703 * break-catch-sig.c (catch_signal_split_args): Update.
7704 * mi/mi-parse.c (mi_parse): Update.
7705
2039bd9f
TT
77062017-09-11 Tom Tromey <tom@tromey.com>
7707
7708 * language.h (language_enum): Make argument const.
7709 * language.c (language_enum): Make argument const.
7710
f1735a53
TT
77112017-09-11 Tom Tromey <tom@tromey.com>
7712
7713 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7714 as function.
7715 (skip_to_space): Rename from skip_to_space_const.
7716 * common/common-utils.c (skip_to_space): New function.
7717 (skip_to_space): Rename from skip_to_space_const.
7718 * cli/cli-utils.h (get_number): Rename from get_number_const.
7719 (extract_arg): Rename from extract_arg_const.
7720 * cli/cli-utils.c (get_number): Rename from get_number_const.
7721 (extract_arg): Rename from extract_arg_const.
7722 (number_or_range_parser::get_number): Use ::get_number.
7723 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7724 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7725 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7726 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7727 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7728 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7729 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7730 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7731
7d221d74
TT
77322017-09-11 Tom Tromey <tom@tromey.com>
7733
7734 * python/python.c (do_start_initialization): Use
7735 py-event-types.def to initialize types.
7736 Define all object type structures.
7737 * python/python-internal.h: Don't declare event initialization
7738 functions.
7739 * python/py-threadevent.c (thread_event_object_type): Don't
7740 define.
7741 * python/py-stopevent.c (stop_event_object_type): Don't define.
7742 * python/py-signalevent.c (signal_event_object_type): Don't
7743 declare or define.
7744 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7745 (clear_objfiles_event_object_type): Don't declare or define.
7746 * python/py-infevents.c (inferior_call_pre_event_object_type)
7747 (inferior_call_post_event_object_type)
7748 (register_changed_event_object_type)
7749 (memory_changed_event_object_type): Don't declare or define.
7750 * python/py-inferior.c (new_thread_event_object_type)
7751 (new_inferior_event_object_type)
7752 (inferior_deleted_event_object_type): Don't declare or define.
7753 * python/py-exitedevent.c (exited_event_object_type): Don't
7754 declare or define.
7755 * python/py-evts.c (gdbpy_initialize_py_events): Use
7756 py-all-events.def.
7757 * python/py-events.h (thread_event_object_type): Don't declare.
7758 (events_object): Use py-all-events.def.
7759 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7760 py-event-types.def.
7761 * python/py-event-types.def: New file.
7762 * python/py-continueevent.c (create_continue_event_object): Don't
7763 declare or define.
7764 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7765 declare or define.
7766 * python/py-all-events.def: New file.
7767
35c61a1d
TT
77682017-09-11 Tom Tromey <tom@tromey.com>
7769
7770 * python/py-threadevent.c (create_thread_event_object): Return
7771 gdbpy_ref.
7772 * python/py-stopevent.h (create_stop_event_object)
7773 (create_breakpoint_event_object, create_signal_event_object):
7774 Update.
7775 * python/py-stopevent.c (create_stop_event_object): Return
7776 gdbpy_ref.
7777 (emit_stop_event): Update.
7778 * python/py-signalevent.c (create_signal_event_object): Return
7779 gdbpy_ref.
7780 * python/py-infevents.c (create_inferior_call_event_object):
7781 Update.
7782 * python/py-event.h (create_event_object)
7783 (create_thread_event_object): Update.
7784 * python/py-event.c (create_event_object): Return gdbpy_ref.
7785 * python/py-continueevent.c: Return gdbpy_ref.
7786 * python/py-bpevent.c (create_breakpoint_event_object): Return
7787 gdbpy_ref.
7788
7c96f8c1
TT
77892017-09-11 Tom Tromey <tom@tromey.com>
7790
7791 PR python/15622:
7792 * NEWS: Add entry.
7793 * python/python.c (do_start_initialization): Initialize new event
7794 types.
7795 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7796 (gdbpy_initialize_inferior_deleted_event)
7797 (gdbpy_initialize_new_thread_event): Declare.
7798 * python/py-threadevent.c (create_thread_event_object): Add option
7799 "thread" parameter.
7800 * python/py-inferior.c (new_thread_event_object_type)
7801 (new_inferior_event_object_type)
7802 (inferior_deleted_event_object_type): Declare.
7803 (python_new_inferior, python_inferior_deleted): New functions.
7804 (add_thread_object): Emit new_thread event.
7805 (gdbpy_initialize_inferior): Attach new functions to corresponding
7806 observers.
7807 (new_thread, new_inferior, inferior_deleted): Define new event
7808 types.
7809 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7810 registries.
7811 * python/py-events.h (events_object) <new_inferior,
7812 inferior_deleted, new_thread>: New fields.
7813 * python/py-event.h (create_thread_event_breakpoint): Add optional
7814 "thread" parameter.
7815
72542b8e
AB
78162017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7817
7818 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7819 check current_ui instead.
7820 (internal_vproblem): Likewise.
7821
0d64823e
SM
78222017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7823
7824 * thread.c (print_thread_info_1): Remove unnecessary calls to
7825 uiout->is_mi_like_p.
7826
eb1e02fd
TT
78272017-09-09 Tom Tromey <tom@tromey.com>
7828
7829 * namespace.h (add_using_directive): Update.
7830 * namespace.c (add_using_directive): Change type of excludes to
7831 std::vector.
7832 * dwarf2read.c (read_import_statement): Use std::vector.
7833 (read_namespace): Update.
7834 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
7835
0fc21fd8
TT
78362017-09-09 Tom Tromey <tom@tromey.com>
7837
7838 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
7839
49663d05
TT
78402017-09-09 Tom Tromey <tom@tromey.com>
7841
7842 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
7843
0b868b60
TT
78442017-09-09 Tom Tromey <tom@tromey.com>
7845
7846 * stack.c (func_command): Use gdb::def_vector.
7847
c0470d48
TT
78482017-09-09 Tom Tromey <tom@tromey.com>
7849
7850 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
7851 ui_out_emit_list, ui_out_emit_tuple.
7852 (mi_cmd_var_update): Likewise.
7853
ca5909c7
TT
78542017-09-09 Tom Tromey <tom@tromey.com>
7855
7856 * mi/mi-interp.c (mi_user_selected_context_changed): Use
7857 ui_out_redirect_pop.
7858 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7859 ui_out_redirect_pop.
7860 * utils.c (do_ui_out_redirect_pop)
7861 (make_cleanup_ui_out_redirect_pop): Remove.
7862 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
7863 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
7864 * ui-out.h (ui_out_redirect_pop): New class.
7865
e6a2252a
TT
78662017-09-09 Tom Tromey <tom@tromey.com>
7867
7868 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
7869 (list_available_thread_groups, mi_cmd_list_thread_groups)
7870 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
7871 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
7872 Likewise.
7873
393702cd
TT
78742017-09-09 Tom Tromey <tom@tromey.com>
7875
7876 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
7877 ui_out_emit_tuple.
7878
76f9c9cf
TT
78792017-09-09 Tom Tromey <tom@tromey.com>
7880
7881 * target.c (flash_erase_command): Use ui_out_emit_tuple.
7882 * stack.c (print_frame): Use ui_out_emit_tuple.
7883 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
7884 (info_spu_mailbox_command, info_spu_dma_command)
7885 (info_spu_proxydma_command): Likewise.
7886 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
7887 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
7888 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7889 ui_out_emit_tuple.
7890 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
7891
dc9fe180
TT
78922017-09-09 Tom Tromey <tom@tromey.com>
7893
7894 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
7895 (class ui_out_emit_table): Update comment.
7896 * ui-out.c (do_cleanup_table_end)
7897 (make_cleanup_ui_out_table_begin_end): Remove.
7898 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
7899 (info_spu_dma_cmdlist): Likewise.
7900 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
7901 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
7902 ui_out_emit_table.
7903
f8cc3da6
TT
79042017-09-09 Tom Tromey <tom@tromey.com>
7905
7906 * thread.c (print_thread_info_1): Use ui_out_emit_table,
7907 ui_out_emit_list, gdb::optional.
7908
481695ed
JB
79092017-09-09 John Baldwin <jhb@FreeBSD.org>
7910
7911 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
7912 prototype.
7913 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
7914 prototype.
7915 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
7916 prototype.
7917 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
7918 * ada-exp.y: Remove _initialize_ada_exp prototype.
7919 * ada-lang.c: Remove _initialize_ada_language prototype.
7920 * ada-tasks.c: Remove _initialize_tasks prototype.
7921 * addrmap.c: Remove _initialize_addrmap prototype.
7922 * agent.c: Remove _initialize_agent prototype.
7923 * aix-thread.c: Remove _initialize_aix_thread prototype.
7924 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
7925 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
7926 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
7927 prototype.
7928 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
7929 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
7930 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
7931 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
7932 prototype.
7933 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
7934 prototype.
7935 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
7936 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
7937 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
7938 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
7939 prototype.
7940 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
7941 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
7942 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
7943 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
7944 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7945 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
7946 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
7947 prototype.
7948 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
7949 prototype.
7950 * annotate.c: Remove _initialize_annotate prototype.
7951 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
7952 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
7953 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
7954 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
7955 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
7956 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
7957 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
7958 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
7959 prototype.
7960 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
7961 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
7962 * auto-load.c: Remove _initialize_auto_load prototype.
7963 * auxv.c: Remove _initialize_auxv prototype.
7964 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
7965 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
7966 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
7967 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
7968 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
7969 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
7970 prototype.
7971 * break-catch-throw.c: Remove _initialize_break_catch_throw
7972 prototype.
7973 * breakpoint.c: Remove _initialize_breakpoint prototype.
7974 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
7975 * btrace.c: Remove _initialize_btrace prototype.
7976 * charset.c: Remove _initialize_charset prototype.
7977 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
7978 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
7979 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
7980 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
7981 * cli/cli-script.c: Remove _initialize_cli_script prototype.
7982 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
7983 * coffread.c: Remove _initialize_coffread prototype.
7984 * compile/compile.c: Remove _initialize_compile prototype.
7985 * complaints.c: Remove _initialize_complaints prototype.
7986 * completer.c: Remove _initialize_completer prototype.
7987 * copying.awk: Remove _initialize_copying prototype.
7988 * copying.c: Regenerate.
7989 * core-regset.c: Remove _initialize_core_regset prototype.
7990 * corefile.c: Remove _initialize_core prototype.
7991 * corelow.c: Remove _initialize_corelow prototype.
7992 * cp-abi.c: Remove _initialize_cp_abi prototype.
7993 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
7994 * cp-support.c: Remove _initialize_cp_support prototype.
7995 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
7996 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
7997 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
7998 * ctf.c: Remove _initialize_ctf prototype.
7999 * d-lang.c: Remove _initialize_d_language prototype.
8000 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
8001 prototype.
8002 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
8003 * dbxread.c: Remove _initialize_dbxread prototype.
8004 * dcache.c: Remove _initialize_dcache prototype.
8005 * demangle.c: Remove _initialize_demangler prototype.
8006 * disasm-selftests.c: Remove _initialize_disasm_selftests
8007 prototype.
8008 * disasm.c: Remove _initialize_disasm prototype.
8009 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
8010 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
8011 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
8012 prototype.
8013 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
8014 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
8015 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
8016 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
8017 * elfread.c: Remove _initialize_elfread prototype.
8018 * exec.c: Remove _initialize_exec prototype.
8019 * extension.c: Remove _initialize_extension prototype.
8020 * f-lang.c: Remove _initialize_f_language prototype.
8021 * f-valprint.c: Remove _initialize_f_valprint prototype.
8022 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
8023 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
8024 * filesystem.c: Remove _initialize_filesystem prototype.
8025 * findcmd.c: Remove _initialize_mem_search prototype.
8026 * fork-child.c: Remove _initialize_fork_child prototype.
8027 * frame-base.c: Remove _initialize_frame_base prototype.
8028 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
8029 * frame.c: Remove _initialize_frame prototype.
8030 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
8031 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
8032 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
8033 * gcore.c: Remove _initialize_gcore prototype.
8034 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
8035 * gdbarch.c: Regenerate.
8036 * gdbarch.sh: Remove _initialize_gdbarch prototype.
8037 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
8038 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
8039 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
8040 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
8041 * go-lang.c: Remove _initialize_go_language prototype.
8042 * go32-nat.c: Remove _initialize_go32_nat prototype.
8043 * guile/guile.c: Remove _initialize_guile prototype.
8044 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
8045 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
8046 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
8047 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
8048 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
8049 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
8050 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
8051 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
8052 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
8053 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
8054 prototype.
8055 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
8056 prototype.
8057 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
8058 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
8059 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
8060 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
8061 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
8062 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
8063 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
8064 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
8065 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
8066 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
8067 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
8068 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
8069 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
8070 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
8071 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
8072 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
8073 prototype.
8074 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
8075 prototype.
8076 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
8077 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
8078 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
8079 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
8080 * infcall.c: Remove _initialize_infcall prototype.
8081 * infcmd.c: Remove _initialize_infcmd prototype.
8082 * inferior.c: Remove _initialize_inferiors prototype.
8083 * inflow.c: Remove _initialize_inflow prototype.
8084 * infrun.c: Remove _initialize_infrun prototype.
8085 * interps.c: Remove _initialize_interpreter prototype.
8086 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
8087 * jit.c: Remove _initialize_jit prototype.
8088 * language.c: Remove _initialize_language prototype.
8089 * linux-fork.c: Remove _initialize_linux_fork prototype.
8090 * linux-nat.c: Remove _initialize_linux_nat prototype.
8091 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
8092 * linux-thread-db.c: Remove _initialize_thread_db prototype.
8093 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
8094 * m2-lang.c: Remove _initialize_m2_language prototype.
8095 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
8096 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
8097 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
8098 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
8099 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
8100 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8101 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8102 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
8103 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
8104 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
8105 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8106 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8107 * machoread.c: Remove _initialize_machoread prototype.
8108 * macrocmd.c: Remove _initialize_macrocmd prototype.
8109 * macroscope.c: Remove _initialize_macroscope prototype.
8110 * maint.c: Remove _initialize_maint_cmds prototype.
8111 * mdebugread.c: Remove _initialize_mdebugread prototype.
8112 * memattr.c: Remove _initialize_mem prototype.
8113 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
8114 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
8115 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
8116 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
8117 * mi/mi-main.c: Remove _initialize_mi_main prototype.
8118 * microblaze-linux-tdep.c: Remove
8119 _initialize_microblaze_linux_tdep prototype.
8120 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
8121 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
8122 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
8123 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
8124 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
8125 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
8126 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
8127 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
8128 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
8129 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
8130 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
8131 prototype.
8132 * mipsread.c: Remove _initialize_mipsread prototype.
8133 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
8134 prototype.
8135 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
8136 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
8137 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
8138 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
8139 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
8140 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
8141 prototype.
8142 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
8143 * nto-procfs.c: Remove _initialize_procfs prototype.
8144 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
8145 * objc-lang.c: Remove _initialize_objc_language prototype.
8146 * objfiles.c: Remove _initialize_objfiles prototype.
8147 * observer.c: Remove observer_test_first_notification_function,
8148 observer_test_second_notification_function,
8149 observer_test_third_notification_function, and
8150 _initialize_observer prototypes.
8151 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
8152 * osabi.c: Remove _initialize_gdb_osabi prototype.
8153 * osdata.c: Remove _initialize_osdata prototype.
8154 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
8155 * parse.c: Remove _initialize_parse prototype.
8156 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
8157 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
8158 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
8159 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
8160 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
8161 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
8162 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
8163 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
8164 * printcmd.c: Remove _initialize_printcmd prototype.
8165 * probe.c: Remove _initialize_probe prototype.
8166 * proc-api.c: Remove _initialize_proc_api prototype.
8167 * proc-events.c: Remove _initialize_proc_events prototype.
8168 * proc-service.c: Remove _initialize_proc_service prototype.
8169 * procfs.c: Remove _initialize_procfs prototype.
8170 * psymtab.c: Remove _initialize_psymtab prototype.
8171 * python/python.c: Remove _initialize_python prototype.
8172 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
8173 * record-btrace.c: Remove _initialize_record_btrace prototype.
8174 * record-full.c: Remove _initialize_record_full prototype.
8175 * record.c: Remove _initialize_record prototype.
8176 * regcache.c: Remove _initialize_regcache prototype.
8177 * reggroups.c: Remove _initialize_reggroup prototype.
8178 * remote-notif.c: Remove _initialize_notif prototype.
8179 * remote-sim.c: Remove _initialize_remote_sim prototype.
8180 * remote.c: Remove _initialize_remote prototype.
8181 * reverse.c: Remove _initialize_reverse prototype.
8182 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
8183 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
8184 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
8185 prototype.
8186 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
8187 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
8188 * rust-exp.y: Remove _initialize_rust_exp prototype.
8189 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
8190 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
8191 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
8192 * score-tdep.c: Remove _initialize_score_tdep prototype.
8193 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
8194 prototype.
8195 * ser-go32.c: Remove _initialize_ser_dos prototype.
8196 * ser-mingw.c: Remove _initialize_ser_windows prototype.
8197 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
8198 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
8199 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
8200 * serial.c: Remove _initialize_serial prototype.
8201 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
8202 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
8203 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
8204 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
8205 * skip.c: Remove _initialize_step_skip prototype.
8206 * sol-thread.c: Remove _initialize_sol_thread prototype.
8207 * solib-aix.c: Remove _initialize_solib_aix prototype.
8208 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
8209 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
8210 * solib-frv.c: Remove _initialize_frv_solib prototype.
8211 * solib-spu.c: Remove _initialize_spu_solib prototype.
8212 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
8213 * solib-target.c: Remove _initialize_solib_target prototype.
8214 * solib.c: Remove _initialize_solib prototype.
8215 * source.c: Remove _initialize_source prototype.
8216 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
8217 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
8218 prototype.
8219 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
8220 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
8221 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
8222 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
8223 prototype.
8224 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
8225 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
8226 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
8227 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
8228 prototype.
8229 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
8230 prototype.
8231 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
8232 prototype.
8233 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
8234 prototype.
8235 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
8236 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
8237 prototype.
8238 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
8239 prototype.
8240 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
8241 prototype.
8242 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
8243 prototype.
8244 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
8245 prototype.
8246 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
8247 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
8248 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
8249 * stabsread.c: Remove _initialize_stabsread prototype.
8250 * stack.c: Remove _initialize_stack prototype.
8251 * stap-probe.c: Remove _initialize_stap_probe prototype.
8252 * std-regs.c: Remove _initialize_frame_reg prototype.
8253 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
8254 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
8255 * symfile.c: Remove _initialize_symfile prototype.
8256 * symmisc.c: Remove _initialize_symmisc prototype.
8257 * symtab.c: Remove _initialize_symtab prototype.
8258 * target-dcache.c: Remove _initialize_target_dcache prototype.
8259 * target-descriptions.c: Remove _initialize_target_descriptions
8260 prototype.
8261 * thread.c: Remove _initialize_thread prototype.
8262 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
8263 prototype.
8264 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
8265 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
8266 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
8267 prototype.
8268 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
8269 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
8270 * tracefile.c: Remove _initialize_tracefile prototype.
8271 * tracepoint.c: Remove _initialize_tracepoint prototype.
8272 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
8273 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
8274 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
8275 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
8276 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
8277 * tui/tui-win.c: Remove _initialize_tui_win prototype.
8278 * tui/tui.c: Remove _initialize_tui prototype.
8279 * typeprint.c: Remove _initialize_typeprint prototype.
8280 * user-regs.c: Remove _initialize_user_regs prototype.
8281 * utils.c: Remove _initialize_utils prototype.
8282 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
8283 * valarith.c: Remove _initialize_valarith prototype.
8284 * valops.c: Remove _initialize_valops prototype.
8285 * valprint.c: Remove _initialize_valprint prototype.
8286 * value.c: Remove _initialize_values prototype.
8287 * varobj.c: Remove _initialize_varobj prototype.
8288 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
8289 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
8290 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
8291 * windows-nat.c: Remove _initialize_windows_nat,
8292 _initialize_check_for_gdb_ini, and _initialize_loadable
8293 prototypes.
8294 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
8295 * xcoffread.c: Remove _initialize_xcoffread prototype.
8296 * xml-support.c: Remove _initialize_xml_support prototype.
8297 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
8298 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
8299 prototype.
8300 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
8301 prototype.
8302 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
8303
a611b5cb
KS
83042017-09-08 Keith Seitz <keiths@redhat.com>
8305
8306 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
8307 field.
8308
469412dd
CW
83092017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
8310
8311 * f-valprint.c (f_val_print): Remove check for one byte
8312 sized integers. Remove printing of character type.
8313
a5ad232b
FP
83142017-09-08 Frank Penczek <frank.penczek@intel.com>
8315 Christoph Weinmann <christoph.t.weinmann@intel.com>
8316 Bernhard Heckel <bernhard.heckel@intel.com>
8317
8318 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
8319 to maintain proper indentation when printing pointers/refs.
8320
e5014227
JB
83212017-09-07 Joel Brobecker <brobecker@adacore.com>
8322
8323 GDB 8.0.1 released.
8324
63c99141
JB
83252017-09-07 Joel Brobecker <brobecker@adacore.com>
8326
8327 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
8328
69c1e056
TT
83292017-09-05 Tom Tromey <tom@tromey.com>
8330
8331 * parse.c (funcall_chain): Now a std::vector.
8332 (start_arglist, end_arglist): Simplify.
8333 (free_funcalls): Remove.
8334 (parse_exp_in_context_1): Remove cleanup.
8335
fef704bf
TT
83362017-09-05 Tom Tromey <tom@tromey.com>
8337
8338 * go-exp.y (go_parse): Don't create a cleanup.
8339
5613c585
TT
83402017-09-05 Tom Tromey <tom@tromey.com>
8341
8342 * d-exp.y (PrimaryExpression): Use std::string.
8343 (d_parse): Don't create a cleanup.
8344
eae49211
TT
83452017-09-05 Tom Tromey <tom@tromey.com>
8346
8347 * utils.c (do_clear_parser_state): Remove.
8348 (make_cleanup_clear_parser_state): Remove.
8349 * p-exp.y (pascal_parse): Use scoped_restore.
8350 * m2-exp.y (m2_parse): Use scoped_restore.
8351 * f-exp.y (f_parse): Use scoped_restore.
8352 * d-exp.y (d_parse): Use scoped_restore.
8353 * c-exp.y (c_parse): Use scoped_restore.
8354 * ada-exp.y (ada_parse): Use scoped_restore.
8355 * utils.h (make_cleanup_clear_parser_state): Remove.
8356
73b9be8b
KS
83572017-09-06 Keith Seitz <keiths@redhat.com>
8358
8359 * dwarf2read.c (dw2_linkage_name_attr): New function.
8360 (dw2_linkage_name): New function.
8361 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
8362 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
8363 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
8364
a102602b
KR
83652017-09-06 Kamil Rytarowski <n54@gmx.com>
8366
8367 * config/djgpp/djconfig.sh: Correct shell portability issue.
8368
28ad437d
KR
83692017-09-06 Kamil Rytarowski <n54@gmx.com>
8370
8371 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
8372
351787dd
JB
83732017-09-06 John Baldwin <jhb@FreeBSD.org>
8374
8375 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
8376 * NEWS: Mention new FreeBSD/mips native configuration.
8377 * configure.host: Add aarch64*-*-freebsd*.
8378 * configure.nat: Likewise.
8379 * aarch64-fbsd-nat.c: New file.
8380
c0f84956
JB
83812017-09-06 John Baldwin <jhb@FreeBSD.org>
8382
8383 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
8384 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
8385 * NEWS: Mention new FreeBSD/aarch64 target.
8386 * configure.tgt: Add aarch64*-*-freebsd*.
8387 * aarch64-fbsd-tdep.c: New file.
8388 * aarch64-fbsd-tdep.h: New file.
8389
7610297a
KR
83902017-09-06 Kamil Rytarowski <n54@gmx.com>
8391
8392 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
8393
fbd1b771
JK
83942017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8395
8396 * parse.c (find_minsym_type_and_address): Don't relocate addresses
8397 of TLS symbols.
8398
5ca79eae
PW
83992017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8400
8401 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
8402 call.
8403
bf93d7ba
SM
84042017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8405
8406 * infrun.c (follow_exec): Call add_thread after
8407 target_find_description.
8408
1bb7c059
SM
84092017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8410
8411 * infrun.c (handle_inferior_event_1): When exec'ing, read
8412 stop_pc after follow_exec.
8413
fc809827
SM
84142017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8415
8416 * remote.c (process_g_packet): Update error message.
8417
d2fcdd85
YQ
84182017-09-05 Yao Qi <yao.qi@linaro.org>
8419
8420 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
8421 targets.
8422
e69570ee
PA
84232017-09-05 Pedro Alves <palves@redhat.com>
8424
8425 * eval.c (eval_call, evaluate_funcall): New functions, factored
8426 out from ...
8427 (evaluate_subexp_standard): ... this.
8428
22916b07
YQ
84292017-09-05 Yao Qi <yao.qi@linaro.org>
8430
8431 * amd64-tdep.c (amd64_target_description): Create target
8432 descriptions.
8433 (_initialize_amd64_tdep): Don't call functions
8434 initialize_tdesc_amd64_*. Add self tests.
8435 * arch/amd64.c (amd64_create_target_description): Add parameter
8436 is_linux. Call set_tdesc_osabi if is_linux is true.
8437 * arch/amd64.h (amd64_create_target_description): Update the
8438 declaration.
8439 * arch/i386.c (i386_create_target_description): Add parameter
8440 is_linux. Call set_tdesc_osabi if is_linux is true.
8441 * arch/i386.h (i386_create_target_description): Update
8442 declaration.
8443 * configure.tgt: Add i386.o to gdb_target_obs.
8444 * features/Makefile (XMLTOC): Remove i386/*.xml.
8445 * features/i386/amd64-avx-avx512.c: Remove.
8446 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
8447 * features/i386/amd64-avx-mpx.c: Remove.
8448 * features/i386/amd64-avx.c: Remove.
8449 * features/i386/amd64-mpx.c: Remove.
8450 * features/i386/amd64.c: Remove.
8451 * features/i386/i386-avx-avx512.c: Remove.
8452 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
8453 * features/i386/i386-avx-mpx.c: Remove.
8454 * features/i386/i386-avx.c: Remove.
8455 * features/i386/i386-mmx.c: Remove.
8456 * features/i386/i386-mpx.c: Remove.
8457 * features/i386/i386.c: Remove.
8458 * i386-tdep.c: Don't include features/i386/i386*.c., include
8459 target-descriptions.h and arch/i386.h.
8460 (i386_target_description): Create target descriptions.
8461 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
8462 functions. Do self tests.
8463
0854b7b1
YQ
84642017-09-05 Yao Qi <yao.qi@linaro.org>
8465
8466 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
8467 * features/i386/amd64-avx-avx512-linux.c: Removed.
8468 * features/i386/amd64-avx-linux.c: Removed.
8469 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
8470 * features/i386/amd64-avx-mpx-linux.c: Removed.
8471 * features/i386/amd64-linux.c: Removed.
8472 * features/i386/amd64-mpx-linux.c: Removed.
8473 * features/i386/x32-avx-avx512-linux.c: Removed.
8474 * features/i386/x32-avx-linux.c: Removed.
8475 * features/i386/x32-linux.c: Removed.
8476
b4570e4b
YQ
84772017-09-05 Yao Qi <yao.qi@linaro.org>
8478
8479 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8480 features/i386/*.c.
8481 (amd64_linux_read_description): Call
8482 amd64_create_target_description.
8483 * arch/amd64.c: New file.
8484 * arch/amd64.h: New file.
8485 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8486 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8487
6c73f67f
YQ
84882017-09-05 Yao Qi <yao.qi@linaro.org>
8489
8490 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8491 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8492 (amd64_linux_read_description): Create target descriptions.
8493 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8494 functions. Add unit tests.
8495 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8496 x32-core.xml.
8497 * features/i386/64bit-avx.c: Generated.
8498 * features/i386/64bit-avx512.c: Generated.
8499 * features/i386/64bit-core.c: Generated.
8500 * features/i386/64bit-linux.c: Generated.
8501 * features/i386/64bit-mpx.c: Generated.
8502 * features/i386/64bit-pkeys.c: Generated.
8503 * features/i386/64bit-segments.c: Generated.
8504 * features/i386/64bit-sse.c: Generated.
8505 * features/i386/x32-core.c: Generated.
8506 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8507 c files for amd64-linux and x32-linux.
8508
9d3d478b
YQ
85092017-09-05 Yao Qi <yao.qi@linaro.org>
8510
8511 * amd64-linux-tdep.c (amd64_linux_read_description): New
8512 function.
8513 (amd64_linux_core_read_description): Call
8514 amd64_linux_read_description.
8515 (amd64_linux_init_abi): Likewise.
8516 (amd64_x32_linux_init_abi): Likewise.
8517 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8518 * x86-linux-nat.c (x86_linux_read_description): Call
8519 amd64_linux_read_description.
8520
b9f1d50f
YQ
85212017-09-05 Yao Qi <yao.qi@linaro.org>
8522
8523 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8524 comments.
8525
188c9e6d
YQ
85262017-09-05 Yao Qi <yao.qi@linaro.org>
8527
8528 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8529 * features/i386/i386-avx-avx512-linux.c: Remove.
8530 * features/i386/i386-avx-linux.c: Remove.
8531 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8532 * features/i386/i386-avx-mpx-linux.c: Remove.
8533 * features/i386/i386-linux.c: Remove.
8534 * features/i386/i386-mmx-linux.c: Remove.
8535 * features/i386/i386-mpx-linux.c: Remove.
8536
5f035c07
YQ
85372017-09-05 Yao Qi <yao.qi@linaro.org>
8538
8539 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8540 (SFILES): Add arch/i386.c.
8541 (HFILES_NO_SRCDIR): Add arch/i386.h.
8542 * arch/i386.c: New file.
8543 * arch/i386.h: New file.
8544 * arch/tdesc.h (allocate_target_description): Declare.
8545 (set_tdesc_architecture): Declare.
8546 (set_tdesc_osabi): Declare.
8547 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8548 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8549 include arch/i386.h.
8550 (i386_linux_read_description): Remove code and call
8551 i386_create_target_description.
8552 (set_tdesc_architecture): New function.
8553 (set_tdesc_osabi): New function.
8554 * target-descriptions.h (allocate_target_description): Remove.
8555
0abe8a89
YQ
85562017-09-05 Yao Qi <yao.qi@linaro.org>
8557
8558 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8559 * target-descriptions.c (tdesc_create_feature): Likewise, and
8560 adjust code.
8561 * features/i386/32bit-avx.c: Re-generated.
8562 * features/i386/32bit-avx512.c: Re-generated.
8563 * features/i386/32bit-core.c: Re-generated.
8564 * features/i386/32bit-linux.c: Re-generated.
8565 * features/i386/32bit-mpx.c: Re-generated.
8566 * features/i386/32bit-pkeys.c: Re-generated.
8567 * features/i386/32bit-sse.c: Re-generated.
8568
0a188386
YQ
85692017-09-05 Yao Qi <yao.qi@linaro.org>
8570
8571 * regformats/regdef.h (struct reg): Override operator == and !=.
8572
f49ff000
YQ
85732017-09-05 Yao Qi <yao.qi@linaro.org>
8574
8575 * arch/tdesc.h: New file.
8576 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8577 * target-descriptions.c: Update comments.
8578 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8579 declarations.
8580 * features/i386/32bit-avx.c: Re-generated.
8581 * features/i386/32bit-avx512.c: Re-generated.
8582 * features/i386/32bit-core.c: Re-generated.
8583 * features/i386/32bit-linux.c: Re-generated.
8584 * features/i386/32bit-mpx.c: Re-generated.
8585 * features/i386/32bit-pkeys.c: Re-generated.
8586 * features/i386/32bit-sse.c: Re-generated.
8587
f7000548
YQ
85882017-09-05 Yao Qi <yao.qi@linaro.org>
8589
8590 * regformats/regdat.sh: Update generated code.
8591
c9a5e2a5
YQ
85922017-09-05 Yao Qi <yao.qi@linaro.org>
8593
8594 * regformats/regdat.sh: Adjust code order.
8595
d6b687ac
SM
85962017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8597
8598 * expprint.c (dump_subexp_body_standard): Use constant format
8599 string in fprintf_filtered call.
8600
a379bfd0
JB
86012017-09-04 John Baldwin <jhb@FreeBSD.org>
8602
8603 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8604 NetBSD/i386.
8605 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8606
f7efc967
JB
86072017-09-04 John Baldwin <jhb@FreeBSD.org>
8608
8609 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8610
c49fbc6c
JB
86112017-09-04 John Baldwin <jhb@FreeBSD.org>
8612
8613 * bsd-kvm.o: Define _KMEMUSER.
8614 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8615 * configure: Regenerate.
8616
26562e73
JB
86172017-09-04 John Baldwin <jhb@FreeBSD.org>
8618
8619 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8620 * i386-fbsd-nat.c: Likewise.
8621
31cf1487
JB
86222017-09-04 John Baldwin <jhb@FreeBSD.org>
8623
8624 * unittests/array-view-selftests.c: Add include of <array>.
8625
5b9f8a7c
JB
86262017-09-04 John Baldwin <jhb@FreeBSD.org>
8627
8628 * spu-tdep.c (flush_ea_cache): Add missing argument to
8629 call_function_by_hand.
8630
d69cf9b2
PA
86312017-09-04 Pedro Alves <palves@redhat.com>
8632
8633 * NEWS (Safer support for debugging with no debug info): New.
8634
3693fdb3
PA
86352017-09-04 Pedro Alves <palves@redhat.com>
8636
8637 * c-exp.y (function_method, function_method_void): Add current
8638 instance flags to TYPE_INSTANCE.
8639 * dwarf2read.c (check_modifier): New.
8640 (compute_delayed_physnames): Assert that only C++ adds delayed
8641 physnames. Mark fn_fields as const/volatile depending on
8642 physname.
8643 * eval.c (make_params): New type_instance_flags parameter. Use
8644 it as the new type's instance flags.
8645 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8646 flags element and pass it to make_params.
8647 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8648 instance flags element.
8649 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8650 * gdbtypes.h: Include "enum-flags.h".
8651 (type_instance_flags): New enum-flags type.
8652 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8653 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8654 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8655 (follow_type_instance_flags): New function.
8656 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8657 * parser-defs.h (follow_type_instance_flags): Declare.
8658 * valops.c (value_struct_elt_for_reference): const/volatile must
8659 match too.
8660
e68cb8e0
PA
86612017-09-04 Pedro Alves <palves@redhat.com>
8662
8663 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8664 function/method scopes; lookup the nested name as a function local
8665 static variable.
8666
858be34c
PA
86672017-09-04 Pedro Alves <palves@redhat.com>
8668
8669 (%type <voidval>): Add function_method.
8670 * c-exp.y (exp): New production for calls with no arguments.
8671 (function_method, function_method_void_or_typelist): New
8672 productions.
8673 (exp): New production for "method()::static_var".
8674 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8675 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8676 Handle OP_FUNC_STATIC_VAR.
8677 * parse.c (operator_length_standard):
8678 Handle OP_FUNC_STATIC_VAR.
8679
dd5901a6
PA
86802017-09-04 Pedro Alves <palves@redhat.com>
8681
8682 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8683 handling.
8684 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8685 Ditto.
8686 * parse.c (operator_length_standard, operator_check_standard):
8687 Ditto.
8688 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8689
46a4882b
PA
86902017-09-04 Pedro Alves <palves@redhat.com>
8691
8692 * ax-gdb.c: Include "typeprint.h".
8693 (gen_expr_for_cast): New function.
8694 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8695 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8696 type is unknown.
8697 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8698 nodebug_data_symbol.
8699 * eval.c: Include "typeprint.h".
8700 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8701 Error out if symbol has unknown type.
8702 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8703 evaluate_subexp_for_cast.
8704 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8705 OP_VAR_MSYM_VALUE.
8706 (evaluate_subexp_for_cast): New function.
8707 * gdbtypes.c (init_nodebug_var_type): New function.
8708 (objfile_type): Use it to initialize types of variables with no
8709 debug info.
8710 * typeprint.c (error_unknown_type): New.
8711 * typeprint.h (error_unknown_type): New declaration.
8712 * compile/compile-c-types.c (convert_type_basic): Handle
8713 TYPE_CODE_ERROR; warn and fallback to int for variables with
8714 unknown type.
8715
fe13dfec
PA
87162017-09-04 Pedro Alves <palves@redhat.com>
8717
8718 * eval.c (evaluate_var_value): New function, factored out from ...
8719 (evaluate_subexp_standard): ... here.
8720
d008ee21
PA
87212017-09-04 Pedro Alves <palves@redhat.com>
8722
8723 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8724 Remove useless assignments to 'op'.
8725
827d0c51
PA
87262017-09-04 Pedro Alves <palves@redhat.com>
8727
8728 * eval.c (eval_skip_value): New function.
8729 (evaluate_subexp_standard): Use it.
8730
2c5a2be1
PA
87312017-09-04 Pedro Alves <palves@redhat.com>
8732
8733 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8734 function name from symbol/minsym and pass it to
8735 error_call_unknown_return_type.
8736
74ea4be4
PA
87372017-09-04 Pedro Alves <palves@redhat.com>
8738
8739 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8740 * ax-gdb.c (gen_msym_var_ref): New function.
8741 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8742 * eval.c (evaluate_var_msym_value): New function.
8743 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8744 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8745 to call_function_by_hand.
8746 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8747 Handle OP_VAR_MSYM_VALUE.
8748 (union exp_element) <msymbol>: New field.
8749 * minsyms.h (struct type): Forward declare.
8750 (find_minsym_type_and_address): Declare.
8751 * parse.c (write_exp_elt_msym): New function.
8752 (write_exp_msymbol): Delete, refactored as ...
8753 (find_minsym_type_and_address): ... this new function.
8754 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8755 (operator_length_standard, operator_check_standard): Handle
8756 OP_VAR_MSYM_VALUE.
8757 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8758
7022349d
PA
87592017-09-04 Pedro Alves <palves@redhat.com>
8760
8761 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8762 TYPE_GNU_IFUNC specially here. Throw error if return type is
8763 unknown.
8764 * ada-typeprint.c (print_func_type): Handle functions with unknown
8765 return type.
8766 * c-typeprint.c (c_type_print_base): Handle functions and methods
8767 with unknown return type.
8768 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8769 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8770 * compile/compile-c-types.c: Include "objfiles.h".
8771 (convert_func): For functions with unknown return type, warn and
8772 default to int.
8773 * compile/compile-object-run.c (compile_object_run): Adjust call
8774 to call_function_by_hand_dummy.
8775 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8776 call_function_by_hand.
8777 * eval.c (evaluate_subexp_standard): Adjust calls to
8778 call_function_by_hand. Handle functions and methods with unknown
8779 return type. Pass expect_type to call_function_by_hand.
8780 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8781 return type.
8782 * gcore.c (call_target_sbrk): Adjust call to
8783 call_function_by_hand.
8784 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8785 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8786 an integer address type instead of nodebug.
8787 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8788 call_function_by_hand.
8789 * infcall.c (error_call_unknown_return_type): New function.
8790 (call_function_by_hand): New "default_return_type" parameter.
8791 Pass it down.
8792 (call_function_by_hand_dummy): New "default_return_type"
8793 parameter. Use it instead of defaulting to int. If there's no
8794 default and the return type is unknown, throw an error. If
8795 there's a default return type, and the called function has no
8796 debug info, then assume the function is prototyped.
8797 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8798 New "default_return_type" parameter.
8799 (error_call_unknown_return_type): New declaration.
8800 * linux-fork.c (call_lseek): Cast return type of lseek.
8801 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8802 call_function_by_hand.
8803 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8804 calls to call_function_by_hand.
8805 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8806 return type.
8807 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8808 (value_nsstring, print_object_command): Adjust calls to
8809 call_function_by_hand.
8810 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8811 functions with unknown return type.
8812 (pascal_type_print_func_varspec_suffix): New function.
8813 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8814 TYPE_CODE_METHOD>: Use it.
8815 * python/py-value.c (valpy_call): Adjust call to
8816 call_function_by_hand.
8817 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8818 call_function_by_hand.
8819 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8820 call_function_by_hand.
8821 * valops.c (value_allocate_space_in_inferior): Adjust call to
8822 call_function_by_hand.
8823 * typeprint.c (type_print_unknown_return_type): New function.
8824 * typeprint.h (type_print_unknown_return_type): New declaration.
8825
54990598
PA
88262017-09-04 Pedro Alves <palves@redhat.com>
8827
8828 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
8829 types with more than one parameter as prototyped.
8830
9a24775b
PA
88312017-09-04 Pedro Alves <palves@redhat.com>
8832
8833 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
8834 (disassemble_command): Use gdb_disassembly_flags instead of bare
8835 int.
8836 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
8837 (dump_insns, do_mixed_source_and_assembly_deprecated)
8838 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
8839 Use gdb_disassembly_flags instead of bare int.
8840 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
8841 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
8842 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
8843 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
8844 (enum gdb_disassembly_flag): ... values of this new enumeration.
8845 (gdb_disassembly_flags): Define.
8846 (gdb_disassembly)
8847 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
8848 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
8849 gdb_disassembly_flags instead of bare int.
8850 * record-btrace.c (btrace_insn_history)
8851 (record_btrace_insn_history, record_btrace_insn_history_range)
8852 (record_btrace_insn_history_from): Use gdb_disassembly_flags
8853 instead of bare int.
8854 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
8855 Use gdb_disassembly_flags instead of bare int.
8856 * target-debug.h (target_debug_print_gdb_disassembly_flags):
8857 Define.
8858 * target-delegates.c: Regenerate.
8859 * target.c (target_insn_history, target_insn_history_from)
8860 (target_insn_history_range): Use gdb_disassembly_flags instead of
8861 bare int.
8862 * target.h: Include "disasm.h".
8863 (struct target_ops) <to_insn_history, to_insn_history_from,
8864 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
8865 int.
8866 (target_insn_history, target_insn_history_from)
8867 (target_insn_history_range): Use gdb_disassembly_flags instead of
8868 bare int.
8869
80a65e9b
SM
88702017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8871
8872 * cli/cli-script.c (build_command_line): For if/while commands,
8873 check whether args is empty.
8874
6b66338c
SM
88752017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8876
8877 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
8878 (enum command_control_type): Likewise.
8879 (struct command_line): Likewise.
8880 (free_command_lines): Likewise.
8881 (struct command_lines_deleter): Likewise.
8882 (command_line_up): Likewise.
8883 (read_command_lines): Likewise.
8884 (read_command_lines_1): Likewise.
8885 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
8886 (enum command_control_type): Likewise.
8887 (struct command_line): Likewise.
8888 (free_command_lines): Likewise.
8889 (struct command_lines_deleter): Likewise.
8890 (command_line_up): Likewise.
8891 (read_command_lines): Likewise.
8892 (read_command_lines_1): Likewise.
8893 * breakpoint.h: Include cli/cli-script.h.
8894 * extension-priv.h: Likewise.
8895 * gdbcmd.h: Likewise.
8896
51abb421
PA
88972017-09-04 Pedro Alves <palves@redhat.com>
8898
8899 * ada-lang.c (is_known_support_routine): Move sal declaration to
8900 where it is initialized.
8901 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
8902 (parse_breakpoint_sals, decode_static_tracepoint_spec)
8903 (clear_command, update_static_tracepoint): Remove init_sal
8904 references. Move declarations closer to initializations.
8905 * cli/cli-cmds.c (list_command): Move sal declarations closer to
8906 initializations.
8907 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
8908 references. Move sal declarations closer to initializations.
8909 * frame.c (find_frame_sal): Return a symtab_and_line via function
8910 return instead of output parameter. Remove init_sal references.
8911 * frame.h (find_frame_sal): Return a symtab_and_line via function
8912 return instead of output parameter.
8913 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
8914 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
8915 instead of memset.
8916 (gdbscm_find_pc_line): Remove init_sal reference.
8917 * infcall.c (call_function_by_hand_dummy): Remove init_sal
8918 references. Move declarations closer to initializations.
8919 * infcmd.c (set_step_frame): Update. Move declarations closer to
8920 initializations.
8921 (finish_backward): Remove init_sal references. Move declarations
8922 closer to initializations.
8923 * infrun.c (process_event_stop_test, handle_step_into_function)
8924 (insert_hp_step_resume_breakpoint_at_frame)
8925 (insert_step_resume_breakpoint_at_caller): Likewise.
8926 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
8927 (symbol_to_sal): Likewise.
8928 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
8929 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
8930 to its initialization.
8931 * reverse.c (save_bookmark_command): Use new/delete. Remove
8932 init_sal references. Move declarations closer to initializations.
8933 * source.c (get_current_source_symtab_and_line): Remove brace
8934 initialization.
8935 (set_current_source_symtab_and_line): Now takes the sal by const
8936 reference. Remove brace initialization.
8937 (line_info): Remove init_sal reference.
8938 * source.h (set_current_source_symtab_and_line): Now takes a
8939 symtab_and_line via const reference.
8940 * stack.c (set_current_sal_from_frame): Adjust.
8941 (print_frame_info): Adjust.
8942 (get_last_displayed_sal): Return the sal via function return
8943 instead of via output parameter. Simplify.
8944 (frame_info): Adjust.
8945 * stack.h (get_last_displayed_sal): Return the sal via function
8946 return instead of via output parameter.
8947 * symtab.c (init_sal): Delete.
8948 (find_pc_sect_line): Remove init_sal references. Move
8949 declarations closer to initializations.
8950 (find_function_start_sal): Remove init_sal references. Move
8951 declarations closer to initializations.
8952 * symtab.h (struct symtab_and_line): In-class initialize all
8953 fields.
8954 * tracepoint.c (set_traceframe_context)
8955 (print_one_static_tracepoint_marker): Remove init_sal references.
8956 Move declarations closer to initializations.
8957 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
8958 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
8959 declarations closer to initializations.
8960 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
8961 init_sal references. Adjust.
8962
6c5b2ebe
PA
89632017-09-04 Pedro Alves <palves@redhat.com>
8964
8965 * ax-gdb.c (agent_command_1): Use range-for.
8966 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8967 * breakpoint.c: Include "common/array-view.h".
8968 (init_breakpoint_sal, create_breakpoint_sal): Change sals
8969 parameter from struct symtabs_and_lines to
8970 array_view<symtab_and_line>. Adjust. Use range-for. Update.
8971 (breakpoint_sals_to_pc): Change sals parameter from struct
8972 symtabs_and_lines to std::vector reference.
8973 (check_fast_tracepoint_sals): Change sals parameter from struct
8974 symtabs_and_lines to std::array_view. Use range-for.
8975 (decode_static_tracepoint_spec): Return a std::vector instead of
8976 symtabs_and_lines. Update.
8977 (create_breakpoint): Update.
8978 (break_range_command, until_break_command, clear_command): Update.
8979 (base_breakpoint_decode_location, bkpt_decode_location)
8980 (bkpt_probe_create_sals_from_location)
8981 (bkpt_probe_decode_location, tracepoint_decode_location)
8982 (tracepoint_probe_decode_location)
8983 (strace_marker_create_sals_from_location): Return a std::vector
8984 instead of symtabs_and_lines.
8985 (strace_marker_create_breakpoints_sal): Update.
8986 (strace_marker_decode_location): Return a std::vector instead of
8987 symtabs_and_lines. Update.
8988 (update_breakpoint_locations): Change struct symtabs_and_lines
8989 parameters to gdb::array_view. Adjust.
8990 (location_to_sals): Return a std::vector instead of
8991 symtabs_and_lines. Update.
8992 (breakpoint_re_set_default): Use std::vector instead of struct
8993 symtabs_and_lines.
8994 (decode_location_default): Return a std::vector instead of
8995 symtabs_and_lines. Update.
8996 * breakpoint.h: Include "common/array-view.h".
8997 (struct breakpoint_ops) <decode_location>: Now returns a
8998 std::vector instead of returning a symtabs_and_lines via output
8999 parameter.
9000 (update_breakpoint_locations): Change sals parameters to use
9001 gdb::array_view.
9002 * cli/cli-cmds.c (edit_command, list_command): Update to use
9003 std::vector and gdb::array_view.
9004 (ambiguous_line_spec): Adjust to use gdb::array_view and
9005 range-for.
9006 (compare_symtabs): Rename to ...
9007 (cmp_symtabs): ... this. Change parameters to symtab_and_line
9008 const reference and adjust.
9009 (filter_sals): Rewrite using std::vector and standard algorithms.
9010 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
9011 (jump_command): Update to use std::vector.
9012 * linespec.c (struct linespec_state) <canonical_names>: Update
9013 comment.
9014 (add_sal_to_sals_basic): Delete.
9015 (add_sal_to_sals, filter_results, convert_results_to_lsals)
9016 (decode_line_2, create_sals_line_offset)
9017 (convert_address_location_to_sals, convert_linespec_to_sals)
9018 (convert_explicit_location_to_sals, parse_linespec)
9019 (event_location_to_sals, decode_line_full, decode_line_1)
9020 (decode_line_with_current_source)
9021 (decode_line_with_last_displayed, decode_objc)
9022 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
9023 (linespec_result::~linespec_result): Adjust to use std::vector
9024 instead of symtabs_and_lines.
9025 * linespec.h (linespec_sals::sals): Now a std::vector.
9026 (struct linespec_result): Use std::vector, bool, and in-class
9027 initialization.
9028 (decode_line_1, decode_line_with_current_source)
9029 (decode_line_with_last_displayed): Return std::vector.
9030 * macrocmd.c (info_macros_command): Use std::vector.
9031 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
9032 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
9033 std::vector.
9034 * probe.h (parse_probes): Return a std::vector.
9035 * python/python.c (gdbpy_decode_line): Use std::vector and
9036 gdb::array_view.
9037 * source.c (select_source_symtab, line_info): Use std::vector.
9038 * stack.c (func_command): Use std::vector.
9039 * symtab.h (struct symtabs_and_lines): Delete.
9040 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
9041
7c44b49c
PA
90422017-09-04 Pedro Alves <palves@redhat.com>
9043
9044 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9045 unittests/array-view-selftests.c.
9046 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
9047 * common/array-view.h: New file.
9048 * unittests/array-view-selftests.c: New file.
9049
e439fa14
PA
90502017-09-04 Pedro Alves <palves@redhat.com>
9051
9052 * cli/cli-cmds.c (edit_command): Pass message to
9053 ambiguous_line_spec.
9054 (list_command): Pass message to ambiguous_line_spec. Say
9055 "first"/"last" instead of "start" and "end" to be consistent with
9056 the manual.
9057 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
9058 them to print formatted message.
9059
7525b645
PA
90602017-09-04 Pedro Alves <palves@redhat.com>
9061
9062 * btrace.c (ftrace_add_pt): Pass btrace_insn to
9063 ftrace_update_insns by reference instead of pointer.
9064
badc0020
YQ
90652017-09-04 Yao Qi <yao.qi@linaro.org>
9066
9067 * i386-go32-tdep.c: Include x86-xstate.h.
9068 (i386_go32_init_abi): Call i386_target_description.
9069 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
9070 if xcr0 is X86_XSTATE_X87_MASK.
9071 * i386-tdep.h (tdesc_i386): Remove the declaration.
9072 (tdesc_i386_mmx): Likewise.
9073
d78bdb54
YQ
90742017-09-04 Yao Qi <yao.qi@linaro.org>
9075
9076 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
9077 X86_XSTATE_SSE_MASK instead of 0.
9078
ca1fa5ee
YQ
90792017-09-04 Yao Qi <yao.qi@linaro.org>
9080
9081 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
9082 i386_target_description.
9083 * i386-fbsd-nat.c (i386fbsd_read_description): Call
9084 i386_target_description.
9085 * i386-tdep.c (i386_gdbarch_init): Likewise.
9086
2434b019
YQ
90872017-09-04 Yao Qi <yao.qi@linaro.org>
9088
9089 * amd64-darwin-tdep.c: Include "x86-xstate.h".
9090 (x86_darwin_init_abi_64): Call amd64_target_description.
9091 * amd64-dicos-tdep.c: Likewise.
9092 * amd64-fbsd-nat.c: Likewise.
9093 * amd64-fbsd-tdep.c: Likewise.
9094 * amd64-nbsd-tdep.c: Likewise.
9095 * amd64-obsd-tdep.c: Likewise.
9096 * amd64-sol2-tdep.c: Likewise.
9097 * amd64-windows-tdep.c: Likewise.
9098 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
9099
0860c437
SM
91002017-09-04 Simon Marchi <simon.marchi@ericsson.com>
9101
9102 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
9103 (btrace_function) <insn>: Change type to use std::vector.
9104 * btrace.c (ftrace_debug, ftrace_call_num_insn,
9105 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
9106 ftrace_update_insns, ftrace_compute_global_level_offset,
9107 btrace_stitch_bts, btrace_clear, btrace_insn_get,
9108 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
9109 change to std::vector.
9110 (ftrace_update_insns): Adjust to change to std::vector, change
9111 type of INSN parameter.
9112 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
9113 * record-btrace.c (btrace_call_history_insn_range,
9114 btrace_compute_src_line_range,
9115 record_btrace_frame_prev_register): Adjust to change to
9116 std::vector.
9117 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
9118 to change to std::vector.
9119
0638b7f9
TT
91202017-09-03 Tom Tromey <tom@tromey.com>
9121
9122 * corefile.c (reopen_exec_file): Use std::string.
9123
8f84fb0e
TT
91242017-09-03 Tom Tromey <tom@tromey.com>
9125
9126 * compile/compile.c (compile_register_name_mangled): Return
9127 std::string.
9128 * compile/compile-loc2c.c (pushf_register_address): Update.
9129 (pushf_register): Update.
9130 * compile/compile-c-types.c (convert_array): Update.
9131 * compile/compile-c-symbols.c (generate_vla_size): Update.
9132 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
9133 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
9134 (convert_one_symbol): Update.
9135 (generate_c_for_for_one_variable): Update.
9136 * compile/compile-c-support.c (c_get_range_decl_name): Return a
9137 std::string.
9138 (generate_register_struct): Update.
9139 * compile/compile-internal.h (c_get_range_decl_name): Return a
9140 std::string.
9141 (compile_register_name_mangled): Return std::string.
9142
18e9961f
TT
91432017-09-03 Tom Tromey <tom@tromey.com>
9144
9145 * utils.c (perror_string): Return a std::string.
9146 (throw_perror_with_name, perror_warning_with_name): Update.
9147
45343786
TT
91482017-09-03 Tom Tromey <tom@tromey.com>
9149
9150 * demangle.c (demangle_command): Use std::string,
9151 unique_xmalloc_ptr.
9152
b57af503
TT
91532017-09-03 Tom Tromey <tom@tromey.com>
9154
9155 * cli/cli-setshow.c (do_set_command): Use std::string.
9156
6eecf35f
TT
91572017-09-03 Tom Tromey <tom@tromey.com>
9158
9159 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
9160
56496dd4
TT
91612017-09-03 Tom Tromey <tom@tromey.com>
9162
9163 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
9164
e91a1fa7
TT
91652017-09-03 Tom Tromey <tom@tromey.com>
9166
9167 * mi/mi-cmd-env.c (env_execute_cli_command): Use
9168 gdb::unique_xmalloc_ptr.
9169
7ffd83d7
TT
91702017-09-03 Tom Tromey <tom@tromey.com>
9171
9172 * thread.c (print_thread_info_1): Use string_printf.
9173 (thread_apply_command, thread_apply_all_command): Use
9174 std::string.
9175
1ccbe998
TT
91762017-09-03 Tom Tromey <tom@tromey.com>
9177
9178 * valprint.c (val_print_string): Update.
9179 * gdbcore.h (memory_error_message): Return std::string.
9180 * corefile.c (memory_error_message): Return std::string.
9181 (memory_error): Update.
9182 * breakpoint.c (insert_bp_location): Update.
9183
23fdd69e
SM
91842017-09-03 Simon Marchi <simon.marchi@ericsson.com>
9185
9186 * target/waitstatus.h (target_waitstatus_to_string): Change
9187 return type to std::string.
9188 * target/waitstatus.c (target_waitstatus_to_string): Return
9189 std::string.
9190 * target.h (target_waitstatus_to_string): Remove declaration.
9191 * infrun.c (resume, clear_proceed_status_thread,
9192 print_target_wait_results, do_target_wait, save_waitstatus,
9193 stop_all_threads): Adjust.
9194 * record-btrace.c (record_btrace_wait): Adjust.
9195 * target-debug.h
9196 (target_debug_print_struct_target_waitstatus_p): Adjust.
9197
5c811d30
JK
91982017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
9199
9200 PR gdb/22046
9201 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
9202 detection.
9203
0a2dde4a
SDJ
92042017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
9205
9206 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
9207 for setting/unsetting environment variables on the remote target.
9208 (New remote packets): Add entries for QEnvironmentHexEncoded,
9209 QEnvironmentUnset and QEnvironmentReset.
9210 * common/environ.c (gdb_environ::operator=): Extend method to
9211 handle m_user_set_env_list and m_user_unset_env_list.
9212 (gdb_environ::clear): Likewise.
9213 (match_var_in_string): Change type of first parameter from 'char
9214 *' to 'const char *'.
9215 (gdb_environ::set): Extend method to handle
9216 m_user_set_env_list and m_user_unset_env_list.
9217 (gdb_environ::unset): Likewise.
9218 (gdb_environ::clear_user_set_env): New method.
9219 (gdb_environ::user_set_envp): Likewise.
9220 (gdb_environ::user_unset_envp): Likewise.
9221 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
9222 m_user_unset_env_list on move constructor/assignment.
9223 (unset): Add new default parameter 'update_unset_list = true'.
9224 (clear_user_set_env): New method.
9225 (user_set_envp): Likewise.
9226 (user_unset_envp): Likewise.
9227 (m_user_set_env_list): New std::set.
9228 (m_user_unset_env_list): Likewise.
9229 * common/rsp-low.c (hex2str): New function.
9230 (bin2hex): New overload for bin2hex function.
9231 * common/rsp-low.c (hex2str): New prototype.
9232 (str2hex): New overload prototype.
9233 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
9234 QEnvironmentUnset and QEnvironmentReset.
9235 (remote_protocol_features): Add QEnvironmentHexEncoded,
9236 QEnvironmentUnset and QEnvironmentReset packets.
9237 (send_environment_packet): New function.
9238 (extended_remote_environment_support): Likewise.
9239 (extended_remote_create_inferior): Call
9240 extended_remote_environment_support.
9241 (_initialize_remote): Add QEnvironmentHexEncoded,
9242 QEnvironmentUnset and QEnvironmentReset packet configs.
9243 * unittests/environ-selftests.c (gdb_selftest_env_var):
9244 New variable.
9245 (test_vector_initialization): New function.
9246 (test_init_from_host_environ): Likewise.
9247 (test_reinit_from_host_environ): Likewise.
9248 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
9249 Likewise.
9250 (test_unset_set_empty_vector): Likewise.
9251 (test_vector_clear): Likewise.
9252 (test_std_move): Likewise.
9253 (test_move_constructor):
9254 (test_self_move): Likewise.
9255 (test_set_unset_reset): Likewise.
9256 (run_tests): Rewrite in terms of the functions above.
9257
654670a4
WP
92582017-08-31 Weimin Pan <weimin.pan@oracle.com>
9259
9260 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
9261 (adi_available): Use a temp variable of type CORE_ADDR as argument
9262 3 when calling target_auxv_search.
9263 (adi_normalize_address): Use masks and xor operators to calculate
9264 normalized address.
9265 (adi_read_versions, adi_write_versions, adi_print_versions)
9266 (do_examine, do_assign): Use paddress.
9267
7755ddb7
JB
92682017-08-29 John Baldwin <jhb@FreeBSD.org>
9269
9270 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
9271 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
9272 out of loop and add supply of FIR.
9273 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
9274 add collect of FIR.
9275
fd437cbc
SM
92762017-08-28 Simon Marchi <simon.marchi@ericsson.com>
9277
3804a343 9278 PR gdb/21827
fd437cbc
SM
9279 * cli/cli-script.c (define_command): Don't convert command name
9280 to lower case.
9281
988f6b3d
JB
92822017-08-25 Joel Brobecker <brobecker@adacore.com>
9283
9284 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
9285 Update all callers accordingly. Remove all code blocks handling
9286 the case where DISPP is not NULL.
9287
663c44ac
JK
92882017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9289
9290 PR symtab/22003
9291 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
9292 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9293 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
9294
f1902523
JK
92952017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9296
9297 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
9298 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
9299 (read_comp_units_from_section): New parameter abbrev_section, use
9300 read_and_check_comp_unit_head, allocate signatured_type if needed.
9301 (create_all_comp_units): Update read_comp_units_from_section caller.
9302
87215ad1
SDJ
93032017-08-23 Pedro Alves <palves@redhat.com>
9304
9305 PR remote/21852
9306 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
9307 to null_ptid and switch to thread without reading the registers
9308 after adding the inferior.
9309
6e41ddec
JK
93102017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9311
9312 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
9313 compile-gcc.
9314 * compile/compile.c (compile_gcc, show_compile_gcc): New.
9315 (compile_to_object): Implement compile_gcc.
9316 (_initialize_compile): Install "set compile-gcc". Initialize
9317 compile_gcc.
9318
e68c32d5
JK
93192017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9320
9321 * compile/compile.c (compile_to_object): Conditionally call
9322 set_verbose. Conditionally call compile or compile_v0.
9323
58afddc6
WP
93242017-08-07 Weimin Pan <weimin.pan@oracle.com>
9325
9326 * sparc64-tdep.h: (adi_normalize_address): New export.
9327 * sparc-nat.h: (open_adi_tag_fd): New export.
9328 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
9329 * sparc64-linux-tdep.c:
9330 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
9331 (sparc64_linux_handle_segmentation_fault): New function.
9332 (sparc64_linux_init_abi): Register
9333 sparc64_linux_handle_segmentation_fault
9334 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
9335 (sparc64_addr_bits_remove): New function.
9336 (sparc64_init_abi): Register sparc64_addr_bits_remove.
9337 (MAX_PROC_NAME_SIZE): New macro.
9338 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
9339 (sparc64adilist): New variable.
9340 (adi_proc_list): New variable.
9341 (find_adi_info): New function.
9342 (add_adi_info): New function.
9343 (get_adi_info_proc): New function.
9344 (get_adi_info): New function.
9345 (info_adi_command): New function.
9346 (read_maps_entry): New function.
9347 (adi_available): New function.
9348 (adi_normalize_address): New function.
9349 (adi_align_address): New function.
9350 (adi_convert_byte_count): New function.
9351 (adi_tag_fd): New function.
9352 (adi_is_addr_mapped): New function.
9353 (adi_read_versions): New function.
9354 (adi_write_versions): New function.
9355 (adi_print_versions): New function.
9356 (do_examine): New function.
9357 (do_assign): New function.
9358 (adi_examine_command): New function.
9359 (adi_assign_command): New function.
9360 (_initialize_sparc64_adi_tdep): New function.
9361
11db9430
SM
93622017-08-22 Simon Marchi <simon.marchi@ericsson.com>
9363
9364 * breakpoint.c (breakpoints_info): Rename to ...
9365 (info_breakpoints_command): ... this.
9366 (watchpoints_info): Rename to ...
9367 (info_watchpoints_command): ... this.
9368 (tracepoints_info): Rename to ...
9369 (info_tracepoints_command): ... this.
9370 (_initialize_breakpoint): Adjust.
9371 * dcache.c (dcache_info): Rename to ...
9372 (info_display_command): ... this.
9373 (_initialize_dcache): Adjust.
9374 * frame.h (args_info): Rename to ...
9375 (info_args_command): ... this.
9376 (locals_info): Rename to ...
9377 (info_locals_command): ... this.
9378 * infcmd.c (nofp_registers_info): Rename to ...
9379 (info_registers_command): ... this.
9380 (float_info): Rename to ...
9381 (info_float_command): ... this.
9382 (program_info): Rename to ...
9383 (info_program_command): ... this.
9384 (all_registers_info): Rename to ...
9385 (info_all_registers_command): ... this.
9386 (vector_info): Rename to ...
9387 (info_vector_command): ... this.
9388 (float_info): Rename to ...
9389 (info_float_command): ... this.
9390 (_initialize_infcmd): Adjust.
9391 * inferior.h (term_info): Rename to ...
9392 (info_terminal_command): ... this.
9393 * inflow.c (term_info): Rename to ...
9394 (info_terminal_command): ... this.
9395 (_initialize_inflow): Adjust.
9396 * infrun.c (signals_info): Rename to ...
9397 (info_signals_command): ... this.
9398 (_initialize_infrun): Adjust.
9399 * objc-lang.c (classes_info): Rename to ...
9400 (info_classes_command): ... this.
9401 (selectors_info): Rename to ...
9402 (info_selectors_command): ... this.
9403 (_initialize_objc_language): Adjust.
9404 * printcmd.c (sym_info): Rename to ...
9405 (info_symbol_command): ... this.
9406 (address_info): Rename to ...
9407 (info_address_command): ... this.
9408 (display_info): Rename to ...
9409 (info_display_command): ... this.
9410 (_initialize_printcmd): Adjust.
9411 * reverse.c (bookmarks_info): Rename to ...
9412 (info_breakpoints_command): ... this.
9413 (_initialize_reverse): Adjust.
9414 * ser-go32.c (dos_info): Rename to ...
9415 (info_serial_command): ... this.
9416 (_initialize_ser_dos): Adjust.
9417 * skip.c (skip_info): Rename to ...
9418 (info_skip_command): ... this.
9419 (_initialize_step_skip): Adjust.
9420 * source.c (line_info): Rename to ...
9421 (info_line_command): ... this.
9422 (source_info): Rename to ...
9423 (info_source_command)
9424 * stack.c (frame_info): Rename to ...
9425 (info_frame_command): ... this.
9426 (locals_info): Rename to ...
9427 (info_locals_command): ... this.
9428 (args_info): Rename to ...
9429 (info_args_command): ... this.
9430 (_initialize_stack): Adjust.
9431 * symtab.c (sources_info): Rename to ...
9432 (info_sources_command): ... this.
9433 (variables_info): Rename to ...
9434 (info_variables_command): ... this.
9435 (functions_info): Rename to ...
9436 (info_functions_command): ... this.
9437 (types_info): Rename to ...
9438 (info_types_command): ... this.
9439 (_initialize_symtab): Adjust.
9440 * target.c (target_info): Rename to ...
9441 (info_target_command): ... this.
9442 (initialize_targets): Adjust.
9443 * tracepoint.c (tvariables_info): Rename to ...
9444 (info_tvariables_command): ... this.
9445 (scope_info): Rename to ...
9446 (info_scope_command): ... this.
9447 (trace_dump_actions): Adjust.
9448 (_initialize_tracepoint): Adjust.
9449
b270e6f9
TT
94502017-08-22 Tom Tromey <tom@tromey.com>
9451
9452 * breakpoint.h (install_breakpoint): Update.
9453 * breakpoint.c (add_solib_catchpoint): Update.
9454 (install_breakpoint): Change argument to a std::unique_ptr.
9455 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
9456 (create_breakpoint_sal, create_breakpoint): Update.
9457 (watch_command_1, catch_exec_command_1)
9458 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
9459 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
9460 Return the breakpoint.
9461 (set_raw_breakpoint_without_location, set_raw_breakpoint)
9462 (new_single_step_breakpoint): Update.
9463 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
9464 std::unique_ptr.
9465 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9466 std::unique_ptr.
9467 * break-catch-sig.c (create_signal_catchpoint): Use
9468 std::unique_ptr.
9469 * ada-lang.c (create_ada_exception_catchpoint): Use
9470 std::unique_ptr.
9471
36bd8eaa
TT
94722017-08-22 Tom Tromey <tom@tromey.com>
9473
9474 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
9475
56f37645
TT
94762017-08-22 Tom Tromey <tom@tromey.com>
9477
9478 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9479 (lookup_partial_symbol): Update.
9480
0b581c69
TT
94812017-08-22 Tom Tromey <tom@tromey.com>
9482
9483 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9484 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9485 (find_and_open_source, symtab_to_fullname): Update.
9486 * psymtab.c (psymtab_to_fullname): Update.
9487
14278e1f
TT
94882017-08-22 Tom Tromey <tom@tromey.com>
9489
9490 * exec.c (exec_file_attach): Update.
9491 * linux-thread-db.c (try_thread_db_load): Update.
9492 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9493 * utils.c (gdb_realpath): Change return type.
9494 (gdb_realpath_keepfile): Update.
9495 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9496 (_initialize_utils): Register the new self test.
9497 * source.c (openp): Update.
9498 (find_and_open_source): Update.
9499 * nto-tdep.c (nto_find_and_open_solib): Update.
9500 * main.c (set_gdb_data_directory): Update.
9501 (captured_main_1): Update.
9502 * dwarf2read.c (dwarf2_get_dwz_file): Update
9503 (dw2_map_symbol_filenames): Update.
9504 * auto-load.c (auto_load_safe_path_vec_update): Update.
9505 (filename_is_in_auto_load_safe_path_vec): Change type of
9506 "filename_realp".
9507 (auto_load_objfile_script): Update.
9508 (file_is_auto_load_safe): Update. Use std::string.
9509 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9510
4971c9a7
TT
95112017-08-22 Tom Tromey <tom@tromey.com>
9512
9513 * utils.c (gdb_realpath_keepfile): Return a
9514 gdb::unique_xmalloc_ptr.
9515 * exec.c (exec_file_attach): Update.
9516 * utils.h (gdb_realpath_keepfile): Return a
9517 gdb::unique_xmalloc_ptr.
9518
e3e41d58
TT
95192017-08-22 Tom Tromey <tom@tromey.com>
9520
9521 * compile/compile.c (compile_file_command): Use
9522 gdb::unique_xmalloc_ptr, std::string.
9523 * utils.c (gdb_abspath): Change return type.
9524 * source.c (openp): Update.
9525 * objfiles.c (allocate_objfile): Update.
9526 * main.c (set_gdb_data_directory): Update.
9527 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9528
0d999a6e
ZZ
95292017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9530
9531 * cli-cmds.c (list_commands): List actual code around more than
9532 one location.
9533
329d5e7e
JB
95342017-08-21 John Baldwin <jhb@FreeBSD.org>
9535
9536 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9537
bf223d3e
PA
95382017-08-21 Pedro Alves <palves@redhat.com>
9539
9540 PR gdb/19487
9541 * c-exp.y (variable production): Handle function aliases.
9542 * minsyms.c (msymbol_is_text): New function.
9543 * minsyms.h (msymbol_is_text): Declare.
9544 * symtab.c (find_function_alias_target): New function.
9545 * symtab.h (find_function_alias_target): Declare.
9546
c973d0aa
PA
95472017-08-21 Pedro Alves <palves@redhat.com>
9548
9549 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9550 typedefs.
9551 * typeprint.c (whatis_exp): If handling "whatis", and expression
9552 is OP_TYPE, strip one typedef level. Otherwise don't strip
9553 typedefs here.
9554 * valops.c (value_cast): Save "to" type before resolving
9555 stubs/typedefs. Use that type as resulting value's type.
9556
2989a365
TT
95572017-08-18 Tom Tromey <tom@tromey.com>
9558 Pedro Alves <palves@redhat.com>
9559
9560 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9561 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9562 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9563 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9564 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9565 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9566 (linux_get_siginfo_data): Add "thread" argument. Use
9567 scoped_restore.
9568 * linux-nat.c (linux_child_follow_fork)
9569 (check_stopped_by_watchpoint): Use scoped_restore.
9570 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9571 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9572 (restore_inferior_ptid, save_inferior_ptid): Remove.
9573 * btrace.c (btrace_fetch): Use scoped_restore.
9574 * bsd-uthread.c (bsd_uthread_fetch_registers)
9575 (bsd_uthread_store_registers): Use scoped_restore.
9576 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9577 scoped_restore.
9578 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9579 (aix_thread_xfer_partial): Use scoped_restore.
9580 * inferior.h (save_inferior_ptid): Remove.
9581
e60eb288
YQ
95822017-08-18 Yao Qi <yao.qi@linaro.org>
9583
9584 PR tdep/21818
9585 * arm-tdep.c (gdb_print_insn_arm): Mark
9586 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9587
6d580b63
YQ
95882017-08-18 Yao Qi <yao.qi@linaro.org>
9589
9590 * NEWS: Mention GDBserver's new option "--selftest".
9591 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9592 * selftest.c: Move it to common/selftest.c.
9593 * selftest.h: Move it to common/selftest.h.
9594 * selftest-arch.c (reset): New function.
9595 (tests_with_arch): Call reset.
9596
86dcbf50
YQ
95972017-08-18 Yao Qi <yao.qi@linaro.org>
9598
9599 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9600 instead of exception_fprintf and printf_filtered.
9601
7649770c
YQ
96022017-08-18 Yao Qi <yao.qi@linaro.org>
9603
9604 * selftest.c (register_self_test): Rename it to
9605 selftests::register_test.
9606 (run_self_tests): selftest::run_tests.
9607 * selftest.h: Update declarations.
9608 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9609 selftests::register_test_foreach_arch.
9610 * selftest-arch.h: Update declaration.
9611 * aarch64-tdep.c: Update.
9612 * arm-tdep.c: Likewise.
9613 * disasm-selftests.c: Likewise.
9614 * dwarf2loc.c: Likewise.
9615 * dwarf2-frame.c: Likewise.
9616 * findvar.c: Likewise.
9617 * gdbarch-selftests.c: Likewise.
9618 * maint.c (maintenance_selftest): Likewise.
9619 * regcache.c: Likewise.
9620 * rust-exp.y: Likewise.
9621 * selftest-arch.c: Likewise.
9622 * unittests/environ-selftests.c: Likewise.
9623 * unittests/function-view-selftests.c: Likewise.
9624 * unittests/offset-type-selftests.c: Likewise.
9625 * unittests/optional-selftests.c: Likewise.
9626 * unittests/scoped_restore-selftests.c: Likewise.
9627 * utils-selftests.c: Likewise.
9628
b0cba12e
PA
96292017-08-17 Pedro Alves <palves@redhat.com>
9630
9631 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9632 local.
9633
4c8aa72d
PA
96342017-08-17 Pedro Alves <palves@redhat.com>
9635
9636 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9637 field.
9638 (reset_die_in_process): Delete, replaced by ...
9639 (process_die_scope): ... this new class. Make it responsible for
9640 freeing cu->line_header too.
9641 (process_die): Use process_die_scope.
9642 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9643 cu->line_header_die_owner. Don't release the line header if it's
9644 owned by the CU.
9645 (setup_type_unit_groups): Make the CU/DIE own the line header.
9646 Don't release the line header here.
9647
ba713918
AL
96482017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9649
9650 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9651
44d0fb3a
RK
96522017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9653
9654 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9655 Single-Key mode
9656
a5afdb16
RK
96572017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9658
9659 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9660 mode command list.
9661
47613aeb
SH
96622017-08-15 Stafford Horne <shorne@gmail.com>
9663
9664 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9665
9c3cc999
SH
96662017-08-15 Stafford Horne <shorne@gmail.com>
9667
9668 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9669
206726fb
SDJ
96702017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9671
9672 PR gdb/21954
9673 * infcmd.c (unset_environment_command): Use the 'clear' method on
9674 the environment instead of resetting it.
9675
0335ac6d
JB
96762017-08-15 John Baldwin <jhb@FreeBSD.org>
9677
9678 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9679 platforms.
9680
d3abe1c8
TT
96812017-08-14 Tom Tromey <tom@tromey.com>
9682
9683 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9684 (print_binary_chars): Likewise.
9685 (BITS_IN_BYTES): Remove.
9686
d6382fff
TT
96872017-08-14 Tom Tromey <tom@tromey.com>
9688
9689 PR gdb/21675
9690 * valprint.c (LOW_ZERO): Change value to 034.
9691 (print_octal_chars): Add static_asserts for octal constants.
9692 * printcmd.c (print_scalar_formatted): Add 'd' case.
9693
f978cb06
TT
96942017-08-11 Tom Tromey <tom@tromey.com>
9695
9696 * symfile.c (add_symbol_file_command): Use std::vector.
9697
2f5404b3
TT
96982017-08-14 Tom Tromey <tom@tromey.com>
9699
9700 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9701 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9702 std::move.
9703 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9704
de7985c3
PA
97052017-08-11 Pedro Alves <palves@redhat.com>
9706
9707 * infrun.c (process_event_stop_test): Adjust
9708 function_name_is_marked_for_skip call.
9709 * skip.c: Include <list>.
9710 (skiplist_entry): Make it a class with private fields, and
9711 getters/setters.
9712 (skiplist_entry_chain): Delete.
9713 (skiplist_entries): New.
9714 (skiplist_entry_count): Delete.
9715 (highest_skiplist_entry_num): New.
9716 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9717 (add_skiplist_entry): Delete.
9718 (skiplist_entry::skiplist_entry): New.
9719 (skiplist_entry::add_entry): New.
9720 (skip_file_command, skip_function): Adjust.
9721 (compile_skip_regexp): Delete.
9722 (skip_command): Don't compile regexp here. Adjust to use
9723 skiplist_entry::add_entry.
9724 (skip_info): Adjust to use range-for and getters.
9725 (skip_enable_command, skip_disable_command): Adjust to use
9726 range-for and setters.
9727 (skip_delete_command): Adjust to use std::list.
9728 (add_skiplist_entry): Delete.
9729 (skip_file_p): Delete, refactored as ...
9730 (skiplist_entry::do_skip_file_p): ... this new method.
9731 (skip_gfile_p): Delete, refactored as ...
9732 (skiplist_entry::do_gskip_file_p): ... this new method.
9733 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9734 (skiplist_entry::skip_function_p): ... this new method.
9735 (function_name_is_marked_for_skip): Now returns bool, and takes
9736 the function sal by const reference. Adjust to use range-for and
9737 skiplist_entry methods.
9738 (_initialize_step_skip): Remove references to
9739 skiplist_entry_chain, skiplist_entry_count.
9740 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9741 takes the function sal by const reference.
9742
be7d3cd5
YQ
97432017-08-11 Yao Qi <yao.qi@linaro.org>
9744
9745 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9746 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9747 (dwarf2_frame_cache):
9748 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9749 RETURN_MASK_ALL and set *this_case to NULL.
9750 * frame-unwind.h: Update comments.
9751
1c90d9f0
YQ
97522017-08-11 Yao Qi <yao.qi@linaro.org>
9753
9754 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9755 (dwarf2_frame_state_copy_regs): Remove.
9756 (dwarf2_frame_state_free_regs): Remove.
9757 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9758 (dwarf2_restore_rule): Call method .alloc_regs instead of
9759 dwarf2_frame_state_alloc_regs.
9760 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9761 constructor. Call std::move.
9762 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9763 (dwarf2_frame_cache): Likewise.
9764
9765 [GDB_SELF_TEST]: Include selftest.h and
9766 selftest-arch.h.
9767 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9768 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9769 execute_cfa_program_test.
9770
9771 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9772 copy ctor, assignment operator, move assignment.
9773 <alloc_regs>: New method.
9774 <swap>: New method.
9775 (struct dwarf2_frame_state): Delete dtor.
9776 (dwarf2_frame_state_alloc_regs): Remove declaration.
9777 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9778 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9779
afe37d6b
YQ
97802017-08-11 Yao Qi <yao.qi@linaro.org>
9781
9782 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9783 (dwarf2_frame_state::dwarf2_frame_state): New.
9784 (dwarf2_frame_state::~dwarf2_frame_state): New.
9785 (dwarf2_fetch_cfa_info): Update.
9786 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9787 rather than a pointer. Update code.
9788 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9789 dtor.
9790 <data_align, code_align, retaddr_column>: Change them to const.
9791 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9792 to bool.
9793
b348037f
YQ
97942017-08-11 Yao Qi <yao.qi@linaro.org>
9795
9796 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9797 <loc.exp>: New field.
9798 * dwarf2-frame.c (execute_cfa_program): Update.
9799 (dwarf2_frame_prev_register): Update.
9800
e7c9de26
PA
98012017-08-10 Pedro Alves <palves@redhat.com>
9802
9803 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9804
e8c6b620
JB
98052017-08-09 John Baldwin <jhb@FreeBSD.org>
9806
9807 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9808 (fbsd_pending_children): Use std::list.
9809 (fbsd_remember_child): Likewise.
9810 (fbsd_is_child_pending): Likewise.
9811 (fbsd_pending_vfork_done): Use std::forward_list.
9812 (fbsd_add_vfork_done): Likewise.
9813 (fbsd_is_vfork_done_pending): Likewise.
9814 (fbsd_next_vfork_done): Likewise.
9815
e4a26669
JB
98162017-08-09 John Baldwin <jhb@FreeBSD.org>
9817
9818 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9819 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9820 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9821 for `mapfilename'.
9822 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 9823 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 9824
142311d3
JB
98252017-08-09 John Baldwin <jhb@FreeBSD.org>
9826
9827 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
9828 "filestuff.h".
9829 (fbsd_find_memory_regions): Fix `mapfile' initialization.
9830
42fa2e0e
TT
98312017-08-09 Tom Tromey <tom@tromey.com>
9832
9833 * skip.c (skiplist_entry): New constructor.
9834 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
9835 (skiplist_entry::file_is_glob): Now bool.
9836 (skiplist_entry::file, skiplist_entry::function): Now
9837 std::string.
9838 (make_skip_entry): Return a unique_ptr. Use new.
9839 (free_skiplist_entry, free_skiplist_entry_cleanup)
9840 (make_free_skiplist_entry_cleanup): Remove.
9841 (skip_command, skip_disable_command, add_skiplist_entry)
9842 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
9843 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
9844 (function_name_is_marked_for_skip): Update.
9845 (skip_delete_command): Update. Use delete.
9846
cd3af38d
JW
98472017-08-09 Jiong Wang <jiong.wang@arm.com>
9848
9849 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
9850 (aarch64_linux_core_read_description): New function.
9851 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
9852
29592bde
PA
98532017-08-09 Pedro Alves <palves@redhat.com>
9854
9855 * cp-name-parser.y (cp_comp_to_string): Return a
9856 gdb::unique_xmalloc_ptr<char>.
9857 * cp-support.c (replace_typedefs_qualified_name)
9858 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
9859 (cp_canonicalize_string_full): Use op= instead of explicit
9860 convertion.
9861 (cp_class_name_from_physname, method_name_from_physname)
9862 (cp_func_name, cp_remove_params): Adjust to use
9863 gdb::unique_xmalloc_ptr<char>.
9864 * cp-support.h (cp_comp_to_string): Return a
9865 gdb::unique_xmalloc_ptr<char>.
9866 * python/py-type.c (typy_lookup_type): Adjust to use
9867 gdb::unique_xmalloc_ptr<char>.
9868
b3340438
L
98692017-08-09 H.J. Lu <hongjiu.lu@intel.com>
9870
9871 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
9872
e88e8651
YQ
98732017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
9874 Yao Qi <yao.qi@linaro.org>
9875
9876 * cp-support.c (cp_canonicalize_string_full): Use
9877 gdb::unique_xmalloc_ptr<char>.
9878 (cp_canonicalize_string): Likewise.
9879
f5a29eb0
YQ
98802017-08-09 Yao Qi <yao.qi@linaro.org>
9881
9882 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
9883 * regformats/i386/amd64-avx-avx512.dat: Remove.
9884 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
9885 * regformats/i386/amd64-avx-mpx.dat:Remove.
9886 * regformats/i386/amd64-avx.dat: Remove.
9887 * regformats/i386/amd64-mpx.dat: Remove.
9888 * regformats/i386/i386-avx-avx512.dat: Remove.
9889 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
9890 * regformats/i386/i386-avx-mpx.dat: Remove.
9891 * regformats/i386/i386-mmx.dat: Remove.
9892 * regformats/i386/i386-mpx.dat: Remove.
9893
57757c2f
YQ
98942017-08-09 Yao Qi <yao.qi@linaro.org>
9895
9896 * amd64-tdep.h (tdesc_x32): Remove the declaration.
9897 * amd64-tdep.c: Don't include features/i386/x32*.c.
9898 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
9899 functions.
9900 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
9901 and i386/x32-avx-avx512.
9902 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
9903 and i386/x32.xml.
9904 * features/i386/x32-avx-avx512.c: Removed.
9905 * features/i386/x32-avx-avx512.xml: Removed.
9906 * features/i386/x32-avx.c: Removed.
9907 * features/i386/x32-avx.xml: Removed.
9908 * features/i386/x32.c: Removed.
9909 * features/i386/x32.xml: Removed.
9910 * regformats/i386/x32-avx-avx512.dat: Removed.
9911 * regformats/i386/x32-avx.dat: Removed.
9912 * regformats/i386/x32.dat: Removed.
9913
ba7b109b
MR
99142017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9915
9916 PR breakpoints/21886
9917 * mem-break.c (default_memory_insert_breakpoint): Use
9918 `->placed_address' rather than `->reqstd_address' for the
9919 breakpoint location.
9920
e347efc3
MR
99212017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9922
9923 * arch-utils.c (default_print_insn): Remove arch/mach/endian
9924 assertions.
9925
0dba2a6c
MR
99262017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9927
9928 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
9929 a union of `tdep_info', `tdesc_data' and `id'.
9930 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
9931 rather than `info.tdep_info'.
9932 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
9933 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9934 * i386-tdep.c (i386_gdbarch_init): Likewise.
9935 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
9936 * mips-tdep.c (mips_gdbarch_init): Likewise.
9937 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9938 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9939 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
9940 `info.tdep_info'.
9941 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
9942 `info.tdep_info'.
9943 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9944 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
9945 `info.tdep_info'.
9946 * spu-tdep.c (spu_gdbarch_init): Likewise.
9947 * gdbarch.h: Regenerate.
9948
16eb6b2d
LS
99492017-08-07 Leszek Swirski <leszeks@google.com>
9950
7b005726 9951 PR symtab/20899
16eb6b2d
LS
9952 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
9953
74cbb09e
SM
99542017-08-07 Simon Marchi <simon.marchi@ericsson.com>
9955
9956 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
9957 (gdbsim_open): Rename gdb_argv args object to argv.
9958
ee0c3293
TT
99592017-08-05 Tom Tromey <tom@tromey.com>
9960
9961 * compile/compile-object-load.c (compile_object_load): Use
9962 gdb::unique_xmalloc_ptr.
9963 * cli/cli-dump.c (scan_filename): Rename from
9964 scan_filename_with_cleanup. Change return type.
9965 (scan_expression): Rename from scan_expression_with_cleanup.
9966 Change return type.
9967 (dump_memory_to_file, dump_value_to_file, restore_command):
9968 Use gdb::unique_xmalloc_ptr. Update.
9969 * cli/cli-cmds.c (find_and_open_script): Use
9970 gdb::unique_xmalloc_ptr.
9971 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
9972 * symmisc.c (maintenance_print_symbols)
9973 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
9974 * symfile.c (symfile_bfd_open, generic_load)
9975 (add_symbol_file_command, remove_symbol_file_command): Use
9976 gdb::unique_xmalloc_ptr.
9977 * source.c (openp): Use gdb::unique_xmalloc_ptr.
9978 * psymtab.c (maintenance_print_psymbols): Use
9979 gdb::unique_xmalloc_ptr.
9980 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
9981 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
9982 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
9983 (reload_shared_libraries_1): Likewise.
9984
3232fabd
TT
99852017-08-05 Tom Tromey <tom@tromey.com>
9986
9987 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
9988 (rust_op_vector, rust_set_vector): New typedefs.
9989 (current_parser): New global.
9990 (work_obstack): Change to pointer type. Update all users.
9991 (rust_ast, pstate): Remove globals.
9992 (struct rust_parser): New.
9993 (%union) <params, field_inits>: Change type.
9994 (start, tuple_expr, unit_expr, struct_expr_list, literal)
9995 (field_expr, expr_list, maybe_expr_list, type_list): Update.
9996 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
9997 (convert_params_to_types, convert_params_to_expression): Change
9998 type of "params".
9999 (ast_string): Change type of "fields".
10000 (rust_parse): Make a rust_parser. Remove cleanups.
10001 (rust_lex_tests): Make and install an auto_obstack.
10002
f02fd774
YQ
100032017-08-04 Yao Qi <yao.qi@linaro.org>
10004
10005 * configure.srv (ipa_x32_linux_regobj): New.
10006 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
10007 instead of X86_TDESC_AVX512.
10008 (initialize_low_tracepoint): Call
10009 init_registers_x32_avx_avx512_linux.
10010
91975afd
YQ
100112017-08-04 Yao Qi <yao.qi@linaro.org>
10012
10013 * utils.h (gdb_argv): Add namespace std for nullptr_t.
10014
2331fa3a
RK
100152017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
10016
10017 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
10018
744e4fe1
TT
100192017-08-03 Tom Tromey <tom@tromey.com>
10020
10021 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
10022 Remove.
10023 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
10024
1c034b67
TT
100252017-08-03 Tom Tromey <tom@tromey.com>
10026
10027 * python/py-param.c (compute_enum_values): Use gdb_argv.
10028
773a1edc
TT
100292017-08-03 Tom Tromey <tom@tromey.com>
10030
10031 * utils.h (struct gdb_argv_deleter): New.
10032 (gdb_argv): New class.
10033 * utils.c (gdb_argv::reset): New method.
10034 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
10035 * tracefile.c (tsave_command): Use gdb_argv.
10036 * top.c (new_ui_command): Use gdb_argv.
10037 * symmisc.c (maintenance_print_symbols)
10038 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
10039 * symfile.c (symbol_file_command, generic_load)
10040 (remove_symbol_file_command): Use gdb_argv.
10041 * stack.c (backtrace_command): Use gdb_argv.
10042 * source.c (add_path, show_substitute_path_command)
10043 (unset_substitute_path_command, set_substitute_path_command):
10044 Use gdb_argv.
10045 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
10046 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
10047 * remote.c (extended_remote_run, remote_put_command)
10048 (remote_get_command, remote_delete_command): Use gdb_argv.
10049 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
10050 (gdbsim_open): Use gdb_argv.
10051 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
10052 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
10053 * procfs.c (procfs_info_proc): Use gdb_argv.
10054 * interps.c (interpreter_exec_cmd): Use gdb_argv.
10055 * infrun.c (handle_command): Use gdb_argv.
10056 * inferior.c (add_inferior_command, clone_inferior_command):
10057 Use gdb_argv.
10058 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
10059 * exec.c (exec_file_command): Use gdb_argv.
10060 * cli/cli-cmds.c (alias_command): Use gdb_argv.
10061 * compile/compile.c (build_argc_argv): Use gdb_argv.
10062
0d50bde3
TT
100632017-08-03 Tom Tromey <tom@tromey.com>
10064
10065 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
10066
7f968c89
TT
100672017-08-03 Tom Tromey <tom@tromey.com>
10068
10069 * python/python.c (compute_python_string): Return std::string.
10070 (gdbpy_eval_from_control_command): Update.
10071 (do_start_initialization): Use std::string.
10072 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
10073 xstrprintf.
10074 * python/py-breakpoint.c (local_setattro): Use string_printf, not
10075 xstrprintf.
10076
3c9ebddd
TT
100772017-08-03 Tom Tromey <tom@tromey.com>
10078
10079 * top.h (do_restore_instream_cleanup): Remove.
10080 * top.c (do_restore_instream_cleanup): Remove.
10081 (read_command_file): Use scoped_restore.
10082 * cli/cli-script.c (execute_user_command): Use scoped_restore.
10083
b51b225e
TT
100842017-08-03 Tom Tromey <tom@tromey.com>
10085
10086 * cli/cli-script.c (execute_user_command)
10087 (execute_control_command): Use scoped_restore.
10088
ac991630
TT
100892017-08-03 Tom Tromey <tom@tromey.com>
10090
10091 * cli/cli-script.c (do_restore_user_call_depth): Remove.
10092 (execute_user_command): Remove user_call_depth; use
10093 user_args_stack's size instead.
10094
898e0c8e
TT
100952017-08-03 Tom Tromey <tom@tromey.com>
10096
10097 * top.h (in_user_command): Remove.
10098 * top.c (in_user_command): Remove.
10099 * cli/cli-script.c (do_restore_user_call_depth)
10100 (execute_user_command): Update.
10101
26fcd5d7
TT
101022017-08-03 Tom Tromey <tom@tromey.com>
10103
10104 * valops.c (search_struct_method): Use gdb::byte_vector.
10105 * valarith.c (value_concat): Use std::vector.
10106 * target.c (memory_xfer_partial): Use gdb::byte_vector.
10107 (simple_search_memory): Likewise.
10108 * printcmd.c (find_string_backward): Use gdb::byte_vector.
10109 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
10110 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
10111 * elfread.c (elf_rel_plt_read): Use std::string.
10112 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
10113 * cli/cli-dump.c (restore_section_callback): Use
10114 gdb::byte_vector.
10115
7c218e6c
TT
101162017-08-03 Tom Tromey <tom@tromey.com>
10117
10118 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
10119
31b68d4a
TT
101202017-08-03 Tom Tromey <tom@tromey.com>
10121
10122 * tui/tui-regs.c (tui_restore_gdbout): Remove.
10123 (tui_register_format): Use scoped_restore.
10124
2ec845e7
TT
101252017-08-03 Tom Tromey <tom@tromey.com>
10126
10127 * reverse.c (exec_direction_default): Remove.
10128 (exec_reverse_once): Use scoped_restore.
10129 * remote.c (restore_remote_timeout): Remove.
10130 (remote_flash_erase, remote_flash_write, remote_flash_done)
10131 (readchar, remote_serial_write): Use scoped_restore.
10132 * cli/cli-script.c (struct source_cleanup_lines_args)
10133 (source_cleanup_lines): Remove.
10134 (script_from_file): Use scoped_restore.
10135 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
10136 (source_command): Use scoped_restore.
10137
b3bc8453
TT
101382017-08-03 Tom Tromey <tom@tromey.com>
10139
10140 * utils.h (make_cleanup_free_so): Remove.
10141 * utils.c (do_free_so, make_cleanup_free_so): Remove.
10142 * solist.h (struct so_deleter): New.
10143 (so_list_up): New typedef.
10144 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
10145
e3ad2841
TT
101462017-08-03 Tom Tromey <tom@tromey.com>
10147
10148 * utils.h (make_cleanup_restore_current_language): Remove.
10149 * utils.c (do_restore_current_language)
10150 (make_cleanup_restore_current_language): Remove.
10151 * parse.c (parse_exp_in_context_1)
10152 (parse_expression_with_language): Use
10153 scoped_restore_current_language.
10154 * mi/mi-main.c (mi_cmd_execute): Use
10155 scoped_restore_current_language.
10156 * language.h (scoped_restore_current_language): New class.
10157
b80cf838
TT
101582017-08-03 Tom Tromey <tom@tromey.com>
10159
10160 * compile/compile.c (cleanup_unlink_file): Remove.
10161 (compile_to_object): Use gdb::unlinker.
10162 (eval_compile_command): Likewise.
10163
fad0444a
TT
101642017-08-03 Tom Tromey <tom@tromey.com>
10165
10166 * utils.h (make_cleanup_fclose): Remove.
10167 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
10168
6e7bc05c
TT
101692017-08-03 Tom Tromey <tom@tromey.com>
10170
10171 * top.c (open_terminal_stream): Return gdb_file_up.
10172 (new_ui_command): Update.
10173
4a45905b
TT
101742017-08-03 Tom Tromey <tom@tromey.com>
10175
10176 * source.c (print_source_lines_base, forward_search_command)
10177 (reverse_search_command): Use gdb_file_up.
10178
7cd06d6e
TT
101792017-08-03 Tom Tromey <tom@tromey.com>
10180
10181 * fbsd-nat.c (fbsd_find_memory_regions): Update.
10182
ed166945
TT
101832017-08-03 Tom Tromey <tom@tromey.com>
10184
10185 * cli/cli-cmds.c (find_and_open_script): Change return type.
10186 Remove "streamp" and "full_path" parameters.
10187 (source_script_with_search): Update.
10188 * auto-load.c (source_script_file): Update.
10189 * cli/cli-cmds.h (find_and_open_script): Change type.
10190 (open_script): New struct.
10191
d419f42d
TT
101922017-08-03 Tom Tromey <tom@tromey.com>
10193
10194 * xml-support.c (xml_fetch_content_from_file): Update.
10195 * ui-file.c (stdio_file::open): Update.
10196 * tracefile-tfile.c (tfile_start): Update.
10197 * remote.c (remote_file_put, remote_file_get): Update.
10198 * nat/linux-procfs.c (linux_proc_get_int)
10199 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
10200 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
10201 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
10202 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
10203 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
10204 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
10205 * linux-nat.c (linux_proc_pending_signals): Update.
10206 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
10207 (file_closer): Remove.
10208 * compile/compile.c (compile_to_object): Update.
10209 * common/filestuff.h (struct gdb_file_deleter): New.
10210 (gdb_file_up): New typedef.
10211 (gdb_fopen_cloexec): Change return type.
10212 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
10213 * cli/cli-dump.c (fopen_with_cleanup): Remove.
10214 (dump_binary_file, restore_binary_file): Update.
10215 * auto-load.c (auto_load_objfile_script_1): Update.
10216
4a2b031d
TT
102172017-08-03 Tom Tromey <tom@tromey.com>
10218
10219 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
10220 (info_static_tracepoint_markers_command): Likewise.
10221 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
10222 * skip.c (skip_info): Use ui_out_emit_table.
10223 * progspace.c (print_program_space): Use ui_out_emit_table.
10224 * osdata.c (info_osdata): Use ui_out_emit_table.
10225 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
10226 ui_out_emit_table.
10227 * linux-thread-db.c (info_auto_load_libthread_db): Use
10228 ui_out_emit_table.
10229 * inferior.c (print_inferior): Use ui_out_emit_table.
10230 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
10231 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
10232 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
10233 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
10234 * ui-out.h (class ui_out_emit_table): New.
10235
a4f320fd
MR
102362017-08-02 Maciej W. Rozycki <macro@imgtec.com>
10237
10238 * mips-tdep.c (mips_fpu_type_str): New function.
10239 (mips_dump_tdep): Call it.
10240
a2f1f308
MR
102412017-08-01 Maciej W. Rozycki <macro@imgtec.com>
10242
10243 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
10244 `->mips_fpu_type'.
10245
7e5ed83b
XR
102462017-07-31 Xavier Roirand <roirand@adacore.com>
10247
10248 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
10249
4c9dc811
XR
102502017-07-27 Xavier Roirand <roirand@adacore.com>
10251
10252 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
10253
27d41eac
YQ
102542017-07-26 Yao Qi <yao.qi@linaro.org>
10255
10256 * cli/cli-cmds.c (maintenancechecklist): New variable.
10257 * gdbcmd.h (maintenancechecklist): Declare it.
10258 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
10259 Call i386_linux_read_description with different masks.
10260 * maint.c (maintenance_check_command): New function.
10261 (_initialize_maint_cmds): Call add_prefix_cmd.
10262 * target-descriptions.c (tdesc_reg): override operator != and ==.
10263 (tdesc_type): Likewise.
10264 (tdesc_feature): Likewise.
10265 (target_desc): Likewise.
10266 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
10267 (maintenance_check_xml_descriptions): New function.
10268 (_initialize_target_descriptions) Add command "xml-descriptions".
10269 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
10270
ea03d0d3
YQ
102712017-07-26 Yao Qi <yao.qi@linaro.org>
10272
10273 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
10274 Include features/i386/32bit-*.c.
10275 (i386_linux_read_description): Generate target description if it
10276 doesn't exist.
10277 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
10278 functions.
10279 * features/i386/32bit-linux.c: Re-generated.
10280 * features/i386/32bit-sse.c: Likewise.
10281 * target-descriptions.c (print_c_feature::visit): Print code to
10282 set register number if needed.
10283 (print_c_feature) <m_next_regnum>: New field.
10284
25aa13e5
YQ
102852017-07-26 Yao Qi <yao.qi@linaro.org>
10286
10287 * features/Makefile (CFILES): Rename with TDESC_CFILES.
10288 (FEATURE_XMLFILES): New.
10289 (FEATURE_CFILES): New.
10290 New rules.
10291 (clean-cfiles): Remove generated c files.
10292 * features/i386/32bit-avx.c: Generated.
10293 * features/i386/32bit-avx512.c: Generated.
10294 * features/i386/32bit-core.c: Generated.
10295 * features/i386/32bit-linux.c: Generated.
10296 * features/i386/32bit-mpx.c: Generated.
10297 * features/i386/32bit-pkeys.c: Generated.
10298 * features/i386/32bit-sse.c: Generated.
10299 * target-descriptions.c: Include algorithm.
10300 (tdesc_element_visitor): Add method visit_end.
10301 (print_c_tdesc): Implement visit_end.
10302 (print_c_tdesc:: m_filename_after_features): Move it to
10303 protected.
10304 (print_c_feature): New class.
10305 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
10306 name starts with "i386/32bit-".
10307
6eb1e6a8
YQ
103082017-07-26 Yao Qi <yao.qi@linaro.org>
10309
10310 * target-descriptions.c (tdesc_element_visitor): New class.
10311 (tdesc_element): New class.
10312 (tdesc_reg): Inherit from tdesc_element.
10313 (tdesc_reg::accept): New function.
10314 (tdesc_type): Inherit from tdesc_element.
10315 (tdesc_type::accept): New function.
10316 (tdesc_feature): Inherit from tdesc_element.
10317 (tdesc_feature::accept): New function.
10318 (target_desc): Inherit from tdesc_element.
10319 (target_desc::target_desc): New.
10320 (target_desc::~target_desc): New.
10321 (target_desc::accept): New.
10322 (allocate_target_description): Use new.
10323 (free_target_description): Use delete.
10324 (print_c_tdesc): New class.
10325 (maint_print_c_tdesc_cmd): Adjust.
10326
10327 * features/aarch64.c: Re-generated.
10328 * features/arc-arcompact.c: Re-generated.
10329 * features/arc-v2.c: Re-generated.
10330 * features/arm/arm-with-iwmmxt.c: Re-generated.
10331 * features/arm/arm-with-m.c: Re-generated.
10332 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
10333 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
10334 * features/arm/arm-with-neon.c: Re-generated.
10335 * features/arm/arm-with-vfpv2.c: Re-generated.
10336 * features/arm/arm-with-vfpv3.c: Re-generated.
10337 * features/i386/amd64-avx-avx512.c: Re-generated.
10338 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10339 * features/i386/amd64-avx.c: Re-generated.
10340 * features/i386/amd64-avx-linux.c: Re-generated.
10341 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
10342 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10343 * features/i386/amd64-avx-mpx.c: Re-generated.
10344 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
10345 * features/i386/amd64.c: Re-generated.
10346 * features/i386/amd64-linux.c: Re-generated.
10347 * features/i386/amd64-mpx.c: Re-generated.
10348 * features/i386/amd64-mpx-linux.c: Re-generated.
10349 * features/i386/i386-avx-avx512.c: Re-generated.
10350 * features/i386/i386-avx-avx512-linux.c: Re-generated.
10351 * features/i386/i386-avx.c: Re-generated.
10352 * features/i386/i386-avx-linux.c: Re-generated.
10353 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
10354 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
10355 * features/i386/i386-avx-mpx.c: Re-generated.
10356 * features/i386/i386-avx-mpx-linux.c: Re-generated.
10357 * features/i386/i386.c: Re-generated.
10358 * features/i386/i386-linux.c: Re-generated.
10359 * features/i386/i386-mmx.c: Re-generated.
10360 * features/i386/i386-mmx-linux.c: Re-generated.
10361 * features/i386/i386-mpx.c: Re-generated.
10362 * features/i386/i386-mpx-linux.c: Re-generated.
10363 * features/i386/x32-avx-avx512.c: Re-generated.
10364 * features/i386/x32-avx-avx512-linux.c: Re-generated.
10365 * features/i386/x32-avx.c: Re-generated.
10366 * features/i386/x32-avx-linux.c: Re-generated.
10367 * features/i386/x32.c: Re-generated.
10368 * features/i386/x32-linux.c: Re-generated.
10369 * features/microblaze.c: Re-generated.
10370 * features/microblaze-with-stack-protect.c: Re-generated.
10371 * features/mips64-dsp-linux.c: Re-generated.
10372 * features/mips64-linux.c: Re-generated.
10373 * features/mips-dsp-linux.c: Re-generated.
10374 * features/mips-linux.c: Re-generated.
10375 * features/nds32.c: Re-generated.
10376 * features/nios2.c: Re-generated.
10377 * features/nios2-linux.c: Re-generated.
10378 * features/rs6000/powerpc-32.c: Re-generated.
10379 * features/rs6000/powerpc-32l.c: Re-generated.
10380 * features/rs6000/powerpc-403.c: Re-generated.
10381 * features/rs6000/powerpc-403gc.c : Re-generated.
10382 * features/rs6000/powerpc-405.c: Re-generated.
10383 * features/rs6000/powerpc-505.c: Re-generated.
10384 * features/rs6000/powerpc-601.c: Re-generated.
10385 * features/rs6000/powerpc-602.c: Re-generated.
10386 * features/rs6000/powerpc-603.c: Re-generated.
10387 * features/rs6000/powerpc-604.c: Re-generated.
10388 * features/rs6000/powerpc-64.c: Re-generated.
10389 * features/rs6000/powerpc-64l.c: Re-generated.
10390 * features/rs6000/powerpc-7400.c: Re-generated.
10391 * features/rs6000/powerpc-750.c: Re-generated.
10392 * features/rs6000/powerpc-860.c: Re-generated.
10393 * features/rs6000/powerpc-altivec32.c: Re-generated.
10394 * features/rs6000/powerpc-altivec32l.c: Re-generated.
10395 * features/rs6000/powerpc-altivec64.c: Re-generated.
10396 * features/rs6000/powerpc-altivec64l.c: Re-generated.
10397 * features/rs6000/powerpc-cell32l.c: Re-generated.
10398 * features/rs6000/powerpc-cell64l.c: Re-generated.
10399 * features/rs6000/powerpc-e500.c: Re-generated.
10400 * features/rs6000/powerpc-e500l.c: Re-generated.
10401 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
10402 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
10403 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
10404 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
10405 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
10406 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
10407 * features/rs6000/powerpc-vsx32.c: Re-generated.
10408 * features/rs6000/powerpc-vsx32l.c: Re-generated.
10409 * features/rs6000/powerpc-vsx64.c: Re-generated.
10410 * features/rs6000/powerpc-vsx64l.c: Re-generated.
10411 * features/rs6000/rs6000.c: Re-generated.
10412 * features/s390-linux32.c: Re-generated.
10413 * features/s390-linux32v1.c: Re-generated.
10414 * features/s390-linux32v2.c: Re-generated.
10415 * features/s390-linux64.c: Re-generated.
10416 * features/s390-linux64v1.c: Re-generated.
10417 * features/s390-linux64v2.c: Re-generated.
10418 * features/s390-te-linux64.c: Re-generated.
10419 * features/s390-tevx-linux64.c: Re-generated.
10420 * features/s390-vx-linux64.c: Re-generated.
10421 * features/s390x-linux64.c: Re-generated.
10422 * features/s390x-linux64v1.c: Re-generated.
10423 * features/s390x-linux64v2.c: Re-generated.
10424 * features/s390x-te-linux64.c: Re-generated.
10425 * features/s390x-tevx-linux64.c: Re-generated.
10426 * features/s390x-vx-linux64.c: Re-generated.
10427 * features/sparc/sparc32-solaris.c: Re-generated.
10428 * features/sparc/sparc64-solaris.c: Re-generated.
10429 * features/tic6x-c62x.c: Re-generated.
10430 * features/tic6x-c62x-linux.c: Re-generated.
10431 * features/tic6x-c64x.c: Re-generated.
10432 * features/tic6x-c64x-linux.c: Re-generated.
10433 * features/tic6x-c64xp.c: Re-generated.
10434 * features/tic6x-c64xp-linux.c: Re-generated.
10435
35b4818d
YQ
104362017-07-26 Yao Qi <yao.qi@linaro.org>
10437
10438 * i386-linux-tdep.c (i386_linux_read_description): New function.
10439 (i386_linux_core_read_description): Call
10440 i386_linux_read_description.
10441 * i386-linux-tdep.h (i386_linux_read_description): Declare.
10442 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
10443 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
10444 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
10445 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
10446 * x86-linux-nat.c (x86_linux_read_description): Call
10447 i386_linux_read_description.
10448
8e2141c6
YQ
104492017-07-26 Yao Qi <yao.qi@linaro.org>
10450
10451 * NEWS: Mention it.
10452 * features/Makefile (%.c: %.xml): Pass the xml file name to
10453 command "maint print c-tdesc".
10454 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
10455 name from 'arg'.
10456
b468ff4c
YQ
104572017-07-26 Yao Qi <yao.qi@linaro.org>
10458
10459 * target-descriptions.c (target_desc): Add ctor and dtor. Do
10460 in-class initialization.
10461 (tdesc_create_feature): Call new instead of XCNEW.
10462 (free_target_description): Ue delete.
10463
b9c0e1b4
JB
104642017-07-25 John Baldwin <jhb@FreeBSD.org>
10465
10466 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
10467
a04b5337
YQ
104682017-07-25 Yao Qi <yao.qi@linaro.org>
10469
10470 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
10471 constant.
10472 (amd64_x32_init_abi): Likewise.
10473 * amd64-tdep.h (amd64_init_abi): Update declaration.
10474 (amd64_x32_init_abi): Likewise.
10475
02ad7fc2
YQ
104762017-07-25 Yao Qi <yao.qi@linaro.org>
10477
10478 PR tdep/21717
10479 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10480 condition for FPSCR.
10481 (arm_linux_store_inferior_registers): Likewise.
10482
b6f48cb0
TT
104832017-07-22 Tom Tromey <tom@tromey.com>
10484
10485 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10486 <syscalls_counts>: Now a std::vector.
10487 (get_catch_syscall_inferior_data): Use "new".
10488 (catch_syscall_inferior_data_cleanup): Use "delete".
10489 (insert_catch_syscall, remove_catch_syscall)
10490 (clear_syscall_counts): Update.
10491
e12c9b7a
TT
104922017-07-22 Tom Tromey <tom@tromey.com>
10493
10494 * break-catch-syscall.c (syscall_catchpoint)
10495 <syscalls_to_be_caught>: Now a std::vector<int>
10496 (~syscall_catchpoint): Remove.
10497 (insert_catch_syscall, remove_catch_syscall)
10498 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10499 (print_mention_catch_syscall, print_recreate_catch_syscall):
10500 Update.
10501 (create_syscall_event_catchpoint): Change type of "filter"
10502 parameter.
10503 (catch_syscall_split_args): Return a std::vector.
10504 (catch_syscall_command_1, catching_syscall_number_1): Update.
10505
4fa8aeac
TT
105062017-07-22 Tom Tromey <tom@tromey.com>
10507
10508 * break-catch-throw.c (struct exception_catchpoint)
10509 <exception_rx>: Now a std::string.
10510 (~exception_catchpoint): Remove.
10511 (print_one_detail_exception_catchpoint): Update.
10512 (handle_gnu_v3_exceptions): Change type of except_rx.
10513 (extract_exception_regexp): Return a std::string.
10514 (catch_exception_command_1): Update.
10515
f746a154
TT
105162017-07-22 Tom Tromey <tom@tromey.com>
10517
10518 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10519 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10520 std::vector.
10521 <catch_all>: Now a bool.
10522 (~signal_catchpoint): Remove.
10523 (signal_catchpoint_insert_location)
10524 (signal_catchpoint_remove_location)
10525 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10526 (signal_catchpoint_print_mention)
10527 (signal_catchpoint_print_recreate)
10528 (signal_catchpoint_explains_signal): Update.
10529 (create_signal_catchpoint): Change type of "filter" and
10530 "catch_all".
10531 (catch_signal_split_args): Return a std::vector. Change type of
10532 "catch_all".
10533 (catch_signal_command): Update.
10534
47e77640
PA
105352017-07-20 Pedro Alves <palves@redhat.com>
10536
10537 * ada-lang.c (ada_language_defn): Make extern.
10538 (_initialize_ada_language): Remove add_language call.
10539 * c-lang.c (c_language_defn, cplus_language_defn)
10540 (asm_language_defn, minimal_language_defn): Make extern.
10541 (_initialize_c_language): Delete.
10542 * completer.c (compare_cstrings): Delete, moved to utils.h.
10543 * d-lang.c (d_language_defn): Make extern.
10544 (_initialize_d_language): Remove add_language calls.
10545 * defs.h (enum language): Add comment.
10546 * f-lang.c (f_language_defn): Make extern.
10547 (_initialize_f_language): Remove add_language call.
10548 * go-lang.c (go_language_defn): Make extern.
10549 (_initialize_go_language): Remove add_language call.
10550 * language.c: Include <algorithm>.
10551 (languages): Redefine as const array.
10552 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10553 (set_language_command): Handle "local". Use for-range loop.
10554 (set_language): Remove loop.
10555 (language_enum): Rewrite.
10556 (language_def, language_str): Remove loops.
10557 (add_language): Delete.
10558 (add_set_language_command): New, based on add_languages.
10559 (skip_language_trampoline): Adjust.
10560 (local_language_defn): Delete.
10561 (language_gdbarch_post_init): Adjust.
10562 (_initialize_language): Remove add_language calls. Call
10563 add_set_language_command.
10564 * language.h (add_language): Delete.
10565 (auto_language_defn)
10566 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10567 (asm_language_defn, c_language_defn, cplus_language_defn)
10568 (d_language_defn, f_language_defn, go_language_defn)
10569 (m2_language_defn, objc_language_defn, opencl_language_defn)
10570 (pascal_language_defn, rust_language_defn): Declare.
10571 * m2-lang.c (m2_language_defn): Make extern.
10572 (_initialize_m2_language): Remove add_language call.
10573 * objc-lang.c (objc_language_defn): Make extern.
10574 (_initialize_objc_language): Remove add_language call.
10575 * opencl-lang.c (opencl_language_defn): Make extern.
10576 (_initialize_opencl_language): Remove add_language call.
10577 * p-lang.c (pascal_language_defn): Make extern.
10578 (_initialize_pascal_language): Delete.
10579 * rust-lang.c (rust_language_defn): Make extern.
10580 (_initialize_rust_language): Delete.
10581 * utils.h (compare_cstrings): New static inline function.
10582
edb0c9cb
PA
105832017-07-20 Pedro Alves <palves@redhat.com>
10584
10585 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10586 (get_var_value): Constify parameters.
10587 (get_int_var_value): Change prototype.
10588 (to_fixed_range_type): Adjust.
10589 * ada-lang.h (get_int_var_value): Change prototype.
10590
a778f165
PA
105912017-07-20 Pedro Alves <palves@redhat.com>
10592
10593 * dwarf2read.c (dw2_lookup_symbol): Use
10594 SYMBOL_MATCHES_SEARCH_NAME.
10595 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10596
42edd901
PA
105972017-07-20 Pedro Alves <palves@redhat.com>
10598
10599 * block.c (block_iter_name_step, block_iter_name_first)
10600 (block_iter_name_next): Delete.
10601 (block_lookup_symbol_primary): Adjust to use
10602 dict_iter_match_first/dict_iter_match_next.
10603 * block.h (block_iter_name_first, block_iter_name_next): Delete
10604 declarations.
10605 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10606 dict_iter_match_first/dict_iter_match_next.
10607
cf325299
PA
106082017-07-20 Pedro Alves <palves@redhat.com>
10609
10610 * cp-support.c (cp_find_first_component_aux): Add missing case for
10611 end of string.
10612
c5ed0576
DB
106132017-07-18 David Blaikie <dblaikie@gmail.com>
10614
10615 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10616 of dwo_cu's dwo_file.
10617
27841e76
YQ
106182017-07-18 Yao Qi <yao.qi@linaro.org>
10619
10620 * remote.c (store_registers_using_G): Remove one line comment.
10621
cfb7e58b
YQ
106222017-07-18 Yao Qi <yao.qi@linaro.org>
10623
10624 * regcache.c (regcache_cpy): Simplify it.
10625 (regcache::cpy_no_passthrough): Remove it.
10626 * regcache.h (cpy_no_passthrough): Remove it.
10627 (regcache_dup, regcache_cpy): Update comments.
10628
386535dd
PA
106292017-07-18 Pedro Alves <palves@redhat.com>
10630
10631 * remote-sim.c (sim_command_completer): Adjust to work with a
10632 completion_tracker instead of a VEC.
10633
c45ec17c
PA
106342017-07-17 Pedro Alves <palves@redhat.com>
10635
10636 * completer.c (complete_source_filenames): New function.
10637 (complete_address_and_linespec_locations): New function.
10638 (location_completer): Use complete_address_and_linespec_locations.
10639 (completion_tracker::build_completion_result): Honor the tracker's
10640 request to suppress append.
10641 * completer.h (completion_tracker::suppress_append_ws)
10642 (completion_tracker::set_suppress_append_ws): New methods.
10643 (completion_tracker::m_suppress_append_ws): New field.
10644 (complete_source_filenames): New declaration.
10645 * linespec.c (linespec_complete_what): New.
10646 (struct ls_parser) <complete_what, completion_word,
10647 completion_quote_char, completion_quote_end, completion_tracker>:
10648 New fields.
10649 (string_find_incomplete_keyword_at_end): New.
10650 (linespec_lexer_lex_string): Record quote char. If in completion
10651 mode, don't throw.
10652 (linespec_lexer_consume_token): Advance the completion word point.
10653 (linespec_lexer_peek_token): Save/restore completion info.
10654 (save_stream_and_consume_token): New.
10655 (set_completion_after_number): New.
10656 (linespec_parse_basic): Set what to complete next depending on
10657 token. Handle function and label completions specially.
10658 (parse_linespec): Disable objc shortcut in completion mode. Set
10659 what to complete next depending on token type. Skip keyword if in
10660 completion mode.
10661 (complete_linespec_component, linespec_complete): New.
10662 * linespec.h (linespec_complete): Declare.
10663
be966d42
PA
106642017-07-17 Pedro Alves <palves@redhat.com>
10665
10666 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10667 Handle 'operator<' / 'operator<<'.
10668
a2459270
PA
106692017-07-17 Pedro Alves <palves@redhat.com>
10670
10671 * completer.c (collect_explicit_location_matches): Handle
10672 MATCH_LABEL.
10673 (convert_explicit_location_to_linespec): New, factored out from
10674 ...
10675 (convert_explicit_location_to_sals): ... this.
10676 (complete_label): New.
10677 (linespec_complete_label, find_label_symbols_in_block): New.
10678 (find_label_symbols): Add completion_mode parameter and adjust to
10679 call find_label_symbols_in_block.
10680 * linespec.h (linespec_complete_label): Declare.
10681
c6756f62
PA
106822017-07-17 Pedro Alves <palves@redhat.com>
10683
10684 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10685 complete_symbol_mode parameter.
10686 * cli/cli-cmds.c (complete_command): Get the completion result out
10687 of the handle_brkchars tracker if used a custom word point.
10688 * completer.c: Include "linespec.h".
10689 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10690 (advance_to_expression_complete_word_point): New.
10691 (completion_tracker::completes_to_completion_word): New.
10692 (complete_files_symbols): Pass down
10693 complete_symbol_mode::EXPRESSION.
10694 (explicit_options, probe_options): New.
10695 (collect_explicit_location_matches): Complete on the
10696 explictit_loc->foo instead of word. Use
10697 linespec_complete_function. Handle MATCH_LINE. Handle offering
10698 keyword and options completions.
10699 (backup_text_ptr): Delete.
10700 (skip_keyword): New.
10701 (complete_explicit_location): Remove 'word' parameter. Add
10702 language, quoted_arg_start and quoted_arg_end parameters.
10703 Rewrite, parsing left to right.
10704 (location_completer): Rewrite.
10705 (location_completer_handle_brkchars): New function.
10706 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10707 (enum complete_line_internal_reason): Adjust comments.
10708 (completion_tracker::discard_completions): New.
10709 (completer_handle_brkchars_func_for_completer): Handle
10710 location_completer.
10711 (gdb_custom_word_point_brkchars)
10712 (gdb_org_rl_basic_quote_characters): New.
10713 (gdb_completion_word_break_characters_throw)
10714 (completion_find_completion_word): Handle trackers that use a
10715 custom word point.
10716 (completion_tracker::advance_custom_word_point_by): New.
10717 (completion_tracker::build_completion_result): Don't rely on
10718 readline appending the quote char.
10719 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10720 use a custom word point.
10721 (gdb_rl_attempted_completion_function): Restore
10722 rl_basic_quote_characters.
10723 * completer.h (class completion_tracker): Extend intro comment.
10724 (completion_tracker::set_quote_char)
10725 (completion_tracker::quote_char)
10726 (completion_tracker::set_use_custom_word_point)
10727 (completion_tracker::use_custom_word_point)
10728 (completion_tracker::custom_word_point)
10729 (completion_tracker::set_custom_word_point)
10730 (completion_tracker::advance_custom_word_point_by)
10731 (completion_tracker::completes_to_completion_word)
10732 (completion_tracker::discard_completions): New methods.
10733 (completion_tracker::m_quote_char)
10734 (completion_tracker::m_use_custom_word_point)
10735 (completion_tracker::m_custom_word_point): New fields.
10736 (advance_to_expression_complete_word_point): Declare.
10737 * f-lang.c (f_collect_symbol_completion_matches): Add
10738 complete_symbol_mode parameter.
10739 * language.h (struct language_defn)
10740 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10741 parameter.
10742 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10743 (linespec_complete_function): New function.
10744 (linespec_lexer_lex_keyword): Adjust.
10745 * linespec.h (linespec_keywords, linespec_complete_function): New
10746 declarations.
10747 * location.c (find_end_quote): New function.
10748 (explicit_location_lex_one): Add explicit_completion_info
10749 parameter. Save quoting info. Don't throw if being called for
10750 completion. Don't handle Ada operators here.
10751 (is_cp_operator, skip_op_false_positives, first_of)
10752 (explicit_location_lex_one_function): New function.
10753 (string_to_explicit_location): Replace 'dont_throw' parameter with
10754 an explicit_completion_info pointer parameter. Handle it. Don't
10755 use explicit_location_lex_one to lex function names. Use
10756 explicit_location_lex_one_function instead.
10757 * location.h (struct explicit_completion_info): New.
10758 (string_to_explicit_location): Replace 'dont_throw' parameter with
10759 an explicit_completion_info pointer parameter.
10760 * symtab.c (default_collect_symbol_completion_matches_break_on):
10761 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10762 (default_collect_symbol_completion_matches)
10763 (collect_symbol_completion_matches): Add complete_symbol_mode
10764 parameter.
10765 (collect_symbol_completion_matches_type): Pass down
10766 complete_symbol_mode::EXPRESSION.
10767 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10768 parameter. Handle LINESPEC mode.
10769 * symtab.h (complete_symbol_mode): New.
10770 (default_collect_symbol_completion_matches_break_on)
10771 (default_collect_symbol_completion_matches)
10772 (collect_symbol_completion_matches)
10773 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10774 parameter.
10775
1d550c82
PA
107762017-07-17 Pedro Alves <palves@redhat.com>
10777
10778 * utils.c (enum class strncmp_iw_mode): New.
10779 (strcmp_iw): Rename to ...
10780 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10781 parameters. Handle them.
10782 (strncmp_iw): New.
10783 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10784 * utils.h (strncmp_iw): Declare.
10785 (strcmp_iw): Move describing comments here.
10786
8090b426
PA
107872017-07-17 Pedro Alves <palves@redhat.com>
10788
10789 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10790 CP_OPERATOR_STR.
10791 * c-typeprint.c (is_type_conversion_operator): Use
10792 CP_OPERATOR_STR.
10793 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10794 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10795 CP_OPERATOR_LEN.
10796 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10797 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10798 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10799 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10800 CP_OPERATOR_STR.
10801 * location.c: Include "cp-support.h".
10802 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10803 CP_OPERATOR_STR.
10804 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10805 CP_OPERATOR_LEN.
10806
6a2c1b87
PA
108072017-07-17 Pedro Alves <palves@redhat.com>
10808
10809 * cli/cli-cmds.c (complete_command): Use a completion tracker
10810 along with completion_find_completion_word for handle_brkchars
10811 phase.
10812 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10813 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10814 (struct gdb_rl_completion_word_info): New.
10815 (gdb_rl_find_completion_word): New.
10816 (completion_find_completion_word): New.
10817 * completer.h (completion_find_completion_word): Declare.
10818
eb3ff9a5
PA
108192017-07-17 Pedro Alves <palves@redhat.com>
10820
10821 * ada-lang.c (symbol_completion_match): Adjust comments.
10822 (symbol_completion_add): Replace vector parameter with
10823 completion_tracker parameter. Use it.
10824 (ada_make_symbol_completion_list): Rename to...
10825 (ada_collect_symbol_completion_matches): ... this. Add
10826 completion_tracker parameter and use it.
10827 (ada_language_defn): Adjust.
10828 * break-catch-syscall.c (catch_syscall_completer): Adjust
10829 prototype and work with completion_tracker instead of VEC.
10830 * breakpoint.c (condition_completer): Adjust prototype and work
10831 with completion_tracker instead of VEC.
10832 * c-lang.c (c_language_defn, cplus_language_defn)
10833 (asm_language_defn, minimal_language_defn): Adjust to renames.
10834 * cli/cli-cmds.c (complete_command): Rework using
10835 completion_tracker. Catch exceptions when completing.
10836 * cli/cli-decode.c (integer_unlimited_completer)
10837 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
10838 with completion_tracker instead of VEC.
10839 * command.h (struct completion_tracker): Forward declare.
10840 (completer_ftype, completer_handle_brkchars_ftype): Change
10841 types.
10842 (complete_on_cmdlist, complete_on_enum): Adjust.
10843 * completer.c: Include <algorithm>.
10844 (struct gdb_completer_state): New.
10845 (current_completion): New global.
10846 (readline_line_completion_function): Delete.
10847 (noop_completer, filename_completer)
10848 (filename_completer_handle_brkchars, complete_files_symbols)
10849 (linespec_location_completer): Adjust to work with a
10850 completion_tracker instead of a VEC.
10851 (string_or_empty): New.
10852 (collect_explicit_location_matches): Adjust to work with a
10853 completion_tracker instead of a VEC.
10854 (explicit_location_completer): Rename to ...
10855 (complete_explicit_location): ... this and adjust to work with a
10856 completion_tracker instead of a VEC.
10857 (location_completer): Adjust to work with a completion_tracker
10858 instead of a VEC.
10859 (add_struct_fields): Adjust to work with a completion_list instead
10860 of VEC.
10861 (expression_completer): Rename to ...
10862 (complete_expression): ... this and adjust to work with a
10863 completion_tracker instead of a VEC. Use complete_files_symbols.
10864 (expression_completer): Reimplement on top of complete_expression.
10865 (symbol_completer): Adjust to work with a completion_tracker
10866 instead of a VEC.
10867 (enum complete_line_internal_reason): Add describing comments.
10868 (complete_line_internal_normal_command): Adjust to work with a
10869 completion_tracker instead of a VEC.
10870 (complete_line_internal): Rename to ...
10871 (complete_line_internal_1): ... this and adjust to work with a
10872 completion_tracker instead of a VEC. Assert TEXT is NULL in the
10873 handle_brkchars phase.
10874 (new_completion_tracker): Delete.
10875 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
10876 complete_line_internal_1.
10877 (free_completion_tracker): Delete.
10878 (INITIAL_COMPLETION_HTAB_SIZE): New.
10879 (completion_tracker::completion_tracker)
10880 (completion_tracker::~completion_tracker): New.
10881 (maybe_add_completion): Delete.
10882 (completion_tracker::maybe_add_completion)
10883 (completion_tracker::add_completion)
10884 (completion_tracker::add_completions): New.
10885 (throw_max_completions_reached_error): Delete.
10886 (complete_line): Adjust to work with a completion_tracker instead
10887 of a VEC. Don't create a completion_tracker_t or check for max
10888 completions here.
10889 (command_completer, command_completer_handle_brkchars)
10890 (signal_completer, reg_or_group_completer_1)
10891 (reg_or_group_completer, default_completer_handle_brkchars):
10892 Adjust to work with a completion_tracker.
10893 (gdb_completion_word_break_characters_throw): New.
10894 (gdb_completion_word_break_characters): Reimplement.
10895 (line_completion_function): Delete.
10896 (completion_tracker::recompute_lowest_common_denominator)
10897 (expand_preserving_ws)
10898 (completion_tracker::build_completion_result)
10899 (completion_result::completion_result)
10900 (completion_result::completion_result)
10901 (completion_result::~completion_result)
10902 (completion_result::completion_result)
10903 (completion_result::release_match_list, compare_cstrings)
10904 (completion_result::sort_match_list)
10905 (completion_result::reset_match_list)
10906 (gdb_rl_attempted_completion_function_throw)
10907 (gdb_rl_attempted_completion_function): New.
10908 * completer.h (completion_list, struct completion_result)
10909 (class completion_tracker): New.
10910 (complete_line): Add completion_tracker parameter.
10911 (readline_line_completion_function): Delete.
10912 (gdb_rl_attempted_completion_function): New.
10913 (noop_completer, filename_completer, expression_completer)
10914 (location_completer, symbol_completer, command_completer)
10915 (signal_completer, reg_or_group_completer): Update prototypes.
10916 (completion_tracker_t, new_completion_tracker)
10917 (make_cleanup_free_completion_tracker): Delete.
10918 (enum maybe_add_completion_enum): Delete.
10919 (maybe_add_completion): Delete.
10920 (throw_max_completions_reached_error): Delete.
10921 * corefile.c (complete_set_gnutarget): Adjust to work with a
10922 completion_tracker instead of a VEC.
10923 * cp-abi.c (cp_abi_completer): Adjust to work with a
10924 completion_tracker instead of a VEC.
10925 * d-lang.c (d_language_defn): Adjust.
10926 * disasm.c (disassembler_options_completer): Adjust to work with a
10927 completion_tracker instead of a VEC.
10928 * f-lang.c (f_make_symbol_completion_list): Rename to ...
10929 (f_collect_symbol_completion_matches): ... this. Adjust to work
10930 with a completion_tracker instead of a VEC.
10931 (f_language_defn): Adjust.
10932 * go-lang.c (go_language_defn): Adjust.
10933 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
10934 Adjust to work with a completion_tracker instead of a VEC.
10935 * infrun.c (handle_completer): Likewise.
10936 * interps.c (interpreter_completer): Likewise.
10937 * interps.h (interpreter_completer): Likewise.
10938 * language.c (unknown_language_defn, auto_language_defn)
10939 (local_language_defn): Adjust.
10940 * language.h (language_defn::la_make_symbol_completion_list):
10941 Rename to ...
10942 (language_defn::la_collect_symbol_completion_matches): ... this
10943 and adjust to work with a completion_tracker instead of a VEC.
10944 * m2-lang.c (m2_language_defn): Adjust.
10945 * objc-lang.c (objc_language_defn): Adjust.
10946 * opencl-lang.c (opencl_language_defn): Adjust.
10947 * p-lang.c (pascal_language_defn): Adjust.
10948 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
10949 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
10950 with a completion_tracker.
10951 * rust-lang.c (rust_language_defn): Adjust.
10952 * symtab.c (free_completion_list, do_free_completion_list)
10953 (return_val, completion_tracker): Delete.
10954 (completion_list_add_name, completion_list_add_symbol)
10955 (completion_list_add_msymbol, completion_list_objc_symbol)
10956 (completion_list_add_fields, add_symtab_completions): Add
10957 completion_tracker parameter and use it.
10958 (default_make_symbol_completion_list_break_on_1): Rename to...
10959 (default_collect_symbol_completion_matches_break_on): ... this.
10960 Add completion_tracker parameter and use it instead of allocating
10961 a completion tracker here.
10962 (default_make_symbol_completion_list_break_on): Delete old
10963 implementation.
10964 (default_make_symbol_completion_list): Delete.
10965 (default_collect_symbol_completion_matches): New.
10966 (make_symbol_completion_list): Delete.
10967 (collect_symbol_completion_matches): New.
10968 (make_symbol_completion_type): Rename to ...
10969 (collect_symbol_completion_matches_type): ... this. Add
10970 completion_tracker parameter and use it instead of VEC.
10971 (make_file_symbol_completion_list_1): Rename to...
10972 (collect_file_symbol_completion_matches): ... this. Add
10973 completion_tracker parameter and use it instead of VEC.
10974 (make_file_symbol_completion_list): Delete.
10975 (add_filename_to_list): Use completion_list instead of a VEC.
10976 (add_partial_filename_data::list): Now a completion_list.
10977 (make_source_files_completion_list): Work with a completion_list
10978 instead of a VEC.
10979 * symtab.h: Include "completer.h".
10980 (default_make_symbol_completion_list_break_on)
10981 (default_make_symbol_completion_list, make_symbol_completion_list)
10982 (make_symbol_completion_type, make_file_symbol_completion_list)
10983 (make_source_files_completion_list): Delete.
10984 (default_collect_symbol_completion_matches_break_on)
10985 (default_collect_symbol_completion_matches)
10986 (collect_symbol_completion_matches)
10987 (collect_symbol_completion_matches_type)
10988 (collect_file_symbol_completion_matches)
10989 (make_source_files_completion_list): New.
10990 * top.c (init_main): Don't install a rl_completion_entry_function
10991 hook. Install a rl_attempted_completion_function hook instead.
10992 * tui/tui-layout.c (layout_completer): Adjust to work with a
10993 completion_tracker.
10994 * tui/tui-regs.c (tui_reggroup_completer):
10995 * tui/tui-win.c (window_name_completer, focus_completer)
10996 (winheight_completer): Adjust to work with a completion_tracker.
10997 * value.c: Include "completer.h".
10998 (complete_internalvar): Adjust to work with a completion_tracker.
10999 * value.h (complete_internalvar): Likewise.
11000
6e1dbf8c
PA
110012017-07-17 Pedro Alves <palves@redhat.com>
11002
11003 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
11004 renames.
11005 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
11006 comments to completer_ftype's declaration.
11007 <completer_handle_brkchars>: Change type to
11008 completer_handle_brkchars_ftype.
11009 * command.h (completer_ftype): Add describing comment and give
11010 names to parameters.
11011 (completer_ftype_void): Rename to ...
11012 (completer_handle_brkchars_ftype) ... this. Add describing comment.
11013 (set_cmd_completer_handle_brkchars): Adjust.
11014 * completer.c (filename_completer_handle_brkchars): New function.
11015 (complete_line_internal_normal_command): New function, factored
11016 out from ...
11017 (complete_line_internal): ... here.
11018 (command_completer_handle_brkchars)
11019 (default_completer_handle_brkchars)
11020 (completer_handle_brkchars_func_for_completer): New functions.
11021 * completer.h (set_gdb_completion_word_break_characters): Delete
11022 declaration.
11023 (completer_handle_brkchars_func_for_completer): New declaration.
11024 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
11025 completer_handle_brkchars_func_for_completer.
11026
78b13106
PA
110272017-07-17 Pedro Alves <palves@redhat.com>
11028
11029 * completer.c (symbol_completer): New function, based on
11030 make_symbol_completion_list_fn.
11031 * completer.h (symbol_completer): New declaration.
11032 * guile/scm-cmd.c (cmdscm_completers): Adjust.
11033 * python/py-cmd.c (completers): Adjust.
11034 * symtab.c (make_symbol_completion_list_fn): Delete.
11035 * symtab.h (make_symbol_completion_list_fn): Delete.
11036 * cli/cli-decode.c (add_cmd): Adjust.
11037
bbf2f4df
PA
110382017-07-17 Pedro Alves <palves@redhat.com>
11039
11040 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
11041 * dwarf2read.c: Include "filename-seen-cache.h".
11042 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
11043 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
11044 * filename-seen-cache.c: New file.
11045 * filename-seen-cache.h: New file.
11046 * symtab.c: Include "filename-seen-cache.h".
11047 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
11048 (create_filename_seen_cache, clear_filename_seen_cache)
11049 (delete_filename_seen_cache, filename_seen): Delete, parts moved
11050 to filename-seen-cache.h/filename-seen-cache.c.
11051 (output_source_filename, sources_info)
11052 (maybe_add_partial_symtab_filename)
11053 (make_source_files_completion_list): Adjust to use
11054 filename_seen_cache.
11055
330cdd98
PA
110562017-07-17 Pedro Alves <palves@redhat.com>
11057
11058 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
11059 fields.
11060 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
11061 dwarf2_debug_sections*)): New.
11062 (dwarf2_per_objfile::dwarf2_per_objfile(const
11063 dwarf2_per_objfile&)): Declare as deleted.
11064 (dwarf2_per_objfile::operator=): Declare as deleted.
11065 (dwarf2_per_objfile::dwarf2_per_objfile)
11066 (dwarf2_per_objfile::~dwarf2_per_objfile)
11067 (dwarf2_per_objfile::free_cached_comp_units): New.
11068 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
11069 ctor. Call dwarf2_per_objfile's ctor manually.
11070 (dwarf2_locate_sections): Deleted/refactored as ...
11071 (dwarf2_per_objfile::locate_sections): ... this new method.
11072 (free_cached_comp_units): Defer to
11073 dwarf2_per_objfile::free_cached_comp_units.
11074 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
11075
8880f2a9
TT
110762017-07-14 Tom Tromey <tom@tromey.com>
11077
11078 PR rust/21764:
11079 * rust-exp.y (convert_ast_to_expression): Add "want_type"
11080 parameter.
11081 <UNOP_SIZEOF>: Split into separate case.
11082 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
11083
65547233
TT
110842017-07-14 Tom Tromey <tom@tromey.com>
11085
11086 PR rust/21763:
11087 * symtab.c (symbol_matches_domain): Add language_rust to special
11088 case.
11089 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
11090 treat LOC_TYPEDEF symbols as variables.
11091
8f14146e
PA
110922017-07-14 Pedro Alves <palves@redhat.com>
11093
11094 * symtab.c (make_file_symbol_completion_list_1): Iterate over
11095 symtabs matching all symtabs with SRCFILE as file name instead of
11096 only considering the first hit, with lookup_symtab.
11097
2347965c
SM
110982017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11099
11100 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
11101 operator_name parameters.
11102 (gen_expr): Update function call.
11103
40f4af28
SM
111042017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11105
11106 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
11107 parameter.
11108 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
11109 Likewise.
11110 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
11111 parameter, use agent_expr::gdbarch instead, update function
11112 calls.
11113 (locexpr_tracepoint_var_ref): Likewise.
11114 (loclist_tracepoint_var_ref): Likewise.
11115 * ax-gdb.c (gen_trace_static_fields): Likewise.
11116 (gen_traced_pop): Likewise.
11117 (gen_frame_args_address): Likewise.
11118 (gen_frame_locals_address): Likewise.
11119 (gen_var_ref): Likewise.
11120 (gen_struct_ref_recursive): Likewise.
11121 (gen_static_field): Likewise.
11122 (gen_maybe_namespace_elt): Likewise.
11123 (gen_expr): Likewise.
11124 (gen_trace_for_var): Likewise.
11125 (gen_trace_for_expr): Likewise.
11126 (gen_trace_for_return_address): Likewise.
11127
053f8057
SM
111282017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11129
11130 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
11131 parameter.
11132 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
11133
6661ad48
SM
111342017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11135
11136 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
11137 from ax, update calls.
11138 (gen_usual_arithmetic): Likewise.
11139 (gen_integral_promotions): Likewise.
11140 (gen_bitfield_ref): Likewise.
11141 (gen_primitive_field): Likewise.
11142 (gen_struct_ref_recursive): Likewise.
11143 (gen_struct_ref): Likewise.
11144 (gen_maybe_namespace_elt): Likewise.
11145 (gen_struct_elt_for_reference): Likewise.
11146 (gen_namespace_elt): Likewise.
11147 (gen_aggregate_elt_ref): Likewise.
11148 (gen_expr): Get gdbarch from ax, update calls.
11149 (gen_expr_binop_rest): Likewise.
11150
c55a47e7
PA
111512017-07-13 Pedro Alves <palves@redhat.com>
11152
11153 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
11154 as default tdesc.
11155 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
11156 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
11157 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
11158 tdesc_amd64_linux as default tdesc. Get final tdesc from the
11159 tdep.
11160 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
11161 Get final tdesc from the tdep.
11162 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
11163 default tdesc.
11164 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
11165 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
11166 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
11167 Use it as default tdesc.
11168 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
11169 down to amd_init_abi. No longer handle fallback tdesc here.
11170 * amd64-tdep.h (tdesc_x32): Declare.
11171 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
11172 parameter.
11173 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
11174 as default tdesc.
11175
55efceab
AA
111762017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11177
11178 * s390-linux-tdep.c (s390_process_record): Add support for
11179 instructions new in arch12.
11180
0aa37b65
JB
111812017-07-11 John Baldwin <jhb@FreeBSD.org>
11182
11183 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
11184 PT_GETFSBASE and PT_GETGSBASE.
11185 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
11186 PT_SETGSBASE.
11187
48aeef91
JB
111882017-07-11 John Baldwin <jhb@FreeBSD.org>
11189
11190 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
11191 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
11192 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
11193 those rules.
11194 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
11195 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
11196 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
11197 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
11198 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
11199 * features/i386/amd64.xml: Add 64bit-segments.xml.
11200 * features/i386/amd64-avx-avx512.c: Regenerated.
11201 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
11202 * features/i386/amd64-avx-mpx.c: Regenerated.
11203 * features/i386/amd64-avx.c: Regenerated.
11204 * features/i386/amd64-mpx.c: Regenerated.
11205 * features/i386/amd64.c: Regenerated.
11206 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
11207 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11208 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
11209 * regformats/i386/amd64-avx.dat: Regenerated.
11210 * regformats/i386/amd64-mpx.dat: Regenerated.
11211 * regformats/i386/amd64.dat: Regenerated.
11212
77c501bc
YQ
112132017-07-10 Yao Qi <yao.qi@linaro.org>
11214
11215 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
11216 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
11217
6dc8d757
AK
112182017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
11219
11220 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
11221 unsetenv.
11222 * gnulib/aclocal.m4: Regenerate.
11223 * gnulib/config.in: Regenerate.
11224 * gnulib/configure: Regenerate.
11225 * gnulib/import/Makefile.am: Regenerate.
11226 * gnulib/import/Makefile.in: Regenerate.
11227 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
11228 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
11229 * gnulib/import/m4/environ.m4: New file.
11230 * gnulib/import/m4/setenv.m4: New file.
11231 * gnulib/import/setenv.c: New file.
11232 * gnulib/import/unsetenv.c: New file.
11233
266934d1
SM
112342017-07-09 Simon Marchi <simon.marchi@ericsson.com>
11235
11236 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
11237 address when op is DW_OP_addr.
11238
03278692
TT
112392017-07-09 Tom Tromey <tom@tromey.com>
11240
11241 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
11242 check and apply to outer type.
11243
4b654465
JB
112442017-07-07 John Baldwin <jhb@FreeBSD.org>
11245
11246 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
11247 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
11248 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
11249 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
11250
2af9fc44
JB
112512017-07-07 John Baldwin <jhb@FreeBSD.org>
11252
11253 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
11254
382b69bb
JB
112552017-07-07 John Baldwin <jhb@FreeBSD.org>
11256
11257 * corelow.c (get_core_siginfo): Remove.
11258 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
11259 instead of get_core_siginfo.
11260 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
11261 * gdbarch.h: Re-generate.
11262 * gdbarch.c: Re-generate.
11263 * linux-tdep.c (linux_core_xfer_siginfo): New.
11264 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
11265
6e5eab33
JB
112662017-07-07 John Baldwin <jhb@FreeBSD.org>
11267
11268 * corelow.c (thread_section_name): Move to ...
11269 * gdbcore.h (thread_section_name): ... here.
11270
929edea9
JB
112712017-07-07 John Baldwin <jhb@FreeBSD.org>
11272
11273 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
11274 (struct siginfo32): New.
11275 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
11276 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
11277 via ptrace(PT_LWPINFO).
11278
762c974a
JB
112792017-07-07 John Baldwin <jhb@FreeBSD.org>
11280
11281 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
11282 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
11283 (fbsd_get_siginfo_type): New.
11284 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
11285 (_initialize_fbsd_tdep): New.
11286
33c5cd75
DB
112872017-07-06 David Blaikie <dblaikie@gmail.com>
11288
11289 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
11290 a singular dwo_unit*) to support multiple CUs in the same way that
11291 multiple TUs are supported.
11292 (create_cus_hash_table): Replace create_dwo_cu with a function for
11293 parsing multiple CUs from a DWO file.
11294 (open_and_init_dwo_file): Use create_cus_hash_table rather than
11295 create_dwo_cu.
11296 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
11297 htab_find, rather than comparing the signature to a singleton CU in
11298 the dwo_file.
11299
8455d262
PA
113002017-07-06 Pedro Alves <palves@redhat.com>
11301
11302 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
11303
4da3eb35
PA
113042017-07-04 Pedro Alves <palves@redhat.com>
11305
11306 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
11307 * gdbtypes.h (TYPE_STATIC): Delete.
11308 (struct fn_field) <is_public, is_abstract, is_static, is_final,
11309 is_synchronized, is_native>: Delete.
11310 <dummy>: Bump.
11311 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
11312 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
11313 (TYPE_FN_FIELD_ABSTRACT): Delete.
11314
5bfd255c
SM
113152017-07-03 Simon Marchi <simon.marchi@ericsson.com>
11316
11317 * buffer.h (buffer_finish): Fix spelling mistakes.
11318
25c54127
EZ
113192017-07-01 Eli Zaretskii <eliz@gnu.org>
11320
11321 * .dir-locals.el: Automatically switch to C-style comments in
11322 versions of Emacs that support the feature.
11323
dc4bde35
SDJ
113242017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11325 Pedro Alves <palves@redhat.com>
11326
11327 PR cli/21688
11328 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
11329 (process_next_line): New variable 'inline_cmd'.
11330 Adjust 'if' clauses for "python", "compile" and "guile" to use
11331 'command_name_equals' and check for '!inline_cmd'.
11332
51ed89aa
SDJ
113332017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11334
11335 PR cli/21688
11336 * cli/cli-script.c (command_name_equals_not_inline): New function.
11337 (process_next_line): Adjust 'if' clauses for "python", "compile"
11338 and "guile" to use command_name_equals_not_inline.
11339
eb17d413
PA
113402017-06-29 Pedro Alves <palves@redhat.com>
11341
11342 * completer.c (expression_completer): Call
11343 linespec_location_completer instead of location_completer.
11344
195bcdd5
PA
113452017-06-29 Pedro Alves <palves@redhat.com>
11346
11347 * completer.c (expression_completer): Remove code that recomputes
11348 'text' from 'word'.
11349
adc764e7
YQ
113502017-06-29 Yao Qi <yao.qi@linaro.org>
11351
11352 * regformats/regdat.sh: Generate code with
11353 "ifndef IN_PROCESS_AGENT".
11354
6e75794e
PA
113552017-06-28 Pedro Alves <palves@redhat.com>
11356
11357 * command.h: Include "common/scoped_restore.h".
11358
bc491f2e
YQ
113592017-06-28 Yao Qi <yao.qi@linaro.org>
11360
11361 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
11362 instead of obstack_grow.
11363
41664b45
DG
113642017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
11365
11366 PR gdb/21337
11367 * symfile.c (reread_symbols): Call objfiles_changed just before
11368 read_symbols.
11369
6da67eb1
PA
113702017-06-27 Pedro Alves <palves@redhat.com>
11371
11372 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
11373 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
11374 (completion_list_add_symbol, completion_list_add_msymbol):
11375 ... these new functions.
11376 (add_symtab_completions)
11377 (default_make_symbol_completion_list_break_on_1): Adjust.
11378
23732b1e
PA
113792017-06-27 Pedro Alves <palves@redhat.com>
11380
11381 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
11382 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
11383 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
11384 dtor.
11385 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
11386 'storage_obstack' field an auto_obstack. In-class initialize all
11387 non-bitfield fields. Make minsyms_read bool.
11388 * symfile.c (read_symbols): Adjust.
11389
a4d1e79a
AH
113902017-06-27 Alan Hayward <alan.hayward@arm.com>
11391
11392 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
11393 (gdbsim_store_register): Likewise.
11394
8268c778
PA
113952017-06-27 Pedro Alves <palves@redhat.com>
11396
11397 * c-exp.y (name_obstack): Now an auto_obstack.
11398 (yylex): Use auto_obstack::clear.
11399 (c_parse): Use auto_obstack::clear instead of reinitializing and
11400 freeing the obstack.
11401 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
11402 * d-exp.y (name_obstack): Now an auto_obstack.
11403 (yylex): Use auto_obstack::clear.
11404 (d_parse): Use auto_obstack::clear instead of reinitializing and
11405 freeing the obstack.
11406 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
11407 auto_obstack.
11408 * dwarf2read.c (create_addrmap_from_index)
11409 (dwarf2_build_psymtabs_hard)
11410 (update_enumeration_type_from_children): Likewise.
11411 * gdb_obstack.h (auto_obstack): New type.
11412 * go-exp.y (name_obstack): Now an auto_obstack.
11413 (build_packaged_name): Use auto_obstack::clear.
11414 (go_parse): Use auto_obstack::clear instead of reinitializing and
11415 freeing the obstack.
11416 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
11417 auto_obstack.
11418 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
11419 * rust-exp.y (work_obstack): Now an auto_obstack.
11420 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
11421 reinitializing and freeing the obstack.
11422 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
11423 (host_char_to_target): Use auto_obstack.
11424 * utils.h (make_cleanup_obstack_free): Delete declaration.
11425 * valprint.c (generic_emit_char, generic_printstr): Use
11426 auto_obstack.
11427
db665f42
SM
114282017-06-27 Simon Marchi <simon.marchi@ericsson.com>
11429
11430 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
11431 thread.
11432 (darwin_init_thread_list): Don't update dummy thread.
11433 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
11434
873c0814
SM
114352017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11436
11437 * record-full.c (netorder16): Remove.
11438
8b5a7a6e
SM
114392017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11440
11441 * common/diagnostics.h: Define macros for GCC.
11442 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
11443 * common/vec.h: Include diagnostics.h.
11444 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
11445 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
11446 warning.
11447
d1435379
SM
114482017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11449
11450 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
11451 New macro.
11452 * ada-lex.l: Ignore deprecated register warnings.
11453
cc75e0fd
SM
114542017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11455
11456 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
11457 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
11458
07809eaf
SM
114592017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11460
11461 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
11462 its own line.
11463
f076f034
SM
114642017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11465
11466 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
11467
0dd5cbc5
AH
114682017-06-23 Alan Hayward <alan.hayward@arm.com>
11469
11470 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
11471 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
11472 (xtensa_register_read_masked): Likewise.
11473
d4c6ce5b
SDJ
114742017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
11475
11476 * common/environ.c (gdb_environ::unset): Update comment.
11477
16892a03
AH
114782017-06-22 Alan Hayward <alan.hayward@arm.com>
11479
11480 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11481 registers.
11482
d7dcbefc
AH
114832017-06-22 Alan Hayward <alan.hayward@arm.com>
11484
11485 * record-full.c (record_full_exec_insn): Use byte_vector.
11486
b30ff123
YQ
114872017-06-22 Yao Qi <yao.qi@linaro.org>
11488
11489 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11490 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11491
4fa847d7
AH
114922017-06-22 Alan Hayward <alan.hayward@arm.com>
11493
11494 * remote.c (cached_reg): Move from here...
11495 * regcache.h (cached_reg): ...to here.
11496 * python/py-unwind.c (struct reg_info): Remove.
11497 (cached_frame_info): Use cached_reg_t.
11498 (pyuw_prev_register): Likewise.
11499 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11500 (pyuw_dealloc_cache): Free all registers.
11501
f4906a9a
PA
115022017-06-22 Pedro Alves <palves@redhat.com>
11503 Simon Marchi <simon.marchi@ericsson.com>
11504
11505 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11506 warning.
11507 * common/diagnostics.h: New file.
11508
b45a1208
PA
115092017-06-22 Pedro Alves <palves@redhat.com>
11510
11511 * common/agent.h: Add include guards.
11512
e4da2c61
SM
115132017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11514
11515 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11516 talk about addressable units instead of bytes.
11517
96160d60
SDJ
115182017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11519
11520 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11521 of '::const_iterator'.
11522
9a6c7d9c
SDJ
115232017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11524
11525 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11526 'unittests/environ-selftests.c'.
11527 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11528 * charset.c (find_charset_names): Declare object 'iconv_env'.
11529 Update code to use 'iconv_env' object. Remove call to
11530 'free_environ'.
11531 * common/environ.c: Include <utility>.
11532 (make_environ): Delete function.
11533 (free_environ): Delete function.
11534 (gdb_environ::clear): New function.
11535 (gdb_environ::operator=): New function.
11536 (gdb_environ::get): Likewise.
11537 (environ_vector): Delete function.
11538 (set_in_environ): Delete function.
11539 (gdb_environ::set): New function.
11540 (unset_in_environ): Delete function.
11541 (gdb_environ::unset): New function.
11542 (gdb_environ::envp): Likewise.
11543 * common/environ.h: Include <vector>.
11544 (struct gdb_environ): Delete; transform into...
11545 (class gdb_environ): ... this class.
11546 (free_environ): Delete prototype.
11547 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11548 environ_vector): Likewise.
11549 * infcmd.c (run_command_1): Update code to call
11550 'envp' from 'gdb_environ' class.
11551 (environment_info): Update code to call methods from 'gdb_environ'
11552 class.
11553 (unset_environment_command): Likewise.
11554 (path_info): Likewise.
11555 (path_command): Likewise.
11556 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11557 (inferior::inferior): Initialize 'environment' using the host's
11558 information.
11559 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11560 Include "environ.h".
11561 (class inferior) <environment>: Change type from 'struct
11562 gdb_environ' to 'gdb_environ'.
11563 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11564 methods from 'gdb_environ' class.
11565 * solib.c (solib_find_1): Likewise
11566 * unittests/environ-selftests.c: New file.
11567
75c554cf
YQ
115682017-06-20 Yao Qi <yao.qi@linaro.org>
11569
11570 * features/i386/i386-linux.xml: Exchange the order of including
11571 32bit-linux.xml and 32bit-sse.xml.
11572 * features/i386/i386-linux.c: Regenerated.
11573
72ddacb7
YQ
115742017-06-20 Yao Qi <yao.qi@linaro.org>
11575
11576 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11577 Delete copy ctor and assignment operator.
11578 (tdesc_type): Likewise.
11579 (tdesc_feature): Likewise.
11580 (tdesc_free_reg): Remove.
11581 (tdesc_create_reg): Use new.
11582 (tdesc_free_type): Remove.
11583 (tdesc_create_vector): Use new.
11584 (tdesc_create_union): Likewise.
11585 (tdesc_create_flags): Likewise.
11586 (tdesc_create_enum): Likewise.
11587 (tdesc_free_feature): Delete.
11588 (free_target_description): Use delete.
11589
325c9fd4
JB
115902017-06-19 John Baldwin <jhb@FreeBSD.org>
11591
11592 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11593 registers.
11594
16b7a719
PA
115952017-06-19 Pedro Alves <palves@redhat.com>
11596
11597 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11598 after gdb::unlinker.
11599
1c8e01c9
SDJ
116002017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11601
11602 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11603 gdb_environ to access an environment variable.
11604
ffce45d2
TP
116052017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11606
11607 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11608 gdb_byte*.
11609
1d4fbac9
SM
116102017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11611
11612 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11613
8465943a
SM
116142017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11615
11616 * configure: Re-generate.
11617 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11618
3e019bdc
SM
116192017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11620
11621 * configure: Re-generate.
11622 * warning.m4: Pass -Werror to compiler when checking for
11623 supported warning flags.
11624
cf0dd6f0
SM
116252017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11626
11627 * Makefile.in (COMPILE.pre): Add "-x c++".
11628
6f98355c
YQ
116292017-06-16 Alan Hayward <alan.hayward@arm.com>
11630 Pedro Alves <palves@redhat.com>
11631 Yao Qi <yao.qi@linaro.org>
11632
11633 * defs.h (RequireLongest): New.
11634 (extract_integer): Declare function template.
11635 (extract_signed_integer): Remove the declaration, but define it
11636 static inline.
11637 (extract_unsigned_integer): Likewise.
11638 (store_integer): Declare function template.
11639 (store_signed_integer): Remove the declaration, but define it
11640 static inline.
11641 (store_unsigned_integer): Likewise.
11642 * findvar.c (extract_integer): New function template.
11643 (extract_signed_integer): Remove.
11644 (extract_unsigned_integer): Remove.
11645 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11646 instantiations.
11647 (store_integer): New function template.
11648 (store_signed_integer): Remove.
11649 (store_unsigned_integer): Remove.
11650 (store_integer): Explicit instantiations.
11651 * regcache.c (regcache_raw_read_signed): Update.
11652 (regcache::raw_read): New function.
11653 (regcache::raw_read_signed): Remove.
11654 (regcache::raw_read_unsigned): Remove.
11655 (regcache_raw_read_unsigned): Update.
11656 (regcache_raw_write_unsigned): Update.
11657 (regcache::raw_write_signed): Remove.
11658 (regcache::raw_write): New function.
11659 (regcache_cooked_read_signed): Update.
11660 (regcache::raw_write_unsigned): Remove.
11661 (regcache::cooked_read_signed): Remove.
11662 (regcache_cooked_read_unsigned): Update.
11663 (regcache::cooked_read_unsigned): Remove.
11664 (regcache_cooked_write_signed): Update.
11665 (regcache_cooked_write_unsigned): Update.
11666 * regcache.h (regcache) <raw_read_signed>: Remove.
11667 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11668 <raw_read, raw_write>: New.
11669 <cooked_read_signed, cooked_write_signed>: Remove.
11670 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11671 <cooked_read, cooked_write>: New.
11672 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11673 (sh64_pseudo_register_write): Update.
11674
a87dc45a
AK
116752017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11676
11677 * arc-tdep.c (arc_disassembler_options): New variable.
11678 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11679 of default_print_insn.
11680 (arc_delayed_print_insn): Set info->section when needed,
11681 use default_print_insn to retrieve a disassembler.
11682
45159d6a
SDJ
116832017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11684
11685 PR gdb/21574
11686 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11687 to mention $SHELL and startup-with-shell.
11688
b46c4cf0
MF
116892017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11690
11691 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11692
6394c606
YQ
116932017-06-14 Yao Qi <yao.qi@linaro.org>
11694
11695 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11696 default_print_insn instead of print_insn_aarch64.
11697 * arm-tdep.c (gdb_print_insn_arm): Call
11698 default_print_insn instead of print_insn_big_arm
11699 and print_insn_little_arm.
11700 * i386-tdep.c (i386_print_insn): Call default_print_insn
11701 instead of print_insn_i386.
11702 * ia64-tdep.c (ia64_print_insn): Call
11703 default_print_insn instead of print_insn_ia64.
11704 * mips-tdep.c (gdb_print_insn_mips): Call
11705 default_print_insn instead of print_insn_big_mips
11706 and print_insn_little_mips.
11707 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11708 instead of print_insn_spu.
11709
d5722aa2
PA
117102017-06-14 Pedro Alves <palves@redhat.com>
11711
11712 * ada-lang.c: Include "common/byte-vector.h".
11713 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11714 * charset.c (wchar_iterator::iterate): Resize the vector instead
11715 of reserving it.
11716 * common/byte-vector.h: Include "common/def-vector.h".
11717 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11718 * cli/cli-dump.c: Include "common/byte-vector.h".
11719 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11720 * common/byte-vector.h: New file.
11721 * common/def-vector.h: New file.
11722 * common/default-init-alloc.h: New file.
11723 * dwarf2loc.c: Include "common/byte-vector.h".
11724 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11725 instead of reserving it.
11726 * dwarf2read.c: Include "common/byte-vector.h".
11727 (data_buf::m_vec): Now a gdb::byte_vector.
11728 * gdb_regex.c: Include "common/def-vector.h".
11729 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11730 * mi/mi-main.c: Include "common/byte-vector.h".
11731 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11732 * printcmd.c: Include "common/byte-vector.h".
11733 (print_scalar_formatted): Use gdb::byte_vector.
11734 * valprint.c: Include "common/byte-vector.h".
11735 (maybe_negate_by_bytes, print_decimal_chars): Use
11736 gdb::byte_vector.
11737
01ec7a27
SM
117382017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11739
11740 * darwin-nat.c: Include "nat/fork-inferior.h".
11741
848d9074
SM
117422017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11743
11744 * configure.nat: Factor out Darwin bits that are not
11745 architecture-specific. Add fork-inferior.o.
11746
3b912944
SM
117472017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11748
11749 * configure.nat: Factor out AIX bits that are not
11750 architecture-specific. Add fork-inferior.o.
11751
55acdf22
AA
117522017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11753
11754 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11755 (read_pieced_value, write_pieced_value): ...here. Reduce to
11756 wrappers that just call rw_pieced_value.
11757
f65e2044
AA
117582017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11759
11760 * dwarf2loc.c (write_pieced_value): When writing the data for a
11761 memory piece, use write_memory_with_notification instead of
11762 write_memory.
11763
23f945bf
AA
117642017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11765
11766 * valops.c (read_value_memory): Change embedded_offset to
11767 represent a bit offset instead of a byte offset.
11768 * value.h (read_value_memory): Adjust comment.
11769
f236533e
AA
117702017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11771
11772 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11773 dest_offset_bits and source_offset_bits.
11774 (write_pieced_value): Likewise.
11775
65d84b76
AA
117762017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11777
11778 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11779 given by DW_OP_bit_piece.
11780 (write_pieced_value): Likewise.
11781
242d31ab
AA
117822017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11783
11784 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11785 some other preparations to the places where sufficient information
11786 is available.
11787 (write_pieced_value): Likewise.
11788
03c8af18
AA
117892017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11790
11791 * dwarf2loc.c (bits_to_bytes): New function.
11792 (read_pieced_value): Fix offset calculations for register pieces
11793 on big-endian targets.
11794 (write_pieced_value): Likewise.
11795
840989c1
AA
117962017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11797
11798 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11799 (write_pieced_value): Likewise.
11800
359b19bb
AA
118012017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11802
11803 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11804 transfer the source value's least significant bits, instead of its
11805 lowest-addressed ones. Rename type_len to max_offset.
11806 (read_pieced_value): Mirror above changes to write_pieced_value as
11807 applicable.
11808
07c9ca3b
AA
118092017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11810
11811 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11812 truncate full bytes from dest_offset_bits before using it as an
11813 offset into the buffer.
11814
f1cc9874
AA
118152017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11816
11817 * dwarf2loc.c (write_pieced_value): Include transfer size in
11818 byte-wise check.
11819
cdaac320
AA
118202017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11821
11822 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11823 calculation of this_size.
11824
af547a96
AA
118252017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11826
11827 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
11828 when targeting a bit-field.
11829 (write_pieced_value): Likewise.
11830
ddd7882a
AA
118312017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11832
11833 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
11834 (allocate_piece_closure): Drop addr_size parameter.
11835 (dwarf2_evaluate_loc_desc_full): Adjust call to
11836 allocate_piece_closure.
11837
e9352324
AA
118382017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11839
11840 PR gdb/21226
11841 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
11842 the LSB end, independent of endianness.
11843
d5d1163e
AA
118442017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11845
11846 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
11847 size capping.
11848
032bb6ea
YQ
118492017-06-13 Yao Qi <yao.qi@linaro.org>
11850
11851 * mips-linux-nat.c: Move include features/mips*-linux.c to
11852 mips-linux-tdep.c.
11853 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
11854 to mips-linux-tdep.c.
11855 * mips-linux-tdep.c: Include features/mips*-linux.c
11856 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
11857 functions.
11858 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
11859 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
11860 (tdesc_mips64_dsp_linux): Declare.
11861
f12f6bad
TT
118622017-06-12 Tom Tromey <tom@tromey.com>
11863
11864 * valprint.h (val_print_type_code_int): Remove.
11865 * valprint.c (generic_val_print_int): Always call
11866 val_print_scalar_formatted.
11867 (val_print_type_code_int): Remove.
11868 * printcmd.c (print_scalar_formatted): Handle options->format==0.
11869 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
11870 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
11871 * ada-valprint.c (ada_val_print_num): Use
11872 val_print_scalar_formatted.
11873
d9109c80
TT
118742017-06-12 Tom Tromey <tom@tromey.com>
11875
11876 * printcmd.c (print_scalar_formatted): Unify the two switches.
11877 Don't convert scalars to LONGEST.
11878
4ac0cb1c
TT
118792017-06-12 Tom Tromey <tom@tromey.com>
11880
11881 PR exp/16225:
11882 * valprint.h (print_decimal_chars): Update.
11883 * valprint.c (maybe_negate_by_bytes): New function.
11884 (print_decimal_chars): Add "is_signed" argument.
11885 * printcmd.c (print_scalar_formatted): Update.
11886
30a25466
TT
118872017-06-12 Tom Tromey <tom@tromey.com>
11888
11889 PR exp/16225:
11890 * valprint.h (print_binary_chars, print_hex_chars): Update.
11891 * valprint.c (val_print_type_code_int): Update.
11892 (print_binary_chars): Add "zero_pad" argument.
11893 (emit_octal_digit): New function.
11894 (print_octal_chars): Don't zero-pad.
11895 (print_decimal_chars): Likewise.
11896 (print_hex_chars): Add "zero_pad" argument.
11897 * sh64-tdep.c (sh64_do_fp_register): Update.
11898 * regcache.c (regcache::dump): Update.
11899 * printcmd.c (print_scalar_formatted): Update.
11900 * infcmd.c (default_print_one_register_info): Update.
11901
b3464d03
PA
119022017-06-12 Pedro Alves <palves@redhat.com>
11903 Alan Hayward <alan.hayward@arm.com>
11904
11905 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
11906 (mips_eabi_push_dummy_call): Rename local 'regsize' to
11907 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
11908 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
11909 Assert that abi_regsize bytes fit in 'ref_valbuf'.
11910
4b76cda9
PA
119112017-06-12 Pedro Alves <palves@redhat.com>
11912
11913 * dwarf2read.c (mapped_symtab::data): Now a vector of
11914 symtab_index_entry instead of vector of
11915 std::unique_ptr<symtab_index_entry>. All users adjusted to check
11916 whether an element's name is NULL instead of checking whether the
11917 element itself is NULL.
11918 (find_slot): Change return type. Adjust.
11919 (hash_expand, , add_index_entry, uniquify_cu_indices)
11920 (write_hash_table): Adjust.
11921
e8f8bcb3
PA
119222017-06-12 Pedro Alves <palves@redhat.com>
11923
11924 * dwarf2read.c (recursively_count_psymbols): New function.
11925 (write_psymtabs_to_index): Call it to compute number of psyms and
11926 pass estimate size of psyms_seen to unordered_set's ctor.
11927
70a1152b
PA
119282017-06-12 Pedro Alves <palves@redhat.com>
11929
11930 * dwarf2read.c (write_hash_table): Check if key already exists
11931 before emplacing.
11932
c2f134ac
PA
119332017-06-12 Pedro Alves <palves@redhat.com>
11934
11935 * dwarf2read.c (data_buf::append_space): Rename to...
11936 (data_buf::grow): ... this, and make private. Adjust all callers.
11937 (data_buf::append_uint): New method.
11938 (add_address_entry, write_one_signatured_type)
11939 (write_psymtabs_to_index): Use it.
11940
a81e6d4d
PA
119412017-06-12 Pedro Alves <palves@redhat.com>
11942
11943 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
11944 (file_write (FILE *, const std::vector<Elem>&)): Delete.
11945 (data_buf::file_write): Call ::fwrite directly.
11946
6fd931f2
PA
119472017-06-12 Pedro Alves <palves@redhat.com>
11948
11949 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
11950 std::vector::erase.
11951
bc8f2430
JK
119522017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11953
11954 Code cleanup: C++ify .gdb_index producer.
11955 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
11956 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
11957 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
11958 (create_strtab, add_string): Remove.
11959 (file_write, data_buf): New.
11960 (struct symtab_index_entry): Use std::vector for cu_indices.
11961 (struct mapped_symtab): Use std::vector for data.
11962 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
11963 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
11964 Remove.
11965 (find_slot): Change return type. Update it to the new data structures.
11966 (hash_expand, add_index_entry): Update it to the new data structures.
11967 (offset_type_compare): Remove.
11968 (uniquify_cu_indices): Update it to the new data structures.
11969 (c_str_view, c_str_view_hasher, vector_hasher): New.
11970 (add_indices_to_cpool): Remove.
11971 (write_hash_table): Update it to the new data structures.
11972 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
11973 (eq_psymtab_cu_index): Remove.
11974 (psym_index_map): New typedef.
11975 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
11976 reference and std::unordered_map for cu_index_htab.
11977 (add_address_entry, add_address_entry_worker, write_address_map)
11978 (write_psymbols): Update it to the new data structures.
11979 (write_obstack): Remove.
11980 (struct signatured_type_index_data): Change types_list to a data_buf
11981 reference and psyms_seen to a std::unordered_set reference.
11982 (write_one_signatured_type, recursively_write_psymbols)
11983 (write_psymtabs_to_index): Update it to the new data structures.
11984
c4dcb155
SM
119852017-06-11 Simon Marchi <simon.marchi@ericsson.com>
11986
11987 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
11988 separate-debug-file commands.
11989 * symfile.h (separate_debug_file_debug): New global.
11990 * symfile.c (separate_debug_file_debug): New global.
11991 (separate_debug_file_exists, find_separate_debug_file): Add
11992 debug output.
11993 (_initialize_symfile): Add "set debug separate-debug-file"
11994 command.
11995 * build-id.c (build_id_to_debug_bfd,
11996 find_separate_debug_file_by_buildid): Add debug output.
11997
6d45d4b4
SM
119982017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
11999
12000 * gdbarch.sh (displaced_step_free_closure): Remove.
12001 * gdbarch.h, gdbarch.c: Re-generate.
12002 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
12003 displaced_step_free_closure.
12004 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
12005 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
12006 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
12007 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
12008 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
12009 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12010 * arch-utils.h (simple_displaced_step_free_closure): Remove.
12011 * arch-utils.c (simple_displaced_step_free_closure): Remove.
12012 * infrun.c (displaced_step_clear): Call xfree instead of
12013 gdbarch_displaced_step_free_closure.
12014
2f91880f
SDJ
120152017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
12016
12017 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
12018 NULL".
12019
b8b6e72f
AH
120202017-06-08 Alan Hayward <alan.hayward@arm.com>
12021
12022 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
12023 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
12024 (mn10300_push_dummy_call): Likewise.
12025
5369082e
AH
120262017-06-08 Alan Hayward <alan.hayward@arm.com>
12027
12028 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
12029
ff4ca5ac
AH
120302017-06-08 Alan Hayward <alan.hayward@arm.com>
12031
12032 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
12033
aefd8b33
SDJ
120342017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12035
12036 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
12037 able to start inferiors using a shell.
12038 (New remote packets): Announce new packet "QStartupWithShell".
12039 * remote.c: Add PACKET_QStartupWithShell.
12040 (extended_remote_create_inferior): Handle new
12041 PACKET_QStartupWithShell.
12042 (remote_protocol_features) <QStartupWithShell>: New entry for
12043 PACKET_QStartupWithShell.
12044 (_initialize_remote): Call "add_packet_config_cmd" for
12045 QStartupShell.
12046
2090129c
SDJ
120472017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12048 Pedro Alves <palves@redhat.com>
12049
12050 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
12051 and "nat/fork-inferior.h".
12052 * common/common-inferior.h: New file, with contents from
12053 "gdb/inferior.h".
12054 * commom/common-utils.c: Include "common-utils.h".
12055 (stringify_argv): New function.
12056 * common/common-utils.h (stringify_argv): New prototype.
12057 * configure.nat: Add "fork-inferior.o" as a dependency for
12058 "*linux*", "fbsd*" and "nbsd*" hosts.
12059 * corefile.c (get_exec_file): Update comment.
12060 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
12061 instead of "startup_inferior".
12062 (darwin_create_inferior): Call "add_thread_silent" after
12063 "fork_inferior".
12064 * fork-child.c: Cleanup unnecessary includes.
12065 (SHELL_FILE): Move to "common/common-fork-child.c".
12066 (environ): Likewise.
12067 (exec_wrapper): Initialize.
12068 (get_exec_wrapper): New function.
12069 (breakup_args): Move to "common/common-fork-child.c"; rename to
12070 "breakup_args_for_exec".
12071 (escape_bang_in_quoted_argument): Move to
12072 "common/common-fork-child.c".
12073 (saved_ui): New variable.
12074 (prefork_hook): New function.
12075 (postfork_hook): Likewise.
12076 (postfork_child_hook): Likewise.
12077 (gdb_startup_inferior): Likewise.
12078 (fork_inferior): Move to "common/common-fork-child.c". Update
12079 function to support gdbserver.
12080 (startup_inferior): Likewise.
12081 * gdbcore.h (get_exec_file): Remove declaration.
12082 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
12083 instead of "startup_inferior". Call "add_thread_silent" after
12084 "fork_inferior".
12085 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
12086 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
12087 instead of "startup_inferior". Call "add_thread_silent" after
12088 "fork_inferior".
12089 * inferior.h: Include "common-inferior.h".
12090 (trace_start_error): Move to "common/common-utils.h".
12091 (trace_start_error_with_name): Likewise.
12092 (fork_inferior): Move prototype to "nat/fork-inferior.h".
12093 (startup_inferior): Likewise.
12094 (gdb_startup_inferior): New prototype.
12095 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
12096 * nat/fork-inferior.h: New file.
12097 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
12098 instead of "startup_inferior". Call "add_thread_silent" after
12099 "fork_inferior".
12100 * target.h (target_terminal_init): Move prototype to
12101 "target/target.h".
12102 (target_terminal_inferior): Likewise.
12103 (target_terminal_ours): Likewise.
12104 * target/target.h (target_terminal_init): New prototype, moved
12105 from "target.h".
12106 (target_terminal_inferior): Likewise.
12107 (target_terminal_ours): Likewise.
12108 * utils.c (gdb_flush_out_err): New function.
12109
043a4934
SDJ
121102017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12111
12112 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
12113 * common/common-gdbthread.h: New file, with parts from
12114 "gdb/gdbthread.h".
12115 * gdbthread.h: Include "common-gdbthread.h".
12116 (switch_to_thread): Moved to "common/common-gdbthread.h".
12117
15652511
SDJ
121182017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12119
12120 * Makefile.in (SFILES): Add "common/job-control.c".
12121 (HFILES_NO_SRCDIR): Add "common/job-control.h".
12122 (COMMON_OBS): Add "job-control.o".
12123 * common/job-control.c: New file, with contents from
12124 "gdb/inflow.c".
12125 * common/job-control.h: New file, with contents from "terminal.h".
12126 * fork-child.c: Include "job-control.h".
12127 * inflow.c: Include "job-control.h".
12128 (gdb_setpgid): Move to "common/common-inflow.c".
12129 (_initialize_inflow): Move setting of "job_control" to
12130 "handle_job_control".
12131 * terminal.h (job_control): Moved to "common/common-terminal.h".
12132 (gdb_setpgid): Likewise.
12133 * top.c: Include "job_control.h".
12134 * utils.c: Likewise.
12135 (job_control): Moved to "job-control.c".
12136
2d7cc5c7
PA
121372017-06-07 Pedro Alves <palves@redhat.com>
12138
12139 * Makefile.in (SFILES): Add gdb_regex.c.
12140 (COMMON_OBS): Add gdb_regex.o.
12141 * ada-lang.c (ada_add_standard_exceptions)
12142 (ada_add_exceptions_from_frame, name_matches_regex)
12143 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
12144 parameter type to compiled_regex. Adjust.
12145 (ada_exceptions_list): Use compiled_regex.
12146 * break-catch-throw.c (exception_catchpoint::pattern): Now a
12147 std::unique_ptr<compiled_regex>.
12148 (exception_catchpoint::~exception_catchpoint): Remove regfree
12149 call.
12150 (check_status_exception_catchpoint): Adjust to use compiled_regex.
12151 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
12152 * breakpoint.c (solib_catchpoint::compiled): Now a
12153 std::unique_ptr<compiled_regex>.
12154 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
12155 (check_status_catch_solib): Adjust to use compiled_regex.
12156 (add_solib_catchpoint): Adjust to use compiled_regex.
12157 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
12158 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
12159 compiled_regex reference. Adjust to use it.
12160 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
12161 declaration. Include "gdb_regex.h".
12162 (apropos_cmd): Change regex parameter to compiled_regex reference.
12163 * gdb_regex.c: New file.
12164 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
12165 declarations.
12166 (class compiled_regex): New.
12167 * linux-tdep.c: Include "common/gdb_optional.h".
12168 (struct mapping_regexes): New, factored out from
12169 mapping_is_anonymous_p, and adjusted to use compiled_regex.
12170 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
12171 gdb::optional and remove cleanups. Adjust to compiled_regex.
12172 * probe.c: Include "common/gdb_optional.h".
12173 (collect_probes): Use compiled_regex and gdb::optional and remove
12174 cleanups.
12175 * skip.c: Include "common/gdb_optional.h".
12176 (skiplist_entry::compiled_function_regexp): Now a
12177 gdb::optional<compiled_regex>.
12178 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
12179 (free_skiplist_entry): Remove regfree call.
12180 (compile_skip_regexp, skip_rfunction_p): Adjust to use
12181 compiled_regex and gdb::optional.
12182 * symtab.c: Include "common/gdb_optional.h".
12183 (search_symbols): Use compiled_regex and gdb::optional.
12184 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
12185 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
12186 to gdb_regex.c.
12187
50d6adef
AH
121882017-06-07 Alan Hayward <alan.hayward@arm.com>
12189
12190 * regcache.c (regcache::save): Avoid buffer use.
12191 (regcache::dump): Likewise.
12192
4a8a33c8
AH
121932017-06-07 Alan Hayward <alan.hayward@arm.com>
12194
12195 * sh-tdep.c (sh_pseudo_register_read): Remove
12196 MAX_REGISTER_SIZE.
12197 (sh_pseudo_register_write): Likewise.
12198 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
12199 (sh64_pseudo_register_write): Likewise
12200
d1be909e
AH
122012017-06-07 Alan Hayward <alan.hayward@arm.com>
12202
12203 * aarch64-tdep.c (aarch64_store_return_value): Use
12204 V_REGISTER_SIZE.
12205 (aarch64_pseudo_read_value): Likewise.
12206 (aarch64_pseudo_write): Likewise.
12207
f4a65042
YQ
122082017-06-06 Yao Qi <yao.qi@linaro.org>
12209
12210 * regformats/regdef.h (set_register_cache): Remove the
12211 declaration.
12212
9f7fb0aa
AH
122132017-06-06 Alan Hayward <alan.hayward@arm.com>
12214
12215 * frame.c (frame_unwind_register_signed): Use
12216 frame_unwind_register_value.
12217
e1e01040
PA
122182017-06-06 Pedro Alves <palves@redhat.com>
12219
12220 PR breakpoints/21553
12221 * breakpoint.c (create_breakpoints_sal_default)
12222 (init_breakpoint_sal, create_breakpoint_sal): Use
12223 gdb::unique_xmalloc_ptr for string parameters.
12224 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12225 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
12226 (base_breakpoint_create_breakpoints_sal)
12227 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
12228 (strace_marker_create_breakpoints_sal)
12229 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
12230 string parameters.
12231 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
12232 gdb::unique_xmalloc_ptr for string parameters.
12233 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12234 parameters.
12235
fbe654c8
AH
122362017-06-06 Alan Hayward <alan.hayward@arm.com>
12237
12238 * alpha-tdep.c (alpha_register_to_value): Use
12239 get_frame_register_value.
12240 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
12241
ae0d01d6
AH
122422017-06-06 Alan Hayward <alan.hayward@arm.com>
12243
12244 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
12245 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
12246 (ia64_value_to_register): Likewise.
12247 (ia64_extract_return_value): Likewise.
12248 (ia64_store_return_value): Likewise.
12249 (ia64_push_dummy_call): Likewise.
12250
49cf576c
JB
122512017-06-04 Joel Brobecker <brobecker@adacore.com>
12252
12253 GDB 8.0 released.
12254
26b6a6ab
SM
122552017-06-03 Simon Marchi <simon.marchi@ericsson.com>
12256
12257 * x86-linux-nat.c (struct arch_lwp_info): Remove.
12258
22827c51
SM
122592017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
12260
12261 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
12262 parameter.
12263 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
12264
0e05cf3a
SM
122652017-06-02 Simon Marchi <simon.marchi@ericsson.com>
12266
12267 * event-loop.c (poll_timers): Unallocate timer using delete
12268 instead of xfree.
12269
c1fc2657
SM
122702017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12271
12272 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
12273 (struct breakpoint) <~breakpoint>: New.
12274 (struct watchpoint): Inherit from breakpoint.
12275 <~watchpoint>: New.
12276 <base>: Remove.
12277 (struct tracepoint): Inherit from breakpoint.
12278 <base>: Remove.
12279 * breakpoint.c (longjmp_breakpoint_ops): Remove.
12280 (struct longjmp_breakpoint): Inherit from breakpoint.
12281 <~longjmp_breakpoint>: New.
12282 <base>: Remove.
12283 (new_breakpoint_from_type): Remove casts.
12284 (watchpoint_in_thread_scope): Remove reference to base field.
12285 (watchpoint_del_at_next_stop): Likewise.
12286 (update_watchpoint): Likewise.
12287 (watchpoint_check): Likewise.
12288 (bpstat_check_watchpoint): Likewise.
12289 (set_longjmp_breakpoint): Likewise.
12290 (struct fork_catchpoint): Inherit from breakpoint.
12291 <base>: Remove.
12292 (struct solib_catchpoint): Inherit from breakpoint.
12293 <~solib_catchpoint>: New.
12294 <base>: Remove.
12295 (dtor_catch_solib): Change to ...
12296 (solib_catchpoint::~solib_catchpoint): ... this.
12297 (breakpoint_hit_catch_solib): Remove reference to base field.
12298 (add_solib_catchpoint): Likewise.
12299 (create_fork_vfork_event_catchpoint): Likewise.
12300 (struct exec_catchpoint): Inherit from breakpoint.
12301 <~exec_catchpoint>: New.
12302 <base>: Remove.
12303 (dtor_catch_exec): Change to ...
12304 (exec_catchpoint::~exec_catchpoint): ... this.
12305 (dtor_watchpoint): Change to ...
12306 (watchpoint::~watchpoint): ... this.
12307 (watch_command_1): Remove reference to base field.
12308 (catch_exec_command_1): Likewise.
12309 (base_breakpoint_dtor): Change to ...
12310 (breakpoint::~breakpoint): ... this.
12311 (base_breakpoint_ops): Remove dtor field value.
12312 (longjmp_bkpt_dtor): Change to ...
12313 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
12314 (strace_marker_create_breakpoints_sal): Remove reference to base
12315 field.
12316 (delete_breakpoint): Don't manually call breakpoint destructor.
12317 (create_tracepoint_from_upload): Remove reference to base field.
12318 (trace_pass_set_count): Likewise.
12319 (initialize_breakpoint_ops): Don't initialize
12320 momentary_breakpoint_ops, don't set dtors.
12321 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
12322 <~ada_catchpoint>: New.
12323 <base>: Remove.
12324 (create_excep_cond_exprs): Remove reference to base field.
12325 (dtor_exception): Change to ...
12326 (ada_catchpoint::~ada_catchpoint): ... this.
12327 (dtor_catch_exception): Remove.
12328 (dtor_catch_exception_unhandled): Remove.
12329 (dtor_catch_assert): Remove.
12330 (create_ada_exception_catchpoint): Remove reference to base
12331 field.
12332 (initialize_ada_catchpoint_ops): Don't set dtors.
12333 * break-catch-sig.c (struct signal_catchpoint): Inherit from
12334 breakpoint.
12335 <~signal_catchpoint>: New.
12336 <base>: Remove.
12337 (signal_catchpoint_dtor): Change to ...
12338 (signal_catchpoint::~signal_catchpoint): ... this.
12339 (create_signal_catchpoint): Remove reference to base field.
12340 (initialize_signal_catchpoint_ops): Don't set dtor.
12341 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
12342 from breakpoint.
12343 <~syscall_catchpoint>: New.
12344 <base>: Remove.
12345 (dtor_catch_syscall): Change to ...
12346 (syscall_catchpoint::~syscall_catchpoint): ... this.
12347 (create_syscall_event_catchpoint): Remove reference to base
12348 field.
12349 (initialize_syscall_catchpoint_ops): Don't set dtor.
12350 * break-catch-throw.c (struct exception_catchpoint): Inherit
12351 from breakpoint.
12352 <~exception_catchpoint>: New.
12353 <base>: Remove.
12354 (dtor_exception_catchpoint): Change to ...
12355 (exception_catchpoint::~exception_catchpoint): ... this.
12356 (handle_gnu_v3_exceptions): Remove reference to base field.
12357 (initialize_throw_catchpoint_ops): Don't set dtor.
12358 * ctf.c (ctf_get_traceframe_address): Remove reference to base
12359 field.
12360 * remote.c (remote_get_tracepoint_status): Likewise.
12361 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
12362 * tracefile.c (tracefile_fetch_registers): Likewise.
12363 * tracepoint.c (actions_command): Likewise.
12364 (validate_actionline): Likewise.
12365 (tfind_1): Likewise.
12366 (get_traceframe_location): Likewise.
12367 (find_matching_tracepoint_location): Likewise.
12368 (parse_tracepoint_status): Likewise.
12369 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
12370
3b0871f4
SM
123712017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12372
12373 * breakpoint.c (struct longjmp_breakpoint): New struct.
12374 (is_tracepoint_type): Change return type to bool.
12375 (is_longjmp_type): New function.
12376 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
12377 (set_raw_breakpoint_without_location): Use
12378 new_breakpoint_from_type.
12379 (set_raw_breakpoint): Likewise.
12380
a5e364af
SM
123812017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12382
12383 * breakpoint.c (new_breakpoint_from_type): New function.
12384 (create_breakpoint_sal): Use new_breakpoint_from_type and
12385 unique_ptr.
12386 (create_breakpoint): Likewise.
12387
ae3b3f34
SM
123882017-05-31 Simon Marchi <simon.marchi@ericsson.com>
12389
12390 * memattr.c (mem_info_command): Rename to ...
12391 (info_mem_command): ... this.
12392 (mem_enable_command): Rename to ...
12393 (enable_mem_command): ... this.
12394 (mem_disable_command): Rename to ...
12395 (disable_mem_command): ... this.
12396 (mem_delete_command): Rename to ...
12397 (delete_mem_command): ... this.
12398 (_initialize_mem): Adjust function names.
12399
13ace077
MM
124002017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12401
12402 * btrace.c (handle_pt_insn_events): New.
12403 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
12404 STATUS. Split into this and ...
12405 (handle_pt_insn_event_flags): ... this.
12406
c56ccc05
MM
124072017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12408
12409 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
12410 and struct pt_insn.resynced.
12411 * configure: Regenerated.
12412 * config.in: Regenerated.
12413
08c3f6d2
TW
124142017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12415
12416 * btrace.c (ftrace_find_call_by_number): New function.
12417 (ftrace_new_function): Store objects, not pointers.
12418 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
12419 ftrace_new_gap, ftrace_update_function,
12420 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
12421 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
12422 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
12423 btrace_ends_with_single_insn, btrace_call_get): Account for
12424 btrace_thread_info::functions now storing objects.
12425 * btrace.h (struct btrace_thread_info): Add constructor.
12426 (struct btrace_thread_info) <functions>: Make std::vector.
12427 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
12428 Initialize with default values.
12429 * record-btrace.c (record_btrace_frame_sniffer): Account for
12430 btrace_thread_info::functions now storing objects.
12431
8ffd39f2
TW
124322017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12433
12434 * btrace.c: Remove typedef bfun_s.
12435 (ftrace_new_gap): Directly add gaps to the list of gaps.
12436 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
12437 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
12438 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
12439 instead of gdb VEC.
12440
4aeb0dfc
TW
124412017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12442
12443 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
12444 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
12445 with btrace_thread_info::next_segment and
12446 btrace_thread_info::prev_segment.
12447 * btrace.h: Remove struct btrace_func_link.
12448 (struct btrace_function): Replace pair of function segment pointers
12449 with pair of indices.
12450 * python/py-record-btrace.c (btpy_call_prev_sibling,
12451 btpy_call_next_sibling): Replace references to
12452 btrace_thread_info::segment with btrace_thread_info::next_segment and
12453 btrace_thread_info::prev_segment.
12454 * record-btrace.c (record_btrace_frame_this_id): Use
12455 btrace_find_call_by_number.
12456
eb8f2b9c
TW
124572017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12458
12459 * btrace.c (ftrace_new_function, ftrace_fixup_level,
12460 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
12461 btrace_insn_next, btrace_insn_prev): Remove references to
12462 btrace_thread_info::flow.
12463 * btrace.h (struct btrace_function): Remove FLOW.
12464
42bfe59e
TW
124652017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12466
12467 * btrace.c (ftrace_find_call_by_number): New function.
12468 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
12469 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
12470 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
12471 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
12472 index.
12473 * btrace.h (struct btrace_function): Turn UP into an index.
12474 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
12475 as an index.
12476 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
12477 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12478 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12479
b54b03bd
TW
124802017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12481
12482 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12483 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12484 ftrace_update_function, ftrace_compute_global_level_offset,
12485 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12486 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12487 btrace_insn_end, btrace_is_empty): Remove references to
12488 btrace_thread_info::begin and btrace_thread_info::end.
12489 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12490 (struct btrace_thread_info) <functions>: Adjust comment.
12491 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12492 btrace_thread_info::begin.
12493
8286623c
TW
124942017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12495
12496 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12497 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12498 ftrace_update_function): Remove arguments that implicitly were always
12499 BTINFO->END.
12500 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12501 Don't pass BTINFO->END.
12502
a0f1b963
TW
125032017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12504
12505 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12506 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12507 btrace_find_insn_by_number): Replace function segment pointer with
12508 index.
12509 (btrace_insn_cmp): Simplify.
12510 * btrace.h: (struct btrace_insn_iterator) Rename index to
12511 insn_index. Replace function segment pointer with index into function
12512 segment vector.
12513 * record-btrace.c (record_btrace_call_history): Replace function
12514 segment pointer use with index.
12515 (record_btrace_frame_sniffer): Retrieve function call segment through
12516 vector.
12517 (record_btrace_set_replay): Remove defunc't safety check.
12518
f158f208
TW
125192017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12520
12521 * btrace.c (btrace_ends_with_single_insn): New function.
12522 (btrace_call_get, btrace_call_number, btrace_call_begin,
12523 btrace_call_end, btrace_call_next, btrace_call_prev,
12524 btrace_find_call_by_number): Use index into call segment vector
12525 instead of pointer.
12526 (btrace_call_cmp): Simplify.
12527 * btrace.h (struct btrace_call_iterator): Replace function call segment
12528 pointer with index into vector.
12529 * record-btrace.c (record_btrace_call_history): Use index instead of
12530 pointer.
12531
521103fd
TW
125322017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12533
12534 * btrace.c (btrace_insn_begin, btrace_insn_end,
12535 btrace_find_insn_by_number): Add btinfo to iterator.
12536 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12537
17b89b34
TW
125382017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12539
12540 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12541 and save pointers directly.
12542 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12543 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12544 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12545 changed signature of functions.
12546 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12547 (btrace_fetch): Remove code that adds btrace_function pointers to
12548 vector of btrace_functions.
12549 (btrace_clear): Simplify freeing vector of btrace_functions.
12550
2b51eddc
TW
125512017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12552
12553 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12554 Replace VEC_* with std::vector functions.
12555 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12556 (struct btrace_thread_info)<functions>: Change type to std::vector.
12557
db6be0d5
SM
125582017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12559
12560 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12561 "Removed targets and native configurations" up. Merge duplicate
12562 "New commands" sub-sections. Add "New options" sub-sections.
12563
b057297a
AH
125642017-05-26 Alan Hayward <alan.hayward@arm.com>
12565
12566 * defs.h (copy_integer_to_size): New declaration.
12567 * findvar.c (copy_integer_to_size): New function.
12568 (do_cint_test): New selftest function.
12569 (copy_integer_to_size_test): Likewise.
12570 (_initialize_findvar): Likewise.
12571 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12572 (mips_fbsd_collect_reg): Use raw_collect_integer.
12573 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12574 (mips64_fill_gregset): Use raw_collect_integer
12575 (mips64_fill_fpregset): Use raw_supply_integer.
12576 * regcache.c (regcache::raw_supply_integer): New function.
12577 (regcache::raw_collect_integer): Likewise.
12578 * regcache.h: (regcache::raw_supply_integer): New declaration.
12579 (regcache::raw_collect_integer): Likewise.
12580
b77b02a5
YQ
125812017-05-24 Yao Qi <yao.qi@linaro.org>
12582
12583 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12584 (COMMON_OBS): Add gdbarch-selftests.o.
12585 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12586 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12587 * gdbarch-selftests.c: New file.
12588 * regcache.h (regcache) <~regcache>: Mark it virtual if
12589 GDB_SELF_TEST.
12590 <raw_write>: Likewise.
12591
e521e87e
YQ
125922017-05-24 Yao Qi <yao.qi@linaro.org>
12593
12594 * regcache.c (current_regcache): Change it to
12595 regcache::current_regcache.
12596 (regcache_observer_target_changed): Update.
12597 (regcache_thread_ptid_changed): Make it a regcache static
12598 method.
12599 (regcache_thread_ptid_changed): Update.
12600 (class regcache_access): New.
12601 (current_regcache_test): Update.
12602 (_initialize_regcache): Update.
12603 * regcache.h: Include forward_list.
12604 (regcache): Declare regcache_thread_ptid_changed and declare
12605 registers_changed_ptid as friend.
12606
d8e07dda
YQ
126072017-05-24 Yao Qi <yao.qi@linaro.org>
12608
12609 * i387-tdep.c (i387_register_to_value): Use register_size
12610 instead of TYPE_LENGTH.
12611 * m68k-tdep.c (m68k_register_to_value): Likewise.
12612
8c8f9122
YQ
126132017-05-24 Yao Qi <yao.qi@linaro.org>
12614
12615 * i387-tdep.c (i387_convert_register_p): Return false if type
12616 code isn't TYPE_CODE_FLT.
12617
68fce50f
YQ
126182017-05-24 Yao Qi <yao.qi@linaro.org>
12619
12620 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12621 length is 4.
12622 (alpha_register_to_value): Remove type length check.
12623 (alpha_value_to_register): Likewise.
12624
88954b49
YQ
126252017-05-24 Yao Qi <yao.qi@linaro.org>
12626
12627 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12628 TYPE_CODE_FLT.
12629
e3ec9b69
YQ
126302017-05-24 Yao Qi <yao.qi@linaro.org>
12631
12632 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12633 TYPE_CODE_FLT or not.
12634
cdd238da
YQ
126352017-05-24 Yao Qi <yao.qi@linaro.org>
12636
12637 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12638 * avr-tdep.c (avr_gdbarch_init): Likewise.
12639 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12640 * cris-tdep.c (cris_gdbarch_init): Likewise.
12641 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12642 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12643 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12644 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12645 * mep-tdep.c (mep_gdbarch_init): Likewise.
12646 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12647 * mips-tdep.c (mips_gdbarch_init): Likewise.
12648 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12649 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12650 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12651 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12652 * v850-tdep.c (v850_gdbarch_init): Likewise.
12653
7a3929c4
YQ
126542017-05-24 Yao Qi <yao.qi@linaro.org>
12655
12656 * selftest-arch.c (tests_with_arch): Call registers_changed
12657 and reinit_frame_cache.
12658 * selftest.c (run_self_tests): Likewise.
12659
f4985dba
YQ
126602017-05-24 Yao Qi <yao.qi@linaro.org>
12661
12662 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12663 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12664
ab20fa4a
YQ
126652017-05-24 Yao Qi <yao.qi@linaro.org>
12666
12667 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12668 set_gdbarch_print_insn.
12669
f532ab94
YQ
126702017-05-24 Yao Qi <yao.qi@linaro.org>
12671
12672 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12673 set_gdbarch_print_insn.
12674
39503f82
YQ
126752017-05-24 Yao Qi <yao.qi@linaro.org>
12676
12677 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12678 set_gdbarch_print_insn.
12679 * arc-tdep.c (arc_gdbarch_init): Likewise.
12680 * arch-utils.c: include dis-asm.h.
12681 (default_print_insn): New function.
12682 * arch-utils.h (default_print_insn): Declare.
12683 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12684 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12685 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12686 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12687 * frv-tdep.c (frv_gdbarch_init): Likewise.
12688 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12689 * gdbarch.sh (print_insn): Use default_print_insn.
12690 * gdbarch.c: Regenerated.
12691 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12692 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12693 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12694 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12695 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12696 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12697 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12698 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12699 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12700 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12701 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12702 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12703 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12704 * mt-tdep.c (mt_gdbarch_init): Likewise.
12705 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12706 * nios2-tdep.c (nios2_print_insn): Remove.
12707 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12708 * rx-tdep.c (rx_gdbarch_init): Likewise.
12709 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12710 * score-tdep.c (score_print_insn): Remove.
12711 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12712 * sh-tdep.c (sh_gdbarch_init): Likewise.
12713 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12714 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12715 * tic6x-tdep.c (tic6x_print_insn): Remove.
12716 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12717 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12718 * v850-tdep.c (v850_gdbarch_init): Likewise.
12719 * vax-tdep.c (vax_gdbarch_init): Likewise.
12720 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12721 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12722
f7241d4f
JB
127232017-05-23 John Baldwin <jhb@FreeBSD.org>
12724
12725 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12726 (MIPS_FP0_REGNUM): Remove.
12727 (MIPS_FSR_REGNUM): Remove.
12728 (mips_fbsd_supply_fpregs): Use mips_regnum.
12729 (mips_fbsd_supply_gregs): Likewise.
12730 (mips_fbsd_collect_fpregs): Likewise.
12731 (mips_fbsd_collect_gregs): Likewise.
12732
d489d81d
JB
127332017-05-23 John Baldwin <jhb@FreeBSD.org>
12734
12735 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12736 (getpfpregs_supplies): New function.
12737 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12738 getfpregs_supplies.
12739 (mips_fbsd_store_inferior_registers): Likewise.
12740
e11b3cdc
PA
127412017-05-22 Pedro Alves <palves@redhat.com>
12742
12743 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12744 maintainer.
12745
0f068fb5
AH
127462017-05-22 Alan Hayward <alan.hayward@arm.com>
12747
12748 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12749 (store_register): Likewise.
12750 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12751 (get_decimal_float_return_value): Likewise.
12752 (do_ppc_sysv_return_value): Likewise.
12753 (ppc64_sysv_abi_push_integer): Likewise.
12754 (ppc64_sysv_abi_push_freg): Likewise.
12755 (ppc64_sysv_abi_return_value_base): Likewise.
12756 (ppc64_sysv_abi_return_value): Likewise.
12757 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12758 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12759 * rs6000-nat.c: Likewise.
12760 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12761 (rs6000_value_to_register): Likewise.
12762 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12763
e6cf65f2
TT
127642017-05-21 Tom Tromey <tom@tromey.com>
12765
12766 PR rust/21466:
12767 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12768 arrays as "[T]", not "[T; ]".
12769
43cc5389
TT
127702017-05-19 Tom Tromey <tom@tromey.com>
12771
12772 PR rust/21484:
12773 * rust-lang.c (exp_descriptor_rust): New function.
12774 (rust_language_defn): Use it.
12775 * p-lang.c (pascal_language_defn): Update.
12776 * opencl-lang.c (opencl_language_defn): Update.
12777 * objc-lang.c (objc_language_defn): Update.
12778 * m2-lang.c (m2_language_defn): Update.
12779 * language.h (struct language_defn)
12780 <la_watch_location_expression>: New member.
12781 * language.c (unknown_language_defn, auto_language_defn)
12782 (local_language_defn): Update.
12783 * go-lang.c (go_language_defn): Update.
12784 * f-lang.c (f_language_defn): Update.
12785 * d-lang.c (d_language_defn): Update.
12786 * c-lang.h (c_watch_location_expression): Declare.
12787 * c-lang.c (c_watch_location_expression): New function.
12788 (c_language_defn, cplus_language_defn, asm_language_defn)
12789 (minimal_language_defn): Use it.
12790 * breakpoint.c (watch_command_1): Call
12791 la_watch_location_expression.
12792 * ada-lang.c (ada_language_defn): Update.
12793
7a6e7fcc
RO
127942017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12795
6e7e1744
RO
12796 PR tui/21482
12797 * gdb_curses.h (NOMACROS): Define.
12798 (NCURSES_NOMACROS): Define.
12799
128002017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12801
12802 PR tui/21482
7a6e7fcc
RO
12803 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12804 arg to char *.
12805 * tui/tui-wingeneral.c (box_win): Likewise.
12806 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12807 (tui_show_source_line): Likewise.
12808 (tui_show_exec_info_content): Likewise.
12809
1933fd8e
VM
128102017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12811
12812 * sparc-tdep.c (sparc_structure_return_p)
12813 (sparc_arg_on_registers_p): New functions.
12814 (sparc32_store_arguments): Use them.
12815 * sparc64-tdep.c (sparc64_16_byte_align_p)
12816 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12817 Handle TYPE_CODE_ARRAY.
12818
21873064
YQ
128192017-05-17 Yao Qi <yao.qi@linaro.org>
12820
12821 * cli/cli-decode.c (add_alias_cmd): New function.
12822 * command.h (add_alias_cmd): Declare.
12823 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
12824 instead call add_alias_cmd.
12825
2b351b19
PA
128262017-05-17 Pedro Alves <palves@redhat.com>
12827
12828 * Makefile.in (nat_extra_makefile_frag): Rename to ...
12829 (nat_makefile_frag): ... this. All references updated.
12830 * configure.ac: Likewise.
12831 * configure.nat: Likewise. Enhance comments.
12832 * configure: Regenerate.
12833
5f2ad7a3
RO
128342017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12835
12836 * procfs.c (procfs_create_inferior): Change prototype to match
12837 definition.
12838
adf3dde5
EZ
128392017-05-13 Eli Zaretskii <eliz@gnu.org>
12840
12841 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
12842 C++ compiler warning.
12843
6830f270
TT
128442017-05-12 Tom Tromey <tom@tromey.com>
12845
12846 PR rust/21483:
12847 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
12848 recurse, just call value_struct_elt directly.
12849
68f2f2e3
TT
128502017-05-12 Tom Tromey <tom@tromey.com>
12851
12852 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
12853 OP_RUST_ARRAY>: Fix.
12854
256afbc2
TT
128552017-05-12 Tom Tromey <tom@tromey.com>
12856
12857 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
12858
94bb8dfe
YQ
128592017-05-09 Yao Qi <yao.qi@linaro.org>
12860
12861 * regcache.c: Include <forward_list>.
12862 (struct regcache_list): Remove.
12863 (current_regcache): Update.
12864 (get_thread_arch_aspace_regcache): Update for std::forward_list.
12865 (regcache_thread_ptid_changed): Likewise.
12866 (registers_changed_ptid): Likewise.
12867 (current_regcache_size): Likewise.
12868
8248946c
YQ
128692017-05-09 Yao Qi <yao.qi@linaro.org>
12870
12871 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
12872 (current_regcache_size): New function.
12873 (current_regcache_test): New function.
12874 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
12875
313c5961
AH
128762017-05-08 Alan Hayward <alan.hayward@arm.com>
12877
12878 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
12879 (print_gp_register_row): Use get_frame_register_value.
12880
27bfc1d1
AH
128812017-05-08 Alan Hayward <alan.hayward@arm.com>
12882
12883 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
12884 (mips_supply_fpregset): Likewise.
12885 (mips64_supply_gregset): Likewise.
12886
146e6c5c
AH
128872017-05-08 Alan Hayward <alan.hayward@arm.com>
12888
12889 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
12890 regcache->raw_supply_zeroed.
12891
e50f25ec
SDJ
128922017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12893
12894 * configure.nat: Rearrange 'case' statements to match
12895 host before cpu.
12896
21ea5acd
SDJ
128972017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12898
12899 * Makefile.in: Remove "@host_makefile_frag@". Add variables
12900 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
12901 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
12902 "@nat_extra_makefile_frag@".
12903 (Makefile): Remove dependency on "@frags@".
12904 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
12905 (data-directory/Makefile): Likewise.
12906 * config/aarch64/linux.mh: Deleted; moved contents to
12907 "gdb/configure.nat".
12908 * config/alpha/alpha-linux.mh: Likewise.
12909 * config/alpha/nbsd.mh: Likewise.
12910 * config/arm/linux.mh: Likewise.
12911 * config/arm/nbsdelf.mh: Likewise.
12912 * config/i386/cygwin.mh: Likewise.
12913 * config/i386/cygwin64.mh: Likewise.
12914 * config/i386/darwin.mh: Likewise.
12915 * config/i386/fbsd.mh: Likewise.
12916 * config/i386/fbsd64.mh: Likewise.
12917 * config/i386/go32.mh: Likewise.
12918 * config/i386/i386gnu.mh: Likewise.
12919 * config/i386/i386sol2.mh: Likewise.
12920 * config/i386/linux.mh: Likewise.
12921 * config/i386/linux64.mh: Likewise.
12922 * config/i386/mingw.mh: Likewise.
12923 * config/i386/mingw64.mh: Likewise.
12924 * config/i386/nbsd64.mh: Likewise.
12925 * config/i386/nbsdelf.mh: Likewise.
12926 * config/i386/nto.mh: Likewise.
12927 * config/i386/obsd.mh: Likewise.
12928 * config/i386/obsd64.mh: Likewise.
12929 * config/i386/sol2-64.mh: Likewise.
12930 * config/ia64/linux.mh: Likewise.
12931 * config/m32r/linux.mh: Likewise.
12932 * config/m68k/linux.mh: Likewise.
12933 * config/m68k/nbsdelf.mh: Likewise.
12934 * config/m68k/obsd.mh: Likewise.
12935 * config/m88k/obsd.mh: Likewise.
12936 * config/mips/fbsd.mh: Likewise.
12937 * config/mips/linux.mh: Likewise.
12938 * config/mips/nbsd.mh: Likewise.
12939 * config/mips/obsd64.mh: Likewise.
12940 * config/pa/linux.mh: Likewise.
12941 * config/pa/nbsd.mh: Likewise.
12942 * config/pa/obsd.mh: Likewise.
12943 * config/powerpc/aix.mh: Likewise.
12944 * config/powerpc/fbsd.mh: Likewise.
12945 * config/powerpc/linux.mh: Likewise.
12946 * config/powerpc/nbsd.mh: Likewise.
12947 * config/powerpc/obsd.mh: Likewise.
12948 * config/powerpc/ppc64-linux.mh: Likewise.
12949 * config/powerpc/spu-linux.mh: Likewise.
12950 * config/s390/linux.mh: Likewise.
12951 * config/sh/nbsd.mh: Likewise.
12952 * config/sparc/fbsd.mh: Likewise.
12953 * config/sparc/linux.mh: Likewise.
12954 * config/sparc/linux64.mh: Likewise.
12955 * config/sparc/nbsd64.mh: Likewise.
12956 * config/sparc/nbsdelf.mh: Likewise.
12957 * config/sparc/obsd64.mh: Likewise.
12958 * config/sparc/sol2.mh: Likewise.
12959 * config/tilegx/linux.mh: Likewise.
12960 * config/vax/nbsdelf.mh: Likewise.
12961 * config/vax/obsd.mh: Likewise.
12962 * config/xtensa/linux.mh: Likewise.
12963 * config/i386/i386gnu.mn: New file, with excerpts from
12964 "config/i386/i386gnu.mh".
12965 * configure: Regenerate.
12966 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
12967 *.mh files under "gdb/config".
12968 * configure.nat: New file, with contents from the
12969 "gdb/config/*/*.mh" files.
12970
7ed1acaf
TW
129712017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
12972
12973 * btrace.c (btrace_clear): Free insn vector.
12974
e13cb306
PA
129752017-05-05 Pedro Alves <palves@redhat.com>
12976
12977 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
12978 * configure: Regenerate.
12979
5ed8105e
PA
129802017-05-04 Pedro Alves <palves@redhat.com>
12981
12982 * Makefile.in (SFILES): Add progspace-and-thread.c.
12983 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
12984 (COMMON_OBS): Add progspace-and-thread.o.
12985 * breakpoint.c: Include "progspace-and-thread.h".
12986 (update_inserted_breakpoint_locations)
12987 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
12988 Use scoped_restore_current_pspace_and_thread.
12989 (create_std_terminate_master_breakpoint): Use
12990 scoped_restore_current_program_space.
12991 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
12992 (print_breakpoint_location): Use
12993 scoped_restore_current_program_space.
12994 (bp_loc_is_permanent): Use
12995 scoped_restore_current_pspace_and_thread.
12996 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
12997 (download_tracepoint_locations): Use
12998 scoped_restore_current_pspace_and_thread.
12999 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
13000 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
13001 (enum step_over_calls_kind): Moved from inferior.h.
13002 (class scoped_restore_current_thread): New class.
13003 * gdbthread.h (make_cleanup_restore_current_thread): Delete
13004 declaration.
13005 (scoped_restore_current_thread): New class.
13006 * infcmd.c: Include "common/gdb_optional.h".
13007 (continue_1, proceed_after_attach): Use
13008 scoped_restore_current_thread.
13009 (notice_new_inferior): Use scoped_restore_current_thread.
13010 * inferior.c: Include "progspace-and-thread.h".
13011 (restore_inferior, save_current_inferior): Delete.
13012 (add_inferior_command, clone_inferior_command): Use
13013 scoped_restore_current_pspace_and_thread.
13014 * inferior.h (scoped_restore_current_inferior): New class.
13015 * infrun.c: Include "progspace-and-thread.h" and
13016 "common/gdb_optional.h".
13017 (follow_fork_inferior): Use
13018 scoped_restore_current_pspace_and_thread.
13019 (scoped_restore_exited_inferior): New class.
13020 (handle_vfork_child_exec_or_exit): Use
13021 scoped_restore_exited_inferior,
13022 scoped_restore_current_pspace_and_thread,
13023 scoped_restore_current_thread and scoped_restore.
13024 (fetch_inferior_event): Use scoped_restore_current_thread.
13025 * linespec.c (decode_line_full, decode_line_1): Use
13026 scoped_restore_current_program_space.
13027 * mi/mi-main.c: Include "progspace-and-thread.h".
13028 (exec_continue): Use scoped_restore_current_thread.
13029 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
13030 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
13031 * proc-service.c (ps_pglobal_lookup): Use
13032 scoped_restore_current_program_space.
13033 * progspace-and-thread.c: New file.
13034 * progspace-and-thread.h: New file.
13035 * progspace.c (release_program_space, clone_program_space): Use
13036 scoped_restore_current_program_space.
13037 (restore_program_space, save_current_program_space)
13038 (save_current_space_and_thread): Delete.
13039 (switch_to_program_space_and_thread): Moved to
13040 progspace-and-thread.c.
13041 * progspace.h (save_current_program_space)
13042 (save_current_space_and_thread): Delete declarations.
13043 (scoped_restore_current_program_space): New class.
13044 * remote.c (remote_btrace_maybe_reopen): Use
13045 scoped_restore_current_thread.
13046 * symtab.c: Include "progspace-and-thread.h".
13047 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
13048 * thread.c (print_thread_info_1): Use
13049 scoped_restore_current_thread.
13050 (struct current_thread_cleanup): Delete.
13051 (do_restore_current_thread_cleanup)
13052 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
13053 (scoped_restore_current_thread::~scoped_restore_current_thread):
13054 ... this new dtor.
13055 (make_cleanup_restore_current_thread): Rename/convert to ...
13056 (scoped_restore_current_thread::scoped_restore_current_thread):
13057 ... this new ctor.
13058 (thread_apply_all_command): Use scoped_restore_current_thread.
13059 (thread_apply_command): Use scoped_restore_current_thread.
13060 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
13061 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
13062
f6223dbb
PA
130632017-05-04 Pedro Alves <palves@redhat.com>
13064
13065 * thread.c (make_cleanup_restore_current_thread): Move
13066 find_thread_ptid call before the is_stopped call. Assert that the
13067 thread is found. Replace is_stopped call by checking the thread's
13068 state directly. Remove unnecessary NULL-thread check.
13069
3c3ae77e
PA
130702017-05-04 Pedro Alves <palves@redhat.com>
13071
13072 * corelow.c (thread_section_name): New class.
13073 (get_core_register_section, get_core_siginfo): Use it.
13074
45eba0ab
AA
130752017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
13076
13077 * corelow.c (sniff_core_bfd): Remove extra semicolon.
13078 (get_core_register_section): Remove xfree of NULL pointer.
13079
f81fdd35
AH
130802017-05-03 Alan Hayward <alan.hayward@arm.com>
13081
13082 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
13083 * regcache.c (regcache::raw_supply_zeroed): New function.
13084 * regcache.h (regcache::raw_supply_zeroed): New declaration.
13085
35837774
SM
130862017-05-03 Simon Marchi <simon.marchi@ericsson.com>
13087
13088 * gdbarch.sh: Remove commented out definition of
13089 TARGET_CHAR_BIT.
13090 * gdbarch.h: Re-generate.
13091
c94fee56
SDJ
130922017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
13093
13094 * configure: Regenerate.
13095
d17f7b36
SM
130962017-05-02 Simon Marchi <simon.marchi@ericsson.com>
13097
13098 * solib-target.c (solib_target_relocate_section_addresses):
13099 Remove num_section_bases, num_bases, segment_bases variables.
13100
b560ebd6
SM
131012017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13102
13103 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
13104
f2f46dfc
SM
131052017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13106
13107 * solib-target.c: Include <vector>
13108 (struct lm_info_target) <~lm_info_target>: Remove.
13109 <segment_bases, section_bases>: Change type to
13110 std::vector<CORE_ADDR>.
13111 (library_list_start_segment, library_list_start_section,
13112 library_list_end_library,
13113 solib_target_relocate_section_addresses): Adjust.
13114
a0ff9e1a
SM
131152017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13116
13117 * gdbarch.sh (software_single_step): Change return type to
13118 std::vector<CORE_ADDR>.
13119 * gdbarch.c, gdbarch.h: Re-generate.
13120 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
13121 Adjust.
13122 (arm_deal_with_atomic_sequence_raw): Adjust.
13123 (thumb_get_next_pcs_raw): Adjust.
13124 (arm_get_next_pcs_raw): Adjust.
13125 (arm_get_next_pcs): Adjust.
13126 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
13127 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
13128 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
13129 (alpha_software_single_step): Adjust.
13130 * alpha-tdep.h (alpha_software_single_step): Adjust.
13131 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
13132 * arm-tdep.c (arm_software_single_step): Adjust.
13133 (arm_breakpoint_kind_from_current_state): Adjust.
13134 * arm-tdep.h (arm_software_single_step): Adjust.
13135 * breakpoint.c (insert_single_step_breakpoint): Adjust.
13136 * cris-tdep.c (cris_software_single_step): Adjust.
13137 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
13138 (micromips_deal_with_atomic_sequence): Adjust.
13139 (deal_with_atomic_sequence): Adjust.
13140 (mips_software_single_step): Adjust.
13141 * mips-tdep.h (mips_software_single_step): Adjust.
13142 * moxie-tdep.c (moxie_software_single_step): Adjust.
13143 * nios2-tdep.c (nios2_software_single_step): Adjust.
13144 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
13145 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
13146 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
13147 * s390-linux-tdep.c (s390_software_single_step): Adjust.
13148 * sparc-tdep.c (sparc_software_single_step): Adjust.
13149 * spu-tdep.c (spu_software_single_step): Adjust.
13150 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
13151
ea480a30
SM
131522017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13153
13154 * gdbarch.sh: Use semi-colon as field separator instead of colon.
13155 * gdbarch.h: Re-generate.
13156
d050f7d7
TW
131572017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13158
13159 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
13160 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
13161 * python/py-instruction.c, python/py-instruction.h: New file.
13162 * python/py-record.c: Add py-instruction.h include.
13163 (gdbpy_initialize_record): Make gdb.Instruction a super class of
13164 gdb.RecordInstruction.
13165 * python/python-internal.h: Add gdbpy_initialize_instruction
13166 declaration.
13167 * python/python.c (do_start_initialization): Add
13168 gdbpy_initialize_instruction.
13169
14f819c8
TW
131702017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13171
13172 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
13173 Remove.
13174 (btrace_func_from_recpy_func): New function.
13175 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
13176 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
13177 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
13178 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
13179 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
13180 Also, use new helper functions.
13181 (btpy_list_item): Use new helper functions.
13182 (recpy_bt_function_call_history): Use new type name.
13183 (btpy_call_getset): Remove.
13184 (gdbpy_initialize_btrace): Remove code to initialize
13185 gdb.BtraceFunctionCall.
13186 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
13187 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
13188 recpy_bt_func_prev, recpy_bt_func_next): New export.
13189 * python/py-record.c (recpy_func_type): New static object.
13190 (recpy_func_new, recpy_func_level, recpy_func_symbol,
13191 recpy_func_instructions, recpy_func_up, recpy_func_prev,
13192 recpy_func_next): New function.
13193 (recpy_element_hash, recpy_element_richcompare): Updated comment.
13194 (recpy_func_getset): New static object.
13195 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
13196 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
13197
0ed5da75
TW
131982017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13199
13200 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
13201 (btpy_object, btpy_insn_type, btpy_new): Remove.
13202 (btpy_list_object): Use gdb.RecordInstruction type instead of
13203 gdb.BtraceInstruction type.
13204 (btrace_insn_from_recpy_insn): New function.
13205 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
13206 btpy_new.
13207 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
13208 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
13209 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
13210 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
13211 instead of btpy_object.
13212 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13213 btpy_insn_data, btpy_insn_decode): Rename to ...
13214 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
13215 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
13216 recpy_bt_insn_decode): This. Also, use new helper functions.
13217 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
13218 recpy_insn_type.
13219 (btpy_insn_getset): Remove.
13220 (gdbpy_initialize_btrace): Remove code to initialize
13221 gdb.BtraceInstruction. Use recpy_element_object.
13222 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
13223 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
13224 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
13225 * python/py-record.c (recpy_insn_type): New static object.
13226 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
13227 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
13228 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
13229 New function.
13230 (recpy_insn_getset): New static object.
13231 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
13232 * python/py-record.h (recpy_element_object): New typedef.
13233 (recpy_insn_type, recpy_insn_new): New export.
13234
913aeadd
TW
132352017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13236
13237 * py-record-btrace.c (btpy_insn_new): Removed.
13238 (btpy_insn_or_gap_new): New function.
13239 (btpy_insn_error): Removed.
13240 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13241 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
13242 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
13243 btpy_insn_or_gap_new instead of btpy_insn_new.
13244 (btpy_insn_getset): Remove btpy_insn_error.
13245 * py-record.c (recpy_gap_type): New static object.
13246 (recpy_gap_object): New typedef.
13247 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
13248 recpy_gap_reason_string): New function.
13249 (recpy_gap_getset): New static object.
13250 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
13251 * py-record.h (recpy_gap_new): New export.
13252
a3be24ad
TW
132532017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13254
13255 * python/py-record.c (recpy_ptid): Remove.
13256 (recpy_record_getset): Remove recpy_ptid.
13257
ae20e79a
TW
132582017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13259
13260 * btrace.c (btrace_fetch): Set inferior_ptid.
13261 * python/py-record-btrace.c: Add "py-record.h" include.
13262 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
13263 recpy_bt_end, recpy_bt_instruction_history,
13264 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
13265 in gdb.Record object instead of current ptid.
13266 * python/py-record.c: Include new "py-record.h" file.
13267 (recpy_record_object): Moved to py-record.h.
13268 * python/py-record.h: New file.
13269
8d0050ea
TW
132702017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13271
13272 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
13273 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
13274 indentation.
13275
3f380b50
JB
132762017-05-01 Joel Brobecker <brobecker@adacore.com>
13277
13278 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
13279 the past maintainers section.
13280
07495424
YQ
132812017-04-28 Yao Qi <yao.qi@linaro.org>
13282
13283 * infcmd.c (get_return_value): Use regcache ctor, and remove
13284 cleanup.
13285
deb1fa3e
YQ
132862017-04-28 Yao Qi <yao.qi@linaro.org>
13287 Pedro Alves <palves@redhat.com>
13288
13289 * regcache.c (regcache::regcache): New tag dispatch ctor.
13290 (do_cooked_read): Moved above.
13291 (regcache_dup): Use the tag dispatch ctor..
13292 * regcache.h (regcache): Declare ctor, delete copy ctor and
13293 assignment operator, remove friend regcache_dup.
13294
b421c83c
YQ
132952017-04-28 Yao Qi <yao.qi@linaro.org>
13296
13297 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
13298 call method save instead of regcache_cpy.
13299 * regcache.h (struct regcache): Make regcache_dup a friend.
13300
ef79d9a3
YQ
133012017-04-28 Yao Qi <yao.qi@linaro.org>
13302
13303 * regcache.c (struct regcache): Move to regcache.h
13304 (regcache::arch): New method.
13305 (regcache_get_ptid): Update.
13306 (get_regcache_arch): Call arch method.
13307 (get_regcache_aspace): Call method aspace.
13308 (register_buffer): Change it to method.
13309 (regcache_save): Change it to regcache::save.
13310 (regcache_restore): Likewise.
13311 (regcache_cpy_no_passthrough): Remove the declaration.
13312 (regcache_cpy): Call methods restore and cpy_no_passthrough.
13313 (regcache_cpy_no_passthrough): Change it to method
13314 cpy_no_passthrough.
13315 (regcache_register_status): Change it to method
13316 get_register_status.
13317 (regcache_invalidate): Change it to method invalidate.
13318 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
13319 (regcache_raw_update): Change it to method raw_update.
13320 (regcache_raw_read): Likewise.
13321 (regcache_raw_read_signed): Likewise.
13322 (regcache_raw_read_unsigned): Likewise.
13323 (regcache_raw_write_signed): Likewise.
13324 (regcache_raw_write_unsigned): Likewise.
13325 (regcache_cooked_read): Likewise.
13326 (regcache_cooked_read_value): Likewise.
13327 (regcache_cooked_read_signed): Likewise.
13328 (regcache_cooked_read_unsigned): Likewise.
13329 (regcache_cooked_write_signed): Likewise.
13330 (regcache_cooked_write_unsigned): Likewise.
13331 (regcache_raw_set_cached_value): Likewise.
13332 (regcache_raw_write): Likewise.
13333 (regcache_cooked_write): Likewise.
13334 (regcache_xfer_part): Likewise.
13335 (regcache_raw_read_part): Likewise.
13336 (regcache_raw_write_part): Likewise.
13337 (regcache_cooked_read_part): Likewise.
13338 (regcache_cooked_write_part): Likewise.
13339 (regcache_raw_supply): Likewise.
13340 (regcache_raw_collect): Likewise.
13341 (regcache_transfer_regset): Likewise.
13342 (regcache_supply_regset): Likewise.
13343 (regcache_collect_regset): Likewise.
13344 (regcache_debug_print_register): Likewise.
13345 (enum regcache_dump_what): Move it to regcache.h.
13346 (regcache_dump): Change it to method dump.
13347 * regcache.h (enum regcache_dump_what): New.
13348 (class regcache): New.
13349 * target.c (target_fetch_registers): Call method
13350 debug_print_register.
13351 (target_store_registers): Likewise.
13352
f8fdb78e
SM
133532017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13354
13355 * windows-nat.c (struct lm_info_windows): Initialize field.
13356 (windows_make_so): Allocate lm_info_windows with new.
13357 (windows_free_so): Free lm_info_windows with delete.
13358
9ccbfd7b
SM
133592017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13360
13361 * solib-darwin.c (struct lm_info_darwin): Initialize field.
13362 (darwin_current_sos): Allocate lm_info_darwin with new, remove
13363 cleanup.
13364 (darwin_free_so): Free lm_info_darwin with delete.
13365
76e75227
SM
133662017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13367
13368 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
13369 <l_addr_p>: Change type to bool.
13370 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
13371 (svr4_free_so): Free lm_info_svr4 with delete.
13372 (svr4_copy_library_list): Replace memcpy with call to copy
13373 constructor.
13374 (library_list_start_library, svr4_default_sos): Allocate
13375 lm_info_svr4 with new.
13376
51046d9e
SM
133772017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13378
13379 * solib-target.c (struct lm_info_target): Add destructor,
13380 initialize fields.
13381 <name>: Change type to std::string.
13382 (library_list_start_library): Allocate lm_info_target with new.
13383 (solib_target_free_library_list): Free lm_info_target with
13384 delete.
13385 (solib_target_current_sos): Adapt to std::string.
13386 (solib_target_free_so): Free lm_info_target with delete.
13387
4023ae76
SM
133882017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13389
13390 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
13391 fields.
13392 (frv_current_sos): Allocate lm_info_frv with new.
13393 (frv_relocate_main_executable): Free lm_info_frv with delete,
13394 allocate with new.
13395 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
13396
af43057b
SM
133972017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13398
13399 * solib-frv.c (struct lm_info_frv): Fix indentation.
13400
b0911207
SM
134012017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13402
13403 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
13404 map field.
13405 (dsbt_current_sos): Allocate lm_info_dsbt with new.
13406 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
13407 and allocate with new.
13408 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
13409
6c401f72
SM
134102017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13411
13412 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
13413 <filename, member_name>: Change type to std::string.
13414 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
13415 (library_list_start_library): Allocate lm_info_aix with new.
13416 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
13417 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
13418 with copy constructor.
13419
d0e449a1
SM
134202017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13421
13422 * solist.h (struct lm_info): Remove.
13423 (struct lm_info_base): New class.
13424 (struct so_list) <lm_info>: Change type to lm_info_base *.
13425 * nto-tdep.c (struct lm_info): Remove.
13426 (lm_addr): Adjust.
13427 * solib-aix.c (struct lm_info): Rename to ...
13428 (struct lm_info_aix): ... this. Extend lm_info_base.
13429 (lm_info_p): Rename to ...
13430 (lm_info_aix_p): ... this, and adjust.
13431 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
13432 solib_aix_parse_libraries, library_list_start_library,
13433 solib_aix_free_library_list, solib_aix_parse_libraries,
13434 solib_aix_get_library_list,
13435 solib_aix_relocate_section_addresses, solib_aix_free_so,
13436 solib_aix_get_section_offsets,
13437 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
13438 Adjust.
13439 (struct solib_aix_inferior_data) <library_list>: Adjust.
13440 * solib-darwin.c (struct lm_info): Rename to ...
13441 (struct lm_info_darwin): ... this. Extend lm_info_base.
13442 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
13443 * solib-dsbt.c (struct lm_info): Rename to ...
13444 (struct lm_info_dsbt): ... this. Extend lm_info_base.
13445 (struct dsbt_info) <main_executable_lm_info): Adjust.
13446 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
13447 dsbt_relocate_section_addresses): Adjust.
13448 * solib-frv.c (struct lm_info): Rename to ...
13449 (struct lm_info_frv): ... this. Extend lm_info_base.
13450 (main_executable_lm_info): Adjust.
13451 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
13452 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
13453 find_canonical_descriptor_in_load_object,
13454 frv_fdpic_find_canonical_descriptor): Adjust.
13455 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
13456 to lm_info_svr4.
13457 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
13458 svr4_clear_so, svr4_copy_library_list,
13459 library_list_start_library, svr4_default_sos, svr4_read_so_list,
13460 svr4_current_sos, svr4_fetch_objfile_link_map,
13461 solist_update_incremental): Adjust.
13462 * solib-svr4.h (struct lm_info_svr4): Move here from
13463 solib-svr4.c.
13464 * solib-target.c (struct lm_info): Rename to ...
13465 (struct lm_info_target): ... this. Extend lm_info_base.
13466 (lm_info_p): Rename to ...
13467 (lm_info_target_p): ... this.
13468 (solib_target_parse_libraries, library_list_start_segment,
13469 library_list_start_section, library_list_start_library,
13470 library_list_end_library, solib_target_free_library_list,
13471 solib_target_current_sos, solib_target_free_so,
13472 solib_target_relocate_section_addresses): Adjust.
13473 * windows-nat.c (struct lm_info): Rename to ...
13474 (struct lm_info_windows): ... this. Extend lm_info_base.
13475 (windows_make_so, handle_load_dll, handle_unload_dll,
13476 windows_xfer_shared_libraries): Adjust.
13477
434a4023
SM
134782017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13479
13480 * solib-darwin.c (struct darwin_so_list): Remove.
13481 (darwin_current_sos): Allocate an so_list object instead of a
13482 darwin_so_list, separately allocate an lm_info object.
13483 (darwin_free_so): Free lm_info.
13484
428544e8
JB
134852017-04-28 John Baldwin <jhb@FreeBSD.org>
13486
13487 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13488 with fprintf_filtered.
13489
4621115f
YQ
134902017-04-28 Yao Qi <yao.qi@linaro.org>
13491
13492 * regcache.c (regcache::regcache): New function.
13493 (regcache::~regcache): New function.
13494 (regcache_xmalloc_1): Remove.
13495 (regcache_xmalloc): Call new regcache.
13496 (regcache_xfree): Call delete regcache.
13497 (get_thread_arch_aspace_regcache): Call new regcache.
13498
339053c2
YQ
134992017-04-28 Yao Qi <yao.qi@linaro.org>
13500
13501 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13502 lwp instead of ptid_get_lwp.
13503
7974a605
YQ
135042017-04-28 Yao Qi <yao.qi@linaro.org>
13505
13506 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13507 lwp_info instead of getting from inferior_ptid.
13508
e15c3eb4
KS
135092017-04-27 Keith Seitz <keiths@redhat.com>
13510
13511 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13512 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13513 (CV_CONVERSION_BADNESS): Define.
13514 (rank_one_type): Remove overly restrictive rvalue reference
13515 rank checks.
13516 Add cv-qualifier checks and subranks for type equality.
13517 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13518 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13519 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13520
72bc1d24
SM
135212017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13522
13523 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13524 count when creating the object.
13525
55bcecda
UW
135262017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13527 Ulrich Weigand <uweigand@de.ibm.com>
13528
13529 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13530 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13531 is used in AIX.
13532 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13533 (process_xcoff_symbol): Likewise.
13534 (scan_xcoff_symtab): Likewise.
13535
5c99fcf8
AH
135362017-04-26 Alan Hayward <alan.hayward@arm.com>
13537
13538 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13539 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13540 (ia64_access_reg): Use get_frame_register_unsigned.
13541 (ia64_access_rse_reg): Likewise.
13542 (ia64_libunwind_frame_prev_register): Likewise.
13543
b41c5a85
JW
135442017-04-26 Jiong Wang <jiong.wang@arm.com>
13545
13546 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13547 * gdbarch.c: Regenerated.
13548 * gdbarch.h: Regenerated.
13549 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13550 visibility external.
13551 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13552 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13553 (enum cfa_how_kind): Move to ...
13554 (struct dwarf2_frame_state_reg_info): Likewise.
13555 (struct dwarf2_frame_state): Likewise.
13556 * dwarf2-frame.h: ... here.
13557 (dwarf2_frame_state_alloc_regs): New declaration.
13558 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13559 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13560
c185f580
AH
135612017-04-26 Alan Hayward <alan.hayward@arm.com>
13562
13563 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13564 regcache_raw_read_unsigned.
13565 (xtensa_pseudo_register_write): Likewise.
13566
19c45594
AH
135672017-04-26 Alan Hayward <alan.hayward@arm.com>
13568
13569 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13570 (nds32_pseudo_register_write): Likewise.
13571
4658f12e
YQ
135722017-04-25 Yao Qi <yao.qi@linaro.org>
13573
13574 * regcache.c (struct regcache) <readonly_p>: Change its type
13575 to bool.
13576 (regcache_xmalloc_1): Update parameter type and callers update.
13577
d581dda8
YQ
135782017-04-25 Yao Qi <yao.qi@linaro.org>
13579
13580 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13581 set_gdbarch_wchar_bit.
13582 * arm-tdep.c (arm_gdbarch_init): Likewise.
13583
debed3db
PA
135842017-04-25 Pedro Alves <palves@redhat.com>
13585
13586 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13587 (BothAreRelocatable, memcopy, memmove): Don't define.
13588 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13589 macros.
13590
b0b92aeb
PA
135912017-04-25 Pedro Alves <palves@redhat.com>
13592
13593 * common/common-defs.h: Include "common/poison.h".
13594 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13595 and adjust.
13596 * common/poison.h: New file.
13597 * common/traits.h: Include <type_traits>.
13598 (Not, Or, Requires): New, moved from common/function-view.h.
13599
16c4d54a
PA
136002017-04-25 Pedro Alves <palves@redhat.com>
13601
13602 * breakpoint.h (struct breakpoint): In-class initialize all
13603 fields. Make boolean fields "bool".
13604 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13605 memset call and initializations no longer necessary.
13606
b5c36682
PA
136072017-04-25 Pedro Alves <palves@redhat.com>
13608
13609 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13610 reference.
13611 (pt_btrace_insn): New function.
13612 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13613
5625a286
PA
136142017-04-25 Pedro Alves <palves@redhat.com>
13615
13616 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13617 "base" field and inherit from "bp_location" instead. Add
13618 non-default ctor.
13619 (allocate_location_exception): Use new non-default ctor.
13620 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13621 (init_bp_location): Convert to ...
13622 (bp_location::bp_location): ... this new ctor, and remove memset
13623 call.
13624 (base_breakpoint_allocate_location): Use the new non-default ctor.
13625 * breakpoint.h (bp_location): Now a class. Declare default and
13626 non-default ctors. In-class initialize all members.
13627 (init_bp_location): Remove declaration.
13628
23bcc18f
PA
136292017-04-25 Pedro Alves <palves@redhat.com>
13630
13631 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13632 assignment operator.
13633
e1ba3053
YQ
136342017-04-24 Yao Qi <yao.qi@linaro.org>
13635
13636 * doublest.c (convert_doublest_to_floatformat): Call
13637 floatformat_totalsize_bytes.
13638
10f489e5
TT
136392017-04-22 Tom Tromey <tom@tromey.com>
13640
13641 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13642 ui_out_emit_list.
13643 * stack.c (print_frame): Use ui_out_emit_list.
13644 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13645 ui_out_emit_list.
13646 * mi/mi-main.c (print_one_inferior)
13647 (mi_cmd_data_list_register_names)
13648 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13649 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13650 ui_out_emit_list.
13651 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13652 (mi_output_solib_attribs): Use ui_out_emit_list,
13653 ui_out_emit_tuple.
13654 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13655 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13656 (mi_cmd_stack_list_args, list_args_or_locals): Use
13657 ui_out_emit_list.
13658 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13659 * breakpoint.c (print_solib_event, output_thread_groups): Use
13660 ui_out_emit_list.
13661
0092b74d
TT
136622017-04-22 Tom Tromey <tom@tromey.com>
13663
13664 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13665 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13666 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13667
a14a62dd
TT
136682017-04-22 Tom Tromey <tom@tromey.com>
13669
13670 * tracepoint.c (tvariables_info_1)
13671 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13672
46b9c129
TT
136732017-04-22 Tom Tromey <tom@tromey.com>
13674
13675 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13676 annotate_arg_emitter.
13677 * breakpoint.c (print_mention_watchpoint)
13678 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13679 * annotate.h (struct annotate_arg_emitter): New.
13680
2e783024
TT
136812017-04-22 Tom Tromey <tom@tromey.com>
13682
13683 * record-btrace.c (record_btrace_insn_history)
13684 (record_btrace_insn_history_range, record_btrace_call_history)
13685 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13686 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13687 ui_out_emit_tuple.
13688 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13689 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13690 * skip.c (skip_info): Use ui_out_emit_tuple.
13691 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13692 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13693 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13694 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13695 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13696 ui_out_emit_tuple.
13697 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13698 (output_register, mi_cmd_data_read_memory)
13699 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13700 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13701 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13702 Use ui_out_emit_tuple.
13703 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13704 ui_out_emit_tuple.
13705 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13706 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13707 * linux-thread-db.c (info_auto_load_libthread_db): Use
13708 ui_out_emit_tuple.
13709 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13710 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13711 * disasm.c (do_mixed_source_and_assembly_deprecated)
13712 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13713 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13714 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13715 * breakpoint.c (print_one_breakpoint_location)
13716 (print_one_breakpoint): Use ui_out_emit_tuple.
13717 * auto-load.c (print_script, info_auto_load_cmd): Use
13718 ui_out_emit_tuple.
13719 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13720
9be21bb4
SM
137212017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13722
13723 * thread.c (print_thread_info_1): Remove dead code.
13724
0d4c07af
JK
137252017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13726
13727 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13728 GDB_SELF_TEST.
13729 * arm-tdep.c (selftests::arm_record_test): Likewise.
13730
4daf993d
YQ
137312017-04-21 Yao Qi <yao.qi@linaro.org>
13732
13733 * regcache.c (regcache_restore): Remove argument 2. Replace
13734 argument 3 with regcache. Get register status from
13735 src->register_status and get register contents from
13736 register_buffer (src, regnum).
13737 (regcache_cpy): Update.
13738
a6c21d4a
PA
137392017-04-19 Pedro Alves <palves@redhat.com>
13740
13741 * gdbthread.h (thread): Add missing closing parenthesis in
13742 comment.
13743
3a3fd0fd
PA
137442017-04-19 Pedro Alves <palves@redhat.com>
13745
13746 * common/refcounted-object.h: New file.
13747 * gdbthread.h: Include "common/refcounted-object.h".
13748 (thread_info): Inherit from refcounted_object and add comments.
13749 (thread_info::incref, thread_info::decref)
13750 (thread_info::m_refcount): Delete.
13751 (thread_info::deletable): Use the refcounted_object::refcount()
13752 method.
13753 * inferior.c (current_inferior_): Add comment.
13754 (set_current_inferior): Increment/decrement refcounts.
13755 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13756 not-deletable instead of comparing with the current inferior.
13757 (initialize_inferiors): Increment the initial inferior's refcount.
13758 * inferior.h (struct inferior): Forward declare.
13759 Include "common/refcounted-object.h".
13760 (current_inferior, set_current_inferior): Move declaration to
13761 before struct inferior's definition, and fix comment.
13762 (inferior): Inherit from refcounted_object. Add comments.
13763 * thread.c (switch_to_thread_no_regs): Reference the thread's
13764 inferior pointer directly instead of doing a ptid lookup.
13765 (switch_to_no_thread): New function.
13766 (switch_to_thread(thread_info *)): New function, factored out
13767 from ...
13768 (switch_to_thread(ptid_t)): ... this.
13769 (restore_current_thread): Delete.
13770 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13771 fields, and add 'inf' field.
13772 (do_restore_current_thread_cleanup): Check whether old->inf is
13773 alive instead of looking up an inferior by ptid. Use
13774 switch_to_thread and switch_to_no_thread.
13775 (restore_current_thread_cleanup_dtor): Use old->inf directly
13776 instead of lookup up an inferior by id. Decref the inferior.
13777 Don't restore 'removable'.
13778 (make_cleanup_restore_current_thread): Same the inferior pointer
13779 in old, instead of the inferior number. Incref the inferior.
13780 Don't save/clear 'removable'.
13781
9bcb1f16
PA
137822017-04-19 Pedro Alves <palves@redhat.com>
13783
13784 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13785 unittests/scoped_restore-selftests.c.
13786 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13787 * common/scoped_restore.h (scoped_restore_base): Make "class".
13788 (scoped_restore_base::release): New public method.
13789 (scoped_restore_base::scoped_restore_base): New protected ctor.
13790 (scoped_restore_base::m_saved_var): New protected field.
13791 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13792 scoped_restore_base base class instead of m_saved_var directly.
13793 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13794 (scoped_restore_tmpl::scoped_restore_tmpl(const
13795 scoped_restore_tmpl<T>&)): Likewise.
13796 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13797 method.
13798 (scoped_restore_tmpl::saved_var): New method.
13799 (scoped_restore_tmpl::m_saved_var): Delete.
13800 * inferior.h (inferior::detaching): Now a bool.
13801 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13802 cleanup.
13803 * unittests/scoped_restore-selftests.c: New file.
13804
26fcd539
PA
138052017-04-19 Pedro Alves <palves@redhat.com>
13806
13807 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13808 Re-sort in alphabetic order.
13809
fdd243b0
PA
138102017-04-18 Pedro Alves <palves@redhat.com>
13811
13812 * xml-support.c (obstack_xml_printf): Delete.
13813 * xml-support.h (obstack_xml_printf): Delete.
13814
4895cde2
PA
138152017-04-18 Pedro Alves <palves@redhat.com>
13816
13817 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13818 vdebug, verror, body_text, start_element, end_element, name,
13819 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13820 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13821 is_xinclude>: Make private and add m_ prefix.
13822 (gdb_xml_parser::body_text): New method, based on ...
13823 (gdb_xml_body_text): ... this. Adjust.
13824 (gdb_xml_parser::vdebug): New method, based on ...
13825 (gdb_xml_debug): ... this. Adjust.
13826 (gdb_xml_parser::verror): New method, based on ...
13827 (gdb_xml_error): ... this. Adjust.
13828 (gdb_xml_parser::start_element): New method, based on ...
13829 (gdb_xml_start_element): ... this. Adjust.
13830 (gdb_xml_start_element_wrapper): Defer to
13831 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
13832 (gdb_xml_parser::end_element): New method, based on ...
13833 (gdb_xml_end_element_wrapper): ... this. Adjust.
13834 (gdb_xml_parser::~gdb_xml_parser): Adjust.
13835 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
13836 (gdb_xml_parser::use_dtd): New method, based on ...
13837 (gdb_xml_use_dtd): ... this. Adjust.
13838 (gdb_xml_parser::parse): New method, based on ...
13839 (gdb_xml_parse): ... this. Adjust.
13840 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
13841 (xinclude_start_include): Adjust to call the parser's name method.
13842 (xml_xinclude_default, xml_xinclude_start_doctype)
13843 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
13844 method.
13845 (xml_process_xincludes): Adjust to call parser methods.
13846 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
13847 declarations.
13848
bd8a901f
PA
138492017-04-18 Pedro Alves <palves@redhat.com>
13850
13851 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
13852 gdb::optional<std::string>.
13853 * xml-support.c: Include <string>.
13854 (scope_level::scope_level(scope_level &&))
13855 (scope_level::~scope_level): Delete.
13856 (scope_level::body): Now a std::string.
13857 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
13858 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
13859 parameter.
13860 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
13861 (xinclude_parsing_data::output): Now a std::string reference.
13862 (xinclude_start_include): Adjust.
13863 (xml_xinclude_default): Adjust.
13864 (xml_process_xincludes): Add 'output' parameter, and return bool.
13865 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
13866 and return bool.
13867 * xml-tdesc.c: Include <unordered_map> and <string>.
13868 (tdesc_xml_cache): Delete.
13869 (tdesc_xml_cache_s): Delete.
13870 (xml_cache): Now an std::unordered_map.
13871 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
13872 (target_fetch_description_xml): Change return type to
13873 gdb::optional<std::string>, and adjust.
13874 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
13875 (target_fetch_description_xml): Change return type to
13876 gdb::optional<std::string>.
13877
d35d1958
PA
138782017-04-18 Pedro Alves <palves@redhat.com>
13879
13880 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13881 unittests/optional-selftests.c.
13882 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
13883 * unittests/optional-selftests.c: New file.
13884 * unittests/optional/assignment/1.cc: New file.
13885 * unittests/optional/assignment/2.cc: New file.
13886 * unittests/optional/assignment/3.cc: New file.
13887 * unittests/optional/assignment/4.cc: New file.
13888 * unittests/optional/assignment/5.cc: New file.
13889 * unittests/optional/assignment/6.cc: New file.
13890 * unittests/optional/assignment/7.cc: New file.
13891 * unittests/optional/cons/copy.cc: New file.
13892 * unittests/optional/cons/default.cc: New file.
13893 * unittests/optional/cons/move.cc: New file.
13894 * unittests/optional/cons/value.cc: New file.
13895 * unittests/optional/in_place.cc: New file.
13896 * unittests/optional/observers/1.cc: New file.
13897 * unittests/optional/observers/2.cc: New file.
13898
22796e97
PA
138992017-04-18 Pedro Alves <palves@redhat.com>
13900
13901 * common/gdb_optional.h: Include common/traits.h.
13902 (in_place_t): New type.
13903 (in_place): New constexpr variable.
13904 (optional::optional): Remove member initialization of
13905 m_instantiated.
13906 (optional::optional(in_place_t...)): New constructor.
13907 (optional::~optional): Use reset.
13908 (optional::optional(const optional&)): New.
13909 (optional::optional(const optional&&)): New.
13910 (optional::optional(T &)): New.
13911 (optional::optional(T &&)): New.
13912 (operator::operator=(const optional &)): New.
13913 (operator::operator=(optional &&)): New.
13914 (operator::operator= (const T &))
13915 (operator::operator= (T &&))
13916 (operator::emplace (Args &&... args)): Return a T&. Use reset.
13917 (operator::reset): New.
13918 (operator::m_instantiated):: Add in-class initializer.
13919 * common/traits.h: Include <type_traits>.
13920 (struct And): New types.
13921
a7fc9b61
PA
139222017-04-18 Pedro Alves <palves@redhat.com>
13923
13924 * xml-support.c: Include <vector>.
13925 (scope_level::scope_level(const gdb_xml_element *))
13926 (scope_level::scope_level(scope_level&&)): New.
13927 (scope_level::~scope_level): New.
13928 (scope_level_s): Delete.
13929 (gdb_xml_parser::scopes): Now a std::vector.
13930 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
13931 Use std::vector.
13932 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
13933 scope cleanup code.
13934 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
13935 of the scopes member. Use std::vector::emplace_back.
13936
010151c9
PA
139372017-04-18 Pedro Alves <palves@redhat.com>
13938
13939 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
13940 a bool.
13941 (gdb_xml_end_element): Change type of first parameter.
13942 (gdb_xml_cleanup): Rename to ...
13943 (gdb_xml_parser::~gdb_xml_parser): ... this.
13944 (gdb_xml_create_parser_and_cleanup): Delete with ...
13945 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
13946 to this new ctor.
13947 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
13948 using gdb_xml_create_parser_and_cleanup.
13949 (xinclude_parsing_data): Add ctor/dtor.
13950 (xml_xinclude_cleanup): Delete.
13951 (xml_process_xincludes): Create a local xinclude_parsing_data
13952 instead of heap-allocating one. Create a local gdb_xml_parser
13953 instead of heap-allocating one with
13954 gdb_xml_create_parser_and_cleanup.
13955
d56060f0
JB
139562017-04-18 John Baldwin <jhb@FreeBSD.org>
13957
13958 PR threads/20743
13959 * fbsd-nat.c (resume_one_thread_cb): Remove.
13960 (resume_all_threads_cb): Remove.
13961 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
13962 iterate_over_threads.
13963
305d16a9
JB
139642017-04-17 Joel Brobecker <brobecker@adacore.com>
13965
13966 * NEWS: Create a new section for the next release branch.
13967 Rename the section of the current branch, now that it has
13968 been cut.
13969
8bb57231
JB
139702017-04-17 Joel Brobecker <brobecker@adacore.com>
13971
13972 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
13973 * version.in: Bump version to 8.0.50.DATE-git.
13974
096c92dd
SDJ
139752017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
13976
13977 PR gdb/21385
13978 * windows-nat.c (windows_create_inferior): Declare 'allargs'
13979 independently of the host, and fix build breakage on Cygwin.
13980
0550c955
PA
139812017-04-13 Pedro Alves <palves@redhat.com>
13982
13983 * inferior.c (free_inferior): Convert to ...
13984 (inferior::~inferior): ... this dtor.
13985 (inferior::inferior): New ctor, factored out from ...
13986 (add_inferior_silent): ... here. Allocate the inferior with a new
13987 expression.
13988 (delete_inferior): Call delete instead of free_inferior.
13989 * inferior.h (gdb_environ, continuation): Forward declare.
13990 (inferior): Now a class. Add in-class initialization to all
13991 members. Make boolean fields bool, except 'detaching'.
13992 (inferior::inferior): New explicit ctor.
13993 (inferior::~inferior): New.
13994
e3d60dfc
PA
139952017-04-13 Pedro Alves <palves@redhat.com>
13996
13997 * inferior.c (init_inferior_list): Delete.
13998 * inferior.h (init_inferior_list): Delete.
13999
5fd69d0a
PA
140002017-04-13 Pedro Alves <palves@redhat.com>
14001
14002 PR threads/13217
14003 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
14004 (top level): Call it twice, with different thread sets.
14005
c6609450
PA
140062017-04-13 Pedro Alves <palves@redhat.com>
14007
14008 * thread.c: Include <algorithm>.
14009 (thread_array_cleanup): Delete.
14010 (scoped_inc_dec_ref): New class.
14011 (live_threads_count): New function.
14012 (set_thread_refcount): Delete.
14013 (tp_array_compar_ascending): Now a bool.
14014 (tp_array_compar): Convert to a std::sort comparison function.
14015 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
14016 and live_threads_count.
14017
2a00d7ce
PA
140182017-04-13 Pedro Alves <palves@redhat.com>
14019
14020 * infrun.c (follow_fork_inferior): Also switch the current
14021 inferior.
14022
441d7c93
PA
140232017-04-13 Pedro Alves <palves@redhat.com>
14024
14025 * breakpoint.c (watch_command_1): Save watchpoint-frame info
14026 before calling create_internal_breakpoint.
14027
808480f6
PA
140282017-04-13 Pedro Alves <palves@redhat.com>
14029
14030 * fork-child.c (execv_argv): New class.
14031 (breakup_args): Refactored as ...
14032 (execv_argv::init_for_no_shell): .. this method of execv_argv.
14033 Copy arguments to storage and replace separators with NULL
14034 terminators in place.
14035 (escape_bang_in_quoted_argument): Adjust to return bool.
14036 (execv_argv::execv_argv): New ctor.
14037 (execv_argv::init_for_shell): New method, factored out from
14038 fork_inferior. Don't strdup strings into the vector.
14039 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
14040 Remove free_vector_argv call.
14041
ad3d022a
YQ
140422017-04-13 Yao Qi <yao.qi@linaro.org>
14043
14044 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
14045 tdep->rx_psw_type.
14046
e6ddc3bf
YQ
140472017-04-13 Yao Qi <yao.qi@linaro.org>
14048
14049 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
14050 * rx-tdep.c (rx_gdbarch_init): Likewise.
14051
bfb8cf90
PA
140522017-04-13 Pedro Alves <palves@redhat.com>
14053
14054 * breakpoint.h (struct breakpoint): Reindent.
14055
f5336ca5
PA
140562017-04-13 Pedro Alves <palves@redhat.com>
14057
14058 * breakpoint.c (bp_location): Rename to ...
14059 (bp_locations): ... this. All references updated.
14060 (bp_location_count): Rename to ...
14061 (bp_locations_count): ... this. All references updated.
14062 (bp_location_placed_address_before_address_max): Rename to ...
14063 (bp_locations_placed_address_before_address_max): ... this. All
14064 references updated.
14065 (bp_location_shadow_len_after_address_max): Rename to ...
14066 (bp_locations_shadow_len_after_address_max): ... this. All
14067 references updated.
14068 (bp_location_compare_addrs): Rename to ...
14069 (bp_locations_compare_addrs): ... this. All references updated.
14070 (bp_location_compare):Rename to ...
14071 (bp_locations_compare): ... this. All references updated.
14072 (bp_location_target_extensions_update): Rename to ...
14073 (bp_locations_target_extensions_update): ... this. All references
14074 updated.
14075
be628ab8
SDJ
140762017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14077
14078 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
14079 * common/common.m4: Check headers 'termios.h', 'termio.h' and
14080 'sgtty.h'.
14081 * common/gdb_termios.h: New file, with parts of "terminal.h".
14082 * inflow.c: Include "gdb_termios.h".
14083 * ser-unix.c: Include "gdb_termios.h".
14084 * terminal.h: Move terminal-related defines to
14085 "common/gdb_termios.h".
14086
8e9e35b1
TT
140872017-04-12 Tom Tromey <tom@tromey.com>
14088
14089 * probe.c (parse_probes): Update.
14090 * location.h (delete_event_location): Don't declare.
14091 (event_location_deleter::operator()): Update.
14092 * location.c (event_location_deleter::operator()): Rename from
14093 delete_event_location.
14094 * linespec.h (linespec_result) <location>: Change type to
14095 event_location_up.
14096 * linespec.c (canonicalize_linespec, event_location_to_sals)
14097 (decode_objc): Update.
14098 (linespec_result): Don't call delete_event_location.
14099 * breakpoint.c (create_breakpoints_sal)
14100 (bkpt_probe_create_sals_from_location)
14101 (strace_marker_create_sals_from_location): Update.
14102
16e802b9
TT
141032017-04-12 Tom Tromey <tom@tromey.com>
14104
14105 * linespec.h (struct linespec_result): Add constructor and
14106 destructor.
14107 (init_linespec_result, destroy_linespec_result)
14108 (make_cleanup_destroy_linespec_result): Don't declare.
14109 * linespec.c (init_linespec_result): Remove.
14110 (linespec_result::~linespec_result): Rename from
14111 destroy_linespec_result. Update.
14112 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
14113 Remove.
14114 * breakpoint.c (create_breakpoint, break_range_command)
14115 (decode_location_default): Update.
14116 * ax-gdb.c (agent_command_1): Update.
14117
d28cd78a
TT
141182017-04-12 Tom Tromey <tom@tromey.com>
14119
14120 * remote.c (remote_download_tracepoint): Update.
14121 * python/py-breakpoint.c (bppy_get_location): Update.
14122 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
14123 (gdbscm_breakpoint_location): Update.
14124 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
14125 * breakpoint.h (struct breakpoint) <location, location_range_end>:
14126 Change type to event_location_up.
14127 * breakpoint.c (create_overlay_event_breakpoint)
14128 (create_longjmp_master_breakpoint)
14129 (create_std_terminate_master_breakpoint)
14130 (create_exception_master_breakpoint)
14131 (breakpoint_event_location_empty_p, print_breakpoint_location)
14132 (print_one_breakpoint_location, create_thread_event_breakpoint)
14133 (init_breakpoint_sal, create_breakpoint)
14134 (print_recreate_ranged_breakpoint, break_range_command)
14135 (init_ada_exception_breakpoint, say_where): Update.
14136 (base_breakpoint_dtor): Don't call delete_event_location.
14137 (bkpt_print_recreate, tracepoint_print_recreate)
14138 (dprintf_print_recreate, update_static_tracepoint)
14139 (breakpoint_re_set_default): Update.
14140
711799d5
TT
141412017-04-12 Tom Tromey <tom@tromey.com>
14142
14143 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
14144 type of "to_do". Update.
14145 (compute_stack_depth): Use std::vector.
14146
52d214d3
TT
141472017-04-12 Tom Tromey <tom@tromey.com>
14148
14149 * printcmd.c (find_instruction_backward): Use std::vector.
14150
4c404b8b
TT
141512017-04-12 Tom Tromey <tom@tromey.com>
14152
14153 * symfile.c (objfilep): Remove typedef.
14154 (reread_symbols): Use a std::vector.
14155
156d9eab
TT
141562017-04-12 Tom Tromey <tom@tromey.com>
14157
14158 * mi/mi-main.c (exec_direction_forward): Remove.
14159 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
14160 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
14161 scoped_restore.
14162 * guile/guile.c (guile_repl_command, guile_command)
14163 (gdbscm_execute_gdb_command): Use scoped_restore.
14164 * go-exp.y (go_parse): Use scoped_restore.
14165 * d-exp.y (d_parse): Use scoped_restore.
14166 * cli/cli-decode.c (cmd_func): Use scoped_restore.
14167 * c-exp.y (c_parse): Use scoped_restore.
14168
4d89769a
TT
141692017-04-12 Tom Tromey <tom@tromey.com>
14170
14171 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
14172 (mi_parse): Update return type.
14173 (mi_parse_free): Remove.
14174 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
14175 (mi_parse::~mi_parse): Rename from mi_parse_free.
14176 (mi_parse_cleanup): Remove.
14177 (mi_parse): Return a unique_ptr. Use new.
14178 * mi/mi-main.c (mi_execute_command): Update.
14179
4b217cc7
TT
141802017-04-12 Tom Tromey <tom@tromey.com>
14181
14182 * location.c (explicit_location_lex_one): Return a
14183 unique_xmalloc_ptr.
14184 (string_to_explicit_location): Update. Remove cleanups.
14185
59d3651b
TT
141862017-04-12 Tom Tromey <tom@tromey.com>
14187
14188 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
14189 (compare_value_and_voffset): Change type. Update.
14190 (compute_vtable_size): Change type of "offset_vec".
14191 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
14192 (gnuv3_get_typeid): Remove extraneous declaration.
14193
b24b0d6c
TT
141942017-04-12 Tom Tromey <tom@tromey.com>
14195
14196 * charset.h (wchar_iterator): Fix comment.
14197
80a3b8c5
TT
141982017-04-12 Tom Tromey <tom@tromey.com>
14199
14200 * charset.c (iconv_wrapper): New class.
14201 (cleanup_iconv): Remove.
14202 (convert_between_encodings): Use it.
14203
c83dd867
TT
142042017-04-12 Tom Tromey <tom@tromey.com>
14205
14206 * symfile.h (increment_reading_symtab): Update type.
14207 * symfile.c (decrement_reading_symtab): Remove.
14208 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
14209 * psymtab.c (psymtab_to_symtab): Update.
14210 * dwarf2read.c (dw2_instantiate_symtab): Update.
14211
0e8621a0
TT
142122017-04-12 Tom Tromey <tom@tromey.com>
14213
14214 * jit.c (struct jit_reader): Declare separately. Add constructor
14215 and destructor. Change type of "handle".
14216 (loaded_jit_reader): Define separately.
14217 (jit_reader_load): Update. New "new".
14218 (jit_reader_unload_command): Use "delete".
14219 * gdb-dlfcn.h (struct dlclose_deleter): New.
14220 (gdb_dlhandle_up): New typedef.
14221 (gdb_dlopen, gdb_dlsym): Update types.
14222 (gdb_dlclose): Remove.
14223 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
14224 (gdb_dlsym): Change type of "handle".
14225 (make_cleanup_dlclose): Remove.
14226 (dlclose_deleter::operator()): Rename from gdb_dlclose.
14227 * compile/compile-c-support.c (load_libcc): Update.
14228
67d89901
TT
142292017-04-12 Tom Tromey <tom@tromey.com>
14230
14231 * symtab.h (find_pcs_for_symtab_line): Change return type.
14232 * symtab.c (find_pcs_for_symtab_line): Change return type.
14233 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
14234 type of "vec". Update.
14235 (ltpy_get_pcs_for_line): Update.
14236 * linespec.c (decode_digits_ordinary): Update.
14237
93921405
TT
142382017-04-12 Tom Tromey <tom@tromey.com>
14239
14240 * tracepoint.c (actions_command): Update.
14241 * python/python.c (python_command, python_interactive_command):
14242 Update.
14243 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
14244 * guile/guile.c (guile_command): Update.
14245 * defs.h (read_command_lines, read_command_lines_1): Return
14246 command_line_up.
14247 (command_lines_deleter): New struct.
14248 (command_line_up): New typedef.
14249 * compile/compile.c (compile_code_command)
14250 (compile_print_command): Update.
14251 * cli/cli-script.h (get_command_line, copy_command_lines): Return
14252 command_line_up.
14253 (make_cleanup_free_command_lines): Remove.
14254 * cli/cli-script.c (get_command_line, read_command_lines_1)
14255 (copy_command_lines): Return command_line_up.
14256 (while_command, if_command, read_command_lines, define_command)
14257 (document_command): Update.
14258 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
14259 Remove.
14260 * breakpoint.h (breakpoint_set_commands): Change type of
14261 "commands".
14262 * breakpoint.c (breakpoint_set_commands): Change type of
14263 "commands". Update.
14264 (do_map_commands_command, update_dprintf_command_list)
14265 (create_tracepoint_from_upload): Update.
14266
ffc2605c
TT
142672017-04-12 Tom Tromey <tom@tromey.com>
14268
14269 * tracepoint.c (scope_info): Update.
14270 * spu-tdep.c (spu_catch_start): Update.
14271 * python/python.c (gdbpy_decode_line): Update.
14272 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
14273 * python/py-breakpoint.c (bppy_init): Update.
14274 * probe.c (parse_probes): Update.
14275 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
14276 * location.h (event_location_deleter): New struct.
14277 (event_location_up): New typedef.
14278 (new_linespec_location, new_address_location, new_probe_location)
14279 (new_explicit_location, copy_event_location)
14280 (string_to_event_location, string_to_event_location_basic)
14281 (string_to_explicit_location): Update return type.
14282 (make_cleanup_delete_event_location): Remove.
14283 * location.c (new_linespec_location, new_address_location)
14284 (new_probe_location, new_explicit_location, copy_event_location):
14285 Return event_location_up.
14286 (delete_event_location_cleanup)
14287 (make_cleanup_delete_event_location): Remove.
14288 (string_to_explicit_location, string_to_event_location_basic)
14289 (string_to_event_location): Return event_location_up.
14290 * linespec.c (canonicalize_linespec, event_location_to_sals)
14291 (decode_line_with_current_source)
14292 (decode_line_with_last_displayed, decode_objc): Update.
14293 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
14294 * completer.c (location_completer): Update.
14295 * cli/cli-cmds.c (edit_command, list_command): Update.
14296 * breakpoint.c (create_overlay_event_breakpoint)
14297 (create_longjmp_master_breakpoint)
14298 (create_std_terminate_master_breakpoint)
14299 (create_exception_master_breakpoint)
14300 (create_thread_event_breakpoint): Update.
14301 (init_breakpoint_sal): Update. Remove some dead code.
14302 (create_breakpoint_sal): Change type of "location". Update.
14303 (create_breakpoints_sal, create_breakpoint, break_command_1)
14304 (dprintf_command, break_range_command, until_break_command)
14305 (init_ada_exception_breakpoint)
14306 (strace_marker_create_sals_from_location)
14307 (update_static_tracepoint, trace_command, ftrace_command)
14308 (strace_command, create_tracepoint_from_upload): Update.
14309 * break-catch-throw.c (re_set_exception_catchpoint): Update.
14310 * ax-gdb.c (agent_command_1): Update.
14311
8f10c932
PA
143122017-04-12 Pedro Alves <palves@redhat.com>
14313
14314 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
14315 * configure.tgt: Handle i[34567]86-*-go32* and
14316 i[34567]86-*-msdosdjgpp*.
14317 * i386-tdep.c (i386_svr4_reg_to_regnum):
14318 Make extern.
14319 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
14320 i386-go32-tdep.c.
14321 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
14322 * i386-go32-tdep.c: New file.
14323 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
14324 declarations.
14325
0a31ccfb
SM
143262017-04-12 Simon Marchi <simon.marchi@ericsson.com>
14327
14328 * aix-thread.c (pd_status2str): Change return type to const char *.
14329
e9bb3fbb
PA
143302017-04-12 Pedro Alves <palves@redhat.com>
14331
14332 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
14333 calls to set_gdbarch_gnu_triplet_regexp.
14334
53375380
PA
143352017-04-12 Pedro Alves <palves@redhat.com>
14336
14337 PR gdb/21323
14338 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
14339 New enum value.
14340 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
14341 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
14342 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
14343 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
14344 * gdbarch.h, gdbarch.c: Regenerate.
14345 * aarch64-tdep.c (aarch64_gdbarch_init): Override
14346 gdbarch_wchar_bit and gdbarch_wchar_signed.
14347 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
14348 * arm-tdep.c (arm_gdbarch_init): Likewise.
14349 * avr-tdep.c (avr_gdbarch_init): Likewise.
14350 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
14351 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
14352 * i386-tdep.c (i386_go32_init_abi): Likewise.
14353 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
14354 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
14355 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
14356 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
14357 * sh-tdep.c (sh_gdbarch_init): Likewise.
14358 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
14359 * sparc64-tdep.c (sparc64_init_abi): Likewise.
14360 * windows-tdep.c (windows_init_abi): Likewise.
14361 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
14362
53e710ac
PA
143632017-04-12 Pedro Alves <palves@redhat.com>
14364
14365 PR c++/21323
14366 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
14367 cplus_primitive_type_char32_t>: New enum values.
14368 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
14369 and cplus_primitive_type_char32_t.
14370 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
14371 32, use the archtecture's built-in type for char16_t and char32_t,
14372 respectively. Otherwise, fallback to init_integer_type as before,
14373 but make the type unsigned, and issue a complaint.
14374 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
14375
ab0538b8
AH
143762017-04-12 Alan Hayward <alan.hayward@arm.com>
14377
5e0e0422 14378 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
14379 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
14380
5430098f
SDJ
143812017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14382
14383 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
14384 'const char *'.
14385
7c5ded6a
SDJ
143862017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14387
14388 * common/common-utils.c (free_vector_argv): New function.
14389 * common/common-utils.h: Include <vector>.
14390 (free_vector_argv): New prototype.
14391 * darwin-nat.c (darwin_create_inferior): Rewrite function
14392 prototype in order to constify "exec_file" and accept a
14393 "std::string" for "allargs".
14394 * fork-child.c: Include <vector>.
14395 (breakup_args): Rewrite function, using C++.
14396 (fork_inferior): Rewrite function header, constify "exec_file_arg"
14397 and accept "std::string" for "allargs". Update the code to
14398 calculate "argv" based on "allargs". Update calls to "exec_fun"
14399 and "execvp".
14400 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
14401 order to constify "exec_file" and accept a "std::string" for
14402 "allargs".
14403 * go32-nat.c (go32_create_inferior): Likewise.
14404 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
14405 * infcmd.c (run_command_1): Constify "exec_file". Use
14406 "std::string" for inferior arguments.
14407 * inferior.h (fork_inferior): Update prototype.
14408 * linux-nat.c (linux_nat_create_inferior): Rewrite function
14409 prototype in order to constify "exec_file" and accept a
14410 "std::string" for "allargs".
14411 * nto-procfs.c (procfs_create_inferior): Likewise.
14412 * procfs.c (procfs_create_inferior): Likewise.
14413 * remote-sim.c (gdbsim_create_inferior): Likewise.
14414 * remote.c (extended_remote_run): Update code to accept
14415 "std::string" as argument.
14416 (extended_remote_create_inferior): Rewrite function prototype in
14417 order to constify "exec_file" and accept a "std::string" for
14418 "allargs".
14419 * rs6000-nat.c (super_create_inferior): Likewise.
14420 (rs6000_create_inferior): Likewise.
14421 * target.h (struct target_ops) <to_create_inferior>: Likewise.
14422 * windows-nat.c (windows_create_inferior): Likewise.
14423
ae0eee42
PA
144242017-04-11 Pedro Alves <palves@redhat.com>
14425
14426 * thread.c: Fix whitespace throughout.
14427
a6acac06
PR
144282017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
14429
14430 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
14431
64403bd1
AH
144322017-04-11 Alan Hayward <alan.hayward@arm.com>
14433
14434 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
14435
a5bef50f
SDJ
144362017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
14437
14438 PR gdb/21364
14439 * osdata.c (info_osdata): Check if 'type' is an empty string
14440 instead of NULL.
14441
9295a5a9
PA
144422017-04-10 Pedro Alves <palves@redhat.com>
14443
14444 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
14445 (ptid_to_global_thread_id, in_thread_list)
14446 (do_captured_list_thread_ids, set_resumed, set_running)
14447 (set_executing, set_stop_requested, finish_thread_state)
14448 (validate_registers_access, can_access_registers_ptid)
14449 (print_thread_info_1, switch_to_thread)
14450 (do_restore_current_thread_cleanup)
14451 (make_cleanup_restore_current_thread, thread_command)
14452 (thread_name_command): Use operator== instead of ptid_equal.
14453
996812e3
PA
144542017-04-10 Pedro Alves <palves@redhat.com>
14455
14456 * thread.c (struct current_thread_cleanup) <next>: Delete field.
14457 (current_thread_cleanup_chain): Delete.
14458 (restore_current_thread_cleanup_dtor)
14459 (make_cleanup_restore_current_thread): Remove references to
14460 current_thread_cleanup_chain.
14461
845b344f
AH
144622017-04-10 Alan Hayward <alan.hayward@arm.com>
14463
14464 * msp430-tdep.c (msp430_pseudo_register_read): Never return
14465 REG_UNKNOWN.
14466
803bdfe4
YQ
144672017-04-10 Yao Qi <yao.qi@linaro.org>
14468
14469 PR gdb/19942
14470 * gdbthread.h (thread_info::deletable): New method.
14471 (thread_info::incref): New method.
14472 (thread_info::decref): New method.
14473 (thread_info::refcount): Move it to private.
14474 * infrun.c (save_stop_context): Call inc_refcount.
14475 (release_stop_context_cleanup): Likewise.
14476 * thread.c (set_thread_exited): New function.
14477 (init_thread_list): Delete "tp" only it is deletable, otherwise
14478 call set_thread_exited.
14479 (delete_thread_1): Call set_thread_exited.
14480 (current_thread_cleanup) <inferior_pid>: Remove.
14481 <thread>: New field.
14482 (restore_current_thread_ptid_changed): Removed.
14483 (do_restore_current_thread_cleanup): Adjust.
14484 (restore_current_thread_cleanup_dtor): Don't call
14485 find_thread_ptid.
14486 (set_thread_refcount): Use dec_refcount.
14487 (make_cleanup_restore_current_thread): Adjust.
14488 (thread_apply_all_command): Call inc_refcount.
14489 (_initialize_thread): Don't call
14490 observer_attach_thread_ptid_changed.
14491
8c25b497
YQ
144922017-04-10 Yao Qi <yao.qi@linaro.org>
14493
14494 * thread.c (delete_thread_1): Hoist code on marking thread as
14495 exited.
14496
8473b447
SM
144972017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14498
14499 * windows-nat.c (windows_detach): Initialize ptid with
14500 minus_one_ptid.
14501
6670ec13
SM
145022017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14503
14504 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14505
ba2f91bb
AH
145062017-04-07 Alan Hayward <alan.hayward@arm.com>
14507
14508 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14509 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14510 (bfin_pseudo_register_write): Likewise
14511
436252de
SM
145122017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14513
14514 * common/ptid.h (struct ptid): Change to...
14515 (class ptid_t): ... this.
14516 <ptid_t>: New constructors.
14517 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14518 matches>: New methods.
14519 <make_null, make_minus_one>: New static methods.
14520 <pid>: Rename to...
14521 <m_pid>: ...this.
14522 <lwp>: Rename to...
14523 <m_lwp>: ...this.
14524 <tid>: Rename to...
14525 <m_tid>: ...this.
14526 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14527 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14528 as references, move comment to class ptid_t.
14529 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14530 ptid_t static methods.
14531 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14532 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14533 Take ptid arguments as references, implement using ptid_t methods.
14534 * unittests/ptid-selftests.c: New file.
14535 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14536 unittests/ptid-selftests.c.
14537 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14538
0dedf377
TP
145392017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14540
14541 * python/python.c (python_run_simple_file): Cast mode literal to
14542 non-const char pointer as expected by PyFile_FromString.
14543
4e9868d4
SM
145442017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14545
14546 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14547 minus_one_ptid and null_ptid.
14548
9bf2a700
PA
145492017-04-05 Pedro Alves <palves@redhat.com>
14550
14551 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14552 * configure: Regenerate.
14553
a121b7c1
PA
145542017-04-05 Pedro Alves <palves@redhat.com>
14555
14556 * ada-exp.y (yyerror): Constify.
14557 * ada-lang.c (bound_name, get_selections)
14558 (ada_variant_discrim_type)
14559 (ada_variant_discrim_name, ada_value_struct_elt)
14560 (ada_lookup_struct_elt_type, is_unchecked_variant)
14561 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14562 (catch_ada_exception_command_split)
14563 (catch_ada_assert_command_split, catch_assert_command)
14564 (ada_op_name): Constify.
14565 * ada-lang.h (ada_yyerror, get_selections)
14566 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14567 * arc-tdep.c (arc_print_frame_cache): Constify.
14568 * arm-tdep.c (arm_skip_stub): Constify.
14569 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14570 (gen_aggregate_elt_ref): Constify.
14571 * bcache.c (print_bcache_statistics): Constify.
14572 * bcache.h (print_bcache_statistics): Constify.
14573 * break-catch-throw.c (catch_exception_command_1):
14574 * breakpoint.c (struct ep_type_description::description):
14575 Constify.
14576 (add_solib_catchpoint): Constify.
14577 (catch_fork_command_1): Add cast.
14578 (add_catch_command): Constify.
14579 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14580 Constify.
14581 * bsd-uthread.c (bsd_uthread_state): Constify.
14582 * buildsym.c (patch_subfile_names): Constify.
14583 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14584 Constify.
14585 * c-exp.y (yyerror): Constify.
14586 (token::oper): Constify.
14587 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14588 * c-varobj.c (cplus_describe_child): Constify.
14589 * charset.c (find_charset_names): Add cast.
14590 (find_charset_names): Constify array and add const_cast.
14591 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14592 (edit_command): Constify.
14593 * cli/cli-decode.c (lookup_cmd): Constify.
14594 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14595 Constify.
14596 (struct dump_context): Constify.
14597 (add_dump_command, restore_command): Constify.
14598 * cli/cli-script.c (get_command_line): Constify.
14599 * cli/cli-script.h (get_command_line): Constify.
14600 * cli/cli-utils.c (check_for_argument): Constify.
14601 * cli/cli-utils.h (check_for_argument): Constify.
14602 * coff-pe-read.c (struct read_pe_section_data): Constify.
14603 * command.h (lookup_cmd): Constify.
14604 * common/print-utils.c (decimal2str): Constify.
14605 * completer.c (gdb_print_filename): Constify.
14606 * corefile.c (set_gnutarget): Constify.
14607 * cp-name-parser.y (yyerror): Constify.
14608 * cp-valprint.c (cp_print_class_member): Constify.
14609 * cris-tdep.c (cris_register_name, crisv32_register_name):
14610 Constify.
14611 * d-exp.y (yyerror): Constify.
14612 (struct token::oper): Constify.
14613 * d-lang.h (d_yyerror): Constify.
14614 * dbxread.c (struct header_file_location::name): Constify.
14615 (add_old_header_file, add_new_header_file, last_function_name)
14616 (dbx_next_symbol_text, add_bincl_to_list)
14617 (find_corresponding_bincl_psymtab, set_namestring)
14618 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14619 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14620 * defs.h (command_line_input, print_address_symbolic)
14621 (deprecated_readline_begin_hook): Constify.
14622 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14623 Constify.
14624 * event-top.c (handle_line_of_input): Constify and add cast.
14625 * exceptions.c (catch_errors): Constify.
14626 * exceptions.h (catch_errors): Constify.
14627 * expprint.c (print_subexp_standard, op_string, op_name)
14628 (op_name_standard, dump_raw_expression, dump_raw_expression):
14629 * expression.h (op_name, op_string, dump_raw_expression):
14630 Constify.
14631 * f-exp.y (yyerror): Constify.
14632 (struct token::oper): Constify.
14633 (struct f77_boolean_val::name): Constify.
14634 * f-lang.c (f_word_break_characters): Constify.
14635 * f-lang.h (f_yyerror): Constify.
14636 * fork-child.c (fork_inferior): Add cast.
14637 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14638 (new_variant): Constify.
14639 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14640 * gdbarch.c: Regenerate.
14641 * gdbcore.h (set_gnutarget): Constify.
14642 * go-exp.y (yyerror): Constify.
14643 (token::oper): Constify.
14644 * go-lang.h (go_yyerror): Constify.
14645 * go32-nat.c (go32_sysinfo): Constify.
14646 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14647 * guile/scm-cmd.c (cmdscm_function): Constify.
14648 * guile/scm-param.c (pascm_param_value): Constify.
14649 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14650 (h8300sx_register_name): Constify.
14651 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14652 Constify.
14653 * ia64-tdep.c (ia64_register_names): Constify.
14654 * infcmd.c (construct_inferior_arguments): Constify.
14655 (path_command, attach_post_wait): Constify.
14656 * language.c (show_range_command, show_case_command)
14657 (unk_lang_error): Constify.
14658 * language.h (language_defn::la_error)
14659 (language_defn::la_name_of_this): Constify.
14660 * linespec.c (decode_line_2): Constify.
14661 * linux-thread-db.c (thread_db_err_str): Constify.
14662 * lm32-tdep.c (lm32_register_name): Constify.
14663 * m2-exp.y (yyerror): Constify.
14664 * m2-lang.h (m2_yyerror): Constify.
14665 * m32r-tdep.c (m32r_register_names): Constify and make static.
14666 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14667 * m88k-tdep.c (m88k_register_name): Constify.
14668 * macroexp.c (appendmem): Constify.
14669 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14670 (upgrade_type, parse_external, parse_partial_symbols)
14671 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14672 (new_symbol): Constify.
14673 * memattr.c (mem_info_command): Constify.
14674 * mep-tdep.c (register_name_from_keyword): Constify.
14675 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14676 Constify.
14677 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14678 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14679 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14680 cast.
14681 (mi_execute_async_cli_command): Constify.
14682 * mips-tdep.c (mips_register_name): Constify.
14683 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14684 (am33_register_name, am33_2_register_name)
14685 * moxie-tdep.c (moxie_register_names): Constify.
14686 * nat/linux-osdata.c (osdata_type): Constify fields.
14687 * nto-tdep.c (nto_parse_redirection): Constify.
14688 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14689 (lookup_child_selector): Constify.
14690 (objc_methcall::name): Constify.
14691 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14692 (lookup_struct_typedef): Constify.
14693 * objfiles.c (pc_in_section): Constify.
14694 * objfiles.h (pc_in_section): Constify.
14695 * p-exp.y (struct token::oper): Constify.
14696 (yyerror): Constify.
14697 * p-lang.h (pascal_yyerror): Constify.
14698 * parser-defs.h (op_name_standard): Constify.
14699 (op_print::string): Constify.
14700 (exp_descriptor::op_name): Constify.
14701 * printcmd.c (print_address_symbolic): Constify.
14702 * psymtab.c (print_partial_symbols): Constify.
14703 * python/py-breakpoint.c (stop_func): Constify.
14704 (bppy_get_expression): Constify.
14705 * python/py-cmd.c (cmdpy_completer::name): Constify.
14706 (cmdpy_function): Constify.
14707 * python/py-event.c (evpy_add_attribute)
14708 (gdbpy_initialize_event_generic): Constify.
14709 * python/py-event.h (evpy_add_attribute)
14710 (gdbpy_initialize_event_generic): Constify.
14711 * python/py-evts.c (add_new_registry): Constify.
14712 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14713 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14714 * python/py-inferior.c (get_buffer): Add cast.
14715 * python/py-param.c (parm_constant::name): Constify.
14716 * python/py-unwind.c (fprint_frame_id): Constify.
14717 * python/python.c (gdbpy_parameter_value): Constify.
14718 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14719 * remote.c (memory_packet_config::name): Constify.
14720 (show_packet_config_cmd, remote_write_bytes)
14721 (remote_buffer_add_string):
14722 * reverse.c (exec_reverse_once): Constify.
14723 * rs6000-tdep.c (variant::name, variant::description): Constify.
14724 * rust-exp.y (rustyyerror): Constify.
14725 * rust-lang.c (rust_op_name): Constify.
14726 * rust-lang.h (rustyyerror): Constify.
14727 * serial.h (serial_ops::name): Constify.
14728 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14729 (sh_sh3e_register_name, sh_sh2e_register_name)
14730 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14731 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14732 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14733 (sh_sh4al_dsp_register_name): Constify.
14734 * sh64-tdep.c (sh64_register_name): Constify.
14735 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14736 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14737 * stabsread.c (patch_block_stabs, read_type_number)
14738 (ref_map::stabs, ref_add, process_reference)
14739 (symbol_reference_defined, define_symbol, define_symbol)
14740 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14741 (read_one_struct_field, read_struct_fields, read_baseclasses)
14742 (read_tilde_fields, read_struct_type, read_array_type)
14743 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14744 (read_huge_number, read_range_type, read_args, common_block_start)
14745 (find_name_end): Constify.
14746 * stabsread.h (common_block_start, define_symbol)
14747 (process_one_symbol, symbol_reference_defined, ref_add):
14748 * symfile.c (get_section_index, add_symbol_file_command):
14749 * symfile.h (get_section_index): Constify.
14750 * target-descriptions.c (tdesc_type::name): Constify.
14751 (tdesc_free_type): Add cast.
14752 * target.c (find_default_run_target):
14753 (add_deprecated_target_alias, find_default_run_target)
14754 (target_announce_detach): Constify.
14755 (do_option): Constify.
14756 * target.h (add_deprecated_target_alias): Constify.
14757 * thread.c (print_thread_info_1): Constify.
14758 * top.c (deprecated_readline_begin_hook, command_line_input):
14759 Constify.
14760 (init_main): Add casts.
14761 * top.h (handle_line_of_input): Constify.
14762 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14763 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14764 (tfind_command): Rename to ...
14765 (tfind_command_1): ... this and constify.
14766 (tfind_command): New function.
14767 (tfind_end_command, tfind_start_command): Adjust.
14768 (encode_source_string): Constify.
14769 * tracepoint.h (encode_source_string): Constify.
14770 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14771 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14772 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14773 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14774 * tui/tui-win.c (parse_scrolling_args): Constify.
14775 * tui/tui-windata.c (tui_erase_data_content): Constify.
14776 * tui/tui-windata.h (tui_erase_data_content): Constify.
14777 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14778 * tui/tui.c (tui_enable): Add cast.
14779 * utils.c (defaulted_query): Constify.
14780 (init_page_info): Add cast.
14781 (puts_debug, subset_compare): Constify.
14782 * utils.h (subset_compare): Constify.
14783 * varobj.c (varobj_format_string): Constify.
14784 * varobj.h (varobj_format_string): Constify.
14785 * vax-tdep.c (vax_register_name): Constify.
14786 * windows-nat.c (windows_detach): Constify.
14787 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14788 * xml-support.c (gdb_xml_end_element): Constify.
14789 * xml-tdesc.c (tdesc_start_reg): Constify.
14790 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14791 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14792 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14793
995816ba
PA
147942017-04-05 Pedro Alves <palves@redhat.com>
14795
14796 * proc-api.c (struct trans): Constify.
14797 (procfs_note): Constify.
14798 * proc-events.c (struct trans, syscall_table):
14799 * proc-flags.c (struct trans): Constify.
14800 * proc-utils.h (procfs_note): Constify.
14801 * proc-why.c (struct trans): Constify.
14802 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14803 (procfs_detach): Constify.
14804 * sol-thread.c (struct string_map): Constify.
14805 (td_err_string, td_state_string): Constify.
14806
3e83a920
PA
148072017-04-05 Pedro Alves <palves@redhat.com>
14808
14809 * proc-api.c (procfs_filename): Don't initialize
14810 procfs_filename.
14811 (prepare_to_trace): Assume procfs_filename is non-NULL.
14812 (_initialize_proc_api): Give procfs_filename a default value here.
14813
63160a43
PA
148142017-04-05 Pedro Alves <palves@redhat.com>
14815
14816 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14817 'cond_string' parameter.
14818 (extract_exception_regexp): Constify 'string' parameter.
14819 (catch_exception_command_1): Constify.
14820 * breakpoint.c (init_catchpoint)
14821 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14822 parameter.
14823 (ep_parse_optional_if_clause, catch_fork_command_1)
14824 (catch_exec_command_1): Constify.
14825 * breakpoint.h (init_catchpoint): Constify 'cond_string'
14826 parameter.
14827 (ep_parse_optional_if_clause): Constify.
14828 * cli/cli-utils.c (remove_trailing_whitespace)
14829 (check_for_argument): Constify.
14830 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
14831 non-const overload.
14832 (check_for_argument): Likewise.
14833
9b2eba3d
PA
148342017-04-05 Pedro Alves <palves@redhat.com>
14835
14836 * event-top.c (command_line_handler): Add cast to execute_command
14837 call.
14838 * record-btrace.c (cmd_record_btrace_bts_start)
14839 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
14840 (cmd_record_btrace_start): Add cast to execute_command call.
14841 * record-full.c (record_full_goto_insn):
14842 * record.c (record_start, record_stop): Add cast to
14843 execute_command_to_string calls.
14844 (cmd_record_start): Add cast to execute_command calls.
14845
2adadf51
PA
148462017-04-05 Pedro Alves <palves@redhat.com>
14847
14848 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
14849 static inline function.
14850 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
14851 array and use gdb_PyArg_ParseTupleAndKeywords.
14852 * python/py-cmd.c (cmdpy_init): Likewise.
14853 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
14854 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
14855 (infpy_search_memory): Likewise.
14856 * python/py-objfile.c (objfpy_add_separate_debug_file)
14857 (gdbpy_lookup_objfile): Likewise.
14858 * python/py-symbol.c (gdbpy_lookup_symbol)
14859 (gdbpy_lookup_global_symbol): Likewise.
14860 * python/py-type.c (gdbpy_lookup_type): Likewise.
14861 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
14862 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
14863 Likewise.
14864
0d1f4ceb
PA
148652017-04-05 Pedro Alves <palves@redhat.com>
14866
14867 * python/python-internal.h (gdb_PyGetSetDef): New type.
14868 * python/py-block.c (block_object_getset)
14869 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
14870 * python/py-event.c (event_object_getset)
14871 (finish_breakpoint_object_getset): Likewise.
14872 * python/py-inferior.c (inferior_object_getset): Likewise.
14873 * python/py-infthread.c (thread_object_getset): Likewise.
14874 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
14875 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
14876 * python/py-objfile.c (objfile_getset): Likewise.
14877 * python/py-progspace.c (pspace_getset): Likewise.
14878 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
14879 Likewise.
14880 * python/py-record.c (recpy_record_getset): Likewise.
14881 * python/py-symbol.c (symbol_object_getset): Likewise.
14882 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
14883 Likewise.
14884 * python/py-type.c (type_object_getset, field_object_getset):
14885 Likewise.
14886 * python/py-value.c (value_object_getset): Likewise.
14887
4d759979
PA
148882017-04-05 Pedro Alves <palves@redhat.com>
14889
14890 * python/python-internal.h (gdb_PyObject_CallMethod)
14891 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
14892 New functions.
14893 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
14894 (PySys_GetObject, PySys_SetPath): New macros.
14895
fdf9e36f
PA
148962017-04-05 Pedro Alves <palves@redhat.com>
14897
14898 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
14899 info_osdata_command.
14900 * osdata.c (info_osdata_command): Rename to ...
14901 (info_osdata): ... this. Constify 'type' parameter, and remove
14902 the 'from_tty' parameter. Accept NULL TYPE.
14903 (info_osdata_command): New function.
14904 * osdata.h (info_osdata_command): Remove declaration.
14905 (info_osdata): New declaration.
14906
9f33b8b7
PA
149072017-04-05 Pedro Alves <palves@redhat.com>
14908
14909 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
14910 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
14911 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
14912 parameter.
14913 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
14914 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
14915 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
14916 parameter.
14917 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
14918 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
14919 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
14920 (mi_cmd_file_list_exec_source_files)
14921 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
14922 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
14923 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
14924 parameter.
14925 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
14926 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
14927 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
14928 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
14929 (mi_cmd_stack_info_frame): Constify 'command' parameter.
14930 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
14931 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
14932 'command' parameter.
14933 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
14934 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
14935 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
14936 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
14937 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
14938 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
14939 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
14940 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
14941 (mi_cmd_var_set_update_range): Constify 'command' parameter.
14942 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
14943 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
14944 parameter.
14945 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
14946 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
14947 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
14948 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
14949 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
14950 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
14951 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
14952 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
14953 (mi_cmd_data_list_changed_registers)
14954 (mi_cmd_data_write_register_values)
14955 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
14956 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
14957 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
14958 (mi_cmd_list_features, mi_cmd_list_target_features)
14959 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
14960 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
14961 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
14962 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
14963 (mi_cmd_trace_frame_collected): Constify 'command'
14964 parameter.
14965 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
14966 'command' parameter.
14967
67cb5b2d
PA
149682017-04-05 Pedro Alves <palves@redhat.com>
14969
14970 * ada-lang.c (ada_completer_word_break_characters): Now a const
14971 array.
14972 (ada_get_gdb_completer_word_break_characters): Constify.
14973 * completer.c (gdb_completer_command_word_break_characters)
14974 (gdb_completer_file_name_break_characters)
14975 (gdb_completer_quote_characters): Now const arrays.
14976 (get_gdb_completer_quote_characters): Constify.
14977 (set_rl_completer_word_break_characters): New function.
14978 (set_gdb_completion_word_break_characters)
14979 (complete_line_internal): Use it.
14980 * completer.h (get_gdb_completer_quote_characters): Constify.
14981 (set_rl_completer_word_break_characters): Declare.
14982 * f-lang.c (f_word_break_characters): Constify.
14983 * language.c (default_word_break_characters): Constify.
14984 * language.h (language_defn::la_word_break_characters): Constify.
14985 (default_word_break_characters): Constify.
14986 * top.c (init_main): Use set_rl_completer_word_break_characters.
14987
7a114964
PA
149882017-04-05 Pedro Alves <palves@redhat.com>
14989
14990 * aix-thread.c (aix_thread_pid_to_str)
14991 (aix_thread_extra_thread_info): Constify.
14992 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
14993 * bsd-uthread.c (bsd_uthread_extra_thread_info)
14994 (bsd_uthread_pid_to_str): Constify.
14995 * corelow.c (core_pid_to_str): Constify.
14996 * darwin-nat.c (darwin_pid_to_str): Constify.
14997 * fbsd-nat.c (fbsd_pid_to_str): Constify.
14998 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
14999 Constify.
15000 * gnu-nat.c (gnu_pid_to_str): Constify.
15001 * go32-nat.c (go32_pid_to_str): Constify.
15002 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
15003 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
15004 * inferior.c (inferior_pid_to_str): Constify.
15005 * linux-nat.c (linux_nat_pid_to_str): Constify.
15006 * linux-tdep.c (linux_core_pid_to_str): Constify.
15007 * linux-thread-db.c (thread_db_pid_to_str)
15008 (thread_db_extra_thread_info): Constify.
15009 * nto-tdep.c (nto_extra_thread_info): Constify.
15010 * nto-tdep.h (nto_extra_thread_info): Constify.
15011 * obsd-nat.c (obsd_pid_to_str): Constify.
15012 * procfs.c (procfs_pid_to_str): Constify.
15013 * ravenscar-thread.c (ravenscar_extra_thread_info)
15014 (ravenscar_pid_to_str): Constify.
15015 * remote-sim.c (gdbsim_pid_to_str): Constify.
15016 * remote.c (remote_threads_extra_info, remote_pid_to_str):
15017 Constify.
15018 * sol-thread.c (solaris_pid_to_str): Constify.
15019 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
15020 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
15021 * target.c (default_pid_to_str, target_pid_to_str)
15022 (normal_pid_to_str, default_pid_to_str): Constify.
15023 * target.h (target_ops::to_pid_to_str)
15024 (target_ops::to_extra_thread_info): Constify.
15025 (target_pid_to_str, normal_pid_to_str): Constify.
15026 * windows-nat.c (windows_pid_to_str): Constify.
15027 * gdbarch.sh (core_pid_to_str): Constify.
15028 * target-delegates.c: Regenerate.
15029 * gdbarch.h, gdbarch.c: Regenerate.
15030
69bbf465
PA
150312017-04-05 Pedro Alves <palves@redhat.com>
15032
15033 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
15034 the memory of the temporary warning_pre_print override.
15035 * utils.c (warning_pre_print): Constify.
15036 * utils.h (warning_pre_print): Constify.
15037
be47f9e8
PA
150382017-04-05 Pedro Alves <palves@redhat.com>
15039
15040 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
15041 (shell_command): New function.
15042 (make_command): Use std::string.
15043 (init_cli_cmds): Register shell_command instead of shell_escape.
15044
bde6261a
PA
150452017-04-05 Pedro Alves <palves@redhat.com>
15046
15047 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
15048 * tracepoint.c (default_collect): Don't initialize.
15049
b38ef47f
PA
150502017-04-05 Pedro Alves <palves@redhat.com>
15051
15052 * macroexp.c (macro_buffer::shared): Now a bool.
15053 (init_buffer): Update.
15054 (init_shared_buffer): Constify 'addr' parameter.
15055 (substitute_args, expand, macro_expand, macro_expand_next): Remove
15056 casts.
15057
f995bbe8
PA
150582017-04-05 Pedro Alves <palves@redhat.com>
15059
15060 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
15061 * disasm.c (set_disassembler_options): Constify local.
15062 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
15063
4a596fe2
SDJ
150642017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
15065
15066 PR gdb/21352
15067 * tracefile.c (tsave_command): Fix argument parsing for '-r'
15068 option.
15069
2cad08ea
YQ
150702017-04-05 Yao Qi <yao.qi@linaro.org>
15071
15072 * frame.c (frame_unwind_register_unsigned): Call
15073 frame_unwind_register_value.
15074
55a98976
YQ
150752017-04-05 Yao Qi <yao.qi@linaro.org>
15076
15077 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
15078 Use gdb_test_multiple, and don't match anchor.
15079
4ac40124
PA
150802017-04-05 Pedro Alves <palves@redhat.com>
15081
15082 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
15083 (Write After Approval): Remove Simon Marchi.
15084
c053b654
PA
150852017-04-05 Pedro Alves <palves@redhat.com>
15086
15087 * common/gdb_optional.h (optional::optional): Make constexpr and
15088 initialize m_dummy.
15089
4c7bf4f9
JB
150902017-04-04 John Baldwin <jhb@FreeBSD.org>
15091
15092 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15093 (amd64fbsd_jmp_buf_reg_offset): Remove.
15094 (amd64fbsd_supply_uthread): Remove function.
15095 (amd64fbsd_collect_uthread): Remove function.
15096 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
15097 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
15098 (x86_64-*-freebsd*): Remove bsd-uthread.o.
15099 (fbsd-nat.c): Update comment.
15100 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15101 (i386fbsd_jmp_buf_reg_offset): Remove.
15102 (i386fbsd_supply_uthread): Remove function.
15103 (i386fbsd_collect_uthread): Remove function.
15104 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
15105
1e1a8bef
JB
151062017-04-04 John Baldwin <jhb@FreeBSD.org>
15107
15108 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
15109 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
15110 * NEWS: Mention that support for FreeBSD/alpha was removed.
15111 * alpha-fbsd-tdep.c: Delete file.
15112 * config/alpha/fbsd.mh: Delete file.
15113 * configure.host: Delete alpha*-*-freebsd* and
15114 alpha*-*-kfreebsd*-gnu.
15115 * configure.tgt: Delete alpha*-*-freebsd* and
15116 alpha*-*-kfreebsd*-gnu.
15117
49907934
JB
151182017-04-04 John Baldwin <jhb@FreeBSD.org>
15119
15120 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
15121 amd64bsd_store_inferior_registers): Use ptid from regcache.
15122
6f77053d
PA
151232017-04-04 Pedro Alves <palves@redhat.com>
15124
15125 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
15126 data fields, make them private and add "m_" prefixes.
15127 (lnp_state_machine::lnp_state_machine): New ctor.
15128 (record_line, check_line_address, handle_set_discriminator)
15129 (handle_set_address, handle_advance_pc, handle_special_opcode)
15130 (handle_advance_line, handle_set_file, handle_negate_stmt)
15131 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
15132 (end_sequence, advance_line): New methods.
15133 (m_gdbarch, m_record_lines_p): New fields.
15134 (lnp_reader_state): Delete.
15135 (dwarf_record_line): Rename to ...
15136 (lnp_state_machine::record_line): ... adjust.
15137 (init_lnp_state_machine): Delete.
15138 (lnp_state_machine::lnp_state_machine): New.
15139 (check_line_address): Rename to ...
15140 (lnp_state_machine::check_line_address): This.
15141 (dwarf_decode_lines_1): Remove reference to "reader_state".
15142 Adjust lnp_state_machine having a non-default ctor. Use bool.
15143 State machine internal state manipulation moved to
15144 lnp_state_machine methods.
15145
9c541725
PA
151462017-04-04 Pedro Alves <palves@redhat.com>
15147
15148 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15149 unittests/offset-type-selftests.c.
15150 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
15151 * common/offset-type.h: New file.
15152 * common/preprocessor.h: New file.
15153 * common/traits.h: New file.
15154 * common/valid-expr.h: New file.
15155 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
15156 sect_offset and cu_offset strong typedefs throughout.
15157 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
15158 typedefs throughout.
15159 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
15160 sect_offset and cu_offset strong typedefs throughout.
15161 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
15162 typedefs throughout.
15163 * gdbtypes.h: Include "common/offset-type.h".
15164 (cu_offset): Now an offset type (strong typedef) instead of a
15165 struct.
15166 (sect_offset): Likewise.
15167 (union call_site_parameter_u): Rename "param_offset" field to
15168 "param_cu_off".
15169 * unittests/offset-type-selftests.c: New file.
15170
ecfb656c
PA
151712017-04-04 Pedro Alves <palves@redhat.com>
15172
15173 * common/underlying.h: New file.
15174 * dwarf2read.c: Include "common/gdb_optional.h" and
15175 "common/underlying.h".
15176 (dir_index, file_name_index): New types.
15177 (file_entry): Use them.
15178 (file_entry::include): Use to_underlying.
15179 (line_header::add_file_name): Use dir_index.
15180 (read_formatted_entries): Use gdb::optional. Read form before
15181 writting to file_entry.
15182 (dwarf_decode_line_header): Use dir_index.
15183 (lnp_state_machine::current_file): Use to_underlying.
15184 (lnp_state_machine::file): Change type to file_name_index.
15185 (dwarf_record_line): Use to_underlying.
15186 (init_lnp_state_machine): Use file_name_index.
15187 (dwarf_decode_lines_1): Use dir_index and file_name_index.
15188
d194f1fe
PA
151892017-04-04 Pedro Alves <palves@redhat.com>
15190
15191 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
15192 operator bool, has_value and get methods.
15193
fff8551c
PA
151942017-04-04 Pedro Alves <palves@redhat.com>
15195
15196 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
15197 fields.
15198 (line_header): Initialize all data fields. Change type of
15199 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
15200 Change type of include_dirs to std::vector<const char *>. Remove
15201 num_include_dirs, include_dirs_size. Change type of file_names to
15202 std::vector<file_entry>. Remove num_file_names, file_names_size.
15203 (line_header::line_header): New.
15204 (line_header::add_include_dir, line_header::add_file_name): New
15205 methods.
15206 (line_header::include_dir_at): Remove NULL check.
15207 (line_header::file_name_at): Add const overload.
15208 (line_header_up): New unique_ptr typedef.
15209 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
15210 std::vector. Remove free_line_header call.
15211 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
15212 free_line_header call.
15213 (free_cu_line_header): Delete.
15214 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
15215 (setup_type_unit_groups): Use line_header_up instead of cleanups.
15216 Adjust to use std::vector.
15217 (free_line_header): Delete.
15218 (free_line_header_voidp): Use delete.
15219 (add_include_dir): Replace with ...
15220 (line_header::add_include_dir): ... this method. Use std::vector.
15221 (add_file_name): Replace with ...
15222 (line_header::add_file_name): ... this method. Use std::vector.
15223 (add_include_dir_stub): Delete.
15224 (read_formatted_entries): Remove memset.
15225 (dwarf_decode_line_header): Return a line_header_up instead of a
15226 raw pointer. Remove cleanup handling. Pass lambdas to
15227 read_formatted_entries. Adjust to use line_header methods.
15228 (dwarf_decode_lines_1): Adjust to use line_header methods.
15229 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
15230 use std::vector.
15231
d62a8ae2
SM
152322017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
15233
15234 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
15235 instead of struct ptid.
15236
db3a1dc7
AH
152372017-05-04 Alan Hayward <alan.hayward@arm.com>
15238
15239 * frame.c (get_frame_register_bytes): Unwind using value.
15240 (put_frame_register_bytes): Likewise.
15241
b1b45502
IB
152422017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
15243
15244 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
15245 aggregate-like.
15246
ec13808e
JK
152472017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
15248
15249 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
15250
12316564
YQ
152512017-03-29 Yao Qi <yao.qi@linaro.org>
15252
15253 * gdbthread.h (struct thread_info): Declare constructor and
15254 destructor. Add some in-class member initializers.
15255 * thread.c (free_thread): Remove.
15256 (init_thread_list): Call delete instead of free_thread.
15257 (new_thread): Call thread_info constructor.
15258 (thread_info::thread_info): New function.
15259 (thread_info::~thread_info): New function.
15260 (delete_thread_1): Call delete instead of free_thread.
15261 (make_cleanup_restore_current_thread): Move tp and frame to
15262 inner block.
15263
fe5f7374
AK
152642017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15265
15266 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
15267 (arc_skip_prologue): Likewise.
15268 (arc_make_frame_cache): Likewise.
15269 (arc_pv_get_operand): New function.
15270 (arc_is_in_prologue): Likewise.
15271 (arc_analyze_prologue): Likewise.
15272 (arc_print_frame_cache): Likewise.
15273 (MAX_PROLOGUE_LENGTH): New constant.
15274
eea78757
AK
152752017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15276
15277 * configure.tgt: Add arc-insn.o.
15278 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
15279 (dump_arc_instruction_command): New function.
15280 (arc_fprintf_disasm): Likewise.
15281 (arc_disassemble_info): Likewise.
15282 (arc_insn_get_operand_value): Likewise.
15283 (arc_insn_get_operand_value_signed): Likewise.
15284 (arc_insn_get_memory_base_reg): Likewise.
15285 (arc_insn_get_memory_offset): Likewise.
15286 (arc_insn_get_branch_target): Likewise.
15287 (arc_insn_dump): Likewise.
15288 (arc_insn_get_linear_next_pc): Likewise.
15289 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
15290 (arc_disassemble_info): Likewise.
15291 (arc_insn_get_branch_target): Likewise.
15292 (arc_insn_get_linear_next_pc): Likewise.
15293 * NEWS: Mention new "maint print arc arc-instruction".
15294
3be78afd
AK
152952017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15296
15297 * arc-tdep (maintenance_print_arc_list): New variable.
15298 (maintenance_print_arc_command): New function.
15299
296ec4fa
AK
153002017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15301
15302 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
15303 Add "limm" and "reserved".
15304 (arc_cannot_fetch_register, arc_cannot_store_register): Add
15305 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
15306 * arc-tdep.h (arc_regnum): Likewise.
15307
f74f865e
MF
153082017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15309
15310 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15311 for THREADPTR register.
15312 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
15313 register.
15314 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
15315 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
15316 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
15317
0d0bf81a
MF
153182017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15319
15320 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
15321 registers above gdbarch_num_regs (gdbarch) as privileged in
15322 call0 ABI.
15323
0ce4291e
MF
153242017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15325
15326 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15327 for a single specified register or for all registers in
15328 a0_base..a0_base + C0_NREGS range.
15329 (supply_gregset_reg): Call regcache_raw_supply for a single
15330 specified register or for all registers in a0_base..a0_base +
15331 C0_NREGS range.
15332
c56054f9
MF
153332017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15334
15335 * arch/xtensa.h (C0_NREGS): Add definition.
15336 * xtensa-tdep.c (C0_NREGS): Remove definition.
15337
a4398628
MF
153382017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15339
15340 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
15341 Drop xtensa_default_isa initialization.
15342 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
15343
8c43009f
PA
153442017-03-27 Pedro Alves <palves@redhat.com>
15345
15346 * dwarf2read.c (file_entry) <dir_index>: Add comment.
15347 (file_entry::include_dir): New method.
15348 (line_header::include_dir_at, line_header::file_name_at): New
15349 methods.
15350 (setup_type_unit_groups, setup_type_unit_groups)
15351 (psymtab_include_file_name): Simplify using the new methods.
15352 (lnp_state_machine) <the_line_header>: New field.
15353 <file>: Add comment.
15354 (lnp_state_machine::current_file): New method.
15355 (dwarf_record_line): Simplify using the new methods.
15356 (init_lnp_state_machine): Initialize the "the_line_header" field.
15357 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
15358 Simplify using the new methods.
15359
a7e80b9e
PA
153602017-03-27 Pedro Alves <palves@redhat.com>
15361
15362 * cp-name-parser.y (make_empty): Delete.
15363 (demangler_special, nested_name, ptr_operator, array_indicator)
15364 (direct_declarator, declarator_1): Use fill_comp instead of
15365 make_empty.
15366
21047726
PA
153672017-03-27 Pedro Alves <palves@redhat.com>
15368
15369 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
15370 to ATTRIBUTE_PRINTF.
15371 * solib-target.c (library_list_start_list): Print "string" not
15372 "version".
15373 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
15374 gdb_xml_error call.
15375
d721ba37
PA
153762017-03-27 Pedro Alves <palves@redhat.com>
15377
15378 * dwarf2read.c (struct file_and_directory): New.
15379 (dwarf2_get_dwz_file): Adjust to use std::string.
15380 (dw2_get_file_names_reader): Adjust to use file_and_directory.
15381 (find_file_and_directory): Adjust to return a file_and_directory
15382 object.
15383 (read_file_scope): Adjust to use file_and_directory. Remove
15384 make_cleanup/do_cleanups calls.
15385 (open_and_init_dwp_file): Adjust to use std::string. Remove
15386 make_cleanup/do_cleanups calls.
15387 * python/python.c (do_start_initialization): Adjust to ldirname
15388 returning a std::string.
15389 * utils.c (ldirname): Now returns a std::string.
15390 * utils.h (ldirname): Change return type to std::string.
15391 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
15392 returning a std::string.
15393 * xml-tdesc.c (file_read_description_xml): Likewise.
15394
ed771251
AH
153952017-03-24 Alan Hayward <alan.hayward@arm.com>
15396
15397 * regcache.c (regcache_debug_print_register): New function.
15398 * regcache.h (regcache_debug_print_register): New declaration.
15399 * target.c (debug_print_register): Remove.
15400 (target_fetch_registers): Call regcache_debug_print_register.
15401 (target_store_registers): Likewise.
15402
568c1b9f
PB
154032017-03-24 Pádraig Brady <pbrady@fb.com>
15404
15405 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
15406 reference beyond the 'lh->include_dirs' array before accessing to
15407 it.
15408 (psymtab_include_file_name): Likewise.
15409 (dwarf_decode_lines_1): Likewise.
15410 (dwarf_decode_lines): Likewise.
15411 (file_file_name): Likewise.
15412
3e00d44f
SM
154132017-03-23 Simon Marchi <simon.marchi@ericsson.com>
15414
15415 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
15416 inferior_ptid.
15417 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15418 ps_lsetfpregs): Likewise.
15419 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
15420 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15421 ps_lsetfpregs): Likewise.
15422 * target.c (target_fetch_registers, target_store_registers):
15423 Remove asserts.
15424
077ae656
AH
154252017-03-23 Alan Hayward <alan.hayward@arm.com>
15426
15427 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
15428
1e2b521d
YQ
154292017-03-23 Yao Qi <yao.qi@linaro.org>
15430
15431 * aarch64-tdep.c (aarch64_process_record_test): Declare.
15432 (_initialize_aarch64_tdep): Register it.
15433 (aarch64_record_load_store): Handle PRFM instruction.
15434 (aarch64_process_record_test): New function.
15435
33877125
YQ
154362017-03-23 Yao Qi <yao.qi@linaro.org>
15437
15438 * aarch64-tdep.c (aarch64_record_load_store): Fix code
15439 indentation.
15440
a0eef940
YQ
154412017-03-23 Yao Qi <yao.qi@linaro.org>
15442
15443 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
15444
3f2a3564
PR
154452017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15446
15447 python/python.c (do_start_initialization): Fix memory leak.
15448
b67aeab0
SM
154492017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
15450
15451 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
15452 using get_ptrace_pid.
15453 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
15454 inferior_ptid.
15455 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
15456 inferior_ptid instead of pid.
15457
ffdbe864
YQ
154582017-03-22 Yao Qi <yao.qi@linaro.org>
15459
15460 * aarch64-tdep.c: Wrap locally used classes in anonymous
15461 namespace.
15462 * arm-tdep.c: Likewise.
15463 * linespec.c: Likewise.
15464 * ui-out.c: Likewise.
15465
9d736fbf
JG
154662017-03-22 Jonah Graham <jonah@kichwacoders.com>
15467
15468 PR gdb/19637
15469 * python/lib/gdb/printer/bound_registers.py: Import sys.
15470
3de88e9a
SM
154712017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15472
15473 * windows-nat.c (do_windows_fetch_inferior_registers): Add
15474 windows_thread_info parameter and use it instead of
15475 current_thread.
15476 (windows_fetch_inferior_registers): Don't set current_thread,
15477 pass the thread to do_windows_fetch_inferior_registers. Use
15478 ptid from regcache instead of inferior_ptid.
15479 (do_windows_store_inferior_registers): Add windows_thread_info
15480 parameter and use it instead of current_thread.
15481 (windows_store_inferior_registers): Don't set current_thread,
15482 pass the thread to do_windows_store_inferior_registers. Use
15483 ptid from regcache instead of inferior_ptid.
15484
0e7b8f61
SM
154852017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15486
15487 * ser-mingw.c (ser_windows_raw): Remove reference to
15488 struct serial::current_timeout.
15489
5badf10a
IR
154902017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15491
15492 PR tdep/20928
15493 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15494 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15495 (sparc64_fsr_type): Fix %fsr decoding.
15496
cee59b3f
TW
154972017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15498
15499 * python/py-record-btrace.c (btpy_insn_data): Change return type
15500 for Python 2.
15501
639a9038
SM
155022017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15503
15504 * spu-linux-nat.c (spu_fetch_inferior_registers,
15505 spu_store_inferior_registers): Use ptid from regcache, set and
15506 restore inferior_ptid.
15507 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15508 Likewise.
15509
bcc0c096
SM
155102017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15511
15512 * i386-linux-nat.c (fetch_register, store_register,
15513 i386_linux_fetch_inferior_registers,
15514 i386_linux_store_inferior_registers): Use ptid from regcache.
15515 * ia64-linux-nat.c (ia64_linux_fetch_register,
15516 ia64_linux_store_register): Likewise.
15517 * inf-ptrace.c (inf_ptrace_fetch_register,
15518 inf_ptrace_store_register): Likewise.
15519 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15520 m32r_linux_store_inferior_registers): Likewise.
15521 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15522 m68kbsd_store_inferior_registers): Likewise.
15523 * m68k-linux-nat.c (fetch_register, store_register,
15524 m68k_linux_fetch_inferior_registers,
15525 m68k_linux_store_inferior_registers): Likewise.
15526 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15527 m88kbsd_store_inferior_registers): Likewise.
15528 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15529 mips_fbsd_store_inferior_registers): Likewise.
15530 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15531 mips64_linux_regsets_store_registers): Likewise.
15532 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15533 mipsnbsd_store_inferior_registers): Likewise.
15534 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15535 mips64obsd_store_inferior_registers): Likewise.
15536 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15537 Likewise.
15538 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15539 ppcfbsd_store_inferior_registers): Likewise.
15540 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15541 ppc_linux_store_inferior_registers): Likewise.
15542 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15543 ppcnbsd_store_inferior_registers): Likewise.
15544 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15545 ppcobsd_store_registers): Likewise.
15546 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15547 Likewise.
15548 * ravenscar-thread.c (ravenscar_fetch_registers,
15549 ravenscar_store_registers, ravenscar_prepare_to_store):
15550 Likewise.
15551 * record-btrace.c (record_btrace_fetch_registers,
15552 record_btrace_store_registers, record_btrace_prepare_to_store):
15553 Likewise.
15554 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15555 Lookup inferior using ptid from regcache, instead of
15556 current_inferior.
15557 * remote.c (remote_fetch_registers, remote_store_registers): Use
15558 ptid from regcache.
15559 * rs6000-nat.c (fetch_register, store_register): Likewise.
15560 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15561 s390_linux_store_inferior_registers): Likewise.
15562 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15563 shnbsd_store_inferior_registers): Likewise.
15564 * sol-thread.c (sol_thread_fetch_registers,
15565 sol_thread_store_registers): Likewise.
15566 * sparc-nat.c (sparc_fetch_inferior_registers,
15567 sparc_store_inferior_registers): Likewise.
15568 * tilegx-linux-nat.c (fetch_inferior_registers,
15569 store_inferior_registers): Likewise.
15570 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15571 vaxbsd_store_inferior_registers): Likewise.
15572 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15573 store_xtregs): Likewise.
15574
c0f55cc6
AV
155752017-03-20 Artemiy Volkov <artemiyv@acm.org>
15576
15577 PR gdb/14441
15578 * NEWS: Mention support for rvalue references in GDB and python.
15579 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15580 supports both lvalue and rvalue references.
15581
15c0a2a9
AV
155822017-03-20 Artemiy Volkov <artemiyv@acm.org>
15583
15584 PR gdb/14441
15585 * gdbtypes.c (rank_one_type): Implement overloading
15586 resolution rules regarding rvalue references.
15587
aa006118
AV
155882017-03-20 Artemiy Volkov <artemiyv@acm.org>
15589
15590 PR gdb/14441
15591 * aarch64-tdep.c (aarch64_type_align)
15592 (aarch64_extract_return_value, aarch64_store_return_value): Change
15593 lvalue reference type checks to general reference type checks.
15594 * amd64-tdep.c (amd64_classify): Likewise.
15595 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15596 Likewise.
15597 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15598 (arm_store_return_value): Likewise.
15599 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15600 * c-typeprint.c (c_print_type): Likewise.
15601 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15602 (cplus_number_of_children, cplus_describe_child): Likewise.
15603 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15604 * completer.c (expression_completer): Likewise.
15605 * cp-support.c (make_symbol_overload_list_adl_namespace):
15606 Likewise.
15607 * darwin-nat-info.c (info_mach_region_command): Likewise.
15608 * dwarf2loc.c (entry_data_value_coerce_ref)
15609 (value_of_dwarf_reg_entry): Likewise.
15610 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15611 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15612 Likewise.
15613 * findvar.c (extract_typed_address, store_typed_address):
15614 Likewise.
15615 * gdbtypes.c (rank_one_type): Likewise.
15616 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15617 * infcall.c (value_arg_coerce): Likewise.
15618 * language.c (pointer_type): Likewise.
15619 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15620 Likewise.
15621 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15622 * mn10300-tdep.c (mn10300_type_align): Likewise.
15623 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15624 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15625 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15626 Likewise.
15627 * printcmd.c (print_formatted, x_command): Likewise.
15628 * python/py-type.c (typy_get_composite, typy_template_argument):
15629 Likewise.
15630 * python/py-value.c (valpy_referenced_value)
15631 (valpy_get_dynamic_type, value_has_field): Likewise.
15632 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15633 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15634 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15635 * spu-tdep.c (spu_scalar_value_p): Likewise.
15636 * symtab.c (lookup_symbol_aux): Likewise.
15637 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15638 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15639 Likewise.
15640 * valops.c (value_cast_pointers, value_cast)
15641 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15642 (value_struct_elt, value_struct_elt_bitpos)
15643 (value_find_oload_method_list, find_overload_match)
15644 (value_rtti_indirect_type): Likewise.
15645 * valprint.c (val_print_scalar_type_p, generic_val_print):
15646 Likewise.
15647 * value.c (value_actual_type, value_as_address, unpack_long)
15648 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15649 (coerce_ref): Likewise.
15650 * varobj.c (varobj_get_value_type): Likewise.
15651
3fcf899d
AV
156522017-03-20 Artemiy Volkov <artemiyv@acm.org>
15653
15654 PR gdb/14441
15655 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15656 table of constants.
15657 * python/lib/gdb/command/explore.py: Support exploring values
15658 of rvalue reference types.
15659 * python/lib/gdb/types.py: Implement get_basic_type() for
15660 rvalue reference types.
15661 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15662 constant.
15663 * python/py-value.c (valpy_getitem): Add an rvalue reference
15664 check.
15665 (valpy_reference_value): Add new parameter "refcode".
15666 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15667 New wrappers for valpy_reference_value().
15668 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15669 (gdbpy_invoke_xmethod): Likewise.
15670
4297a3f0
AV
156712017-03-20 Artemiy Volkov <artemiyv@acm.org>
15672
15673 PR gdb/14441
15674 * dwarf2read.c (process_die, read_type_die_1): Handle the
15675 DW_TAG_rvalue_reference_type DIE.
15676 (read_tag_reference_type): Add new parameter "refcode".
15677
e1cb3213
AV
156782017-03-20 Artemiy Volkov <artemiyv@acm.org>
15679
15680 PR gdb/14441
15681 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15682 (c_type_print_modifier, c_type_print_varspec_suffix)
15683 (c_type_print_base): Support printing rvalue reference types.
15684 * c-valprint.c (c_val_print, c_value_print): Support printing
15685 rvalue reference values.
15686
e4347c89
AV
156872017-03-20 Artemiy Volkov <artemiyv@acm.org>
15688
15689 PR gdb/14441
15690 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15691 typename.
15692 * cp-support.c (replace_typedefs): Handle
15693 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15694 * python/py-type.c (typy_lookup_type): Likewise.
15695
53cc15f5
AV
156962017-03-20 Artemiy Volkov <artemiyv@acm.org>
15697
15698 PR gdb/14441
15699 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15700 * parse.c (insert_type): Change assert statement.
15701 (follow_types): Handle rvalue reference types.
15702 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15703 constant.
15704
a65cfae5
AV
157052017-03-20 Artemiy Volkov <artemiyv@acm.org>
15706
15707 PR gdb/14441
15708 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15709 value_ref() interface.
15710 * c-valprint.c (c_value_print): Likewise.
15711 * infcall.c (value_arg_coerce): Likewise.
15712 * python/py-value.c (valpy_reference_value): Likewise.
15713 * valops.c (value_cast, value_reinterpret_cast)
15714 (value_dynamic_cast, typecmp): Likewise.
15715 (value_ref): Parameterize by kind of return value reference type.
15716 * value.h (value_ref): Add new parameter "refcode".
15717
3b224330
AV
157182017-03-20 Artemiy Volkov <artemiyv@acm.org>
15719
15720 PR gdb/14441
15721 * dwarf2read.c (read_tag_reference_type): Use
15722 lookup_lvalue_reference_type() instead of lookup_reference_type().
15723 * eval.c (evaluate_subexp_standard): Likewise.
15724 * f-exp.y: Likewise.
15725 * gdbtypes.c (make_reference_type, lookup_reference_type):
15726 Generalize with rvalue reference types.
15727 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15728 convenience wrappers for lookup_reference_type().
15729 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15730 reference kind parameter.
15731 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15732 wrappers for lookup_reference_type().
15733 * guile/scm-type.c (gdbscm_type_reference): Use
15734 lookup_lvalue_reference_type() instead of lookup_reference_type().
15735 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15736 * parse.c (follow_types): Likewise.
15737 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15738 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15739 Likewise.
15740 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15741 (gdbpy_invoke_xmethod): Likewise.
15742 * stabsread.c: Provide extra argument to make_reference_type()
15743 call.
15744 * valops.c (value_ref, value_rtti_indirect_type): Use
15745 lookup_lvalue_reference_type() instead of lookup_reference_type().
15746
f9aeb8d4
AV
157472017-03-20 Artemiy Volkov <artemiyv@acm.org>
15748
15749 PR gdb/14441
15750 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15751 (TYPE_IS_REFERENCE): New macro.
15752 (struct type): Add rvalue_reference_type field.
15753 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15754
51457a05
MAL
157552017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15756
15757 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15758 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15759 New function definition.
15760 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15761 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15762 New function declaration.
15763 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15764 * mi/mi-interp.h: New file.
15765 * solib.c (info_sharedlibrary_command): Replace for loop with
15766 ALL_SO_LIBS macro
15767 * solib.h (update_solib_list): New function declaration.
15768 (so_list_head): Move macro.
15769 * solist.h (ALL_SO_LIBS): New macro.
15770
e696b3ad
MAL
157712017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15772
15773 * infcmd.c (post_create_inferior): Remove unused argument in
15774 call to solib_add.
15775 * remote.c (remote_start_remote): Likewise.
15776 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15777 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15778 (enable_break): Likewise.
15779 * solib.c (update_solib_list): Remove unused target argument
15780 and its documentation.
15781 (solib_add): Remove unused target argument. Remove unused
15782 argument in call to update_solib_list.
15783 (info_sharedlibrary_command): Remove unused argument in call
15784 to update_solib_list.
15785 (sharedlibrary_command): Remove unused argument in call to
15786 solib_add.
15787 (handle_solib_event): Likewise.
15788 (reload_shared_libraries): Likewise.
15789 * solib.h (solib_add): Remove unused target argument.
15790
dcb84eda
AA
157912017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15792
15793 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15794 (s390_displaced_step_fixup): Cover relative branches with the
15795 default fixup handling. This fixes lack of support for some
15796 relative branch instructions.
15797
d9cb6cdc
SM
157982017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15799
15800 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15801 ptid from regcache.
15802
1afaf9f4
SM
158032017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15804
15805 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15806 i386_darwin_store_inferior_registers): Use ptid from regcache.
15807
aac12e24
SM
158082017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15809
15810 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15811 i386bsd_store_inferior_registers): Use ptid from regcache.
15812
bbe1eef1
SM
158132017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15814
15815 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15816 hppaobsd_store_registers): Use ptid from regcache.
15817
10799020
SM
158182017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15819
15820 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15821 hppanbsd_store_registers): Use ptid from regcache.
15822
00204cf7
SM
158232017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15824
15825 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
15826 from regcache. Use get_ptrace_pid.
15827
11a33714
SM
158282017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15829
15830 * corelow.c (get_core_register_section): Use ptid from regcache,
15831 update doc.
15832
317cd492
SM
158332017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15834
15835 * bsd-uthread.c (bsd_uthread_fetch_registers,
15836 bsd_uthread_store_registers): Use ptid from regcache, set and
15837 restore inferior_ptid.
15838
9ac8a7c2
SM
158392017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15840
15841 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
15842 fetch_fp_regs, store_register, store_regs, store_fp_register,
15843 store_fp_regs): Use ptid from regcache.
15844
4ac4bb6a
SM
158452017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15846
15847 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
15848 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
15849 store_vfp_regs): Use ptid from regcache.
15850
9bcbdca8
PA
158512017-03-17 Pedro Alves <palves@redhat.com>
15852
15853 PR remote/21188
15854 * ser-base.c (ser_base_wait_for): Add comment.
15855 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
15856 version.
15857 * ser-unix.c (hardwire_raw): Remove reference to
15858 scb->current_timeout.
15859 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
15860 (hardwire_ops): Install ser_base_readchar instead of
15861 hardwire_readchar.
15862 * serial.h (struct serial) <current_timeout, timeout_remaining>:
15863 Remove fields.
15864
7503099f
JG
158652017-03-17 Jonah Graham <jonah@kichwacoders.com>
15866
15867 PR gdb/19637
15868 * python/lib/gdb/printer/bound_registers.py: Add support for
15869 Python 3.
15870
7942e96e
AA
158712017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
15872
15873 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
15874 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
15875 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
15876 byte_offset to subobj_byte_offset. Fix the handling of
15877 DWARF_VALUE_STACK on big-endian targets when coming via an
15878 implicit pointer.
15879 (dwarf2_evaluate_loc_desc): Adjust call to
15880 dwarf2_evaluate_loc_desc_full.
15881 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
15882 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
15883
ba14f379
YQ
158842017-03-16 Yao Qi <yao.qi@linaro.org>
15885
15886 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
15887 and REVSH instructions.
15888
b121eeb9
YQ
158892017-03-16 Yao Qi <yao.qi@linaro.org>
15890
15891 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
15892 (arm_record_test): Declare.
15893 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
15894 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
15895 align with the manual.
15896 (thumb_record_misc): Adjust the code order to align with the
15897 manual.
15898 (thumb2_record_decode_insn_handler): Fix instruction matching.
15899 (instruction_reader_thumb): New class.
15900 (arm_record_test): New function.
15901
728a7913
YQ
159022017-03-16 Yao Qi <yao.qi@linaro.org>
15903
15904 * arm-tdep.c (abstract_memory_reader): New class.
15905 (instruction_reader): New class.
15906 (extract_arm_insn): Add argument 'reader'. Callers updated.
15907 (decode_insn): Likewise.
15908
34b43320
DE
159092017-03-16 Doug Evans <dje@google.com>
15910
a7c0469f
DE
15911 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
15912 member. Change type of TYPE member to SCM. All uses updated.
15913 (lsscm_make_lazy_string_smob): Add assert.
15914 (lsscm_make_lazy_string): Flag bad length values.
15915 (lsscm_elt_type): New function.
15916 (gdbscm_lazy_string_to_value): Rewrite to use
15917 lsscm_safe_lazy_string_to_value.
15918 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
15919 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
15920 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
15921 in incoming type.
15922 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15923 * guile/scm-type.c (tyscm_scm_to_type): New function.
15924
159252017-03-15 Doug Evans <dje@google.com>
15926
34b43320
DE
15927 PR python/17728, python/18439, python/18779
15928 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
15929 member. Change type of TYPE member to PyObject *. All uses updated.
15930 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
15931 (gdbpy_create_lazy_string_object): Flag bad length values.
15932 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
15933 Handle typedefs in incoming type.
15934 (stpy_lazy_string_elt_type): New function.
15935 (gdbpy_extract_lazy_string): Call it.
15936 * python/py-value.c (valpy_lazy_string): Flag bad length values.
15937 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
15938 typedefs in incoming type.
15939
a3a5fecc
DE
159402017-03-16 Doug Evans <dje@google.com>
15941
15942 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15943 * guile/scm-type.c (tyscm_scm_to_type): New function.
15944
28f1c605
JW
159452017-03-16 Jiong Wang <jiong.wang@arm.com>
15946
15947 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
15948 "ULONGEST" for "skip".
15949
87c336f6
AA
159502017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15951
15952 PR gdb/21220
15953 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
15954 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
15955 (inf_ptrace_peek_poke): ...here. New function. Now also loop
15956 over ptrace peek/poke until end of buffer or error.
15957
cf81cf60
SM
159582017-03-14 Simon Marchi <simon.marchi@ericsson.com>
15959
15960 * parse.c (length_of_subexp): Make static.
15961 * parser-defs.h (length_of_subexp): Remove.
15962
a379284a
AA
159632017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15964
15965 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
15966 as well.
15967
8a6200ba
PA
159682017-03-14 Pedro Alves <palves@redhat.com>
15969
15970 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
15971 (main): Use std::unique_ptr. Remove calls to
15972 cp_demangled_name_parse_free.
15973
f79ec206
SM
159742017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15975
15976 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
15977 alphabsd_store_inferior_registers): Use regcache->ptid instead
15978 of inferior_ptid.
15979
edb5fb00
SM
159802017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15981
15982 * aix-thread.c (aix_thread_fetch_registers,
15983 aix_thread_store_registers): Use regcache->ptid instead of
15984 inferior_ptid.
15985
55119686
SM
159862017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15987
15988 * aarch64-linux-nat.c (fetch_gregs_from_thread,
15989 store_gregs_to_thread, fetch_fpregs_from_thread,
15990 store_fpregs_to_thread): Use regcache->ptid instead of
15991 inferior_ptid.
15992
6a06fbb7
SM
159932017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15994
15995 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
15996 amd64_linux_fetch_inferior_registers): Use regcache->ptid
15997 instead of inferior_ptid.
15998
c6386875
SM
159992017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16000
16001 * target.c (target_fetch_registers, target_store_registers): Add
16002 assert.
16003
ddaaf0fb
SM
160042017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16005
16006 * regcache.h (regcache_get_ptid): New function.
16007 * regcache.c (regcache_get_ptid): New function.
16008
b9da89d1 160092017-03-13 Mark Wielaard <mark@klomp.org>
16010
16011 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
16012
5f4d1085
KS
160132017-03-10 Keith Seitz <keiths@redhat.com>
16014
16015 PR c++/8218
16016 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
16017
c65d6b55
PA
160182017-03-08 Pedro Alves <palves@redhat.com>
16019
16020 PR gdb/18360
16021 * infrun.c (start_step_over, do_target_resume, resume)
16022 (restart_threads): Assert we're not resuming a thread that is
16023 meant to be stopped.
16024 (infrun_thread_stop_requested_callback): Delete.
16025 (infrun_thread_stop_requested): If the thread is internally
16026 stopped, queue a pending stop event and clear the thread's
16027 inline-frame state.
16028 (handle_stop_requested): New function.
16029 (handle_syscall_event, handle_inferior_event_1): Use
16030 handle_stop_requested.
16031 (handle_stop_requested): New function.
16032 (handle_signal_stop): Set the thread's stop_signal here instead of
16033 at caller.
16034 (finish_step_over): Clear step over info unconditionally.
16035 (handle_signal_stop): If the user had interrupted the event
16036 thread, consider the stop a random signal.
16037 (handle_signal_stop) <signal arrived while stepping over
16038 breakpoint>: Don't restart threads here.
16039 (stop_waiting): Don't clear step-over info here.
16040
15c22686
PA
160412017-03-08 Pedro Alves <palves@redhat.com>
16042
16043 PR 21206
16044 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
16045 goes to argument 2, not 1.
16046
6e5d74e7
PA
160472017-03-08 Pedro Alves <palves@redhat.com>
16048
16049 PR cli/21218
16050 * top.c (gdb_readline_wrapper): Avoid passing NULL to
16051 display_gdb_prompt.
16052 (command_line_input): Add comment.
16053
9753a2f6
PA
160542017-03-08 Pedro Alves <palves@redhat.com>
16055
16056 PR tui/21216
16057 * tui/tui-file.c (tui_file::write): New.
16058 * tui/tui-file.h (tui_file): Override "write".
16059 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
16060 factored out from ...
16061 (tui_puts): ... here.
16062 (tui_putc): Use them.
16063 (tui_write): New function.
16064 * tui/tui-io.h (tui_write): Declare.
16065
1672e0d9
SDJ
160662017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
16067
16068 * Makefile.in (SFILES): Replace "environ.c" with
16069 "common/environ.c".
16070 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
16071 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
16072 to...
16073 * common/environ.c: ... here.
16074 * environ.h: Moved to...
16075 * common/environ.h: ... here.
16076
f7bb4e3a
PB
160772017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16078
16079 * gdbarch.sh (pstring_ptr): New static function.
16080 (gdbarch_disassembler_options): Use it.
16081 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
16082 not valid_disassembler_option->name.
16083 * gdbarch.c: Regenerate.
16084
e45ced6c
PB
160852017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16086
16087 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
16088
5f6fd321
PA
160892017-03-07 Pedro Alves <palves@redhat.com>
16090
16091 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
16092
6dbb839a 160932017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
16094
16095 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
16096 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
16097 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 16098 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 16099
d274ecf4
SM
161002017-03-06 Simon Marchi <simon.marchi@ericsson.com>
16101
16102 * xtensa-linux-nat.c (fetch_gregs): Remove const.
16103
df97be55
SM
161042017-03-03 Simon Marchi <simon.marchi@ericsson.com>
16105
16106 * remote.c (remote_add_target_side_commands): Use range-based
16107 for loop.
16108
7d45f3df
YQ
161092017-03-03 Yao Qi <yao.qi@linaro.org>
16110
16111 PR gdb/21165
16112 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
16113 value is lazy.
16114 * valprint.c (common_val_print): Likewise.
16115
65b48a81
PB
161162017-02-28 Peter Bergner <bergner@vnet.ibm.com>
16117
16118 * NEWS: Mention new set/show disassembler-options commands.
16119 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
16120 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
16121 (prospective_options): New static variable.
16122 (gdb_disassembler::gdb_disassembler): Initialize
16123 m_di.disassembler_options.
16124 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
16125 (get_disassembler_options): New function.
16126 (set_disassembler_options): Likewise.
16127 (set_disassembler_options_sfunc): Likewise.
16128 (show_disassembler_options_sfunc): Likewise.
16129 (disassembler_options_completer): Likewise.
16130 (_initialize_disasm): Likewise.
16131 * disasm.h (get_disassembler_options): New prototype.
16132 (set_disassembler_options): Likewise.
16133 * gdbarch.sh (gdbarch_disassembler_options): New variable.
16134 (gdbarch_verify_disassembler_options): Likewise.
16135 * gdbarch.c: Regenerate.
16136 * gdbarch.h: Likewise.
16137 * arm-tdep.c (num_disassembly_options): Delete.
16138 (set_disassembly_style): Likewise.
16139 (arm_disassembler_options): New static variable.
16140 (set_disassembly_style_sfunc): Convert short style name into long
16141 option name. Call set_disassembler_options.
16142 (show_disassembly_style_sfunc): New function.
16143 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
16144 set_gdbarch_verify_disassembler_options.
16145 (_initialize_arm_tdep): Delete regnames variable and update callers.
16146 (arm_disassembler_options): Initialize.
16147 (disasm_options): New variable.
16148 (num_disassembly_options): Rename from this...
16149 (num_disassembly_styles): ...to this. Compute by scanning through
16150 disasm_options.
16151 (valid_disassembly_styles): Initialize using disasm_options.
16152 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
16153 set_arm_regname_option.
16154 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
16155 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
16156 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
16157 set_gdbarch_verify_disassembler_options.
16158 * s390-tdep.c (s390_disassembler_options): New static variable.
16159 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
16160 set_gdbarch_verify_disassembler_options.
16161
d538e36d
SM
161622017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16163
16164 * remote.c (remote_add_target_side_condition): Remove "struct"
16165 keyword from range-based for loop.
16166
83621223
SM
161672017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16168
16169 * remote.c (remote_add_target_side_condition): Use range-based
16170 for loop. Update comment.
16171
2123df0e
YQ
161722017-02-27 Yao Qi <yao.qi@linaro.org>
16173
16174 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
16175
8e368124
AH
161762017-02-26 Alan Hayward <alan.hayward@arm.com>
16177
16178 * regcache.c (regcache_raw_update): New function.
16179 (regcache_raw_read): Move code to regcache_raw_update.
16180 * regcache.h (regcache_raw_update): New declaration.
16181 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
16182
a49dd8dd
JK
161832017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
16184
16185 * dwarf2read.c (create_debug_type_hash_table): Initialize
16186 header.signature and header.type_offset_in_tu.
16187
34e4bae9
PA
161882017-02-24 Pedro Alves <palves@redhat.com>
16189
16190 * symtab.c (make_file_symbol_completion_list_1): Use
16191 add_symtab_completions.
16192
b0e4b369
AH
161932017-02-24 Alan Hayward <alan.hayward@arm.com>
16194
16195 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
16196
975c21ab
AH
161972017-02-24 Alan Hayward <alan.hayward@arm.com>
16198
16199 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
16200 I386_MAX_REGISTER_SIZE.
16201 (i386_pseudo_register_write): Likewise.
16202 (i386_process_record): Likewise.
16203 * i387-tdep.c (i387_supply_xsave): Likewise.
16204 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
16205 (store_register): Likewise.
16206
14bc53a8
PA
162072017-02-23 Pedro Alves <palves@redhat.com>
16208
16209 * ada-lang.c: Include "common/function-view.h".
16210 (ada_iterate_over_symbols): Adjust to use function_view as
16211 callback type.
16212 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
16213 (ada_make_symbol_completion_list): Use a lambda.
16214 (ada_exc_search_name_matches): Delete.
16215 (name_matches_regex): New.
16216 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
16217 * compile/compile-c-support.c: Include "common/function-view.h".
16218 (print_one_macro): Change prototype to accept a ui_file pointer.
16219 (write_macro_definitions): Use a lambda.
16220 * dwarf2read.c: Include "common/function-view.h".
16221 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
16222 (dw2_expand_symtabs_matching): Adjust to use function_view as
16223 callback type.
16224 * language.h: Include "common/function-view.h".
16225 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
16226 function_view as callback type.
16227 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
16228 * linespec.c: Include "common/function-view.h".
16229 (collect_info::add_symbol): New method.
16230 (struct symbol_and_data_callback, iterate_inline_only, struct
16231 symbol_matcher_data, iterate_name_matcher): Delete.
16232 (iterate_over_all_matching_symtabs): Adjust to use function_view
16233 as callback type and lambdas.
16234 (iterate_over_file_blocks): Adjust to use function_view as
16235 callback type.
16236 (decode_compound_collector): Now a class with private fields.
16237 (decode_compound_collector::release_symbols): New method.
16238 (collect_one_symbol): Rename to...
16239 (decode_compound_collector::operator()): ... this and adjust.
16240 (lookup_prefix_sym): decode_compound_collector construction bits
16241 move to decode_compound_collector ctor. Pass the
16242 decode_compound_collector object directly as callback. Remove
16243 cleanups and use decode_compound_collector::release_symbols
16244 instead.
16245 (symtab_collector): Now a class with private fields.
16246 (symtab_collector::release_symtabs): New method.
16247 (add_symtabs_to_list): Rename to...
16248 (symtab_collector::operator()): ... this and adjust.
16249 (collect_symtabs_from_filename): symtab_collector construction
16250 bits move to symtab_collector ctor. Pass the symtab_collector
16251 object directly as callback. Remove cleanups and use
16252 symtab_collector::release_symtabs instead.
16253 (collect_symbols): Delete.
16254 (add_matching_symbols_to_info): Use lambdas.
16255 * macrocmd.c (print_macro_callback): Delete.
16256 (info_macro_command): Use a lambda.
16257 (info_macros_command): Pass print_macro_definition as callable
16258 directly.
16259 (print_one_macro): Remove 'ignore' parameter.
16260 (macro_list_command): Adjust.
16261 * macrotab.c (macro_for_each_data::fn): Now a function_view.
16262 (macro_for_each_data::user_data): Delete field.
16263 (foreach_macro): Adjust to call the function_view.
16264 (macro_for_each): Adjust to use function_view as callback type.
16265 (foreach_macro_in_scope): Adjust to call the function_view.
16266 (macro_for_each_in_scope): Adjust to use function_view as callback
16267 type.
16268 * macrotab.h: Include "common/function-view.h".
16269 (macro_callback_fn): Declare a prototype instead of a pointer.
16270 Remove "user_data" parameter.
16271 (macro_for_each, macro_for_each_in_scope): Adjust to use
16272 function_view as callback type.
16273 * psymtab.c (partial_map_expand_apply)
16274 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
16275 Adjust to use function_view as callback type and to return bool.
16276 (psym_expand_symtabs_matching): Adjust to use function_view as
16277 callback types.
16278 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
16279 to use function_view as callback type and to return bool.
16280 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
16281 callback types.
16282 * symfile.c (expand_symtabs_matching): Adjust to use function_view
16283 as callback types.
16284 * symfile.h: Include "common/function-view.h".
16285 (expand_symtabs_file_matcher_ftype)
16286 (expand_symtabs_symbol_matcher_ftype)
16287 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
16288 return bool.
16289 (quick_symbol_functions::map_symtabs_matching_filename)
16290 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
16291 function_view as callback type and return bool.
16292 (expand_symtabs_matching): Adjust to use function_view as callback
16293 type.
16294 (maintenance_expand_name_matcher)
16295 (maintenance_expand_file_matcher): Delete.
16296 (maintenance_expand_symtabs): Use lambdas.
16297 * symtab.c (iterate_over_some_symtabs): Adjust to use
16298 function_view as callback types and return bool.
16299 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
16300 of a cleanup.
16301 (lookup_symtab_callback): Delete.
16302 (lookup_symtab): Use a lambda.
16303 (iterate_over_symbols): Adjust to use function_view as callback
16304 type.
16305 (struct search_symbols_data, search_symbols_file_matches)
16306 (search_symbols_name_matches): Delete.
16307 (search_symbols): Use a pair of lambdas.
16308 (struct add_name_data, add_macro_name, symbol_completion_matcher)
16309 (symtab_expansion_callback): Delete.
16310 (default_make_symbol_completion_list_break_on_1): Use lambdas.
16311 * symtab.h: Include "common/function-view.h".
16312 (iterate_over_some_symtabs): Adjust to use function_view as
16313 callback type and return bool.
16314 (iterate_over_symtabs): Adjust to use function_view as callback
16315 type.
16316 (symbol_found_callback_ftype): Remove 'data' parameter and return
16317 bool.
16318 (iterate_over_symbols): Adjust to use function_view as callback
16319 type.
16320
07e253aa
PA
163212017-02-23 Pedro Alves <palves@redhat.com>
16322
16323 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
16324 (%.o) <unittests/%.c>: New pattern.
16325 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
16326 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
16327 * common/function-view.h: New file.
16328 * unittests/function-view-selftests.c: New file.
16329 * configure: Regenerate.
16330
8eaf5320
SM
163312017-02-23 Simon Marchi <simon.marchi@ericsson.com>
16332
16333 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
16334 inferior_ptid.
16335 * go32-nat.c (go32_thread_alive): Likewise.
16336
38768751
YQ
163372017-02-23 Yao Qi <yao.qi@linaro.org>
16338
16339 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
16340 delete.
16341
0a8beaba
YQ
163422017-02-23 Yao Qi <yao.qi@linaro.org>
16343
16344 * varobj.c (varobj_clear_saved_item): Use delete instead of
16345 xfree.
16346 (update_dynamic_varobj_children): Likewise.
16347
58fdfd2c
JK
163482017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16349
16350 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
16351
1b90b139
SM
163522017-02-21 Simon Marchi <simon.marchi@ericsson.com>
16353
16354 * common/enum-flags.h (enum_flags::enum_flags): Initialize
16355 m_enum_value to 0 in default constructor.
16356
2039d74e
EBM
163572017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
16358
16359 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
16360 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
16361 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
16362 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
16363 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
16364 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
16365 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
16366 IS_STORE_CONDITIONAL_INSN.
16367
7814882a
JK
163682017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16369
16370 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
16371
0ae60b63
JK
163722017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16373
16374 * NEWS (Changes since GDB 7.12): Add DWARF-5.
16375
0224619f
JK
163762017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16377
16378 * dwarf2read.c (skip_one_die, read_attribute_value)
16379 (dwarf2_const_value_attr, dump_die_shallow)
16380 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
16381 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
16382
0af92d60
JK
163832017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16384
16385 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
16386 (dwarf_parse_macro_header): Accept DWARF version 5.
16387 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
16388
216f72a1
JK
163892017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16390
16391 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
16392 DW_AT_GNU_*.
16393 * common/common-exceptions.h (enum errors): Likewise.
16394 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
16395 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
16396 (dwarf_expr_context::execute_stack_op): Likewise.
16397 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
16398 Likewise.
16399 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
16400 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
16401 (show_entry_values_debug, call_site_to_target_addr)
16402 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
16403 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
16404 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
16405 (value_of_dwarf_block_entry, indirect_pieced_value)
16406 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
16407 (disassemble_dwarf_expression): Likewise.
16408 * dwarf2read.c (process_die, inherit_abstract_dies)
16409 (read_call_site_scope): Likewise.
16410 * gdbtypes.h (struct func_type, struct call_site_parameter)
16411 (struct call_site): Likewise.
16412 * stack.c (read_frame_arg): Likewise.
16413 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
16414
43988095
JK
164152017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16416
16417 * defs.h (read_unsigned_leb128): New declaration.
16418 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
16419 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
16420 (dwarf2_find_location_expression): Call also
16421 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
16422 * dwarf2loc.h (dwarf2_version): New declaration.
16423 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
16424 rnglists.
16425 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
16426 .debug_rnglists.
16427 (struct dwop_section_names): Add loclists_dwo.
16428 (dwop_section_names): Add .debug_loclists.dwo.
16429 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
16430 (struct dwarf2_per_cu_data): Add dwarf_version.
16431 (struct dwo_sections): Add loclists.
16432 (struct attr_abbrev): Add implicit_const.
16433 (read_indirect_line_string): New declaration.
16434 (read_unsigned_leb128): Delete declaration.
16435 (rcuh_kind): New definition.
16436 (read_and_check_comp_unit_head): Change parameter
16437 is_debug_types_section to section_kind.
16438 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
16439 (read_comp_unit_head): Change parameter abfd to section, add parameter
16440 section_kind. Handle DWARF-5.
16441 (error_check_comp_unit_head): Accept also DWARF version 5.
16442 (read_and_check_comp_unit_head): Change parameter
16443 is_debug_types_section to section_kind.
16444 (read_and_check_type_unit_head): Delete function.
16445 (read_abbrev_offset): Handle DWARF-5.
16446 (create_debug_type_hash_table): Add parameter section_kind. Process
16447 only DW_UT_type. Use signature and type_offset_in_tu from struct
16448 comp_unit_head.
16449 (create_debug_types_hash_table): Update create_debug_type_hash_table
16450 caller.
16451 (create_all_type_units): Call create_debug_type_hash_table.
16452 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
16453 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
16454 caller.
16455 (skip_one_die): Handle DW_FORM_implicit_const.
16456 (dwarf2_rnglists_process): New function.
16457 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
16458 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
16459 (read_attribute_value): Handle DW_FORM_implicit_const,
16460 DW_FORM_line_strp.
16461 (read_attribute): Handle DW_FORM_implicit_const.
16462 (read_indirect_string_at_offset_from): New function from
16463 read_indirect_string_at_offset.
16464 (read_indirect_string_at_offset): Call
16465 read_indirect_string_at_offset_from.
16466 (read_indirect_line_string_at_offset): New function.
16467 (read_indirect_string): New function comment.
16468 (read_indirect_line_string): New function.
16469 (read_unsigned_leb128): Make it global.
16470 (dwarf2_string_attr): Handle DWARF-5.
16471 (add_include_dir_stub, read_formatted_entries): New functions.
16472 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
16473 Handle DWARF-5.
16474 (per_cu_header_read_in): Update read_comp_unit_head caller.
16475 (dwarf2_version): New function.
16476 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
16477 rnglists.
16478 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16479 fields.
16480
22d2f3ab
JK
164812017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16482
16483 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16484
5f46c5a5
JK
164852017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16486
16487 * dwarf2read.c (dwarf2_ranges_process): New function from
16488 dwarf2_ranges_read.
16489 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16490 dwarf2_ranges_process.
16491
78d4d2c5
JK
164922017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16493
16494 * dwarf2read.c (create_debug_type_hash_table): New function from
16495 create_debug_types_hash_table.
16496 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16497 (create_all_type_units, open_and_init_dwo_file): Update
16498 create_debug_types_hash_table callers.
16499
1b076f25
SDJ
165002017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16501
16502 PR gdb/16188
16503 * fork-child.c (trace_start_error): Fix thinko. va_end should
16504 refer to 'ap', not 'args'.
16505
0db8980c
SDJ
165062017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16507 Pedro Alves <palves@redhat.com>
16508
16509 PR gdb/16188
16510 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16511 calls succeeded.
16512 * fork-child.c (trace_start_error): New function.
16513 (trace_start_error_with_name): Likewise.
16514 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16515 * inf-ptrace.c (inf_ptrace_me): Likewise.
16516 * inferior.h (trace_start_error): New prototype.
16517 (trace_start_error_with_name): Likewise.
16518
99e8a4f9
SDJ
165192017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16520
16521 PR gdb/21164
16522 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16523 NULL before using it.
16524 * symmisc.c (maintenance_print_symbols): Likewise.
16525 (maintenance_print_msymbols): Likewise.
16526
4e746bb6
TW
165272017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16528
16529 * NEWS: Add record Python bindings entry.
16530
165312017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16532
16533 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16534 py-record-full.o.
16535 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16536 * python/py-record-btrace.c, python/py-record-btrace.h,
16537 python/py-record-full.c, python/py-record-full.h: New file.
16538 * python/py-record.c: Add include for py-record-btrace.h and
16539 py-record-full.h.
16540 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16541 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16542 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16543 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16544 New definition.
16545 (gdbpy_initialize_btrace): New export.
16546 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16547
165482017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16549
16550 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16551 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16552 * python/py-record.c: New file.
16553 * python/python-internal.h (gdbpy_start_recording,
16554 gdbpy_current_recording, gdpy_stop_recording,
16555 gdbpy_initialize_record): New export.
16556 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16557 (python_GdbMethods): Add gdbpy_start_recording,
16558 gdbpy_current_recording and gdbpy_stop_recording.
16559
165602017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16561
16562 * record-btrace.c (record_btrace_record_method): New function.
16563 (init_record_btrace_ops): Initialize to_record_method.
16564 * record-full.c (record_full_record_method): New function.
16565 (init_record_full_ops, init_record_full_core_ops): Add
16566 record_full_record_method.
16567 * record.h (enum record_method): New enum.
16568 * target-debug.h (target_debug_print_enum_record_method: New define.
16569 * target-delegates.c: Regenerate.
16570 * target.c (target_record_method): New function.
16571 * target.h: Include record.h.
16572 (struct target_ops) <to_record_method>: New field.
16573 (target_record_method): New export.
16574
165752017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16576
16577 * record.h (record_start, record_stop): New export.
16578 * record.c (record_start, record_stop): New function.
16579
165802017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16581
16582 * btrace.c (btrace_fetch): Copy function call segments pointer
16583 into a vector.
16584 (btrace_clear): Clear the vector.
16585 (btrace_find_insn_by_number): Use binary search to find the correct
16586 function call segment.
16587 * btrace.h (brace_fun_p): New typedef.
16588 (struct btrace_thread_info) <functions>: New field.
16589
165902017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16591
16592 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16593 * btrace.c (btrace_decode_error): ... here. New function.
16594 * btrace.h (btrace_decode_error): New export.
16595
165962017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16597
16598 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16599 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16600 btrace_find_insn_by_number): Remove special case for gaps.
16601 * btrace.h (btrace_insn_get_error): New export.
16602 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16603 * record-btrace.c (btrace_insn_history): Print number for gaps.
16604 (record_btrace_info, record_btrace_goto): Handle gaps.
16605
3f77c769
TT
166062017-02-14 Tom Tromey <tom@tromey.com>
16607
16608 PR python/13598:
16609 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16610 event.
16611 * python/py-evts.c (gdbpy_initialize_py_events): Add
16612 before_prompt registry.
16613 * python/py-events.h (events_object) <before_prompt>: New field.
16614
4c2c7ac6
MM
166152017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16616
16617 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16618
5cf30ebf
LM
166192017-02-13 Luis Machado <lgustavo@codesourcery.com>
16620
16621 * symfile (_initialize_symfile): Add usage text to the load command's
16622 help text.
16623
26a06916
SM
166242017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16625
16626 * utils.c (defaulted_query): Don't query on secondary UIs.
16627
0b145e37
TT
166282017-02-10 Tom Tromey <tom@tromey.com>
16629
16630 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16631
2d8365c4
TT
166322017-02-10 Tom Tromey <tom@tromey.com>
16633
16634 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16635 "cleanup" local.
16636 * python/py-type.c (typy_legacy_template_argument): Remove
16637 unnecessary "cleanup" local.
16638
2bb8f231
TT
166392017-02-10 Tom Tromey <tom@tromey.com>
16640
16641 * python/python.c (do_start_initialization): New function, from
16642 _initialize_python.
16643 (_initialize_python): Call do_start_initialization.
16644 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16645 goto.
16646
1bdfaf42
TT
166472017-02-10 Tom Tromey <tom@tromey.com>
16648
16649 * python/py-prettyprint.c (pretty_print_one_value): Use
16650 gdbpy_ref.
16651
88b6faea
TT
166522017-02-10 Tom Tromey <tom@tromey.com>
16653
16654 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16655 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16656 gdbpy_ref.
16657 * python/py-type.c (field_new): Use gdbpy_ref.
16658 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16659 gdbpy_ref.
16660 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16661 (py_free_pspace): Likewise.
16662 (pspace_to_pspace_object): Likewise.
16663 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16664 (py_free_objfile): Likewise.
16665 (objfile_to_objfile_object): Likewise.
16666 * python/py-inferior.c (delete_thread_object): Use
16667 gdbpy_ref.
16668 (infpy_read_memory): Likewise.
16669 (py_free_inferior): Likewise.
16670 * python/py-evtregistry.c (create_eventregistry_object): Use
16671 gdbpy_ref.
16672 * python/py-event.c (create_event_object): Use gdbpy_ref.
16673
7780f186
TT
166742017-02-10 Tom Tromey <tom@tromey.com>
16675
16676 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16677 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16678 used.
16679 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16680 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16681 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16682 python/py-framefilter.c, python/py-function.c,
16683 python/py-inferior.c, python/py-infevents.c,
16684 python/py-linetable.c, python/py-newobjfileevent.c,
16685 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16686 python/py-signalevent.c, python/py-stopevent.c,
16687 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16688 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16689 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16690 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16691
d4b0bb18
TT
166922017-02-10 Tom Tromey <tom@tromey.com>
16693
16694 * ui-out.h (ui_out_emit_type): New class.
16695 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16696 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16697 and ui_out_emit_tuple.
16698 (enumerate_locals): Likewise.
16699 (py_mi_print_variables, py_print_locals, py_print_args): Use
16700 ui_out_emit_list.
16701 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16702 ui_out_emit_list.
16703 * common/gdb_optional.h: New file.
16704
f67f945c
MG
167052017-02-10 Martin Galvan <martingalvan@sourceware.org>
16706
16707 * MAINTAINERS (Write After Approval): Update my e-mail address.
16708
18da0c51
MG
167092017-02-10 Martin Galvan <martingalvan@sourceware.org>
16710
16711 PR gdb/21122
16712 * breakpoint.c (_initialize_breakpoint): Update the help description
16713 of the 'commands' command to indicate that it takes a list argument.
16714
62c14536
SM
167152017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16716
16717 * interps.c (current_interp_set_logging): Remove "return".
16718
ff6fa247
GB
167192017-02-09 Gary Benson <gbenson@redhat.com>
16720
16721 * symtab.c (add_symtab_completions): Prevent NULL pointer
16722 dereference.
16723
a474bd8e
PA
167242017-02-08 Pedro Alves <palves@redhat.com>
16725
16726 * interps.c (interp::interp): Remove reference to quiet_p.
16727 (interp_set): Make static. Remove dead "Switching to" output
16728 code.
16729 (interp_quiet_p, interp_set_quiet): Delete.
16730 (interpreter_exec_cmd): Don't set the interpreter quiet.
16731 * interps.h (interp_quiet_p): Make static.
16732 (class interp) <quiet_p>: Remove field
16733
3d7b173c
JG
167342017-02-08 Jerome Guitton <guitton@adacore.com>
16735
604c4576
JG
16736 * cli/cli-decode.c (find_command_name_length): Make it extern.
16737 * cli/cli-decode.h (find_command_name_length): Declare.
16738 * cli/cli-script.c (command_name_equals, line_first_arg):
16739 New functions.
16740 (process_next_line): Use cli-decode to parse command names.
16741 (build_command_line): Make args a constant pointer.
16742
167432017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 16744
3d7b173c
JG
16745 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16746 Remove case-insensitive search.
16747
1291063d
JM
167482017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16749
16750 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16751 at the end of the line. Avoids an ARI warning.
16752
20b477a7
LM
167532017-02-06 Luis Machado <lgustavo@codesourcery.com>
16754
16755 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16756 rdseed instructions.
16757 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16758
3f7b46f2
IR
167592017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16760
16761 PR tdep/20936
16762 Provide and use sparc32 and sparc64 target description XML files.
16763 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16764 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16765 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16766 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16767 * features/sparc/sparc32-solaris.xml: New file.
16768 * features/sparc/sparc64-solaris.xml: New file.
16769 * features/sparc/sparc32-solaris.c: Generated.
16770 * features/sparc/sparc64-solaris.c: Generated.
16771 * sparc-tdep.h: Account for differences in target descriptions.
16772 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16773 (sparc32_register_type): Use target provided registers.
16774 (validate_tdesc_registers): New function.
16775 (sparc32_gdbarch_init): Use tdesc_has_registers.
16776 Set pseudoregister functions.
16777 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16778 (sparc64_register_type): Use target provided registers.
16779 (sparc64_init_abi): Set pseudoregister functions.
16780
f0fd41c1
TT
167812017-02-03 Tom Tromey <tom@tromey.com>
16782
16783 PR rust/21097:
16784 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16785 with a single member.
16786
d6f9b0fb
PA
167872017-02-03 Pedro Alves <palves@redhat.com>
16788
16789 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16790 (cli_interp_base::~cli_interp_base): New.
16791 (cli_interp): New struct.
16792 (as_cli_interp): Cast the interp itself to cli_interp.
16793 (cli_interpreter_pre_command_loop): Rename to ...
16794 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16795 parameter.
16796 (cli_interpreter_init): Rename to ...
16797 (cli_interp::init): ... this. Remove 'self' parameter. Use
16798 boolean. Make extern.
16799 (cli_interpreter_resume): Rename to ...
16800 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16801 extern.
16802 (cli_interpreter_suspend): Rename to ...
16803 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16804 extern.
16805 (cli_interpreter_exec): Rename to ...
16806 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16807 extern.
16808 (cli_interpreter_supports_command_editing): Rename to ...
16809 (cli_interp_base::supports_command_editing): ... this. Remove
16810 'interp' parameter. Make extern.
16811 (cli_ui_out): Rename to ...
16812 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16813 Make extern.
16814 (cli_set_logging): Rename to ...
16815 (cli_interp_base::set_logging): ... this. Remove 'interp'
16816 parameter. Make extern.
16817 (cli_interp_procs): Delete.
16818 (cli_interp_factory): Adjust to use "new".
16819 * cli/cli-interp.h: Include "interps.h".
16820 (struct cli_interp_base): New struct.
16821 * interps.c (struct interp): Delete. Fields moved to interps.h.
16822 (interp_new): Delete.
16823 (interp::interp, interp::~interp): New.
16824 (interp_set): Use bool, and return void. Assume the interpreter
16825 has suspend, init and resume methods, and that the all return
16826 void.
16827 (set_top_level_interpreter): interp_set returns void.
16828 (interp_ui_out): Adapt.
16829 (current_interp_set_logging): Adapt.
16830 (interp_data): Delete.
16831 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
16832 (interp_exec): Adapt.
16833 (top_level_interpreter_data): Delete.
16834 * interps.h (interp_init_ftype, interp_resume_ftype)
16835 (interp_suspend_ftype, interp_exec_ftype)
16836 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
16837 (class interp): New.
16838 (interp_new): Delete.
16839 (interp_set): Now returns void. Use bool.
16840 (interp_data, top_level_interpreter_data): Delete.
16841 * mi/mi-common.h: Include interps.h.
16842 (class mi_interp): Inherit from interp. Define a ctor. Declare
16843 init, resume, suspect, exec, interp_ui_out, set_logging and
16844 pre_command_loop methods.
16845 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
16846 (mi_interpreter_init): Rename to ...
16847 (mi_interp::init): ... this. Remove the 'interp' parameter, use
16848 bool, return void and make extern. Adjust.
16849 (mi_interpreter_resume): ... Rename to ...
16850 (mi_interp::resume): ... this. Remove the 'data' parameter,
16851 return void and make extern. Adjust.
16852 (mi_interpreter_suspend): ... Rename to ...
16853 (mi_interp::suspend): ... this. Remove the 'data' parameter,
16854 return void and make extern. Adjust.
16855 (mi_interpreter_exec): ... Rename to ...
16856 (mi_interp::exec): ... this. Remove the 'data' parameter and make
16857 extern. Adjust.
16858 (mi_interpreter_pre_command_loop): ... Rename to ...
16859 (mi_interp::pre_command_loop): ... this. Remove the 'self'
16860 parameter and make extern.
16861 (mi_on_normal_stop_1): Adjust.
16862 (mi_ui_out): Rename to ...
16863 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
16864 parameter and make extern. Adjust.
16865 (mi_set_logging): Rename to ...
16866 (mi_interp::set_logging): ... this. Remove the 'interp'
16867 parameter and make extern. Adjust.
16868 (mi_interp_procs): Delete.
16869 (mi_interp_factory): Adjust to use 'new'.
16870 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
16871 (mi_print_exception, mi_execute_command, mi_load_progress):
16872 Adjust.
16873 * tui/tui-interp.c (tui_interp): New class.
16874 (as_tui_interp): Return a tui_interp pointer.
16875 (tui_on_normal_stop, tui_on_signal_received)
16876 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
16877 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
16878 to use interp::interp_ui_out.
16879 (tui_init): Rename to ...
16880 (tui_interp::init): ... this. Remove the 'self' parameter, use
16881 bool, return void and make extern. Adjust.
16882 (tui_resume): Rename to ...
16883 (tui_interp::resume): ... this. Remove the 'data' parameter,
16884 return void and make extern. Adjust.
16885 (tui_suspend): Rename to ...
16886 (tui_interp::suspend): ... this. Remove the 'data' parameter,
16887 return void and make extern. Adjust.
16888 (tui_ui_out): Rename to ...
16889 (tui_interp::interp_ui_out): ... this. Remove the 'self'
16890 parameter, and make extern. Adjust.
16891 (tui_exec): Rename to ...
16892 (tui_interp::exec): ... this. Remove the 'data' parameter and
16893 make extern.
16894 (tui_interp_procs): Delete.
16895 (tui_interp_factory): Use "new".
16896
65c40c95
TT
168972017-02-02 Tom Tromey <tom@tromey.com>
16898
16899 * rust-exp.y (ends_raw_string, space_then_number)
16900 (rust_identifier_start_p): Return bool.
16901 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
16902 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
16903 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
16904 (rust_chartype_p): Return bool.
16905 (val_print_struct, rust_print_struct_def, rust_print_type):
16906 Update.
16907 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
16908 Return bool.
16909
b50f188d
TT
169102017-02-02 Tom Tromey <tom@tromey.com>
16911
16912 * rust-lang.c: Reindent.
16913
03c85b11
TT
169142017-02-02 Tom Tromey <tom@tromey.com>
16915
16916 * rust-lang.h (rust_crate_for_block): Update.
16917 * rust-lang.c (rust_crate_for_block): Return std::string.
16918 (rust_get_disr_info): Use std:;string, not
16919 gdb::unique_xmalloc_ptr.
16920 * rust-exp.y (crate_name): Update.
16921
9b6da501
PA
169222017-02-02 Pedro Alves <palves@redhat.com>
16923
16924 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
16925 field out of gdb_disassembler_test and make it static.
16926
ec4cb20b
PA
169272017-02-02 Pedro Alves <palves@redhat.com>
16928
16929 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
16930 mi1_interp and mi_interp fields.
16931
5be5dbf0
PA
169322017-02-02 Pedro Alves <palves@redhat.com>
16933
616268b6
PA
16934 * cli/cli-interp.c (struct saved_output_files, saved_output):
16935 Moved from cli/cli-logging.c.
16936 (cli_set_logging): New function.
16937 (cli_interp_procs): Install cli_set_logging.
16938 * cli/cli-interp.h (make_logging_output, cli_set_logging):
16939 Declare.
16940 * cli/cli-logging.c (struct saved_output_files, saved_output):
16941 Moved to cli/cli-interp.c.
16942 (pop_output_files): Don't save outputs here.
16943 (make_logging_output): New function.
16944 (handle_redirections): Don't build tee nor save previous outputs
16945 here.
16946 * interps.c (current_interp_set_logging): Change prototype.
16947 Assume there's always a set_logging_proc method installed.
16948 * interps.h (interp_set_logging_ftype): Change prototype.
16949 (current_interp_set_logging): Change prototype and adjust comment.
16950 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
16951 use make_logging_output.
16952 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
169532017-02-02 Pedro Alves <palves@redhat.com>
16954
5be5dbf0
PA
16955 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
16956 from ...
16957 (set_logging_overwrite): ... here.
16958 (logging_no_redirect_file): Delete.
16959 (set_logging_redirect): Don't handle redirection on the fly.
16960 Instead warn that "logging off" / "logging on" is necessary.
16961 (pop_output_files): Delete references to logging_no_redirect_file.
16962 (show_logging_command): Always speak in terms of what will happen
16963 once logging is reenabled.
16964
c99cc448
PA
169652017-02-02 Pedro Alves <palves@redhat.com>
16966
16967 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
16968
8b172ce7
PA
169692017-02-02 Pedro Alves <palves@redhat.com>
16970
16971 * disasm.c (gdb_pretty_print_insn): Rename to ...
16972 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
16973 Remove gdbarch parameter. Adapt to clear the object's buffers
16974 instead of allocating new buffers, and to print using the object's
16975 gdb_disassembler instead of calling gdb_print_insn.
16976 (dump_insns): Use gdb_pretty_print_disassembler.
16977 * disasm.h (gdb_pretty_print_insn): Delete declaration.
16978 (gdb_pretty_print_disassembler): New class.
16979 * record-btrace.c (btrace_insn_history): Use
16980 gdb_pretty_print_disassembler.
16981
d7e74731
PA
169822017-02-02 Pedro Alves <palves@redhat.com>
16983
16984 * ada-lang.c (type_as_string): Use string_file.
16985 * ada-valprint.c (ada_print_floating): Use string_file.
16986 * ada-varobj.c (ada_varobj_scalar_image)
16987 (ada_varobj_get_value_image): Use string_file.
16988 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
16989 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
16990 * breakpoint.c (update_inserted_breakpoint_locations)
16991 (insert_breakpoint_locations, reattach_breakpoints)
16992 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
16993 (print_it_watchpoint): Use string_file.
16994 (save_breakpoints): Use stdio_file.
16995 * c-exp.y (oper): Use string_file.
16996 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
16997 tee_file.
16998 (pop_output_files): Use delete.
16999 (handle_redirections): Use stdio_file and tee_file.
17000 * cli/cli-setshow.c (do_show_command): Use string_file.
17001 * compile/compile-c-support.c (c_compute_program): Use
17002 string_file.
17003 * compile/compile-c-symbols.c (generate_vla_size): Take a
17004 'string_file &' instead of a 'ui_file *'.
17005 (generate_c_for_for_one_variable): Take a 'string_file &' instead
17006 of a 'ui_file *'. Use string_file.
17007 (generate_c_for_variable_locations): Take a 'string_file &'
17008 instead of a 'ui_file *'.
17009 * compile/compile-internal.h (generate_c_for_for_one_variable):
17010 Take a 'string_file &' instead of a 'ui_file *'.
17011 * compile/compile-loc2c.c (push, pushf, unary, binary)
17012 (print_label, pushf_register_address, pushf_register)
17013 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
17014 'ui_file *'. Adjust.
17015 * compile/compile.c (compile_to_object): Use string_file.
17016 * compile/compile.h (compile_dwarf_expr_to_c)
17017 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
17018 'ui_file *'.
17019 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
17020 (replace_typedefs_qualified_name): Use string_file and
17021 obstack_copy0.
17022 * disasm.c (gdb_pretty_print_insn): Use string_file.
17023 (gdb_disassembly): Adjust reference the null_stream global.
17024 (do_ui_file_delete): Delete.
17025 (gdb_insn_length): Use null_stream.
17026 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
17027 * dwarf2loc.c (dwarf2_compile_property_to_c)
17028 (locexpr_generate_c_location, loclist_generate_c_location): Take a
17029 'string_file &' instead of a 'ui_file *'.
17030 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
17031 * dwarf2read.c (do_ui_file_peek_last): Delete.
17032 (dwarf2_compute_name): Use string_file.
17033 * event-top.c (gdb_setup_readline): Use stdio_file.
17034 * gdbarch.sh (verify_gdbarch): Use string_file.
17035 * gdbtypes.c (safe_parse_type): Use null_stream.
17036 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
17037 string_file.
17038 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
17039 'string_file *' instead of a 'ui_file *'.
17040 (gdbscm_arch_disassemble): Use string_file.
17041 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
17042 * guile/scm-ports.c (class ioscm_file_port): Now a class that
17043 inherits from ui_file.
17044 (ioscm_file_port_delete, ioscm_file_port_rewind)
17045 (ioscm_file_port_put): Delete.
17046 (ioscm_file_port_write): Rename to ...
17047 (ioscm_file_port::write): ... this. Remove file_port_magic
17048 checks.
17049 (ioscm_file_port_new): Delete.
17050 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
17051 ui_file_up.
17052 * guile/scm-type.c (tyscm_type_name): Use string_file.
17053 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
17054 Use string_file.
17055 * infcmd.c (print_return_value_1): Use string_file.
17056 * infrun.c (print_target_wait_results): Use string_file.
17057 * language.c (add_language): Use string_file.
17058 * location.c (explicit_to_string_internal): Use string_file.
17059 * main.c (captured_main_1): Use null_file.
17060 * maint.c (maintenance_print_architecture): Use stdio_file.
17061 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
17062 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
17063 event_channel>: Change type to mi_console_file pointer.
17064 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
17065 (mi_console_file_delete): Delete.
17066 (struct mi_console_file): Delete.
17067 (mi_console_file_magic): Delete.
17068 (mi_console_file_new): Delete.
17069 (mi_console_file::mi_console_file): New.
17070 (mi_console_file_delete): Delete.
17071 (mi_console_file_fputs): Delete.
17072 (mi_console_file::write): New.
17073 (mi_console_raw_packet): Delete.
17074 (mi_console_file::flush): New.
17075 (mi_console_file_flush): Delete.
17076 (mi_console_set_raw): Rename to ...
17077 (mi_console_file::set_raw): ... this.
17078 * mi/mi-console.h (class mi_console_file): New class.
17079 (mi_console_file_new, mi_console_set_raw): Delete.
17080 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
17081 (mi_set_logging): Use delete and tee_file. Adjust.
17082 * mi/mi-main.c (output_register): Use string_file.
17083 (mi_cmd_data_evaluate_expression): Use string_file.
17084 (mi_cmd_data_read_memory): Use string_file.
17085 (mi_cmd_execute, print_variable_or_computed): Use string_file.
17086 * mi/mi-out.c (mi_ui_out::main_stream): New.
17087 (mi_ui_out::rewind): Use main_stream and
17088 string_file.
17089 (mi_ui_out::put): Use main_stream and string_file.
17090 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17091 Allocate a 'string_file' instead.
17092 (mi_out_new): Don't allocate a mem_fileopen stream here.
17093 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17094 (mi_ui_out::main_stream): Declare method.
17095 * printcmd.c (eval_command): Use string_file.
17096 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
17097 * python/py-arch.c (archpy_disassemble): Use string_file.
17098 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
17099 * python/py-frame.c (frapy_str): Use string_file.
17100 * python/py-framefilter.c (py_print_type, py_print_single_arg):
17101 Use string_file.
17102 * python/py-type.c (typy_str): Use string_file.
17103 * python/py-unwind.c (unwind_infopy_str): Use string_file.
17104 * python/py-value.c (valpy_str): Use string_file.
17105 * record-btrace.c (btrace_insn_history): Use string_file.
17106 * regcache.c (regcache_print): Use stdio_file.
17107 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
17108 * remote.c (escape_buffer): Use string_file.
17109 * rust-lang.c (rust_get_disr_info): Use string_file.
17110 * serial.c (serial_open_ops_1): Use stdio_file.
17111 (do_serial_close): Use delete.
17112 * stack.c (print_frame_arg): Use string_file.
17113 (print_frame_args): Remove local mem_fileopen stream, not used.
17114 (print_frame): Use string_file.
17115 * symmisc.c (maintenance_print_symbols): Use stdio_file.
17116 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
17117 Take a 'string_file *' instead of a 'ui_file *'.
17118 * top.c (new_ui): Use stdio_file and stderr_file.
17119 (free_ui): Use delete.
17120 (execute_command_to_string): Use string_file.
17121 (quit_confirm): Use string_file.
17122 * tracepoint.c (collection_list::append_exp): Use string_file.
17123 * tui/tui-disasm.c (tui_disassemble): Use string_file.
17124 * tui/tui-file.c: Don't include "ui-file.h".
17125 (enum streamtype, struct tui_stream): Delete.
17126 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
17127 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
17128 (tui_file::tui_file): New method.
17129 (tui_file_fputs): Delete.
17130 (tui_file_get_strbuf): Delete.
17131 (tui_file::puts): New method.
17132 (tui_file_adjust_strbuf): Delete.
17133 (tui_file_flush): Delete.
17134 (tui_file::flush): New method.
17135 * tui/tui-file.h: Tweak intro comment.
17136 Include ui-file.h.
17137 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
17138 (tui_file_adjust_strbuf): Delete declarations.
17139 (class tui_file): New class.
17140 * tui/tui-io.c (tui_initialize_io): Use tui_file.
17141 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
17142 (tui_register_format): Use string_stream.
17143 * tui/tui-stack.c (tui_make_status_line): Use string_file.
17144 (tui_get_function_from_frame): Use string_file.
17145 * typeprint.c (type_to_string): Use string_file.
17146 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
17147 (null_stream): New global.
17148 (ui_file_delete): Delete.
17149 (ui_file::ui_file): New.
17150 (null_file_isatty): Delete.
17151 (ui_file::~ui_file): New.
17152 (null_file_rewind): Delete.
17153 (ui_file::printf): New.
17154 (null_file_put): Delete.
17155 (null_file_flush): Delete.
17156 (ui_file::putstr): New.
17157 (null_file_write): Delete.
17158 (ui_file::putstrn): New.
17159 (null_file_read): Delete.
17160 (ui_file::putc): New.
17161 (null_file_fputs): Delete.
17162 (null_file_write_async_safe): Delete.
17163 (ui_file::vprintf): New.
17164 (null_file_delete): Delete.
17165 (null_file::write): New.
17166 (null_file_fseek): Delete.
17167 (null_file::puts): New.
17168 (ui_file_data): Delete.
17169 (null_file::write_async_safe): New.
17170 (gdb_flush, ui_file_isatty): Adjust.
17171 (ui_file_put, ui_file_rewind): Delete.
17172 (ui_file_write): Adjust.
17173 (ui_file_write_for_put): Delete.
17174 (ui_file_write_async_safe, ui_file_read): Adjust.
17175 (ui_file_fseek): Delete.
17176 (fputs_unfiltered): Adjust.
17177 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
17178 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
17179 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
17180 (set_ui_file_data): Delete.
17181 (string_file::~string_file, string_file::write)
17182 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
17183 (do_ui_file_as_string, ui_file_as_string): Delete.
17184 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
17185 (struct mem_file): Delete.
17186 (mem_file_new): Delete.
17187 (stdio_file::stdio_file): New.
17188 (mem_file_delete): Delete.
17189 (stdio_file::stdio_file): New.
17190 (mem_fileopen): Delete.
17191 (stdio_file::~stdio_file): New.
17192 (mem_file_rewind): Delete.
17193 (stdio_file::set_stream): New.
17194 (mem_file_put): Delete.
17195 (stdio_file::open): New.
17196 (mem_file_write): Delete.
17197 (stdio_file_magic, struct stdio_file): Delete.
17198 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
17199 (stdio_file::flush): New.
17200 (stdio_file_read): Rename to ...
17201 (stdio_file::read): ... this. Adjust.
17202 (stdio_file_write): Rename to ...
17203 (stdio_file::write): ... this. Adjust.
17204 (stdio_file_write_async_safe): Rename to ...
17205 (stdio_file::write_async_safe) ... this. Adjust.
17206 (stdio_file_fputs): Rename to ...
17207 (stdio_file::puts) ... this. Adjust.
17208 (stdio_file_isatty): Delete.
17209 (stdio_file_fseek): Delete.
17210 (stdio_file::isatty): New.
17211 (stderr_file_write): Rename to ...
17212 (stderr_file::write) ... this. Adjust.
17213 (stderr_file_fputs): Rename to ...
17214 (stderr_file::puts) ... this. Adjust.
17215 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
17216 (stderr_file::stderr_file): New.
17217 (tee_file_magic): Delete.
17218 (struct tee_file): Delete.
17219 (tee_file::tee_file): New.
17220 (tee_file_new): Delete.
17221 (tee_file::~tee_file): New.
17222 (tee_file_delete): Delete.
17223 (tee_file_flush): Rename to ...
17224 (tee_file::flush): ... this. Adjust.
17225 (tee_file_write): Rename to ...
17226 (tee_file::write): ... this. Adjust.
17227 (tee_file::write_async_safe): New.
17228 (tee_file_fputs): Rename to ...
17229 (tee_file::puts): ... this. Adjust.
17230 (tee_file_isatty): Rename to ...
17231 (tee_file::isatty): ... this. Adjust.
17232 * ui-file.h (struct obstack, struct ui_file): Don't
17233 forward-declare.
17234 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
17235 (ui_file_write_ftype)
17236 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
17237 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
17238 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
17239 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
17240 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
17241 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
17242 (set_ui_file_fseek): Delete.
17243 (ui_file_data, ui_file_delete, ui_file_rewind)
17244 (struct ui_file): New.
17245 (ui_file_up): New.
17246 (class null_file): New.
17247 (null_stream): Declare.
17248 (ui_file_write_for_put, ui_file_put): Delete.
17249 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
17250 Delete.
17251 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
17252 (gdb_fopen, tee_file_new): Delete.
17253 (struct string_file): New.
17254 (struct stdio_file): New.
17255 (stdio_file_up): New.
17256 (struct stderr_file): New.
17257 (class tee_file): New.
17258 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
17259 of a 'ui_file *'. Adjust.
17260 * ui-out.h (class ui_out) <field_stream>: Likewise.
17261 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
17262 (null_stream): Delete.
17263 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
17264 Adjust.
17265 * utils.h (struct ui_file): Delete forward declaration..
17266 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
17267 (error_stream): Take a 'string_file &' instead of a
17268 'ui_file *'.
17269 * varobj.c (varobj_value_get_print_value): Use string_file.
17270 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
17271 * gdbarch.c: Regenerate.
17272
187808b0
PA
172732017-02-02 Pedro Alves <palves@redhat.com>
17274
17275 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
17276 (gdb_pretty_print_insn): ... this. Now a free function. Add back
17277 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
17278 Adjust to call gdb_print_insn instead of
17279 gdb_disassembler::print_insn.
17280 (dump_insns, do_mixed_source_and_assembly_deprecated)
17281 (do_mixed_source_and_assembly, do_assembly_only): Add back a
17282 'gdbarch' parameter. Remove gdb_disassembler parameter.
17283 (gdb_disassembly): Don't allocate a gdb_disassembler here.
17284 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
17285 declaration.
17286 (gdb_pretty_print_insn): Re-add declaration.
17287 * record-btrace.c (btrace_insn_history): Don't allocate a
17288 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
17289
7a8eb317
SM
172902017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
17291
17292 * disasm.h (gdb_disassembly): Remove file_string parameter.
17293 * disasm.c (gdb_disassembly): Likewise.
17294 * cli/cli-cmds.c (print_disassembly): Adapt.
17295 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
17296 * stack.c (do_gdb_disassembly): Likewise.
17297
7346ef59
AA
172982017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
17299
17300 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
17301 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
17302 targets. And if the implicit value is longer than needed, extract
17303 the first bytes instead of the "least significant" ones.
17304
cd4007e4
MM
173052017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17306
17307 * btrace.c (btrace_enable): Do not call btrace_add_pc for
17308 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
17309 (btrace_fetch): Assert can_access_registers_ptid.
17310 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
17311 validate_registers_access.
17312
cf77c34e
MM
173132017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17314
17315 * gdbthread.h (can_access_registers_ptid): New.
17316 * thread.c (can_access_registers_ptid): New.
17317
be85ce7d
PA
173182017-02-01 Pedro Alves <palves@redhat.com>
17319
17320 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
17321
29b0b251
PA
173222017-01-31 Pedro Alves <palves@redhat.com>
17323
17324 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
17325 Fix typos.
17326
289b5b24
PA
173272017-01-31 Pedro Alves <palves@redhat.com>
17328
17329 * stack.c (print_frame_args): Remove local mem_fileopen stream,
17330 not used.
17331
b47413b4
PA
173322017-01-31 Pedro Alves <palves@redhat.com>
17333
17334 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
17335
60adb36c
PA
173362017-01-31 Pedro Alves <palves@redhat.com>
17337
17338 * common/scoped_restore.h
17339 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
17340 change the value's parameter type to T2.
17341 (make_scoped_restore): Likewise.
17342
2735833d
WT
173432017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17344 Richard Henderson <rth@redhat.com>
17345
17346 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
17347 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
17348 GS_BASE for older kernels.
17349 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
17350 GS_BASE for older kernels.
17351 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
17352 and GS_BASE to the offset table.
17353 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
17354 system register group.
17355 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
17356 for older kernels.
17357 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
17358 amd64 ABI.
17359 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
17360 AMD64_GSBASE_REGNUM.
17361 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
17362 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
17363 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
17364 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
17365 i386/64bit-segments.xml in those rules.
17366 * features/i386/64bit-segments.xml: New file.
17367 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
17368 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
17369 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
17370 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
17371 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
17372 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
17373 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
17374 * features/i386/amd64-avx-linux.c: Regenerated.
17375 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
17376 * features/i386/amd64-avx-mpx.c: Regenerated.
17377 * features/i386/amd64-avx512-linux.c: Regenerated.
17378 * features/i386/amd64-linux.c: Regenerated.
17379 * features/i386/amd64-mpx-linux.c: Regenerated.
17380 * features/i386/i386-avx-mpx-linux.c: Regenerated.
17381 * features/i386/i386-avx-mpx.c: Regenerated.
17382 * features/i386/x32-avx-linux.c: Regenerated.
17383 * features/i386/x32-avx512-linux.c: Regenerated.
17384 * regformats/i386/amd64-avx-linux.dat: Regenerated.
17385 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
17386 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
17387 * regformats/i386/amd64-linux.dat: Regenerated.
17388 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
17389 * regformats/i386/x32-avx-linux.dat: Regenerated.
17390 * regformats/i386/x32-avx512-linux.dat: Regenerated.
17391 * regformats/i386/x32-linux.dat: Regenerated.
17392
8884e97e
WT
173932017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17394
17395 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
17396 Set to AMD64_NUM_REGS.
17397
7005d26a
WT
173982017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17399
17400 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
17401 that checks validity of a register number.
17402
4bd2e1b2
KC
174032017-01-27 Kees Cook <keescook@google.com>
17404
17405 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
17406 fetch_fpregs if target has fpa registers.
17407 (arm_linux_store_inferior_registers): Call store_fpregs if target
17408 has fpa registers.
17409
7cf1de6c
AA
174102017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
17411
17412 * cris-tdep.c (cris_gdbarch_init): Remove check for
17413 info.byte_order and force it to BFD_ENDIAN_LITTLE.
17414
874a1c8c
AT
174152017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
17416
17417 * corelow.c (get_core_register_section): Check for regset
17418 existence before checking for REGSET_VARIABLE_SIZE.
17419
d8b49cf0
YQ
174202017-01-26 Yao Qi <yao.qi@linaro.org>
17421 Pedro Alves <palves@redhat.com>
17422
17423 PR gdb/20939
17424 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
17425 call memory_error, save memaddr instead.
17426 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
17427 negative, cal memory_error.
17428 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
17429
658ca58c
YQ
174302017-01-26 Yao Qi <yao.qi@linaro.org>
17431
17432 * disasm-selftests.c (memory_error_test): New function.
17433 (_initialize_disasm_selftests): Register memory_error_test.
17434
79843d45
YQ
174352017-01-26 Yao Qi <yao.qi@linaro.org>
17436
17437 * Makefile.in (SFILES): Add disasm-selftests.c and
17438 selftest-arch.c.
17439 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
17440 * disasm-selftests.c: New file.
17441 * selftest-arch.c: New file.
17442 * selftest-arch.h: New file.
17443
8cafda32
YQ
174442017-01-26 Yao Qi <yao.qi@linaro.org>
17445
17446 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
17447 to bfd_arch_mep. Don't return 0 if section is not
17448 found. Call print_insn_mep.
17449
e47ad6c0
YQ
174502017-01-26 Pedro Alves <palves@redhat.com>
17451 Yao Qi <yao.qi@linaro.org>
17452
17453 * arm-tdep.c: Include "disasm.h".
17454 (gdb_print_insn_arm): Update code to get gdbarch.
17455 * disasm.c (dis_asm_read_memory): Change it to
17456 gdb_disassembler::dis_asm_read_memory.
17457 (dis_asm_memory_error): Likewise.
17458 (dis_asm_print_address): Likewise.
17459 (gdb_pretty_print_insn): Change it to
17460 gdb_disassembler::pretty_print_insn.
17461 (dump_insns): Add one argument gdb_disassemlber. All
17462 callers updated.
17463 (do_mixed_source_and_assembly_deprecated): Likewise.
17464 (do_mixed_source_and_assembly): Likewise.
17465 (do_assembly_only): Likewise.
17466 (gdb_disassembler::gdb_disassembler): New.
17467 (gdb_disassembler::print_insn): New.
17468 * disasm.h (class gdb_disassembler): New.
17469 (gdb_pretty_print_insn): Remove declaration.
17470 (gdb_disassemble_info): Likewise.
17471 * guile/scm-disasm.c (class gdbscm_disassembler): New.
17472 (gdbscm_disasm_read_memory_worker): Update.
17473 (gdbscm_disasm_read_memory): Update.
17474 (gdbscm_disasm_memory_error): Remove.
17475 (gdbscm_disasm_print_address): Remove.
17476 (gdbscm_disassembler::gdbscm_disassembler): New.
17477 (gdbscm_print_insn_from_port): Update.
17478 * mips-tdep.c: Include disasm.h.
17479 (gdb_print_insn_mips): Update code to get gdbarch.
17480 * record-btrace.c (btrace_insn_history): Update.
17481 * spu-tdep.c: Include disasm.h.
17482 (struct spu_dis_asm_data): Remove.
17483 (struct spu_dis_asm_info): New.
17484 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17485 SPU id.
17486 (gdb_print_insn_spu): Cast disassemble_info to
17487 spu_dis_asm_info.
17488
80d75874
YQ
174892017-01-26 Yao Qi <yao.qi@linaro.org>
17490
17491 * disasm.c (do_ui_file_delete): Delete.
17492 (gdb_insn_length): Move code creating stream to ...
17493 * utils.c (null_stream): ... here. New function.
17494 * utils.h (null_stream): Declare.
17495
60685cd0
SM
174962017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17497
17498 * python/py-inferior.c (find_thread_object): Return directly
17499 from the loop. Remove "found" variable.
17500
eb1cdb62
JB
175012017-01-21 Joel Brobecker <brobecker@adacore.com>
17502
17503 GDB 7.12.1 released.
17504
b1ce6568
SM
175052017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17506
17507 * python/py-function.c (fnpy_call): Reorder declarations to have
17508 the gdbpy_enter object declared first.
17509 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17510
6f8b0407
SM
175112017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17512
fec93fb1 17513 PR python/21068
6f8b0407
SM
17514 * python/python-internal.h (PyMem_RawMalloc): Define for
17515 Python < 3.4.
17516 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17517 PyMem_RawMalloc instead of PyMem_Malloc.
17518
78cbbba8
LM
175192017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17520 Luis Machado <lgustavo@codesourcery.com>
17521
17522 * NEWS (New commands): Mention flash-erase.
17523 (New MI commands): Mention target-flash-erase.
17524 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17525 command.
17526 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17527 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17528 * target.c (flash_erase_command): New function.
17529 (initialize_targets): Add new flash-erase command.
17530 * target.h (flash_erase_command): New declaration.
17531
2132fe85
JB
175322017-01-20 Joel Brobecker <brobecker@adacore.com>
17533
17534 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17535 HAVE_SYS_PROCFS_H is defined.
17536
d1dff226
AH
175372017-01-18 Alan Hayward <alan.hayward@arm.com>
17538
17539 * remote.c (struct cached_reg): Change data into a pointer.
17540 * (stop_reply_dtr): Free data pointers before deleting vector.
17541 (process_stop_reply): Likewise.
17542 (remote_parse_stop_reply): Allocate space for data
17543
9890e433
AH
175442017-01-18 Alan Hayward <alan.hayward@arm.com>
17545
17546 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17547 MAX_REGISTER_SIZE.
17548 (amd64_pseudo_register_read_value): Likewise.
17549 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17550 (store_register_using_P): Likewise.
17551 * regcache.c (regcache_xfer_part): Likewise.
17552
7a36499a
IR
175532017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17554
17555 Split real and pseudo registers.
17556 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17557 (sparc32_pseudo_regnum): New enum.
17558 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17559 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17560 (SPARC32_CP0_REGISTERS): New macro.
17561 (sparc32_pseudo_register_name): New function.
17562 (sparc32_register_name): Use sparc32_pseudo_register_name.
17563 (sparc32_pseudo_register_type): New function.
17564 (sparc32_register_type): Use sparc32_pseudo_register_type.
17565 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17566 pseudo register numbers.
17567 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17568 (SPARC64_CP0_REGISTERS): New macro.
17569 (sparc64_pseudo_register_name): New function.
17570 (sparc64_register_name): Use sparc64_pseudo_register_name.
17571 (sparc64_pseudo_register_type): New function.
17572 (sparc64_register_type): Use sparc64_pseudo_register_type.
17573 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17574 pseudo register numbers.
17575 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17576 sparc64_store_arguments): Handle pseudo register numbers.
17577
6f8976bf
YQ
175782017-01-13 Yao Qi <yao.qi@linaro.org>
17579
17580 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17581 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17582 output.
17583 (getpkt_or_notif_sane_1): Likewise.
17584
e4241ace
YQ
175852017-01-13 Yao Qi <yao.qi@linaro.org>
17586
17587 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17588 of CC. Pass "-x c++-header" instead of "-x c".
17589
3015c064
SM
175902017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17591
17592 * remote.c (remote_can_async_p): Update comment.
17593
fde1b17d
SM
175942017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17595
17596 * linux-nat.c (linux_nat_can_async_p): Update comment.
17597
ca1ca08b
SM
175982017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17599
17600 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17601
4ad2da73
SM
176022017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17603
17604 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17605
c8b23b3f
TT
176062017-01-10 Tom Tromey <tom@tromey.com>
17607
17608 * python/py-type.c (typy_legacy_template_argument): Update.
17609 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17610 ~demangle_parse_info): Declare new members.
17611 (cp_demangled_name_to_comp): Return unique_ptr.
17612 (cp_demangled_name_parse_free)
17613 (make_cleanup_cp_demangled_name_parse_free)
17614 (cp_new_demangle_parse_info): Remove.
17615 * cp-support.c (do_demangled_name_parse_free_cleanup)
17616 (make_cleanup_cp_demangled_name_parse_free): Remove.
17617 (inspect_type, cp_canonicalize_string_full)
17618 (cp_canonicalize_string): Update.
17619 (mangled_name_to_comp): Change return type.
17620 (cp_class_name_from_physname, method_name_from_physname)
17621 (cp_func_name, cp_remove_params): Update.
17622 * cp-name-parser.y (demangle_parse_info): New constructor, from
17623 cp_new_demangle_parse_info.
17624 (~demangle_parse_info): New destructor, from
17625 cp_demangled_name_parse_free.
17626 (cp_merge_demangle_parse_infos): Update.
17627 (cp_demangled_name_to_comp): Change return type.
17628
1ac32117
TT
176292017-01-10 Tom Tromey <tom@tromey.com>
17630
17631 * top.c (prevent_dont_repeat): Change return type.
17632 * python/python.c (execute_gdb_command): Use std::string.
17633 Update.
17634 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17635 * command.h (prevent_dont_repeat): Change return type.
17636 * breakpoint.c (bpstat_do_actions_1): Update.
17637
0cf08227
TT
176382017-01-10 Tom Tromey <tom@tromey.com>
17639
17640 * value.h (scoped_value_mark::~scoped_value_mark): Call
17641 free_to_mark.
17642 (scoped_value_mark::free_to_mark): New method.
17643 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17644 scoped_value_mark.
17645
eb115069
TT
176462017-01-10 Tom Tromey <tom@tromey.com>
17647
17648 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17649 (valpy_reference_value, valpy_const_value, valpy_get_address)
17650 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17651 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17652 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17653 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17654 scoped_value_mark.
17655 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17656 * value.h (scoped_value_mark): New class.
17657
906768f9
TT
176582017-01-10 Tom Tromey <tom@tromey.com>
17659
17660 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17661 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17662 * psymtab.c (discard_psymtabs_upto): Remove.
17663 (make_cleanup_discard_psymtabs): Remove.
17664 (struct psymtab_state): Remove.
17665
bef155c3
TT
176662017-01-10 Tom Tromey <tom@tromey.com>
17667
17668 * record-full.c (record_full_save_cleanups): Remove.
17669 (record_full_save): Use gdb::unlinker.
17670 * gcore.c (do_bfd_delete_cleanup): Remove.
17671 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17672 cleanups.
17673 * dwarf2read.c (unlink_if_set): Remove.
17674 (write_psymtabs_to_index): Use gdb::unlinker.
17675 * common/gdb_unlinker.h: New file.
17676
192b62ce
TT
176772017-01-10 Tom Tromey <tom@tromey.com>
17678
17679 * windows-tdep.c (windows_xfer_shared_library): Update.
17680 * windows-nat.c (windows_make_so): Update.
17681 * utils.h (make_cleanup_bfd_unref): Remove.
17682 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17683 * symfile.h (symfile_bfd_open)
17684 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17685 * symfile.c (read_symbols, symbol_file_add)
17686 (separate_debug_file_exists): Update.
17687 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17688 (generic_load, reread_symbols): Update.
17689 * symfile-mem.c (symbol_file_add_from_memory): Update.
17690 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17691 (spu_symbol_file_add_from_memory): Update.
17692 * solist.h (struct target_so_ops) <bfd_open>: Return
17693 gdb_bfd_ref_ptr.
17694 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17695 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17696 gdb_bfd_ref_ptr.
17697 (solib_map_sections, reload_shared_libraries_1): Update.
17698 * solib-svr4.c (enable_break): Update.
17699 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17700 * solib-frv.c (enable_break2): Update.
17701 * solib-dsbt.c (enable_break): Update.
17702 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17703 gdb_bfd_ref_ptr.
17704 (darwin_solib_get_all_image_info_addr_at_init): Update.
17705 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17706 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17707 * record-full.c (record_full_save): Update.
17708 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17709 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17710 * minidebug.c (find_separate_debug_file_in_section): Return
17711 gdb_bfd_ref_ptr.
17712 * machoread.c (macho_add_oso_symfile): Change abfd to
17713 gdb_bfd_ref_ptr.
17714 (macho_symfile_read_all_oso): Update.
17715 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17716 (macho_symfile_read): Update.
17717 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17718 (jit_bfd_try_read_symtab): Update.
17719 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17720 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17721 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17722 gdb_bfd_ref_ptr.
17723 (gdb_bfd_ref_policy): New struct.
17724 (gdb_bfd_ref_ptr): New typedef.
17725 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17726 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17727 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17728 gdb_bfd_ref_ptr.
17729 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17730 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17731 (gcore_command): Update.
17732 * exec.c (exec_file_attach): Update.
17733 * elfread.c (elf_symfile_read): Update.
17734 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17735 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17736 (open_and_init_dwo_file): Update.
17737 (open_dwp_file): Return gdb_bfd_ref_ptr.
17738 (open_and_init_dwp_file): Update.
17739 * corelow.c (core_open): Update.
17740 * compile/compile-object-load.c (compile_object_load): Update.
17741 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17742 * coffread.c (coff_symfile_read): Update.
17743 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17744 gdb_bfd_ref_ptr. Rename.
17745 (dump_bfd_file, restore_command): Update.
17746 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17747 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17748 (find_separate_debug_file_by_buildid): Update.
17749
50315b21
TT
177502017-01-10 Tom Tromey <tom@tromey.com>
17751
17752 * common/gdb_ref_ptr.h: New file.
17753 * python/py-ref.h (struct gdbpy_ref_policy): New.
17754 (gdbpy_ref): Now a typedef.
17755
fc4007c9
TT
177562017-01-10 Tom Tromey <tom@tromey.com>
17757
17758 * utils.h (make_cleanup_htab_delete): Don't declare.
17759 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17760 Remove.
17761 * linespec.c (decode_compound_collector): Add constructor,
17762 destructor.
17763 (lookup_prefix_sym): Remove cleanup.
17764 (symtab_collector): Add constructor, destructor.
17765 (collect_symtabs_from_filename): Remove cleanup.
17766 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17767 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17768 Use htab_up.
17769 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17770 * dwarf2read.c (dw2_expand_symtabs_matching)
17771 (dw2_map_symbol_filenames, dwarf_decode_macros)
17772 (write_psymtabs_to_index): Use htab_up.
17773 * dwarf2loc.c (func_verify_no_selftailcall)
17774 (call_site_find_chain_1, func_verify_no_selftailcall)
17775 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17776 std::vector, gdb::unique_xmalloc_ptr.
17777 (call_sitep): Remove typedef.
17778 (dwarf2_locexpr_baton_eval): Remove unused variable.
17779
8dbcee67
TT
177802017-01-10 Tom Tromey <tom@tromey.com>
17781
17782 * python/python-internal.h (make_cleanup_py_decref)
17783 (make_cleanup_py_xdecref): Don't declare.
17784 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17785 (py_xdecref, make_cleanup_py_xdecref): Remove.
17786
13df46cc
TT
177872017-01-10 Tom Tromey <tom@tromey.com>
17788
17789 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17790 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17791
06fc9bf7
TT
177922017-01-10 Tom Tromey <tom@tromey.com>
17793
17794 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17795
830a4934
TT
177962017-01-10 Tom Tromey <tom@tromey.com>
17797
17798 * python/py-utils.c (unicode_to_encoded_string)
17799 (python_string_to_target_string)
17800 (python_string_to_target_python_string)
17801 (python_string_to_host_string, gdbpy_obj_to_string)
17802 (get_addr_from_python): Use gdbpy_ref.
17803
4586d543
TT
178042017-01-10 Tom Tromey <tom@tromey.com>
17805
17806 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17807 gdbpy_ref.
17808
59876f8f
TT
178092017-01-10 Tom Tromey <tom@tromey.com>
17810
17811 * python/python.c (eval_python_command, gdbpy_decode_line)
17812 (gdbpy_run_events, gdbpy_start_type_printers)
17813 (gdbpy_apply_type_printers): Use gdbpy_ref.
17814
97d83487
TT
178152017-01-10 Tom Tromey <tom@tromey.com>
17816
17817 * python/py-param.c (get_doc_string, compute_enum_values): Use
17818 gdbpy_ref.
17819
9205649a
TT
178202017-01-10 Tom Tromey <tom@tromey.com>
17821
17822 * python/py-inferior.c (find_thread_object, build_inferior_list):
17823 Use gdbpy_ref.
17824
74c49d45
TT
178252017-01-10 Tom Tromey <tom@tromey.com>
17826
17827 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17828
16361ffb
TT
178292017-01-10 Tom Tromey <tom@tromey.com>
17830
17831 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
17832 gdbpy_ref.
17833
905f2cca
TT
178342017-01-10 Tom Tromey <tom@tromey.com>
17835
17836 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
17837 extra incref.
17838 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
17839 Use gdbpy_ref.
17840
64081434
TT
178412017-01-10 Tom Tromey <tom@tromey.com>
17842
17843 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17844 gdbpy_ref.
17845
59e9e831
TT
178462017-01-10 Tom Tromey <tom@tromey.com>
17847
17848 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
17849 decref results of PyArg_ParseTupleAndKeywords.
17850
9de10f6d
TT
178512017-01-10 Tom Tromey <tom@tromey.com>
17852
17853 * python/python.c (python_run_simple_file): Use
17854 unique_xmalloc_ptr, gdbpy_ref.
17855
2bd5759d
TT
178562017-01-10 Tom Tromey <tom@tromey.com>
17857
17858 * python/py-prettyprint.c (print_stack_unless_memory_error)
17859 (print_string_repr, print_children): Use gdbpy_ref.
17860 (dummy_python_frame): New class.
17861 (dummy_python_frame::dummy_python_frame): Rename from
17862 push_dummy_python_frame.
17863 (py_restore_tstate): Remove.
17864
3b4e0e01
TT
178652017-01-10 Tom Tromey <tom@tromey.com>
17866
17867 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17868
17a22718
TT
178692017-01-10 Tom Tromey <tom@tromey.com>
17870
17871 * python/python.c (ensure_python_env, restore_python_env):
17872 Remove.
17873 * python/python-internal.h (ensure_python_env): Don't declare.
17874 * varobj.h (varobj_ensure_python_env): Don't declare.
17875 * varobj.c (varobj_ensure_python_env): Remove.
17876
68cdc557
TT
178772017-01-10 Tom Tromey <tom@tromey.com>
17878
17879 * varobj.c (varobj_value_get_print_value): Use
17880 gdbpy_enter_varobj.
17881
1eba6383
TT
178822017-01-10 Tom Tromey <tom@tromey.com>
17883
17884 * python/py-prettyprint.c (print_string_repr, print_children):
17885 Update.
17886 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
17887 of "encoding".
17888 * varobj.c (varobj_value_get_print_value): Update.
17889 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
17890
bde7b3e3
TT
178912017-01-10 Tom Tromey <tom@tromey.com>
17892
17893 * varobj.c (varobj_get_display_hint)
17894 (dynamic_varobj_has_child_method, install_new_value_visualizer)
17895 (varobj_set_visualizer, free_variable): Use
17896 gdbpy_enter_varobj.
17897
a7785f8c
TT
178982017-01-10 Tom Tromey <tom@tromey.com>
17899
17900 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
17901 (do_finish_initialization): New function. Use gdbpy_ref.
17902 (gdbpy_finish_initialization): Use gdbpy_enter. Call
17903 do_finish_initialization.
17904
2865bfce
TT
179052017-01-10 Tom Tromey <tom@tromey.com>
17906
17907 * python/py-param.c (get_set_value, get_show_value): Use
17908 gdbpy_enter, gdbpy_ref.
17909
0e9dcc75
TT
179102017-01-10 Tom Tromey <tom@tromey.com>
17911
17912 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
17913
12a5cedd
TT
179142017-01-10 Tom Tromey <tom@tromey.com>
17915
17916 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
17917
788f2586
TT
179182017-01-10 Tom Tromey <tom@tromey.com>
17919
17920 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
17921 Use gdbpy_enter_varobj.
17922
6cd67bea
TT
179232017-01-10 Tom Tromey <tom@tromey.com>
17924
17925 * varobj.c (gdbpy_enter_varobj): New constructor.
17926 * python/python-internal.h (gdbpy_enter_varobj): New class.
17927 * python/py-varobj.c (py_varobj_get_iterator): Use
17928 gdbpy_enter_varobj.
17929
14b122bf
TT
179302017-01-10 Tom Tromey <tom@tromey.com>
17931
17932 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
17933 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17934 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
17935 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
17936 unique_xmalloc_ptr.
17937 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
17938
bf1ca3b9
TT
179392017-01-10 Tom Tromey <tom@tromey.com>
17940
17941 * python/py-xmethods.c (invoke_match_method): Use
17942 gdbpy_ref.
17943
572a5524
TT
179442017-01-10 Tom Tromey <tom@tromey.com>
17945
17946 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
17947 gdbpy_enter, gdbpy_ref.
17948
396a78b6
TT
179492017-01-10 Tom Tromey <tom@tromey.com>
17950
17951 * python/python.c (python_interactive_command): Use gdbpy_enter.
17952
a88b13c7
TT
179532017-01-10 Tom Tromey <tom@tromey.com>
17954
17955 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
17956 gdbpy_ref.
17957
e9f0c363
TT
179582017-01-10 Tom Tromey <tom@tromey.com>
17959
17960 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
17961 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17962
6349f452
TT
179632017-01-10 Tom Tromey <tom@tromey.com>
17964
17965 * utils.h (htab_deleter): New struct.
17966 (htab_up): New typedef.
17967 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
17968 gdbpy_enter, gdbpy_ref, htab_up.
17969
c0171de6
TT
179702017-01-10 Tom Tromey <tom@tromey.com>
17971
17972 * python/py-unwind.c (pending_frame_invalidate): Remove.
17973 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
17974
f18e226f
TT
179752017-01-10 Tom Tromey <tom@tromey.com>
17976
17977 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
17978 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
17979
c57af3f1
TT
179802017-01-10 Tom Tromey <tom@tromey.com>
17981
17982 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
17983
60e600ec
TT
179842017-01-10 Tom Tromey <tom@tromey.com>
17985
17986 * python/python.c (gdbpy_eval_from_control_command)
17987 (gdbpy_source_script, gdbpy_run_events)
17988 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
17989 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
17990 gdbpy_enter.
17991
bf7da5b0
TT
179922017-01-10 Tom Tromey <tom@tromey.com>
17993
17994 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
17995
2d38bced
TT
179962017-01-10 Tom Tromey <tom@tromey.com>
17997
17998 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
17999
07bc7329
TT
180002017-01-10 Tom Tromey <tom@tromey.com>
18001
18002 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
18003 (python_on_inferior_call_pre, python_on_inferior_call_post)
18004 (python_on_memory_change, python_on_register_change)
18005 (python_inferior_exit, python_new_objfile, add_thread_object)
18006 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
18007
6e7c365e
TT
180082017-01-10 Tom Tromey <tom@tromey.com>
18009
18010 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
18011 (bpfinishpy_handle_exit): Use gdbpy_enter.
18012
6ba0cd40
TT
180132017-01-10 Tom Tromey <tom@tromey.com>
18014
18015 * python/py-cmd.c (cmdpy_destroyer)
18016 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
18017 gdbpy_enter.
18018
de2dc875
TT
180192017-01-10 Tom Tromey <tom@tromey.com>
18020
18021 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
18022 gdbpy_enter.
18023 (gdbpy_breakpoint_has_cond): Likewise.
18024
4ecee2c4
TT
180252017-01-10 Tom Tromey <tom@tromey.com>
18026
18027 * python/python.c (gdbpy_enter): New constructor.
18028 (~gdbpy_enter): New destructor.
18029 (restore_python_env, ensure_python_env): Rewrite.
18030 * python/python-internal.h (gdbpy_enter): New class.
18031
37fce74f
TT
180322017-01-10 Tom Tromey <tom@tromey.com>
18033
18034 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
18035
53a0cca3
TT
180362017-01-10 Tom Tromey <tom@tromey.com>
18037
18038 * python/py-value.c (value_has_field, get_field_flag)
18039 (get_field_type, valpy_getitem, convert_value_from_python): Use
18040 gdbpy_ref.
18041
ff3724f5
TT
180422017-01-10 Tom Tromey <tom@tromey.com>
18043
18044 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
18045 gdbpy_ref.
18046
0700aea5
TT
180472017-01-10 Tom Tromey <tom@tromey.com>
18048
18049 * python/py-prettyprint.c (search_pp_list)
18050 (find_pretty_printer_from_objfiles)
18051 (find_pretty_printer_from_progspace)
18052 (find_pretty_printer_from_gdb, find_pretty_printer)
18053 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
18054 gdbpy_ref.
18055
1bb44c9f
TT
180562017-01-10 Tom Tromey <tom@tromey.com>
18057
18058 * python/py-param.c (call_doc_function): Use gdbpy_ref.
18059
87ce03fd
TT
180602017-01-10 Tom Tromey <tom@tromey.com>
18061
18062 * python/py-linetable.c (build_line_table_tuple_from_pcs)
18063 (ltpy_get_all_source_lines): Use gdbpy_ref.
18064
ee0a3fb8
TT
180652017-01-10 Tom Tromey <tom@tromey.com>
18066
18067 * python/py-framefilter.c (extract_sym, extract_value)
18068 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
18069 gdbpy_ref.
18070
bf2a52fa
TT
180712017-01-10 Tom Tromey <tom@tromey.com>
18072
18073 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
18074
f59fe7f8
TT
180752017-01-10 Tom Tromey <tom@tromey.com>
18076
18077 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
18078
80bd970a
TT
180792017-01-10 Tom Tromey <tom@tromey.com>
18080
18081 * python/py-function.c (convert_values_to_python, fnpy_init): Use
18082 gdbpy_ref.
18083
d1b3de2e
TT
180842017-01-10 Tom Tromey <tom@tromey.com>
18085
18086 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
18087
3bb43384
TT
180882017-01-10 Tom Tromey <tom@tromey.com>
18089
18090 * python/py-type.c (convert_field, make_fielditem, typy_fields)
18091 (typy_range): Use gdbpy_ref.
18092
abf5651e
TT
180932017-01-10 Tom Tromey <tom@tromey.com>
18094
18095 * python/py-threadevent.c (create_thread_event_object): Use
18096 gdbpy_ref.
18097 * python/py-stopevent.c (create_stop_event_object): Simplify.
18098 (emit_stop_event): Use gdbpy_ref.
18099 * python/py-signalevent.c (create_signal_event_object): Use
18100 gdbpy_ref.
18101 * python/py-newobjfileevent.c (create_new_objfile_event_object)
18102 (emit_new_objfile_event, create_clear_objfiles_event_object)
18103 (emit_clear_objfiles_event): Use gdbpy_ref.
18104 * python/py-infevents.c (create_inferior_call_event_object)
18105 (create_register_changed_event_object)
18106 (create_memory_changed_event_object, emit_inferior_call_event)
18107 (emit_memory_changed_event, emit_register_changed_event): Use
18108 gdbpy_ref.
18109 * python/py-exitedevent.c (create_exited_event_object)
18110 (emit_exited_event): Use gdbpy_ref.
18111 * python/py-event.h (evpy_emit_event): Remove
18112 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
18113 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
18114 * python/py-continueevent.c (emit_continue_event): Use
18115 gdbpy_ref.
18116 * python/py-breakpoint.c (gdbpy_breakpoint_created)
18117 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
18118 gdbpy_ref.
18119 * python/py-bpevent.c (create_breakpoint_event_object): Use
18120 gdbpy_ref.
18121
a68ff33e
TT
181222017-01-10 Tom Tromey <tom@tromey.com>
18123
18124 * python/py-ref.h: New file.
18125
7becfd03
SM
181262017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18127
18128 * cli-out.c (cli_ui_out::do_redirect): Change return type to
18129 void.
18130 * cli-out.h (cli_ui_out::do_redirect): Likewise.
18131 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
18132 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
18133 * ui-out.c (ui_out::redirect): Likewise.
18134 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
18135 * cli/cli-logging.c (set_logging_redirect): Update call site of
18136 ui_out::redirect.
18137 (handle_redirections): Likewise.
18138 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
18139 * top.c (execute_command_to_string): Likewise.
18140 * utils.c (do_ui_out_redirect_pop): Likewise.
18141
df294654
SM
181422017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18143
18144 * stack.c (_initialize_stack): Update "frame" command help message.
18145
f5e6296e
IB
181462017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
18147
18148 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
18149
0e2d6fa6
YQ
181502017-01-06 Yao Qi <yao.qi@linaro.org>
18151
18152 * x86-linux-nat.h: Include gdb_proc_service.h.
18153
44d6d3f9
YQ
181542017-01-06 Yao Qi <yao.qi@linaro.org>
18155
18156 * ser-base.h: Include serial.h.
18157
656731fe
YQ
181582017-01-06 Yao Qi <yao.qi@linaro.org>
18159
18160 * ppc-linux-tdep.h: Include ppc-tdep.h.
18161
1ca8f924
YQ
181622017-01-06 Yao Qi <yao.qi@linaro.org>
18163
18164 * nat/amd64-linux-siginfo.h: Include signal.h.
18165
bc3008c4
YQ
181662017-01-06 Yao Qi <yao.qi@linaro.org>
18167
18168 * nat/aarch64-linux-hw-point.h: Include break-common.h.
18169
66c80d03
YQ
181702017-01-06 Yao Qi <yao.qi@linaro.org>
18171
18172 * mi/mi-parse.h: Include mi-cmds.h.
18173
051d2dda
YQ
181742017-01-06 Yao Qi <yao.qi@linaro.org>
18175
18176 * inf-loop.c: Don't include "target.h".
18177 * inf-loop.h: Include it here.
18178
8018d34f
YQ
181792017-01-06 Yao Qi <yao.qi@linaro.org>
18180
18181 * dfp.h: Include "dboulest.h" and "expression.h".
18182
c0b8369c
YQ
181832017-01-06 Yao Qi <yao.qi@linaro.org>
18184
18185 * ax-gdb.h: Include "ax.h".
18186
ad5cba2a
YQ
181872017-01-06 Yao Qi <yao.qi@linaro.org>
18188
18189 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
18190 with nat/gdb_ptrace.h.
18191
1c33cd7f
YQ
181922017-01-05 Yao Qi <yao.qi@linaro.org>
18193
18194 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
18195 new line.
18196 (mips64_fbsd_sigframe_init): Likewise.
18197
c988ac1d
JB
181982017-01-04 John Baldwin <jhb@FreeBSD.org>
18199
18200 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
18201 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
18202
b268007c
JB
182032017-01-04 John Baldwin <jhb@FreeBSD.org>
18204
18205 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
18206 * NEWS: Mention new FreeBSD/mips native configuration.
18207 * config/mips/fbsd.mh: New file.
18208 * configure.host: Add mips*-*-freebsd*.
18209 * mips-fbsd-nat.c: New file.
18210
387360da
JB
182112017-01-04 John Baldwin <jhb@FreeBSD.org>
18212
18213 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
18214 (ALLDEPFILES): Add mips-fbsd-tdep.c.
18215 * NEWS: Mention new FreeBSD/mips target.
18216 * configure.tgt: Add mips*-*-freebsd*.
18217 * mips-fbsd-tdep.c: New file.
18218 * mips-fbsd-tdep.h: New file.
18219
2aaaf250
YQ
182202017-01-04 Yao Qi <yao.qi@linaro.org>
18221
18222 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
18223 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
18224
61baf725
JB
182252017-01-01 Joel Brobecker <brobecker@adacore.com>
18226
6dbb839a 18227 Update copyright year range in all GDB files.
61baf725 18228
c113e7ff 182292017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 18230
c113e7ff 18231 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 18232
c113e7ff 18233For older changes see ChangeLog-2016.
c906108c
SS
18234\f
18235Local Variables:
18236mode: change-log
18237left-margin: 8
18238fill-column: 74
18239version-control: never
57da7796 18240coding: utf-8
c906108c 18241End:
This page took 2.792524 seconds and 4 git commands to generate.