Ignore warning about using different types of enums in switch
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
0436426c
SM
12017-12-29 Simon Marchi <simon.marchi@ericsson.com>
2
3 * common/diagnostics.h
4 (DIAGNOSTIC_IGNORE_SWITCH_DIFFERENT_ENUM_TYPES): New macro.
5 * amd64-linux-tdep.c (amd64_canonicalize_syscall): Use it.
6
502a625a
SM
72017-12-29 Simon Marchi <simon.marchi@ericsson.com>
8
9 * linux-thread-db.c (thread_db_detach): Remove call to
10 delete_thread_db_info.
11
4ee2b642
SM
122017-12-28 Simon Marchi <simon.marchi@polymtl.ca>
13
14 * target.h (enum target_object) <TARGET_OBJECT_HPUX_UREGS,
15 TARGET_OBJECT_HPUX_SOLIB_GOT>: Remove.
16
cef0f868
SH
172017-12-27 Franck Jullien <franck.jullien@gmail.com>
18 Stafford Horne <shorne@gmail.com>
19
20 * target-descriptions.c (tdesc_register_in_reggroup_p): Support
21 arbitrary strings.
22 (tdesc_use_registers): Add logic to register new reggroups.
23 (tdesc_reg::group): Update comment to indicate we allow
24 arbitrary strings.
25 * NEWS (Changes since GDB 8.0): Announce that GDB supports
26 arbitrary reggroups.
27
f7efd549
SH
282017-12-27 Stafford Horne <shorne@gmail.com>
29
30 * reggroups.c (reggroup_gdbarch_new): New function.
31 (reggroup_find): New function.
32 * reggroups.h (reggroup_gdbarch_new): New function.
33 (reggroup_find): New function.
34
c1166ca9
SH
352017-12-27 Stafford Horne <shorne@gmail.com>
36
37 * reggroups.c (reggroups_init): Change to depend only on
38 obstack rather than gdbarch.
39 (reggroup_add): Remove logic for forcing premature init.
40 (_initialize_reggroup): Set `reggroups_data` with
41 gdbarch_data_register_pre_init() rather than
42 gdbarch_data_register_post_init().
43
b67d92b0
SH
442017-12-27 Stafford Horne <shorne@gmail.com>
45
46 * infcmd.c (_initialize_infcmd): Add help for info reg $reggroup
47 and info all-registers $reggroup feature.
48
6e8c24fe
SM
492017-12-23 Simon Marchi <simon.marchi@polymtl.ca>
50
51 * target-descriptions.c (print_c_tdesc)
52 <printf_field_type_assignment>: Add ATTRIBUTE_PRINTF.
53
a8d2e585
SM
542017-12-21 Simon Marchi <simon.marchi@ericsson.com>
55 Sergio Durigan Junior <sergiodj@redhat.com>
56
57 * target-descriptions.c (print_c_tdesc) <visit>: Don't output
58 field_type declaration, use printf_field_type_assignment
59 instead.
60 <printf_field_type_assignment>: New method.
61 * features/aarch64-core.c, features/aarch64-fpu.c
62 features/arc-arcompact.c, features/arc-v2.c,
63 features/arm/arm-with-iwmmxt.c, features/i386/32bit-core.c,
64 features/i386/32bit-mpx.c, features/i386/32bit-sse.c,
65 features/i386/64bit-avx512.c, features/i386/64bit-core.c,
66 features/i386/64bit-mpx.c, features/i386/64bit-sse.c,
67 features/i386/x32-core.c, features/or1k.c,
68 features/rs6000/powerpc-7400.c,
69 features/rs6000/powerpc-altivec32.c,
70 features/rs6000/powerpc-altivec32l.c,
71 features/rs6000/powerpc-altivec64.c,
72 features/rs6000/powerpc-altivec64l.c,
73 features/rs6000/powerpc-cell32l.c,
74 features/rs6000/powerpc-cell64l.c,
75 features/rs6000/powerpc-isa205-altivec32l.c,
76 features/rs6000/powerpc-isa205-altivec64l.c,
77 features/rs6000/powerpc-isa205-vsx32l.c,
78 features/rs6000/powerpc-isa205-vsx64l.c,
79 features/rs6000/powerpc-vsx32.c,
80 features/rs6000/powerpc-vsx32l.c,
81 features/rs6000/powerpc-vsx64.c,
82 features/rs6000/powerpc-vsx64l.c, features/s390-gs-linux64.c,
83 features/s390-tevx-linux64.c, features/s390-vx-linux64.c,
84 features/s390x-gs-linux64.c, features/s390x-tevx-linux64.c,
85 features/s390x-vx-linux64.c: Re-generate.
86
27e9ff87
UB
872017-12-20 Uros Bizjak <ubizjak@gmail.com>
88
89 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Remove
90 write-only assignment to "insn" variable.
91
396d3980
UW
922017-12-20 Ulrich Weigand <uweigand@de.ibm.com>
93
94 * spu-tdep.c (spu_gdbarch_init): Set set_gdbarch_significant_addr_bit
95 to 64 bits.
96 (ppc_linux_init_abi): Likewise, if Cell/B.E. is supported.
97
eccab96d
JB
982017-12-18 Joel Brobecker <brobecker@adacore.com>
99
100 * ada-lang.c (ada_to_fixed_type_1): Rethrow errors with
101 a more detailed exception message when getting an exception
102 while trying to read the value of an XVZ variable.
103 * ada-valprint.c (ada_val_print): Only catch RETURN_MASK_ERROR
104 exceptions. Print an error message when an exception is caught.
105
0e2da9f0
JB
1062017-12-18 Joel Brobecker <brobecker@adacore.com>
107
108 * ada-lang.c (assign_component): Strip any TYPE_CODE_TYPEDEF
109 layer from lhs' type.
110 (assign_aggregate): Likewise.
111
cb923fcc
XR
1122017-12-18 Xavier Roirand <roirand@adacore.com>
113
114 * ada-lang.c (ada_convert_actual): Change the way actual value
115 are passed to the inferior when the inferior expects a pointer type.
116
38af1824
SH
1172017-12-17 Stafford Horne <shorne@gmail.com>
118
119 * gdb/or1k-tdep.c (show_or1k_debug): Fix function parameter alignment.
120 (or1k_analyse_inst): Likewise.
121 (or1k_single_step_through_delay): Likewise.
122 (or1k_frame_cache): Fix parameter alignment and use paddress()
123 instead of %x.
124
b282f0f2
SH
1252017-12-17 Stafford Horne <shorne@gmail.com>
126
127 * NEWS (Changes since GDB 8.0): Mention new or1k target and new
128 commands to set/show or1k debug.
129
46afe196
SDJ
1302017-12-15 Sergio Durigan Junior <sergiodj@redhat.com>
131
132 * typeprint.c (whatis_exp): Fix ARI warning and reindent "if"
133 condition.
134
7c161838
SDJ
1352017-12-15 Sergio Durigan Junior <sergiodj@redhat.com>
136 Pedro Alves <palves@redhat.com>
137
138 PR cli/16224
139 * NEWS (Changes since GDB 8.0): Mention new '/o' flag.
140 * c-typeprint.c (OFFSET_SPC_LEN): New define.
141 (c_type_print_varspec_prefix): New argument 'struct
142 print_offset_data *'.
143 (c_type_print_base_1): New function and prototype.
144 (c_print_type_1): New function, with code from 'c_print_type'.
145 (c_print_type): Use 'c_print_type_1'.
146 (c_type_print_varspec_prefix): New argument 'struct
147 print_offset_data *'. Use it. Call 'c_type_print_base_1'
148 instead of 'c_print_type_base'.
149 (print_spaces_filtered_with_print_options): New function.
150 (output_access_specifier): Take new argument FLAGS. Modify
151 function to call 'print_spaces_filtered_with_print_options'.
152 (c_print_type_vtable_offset_marker): New function.
153 (c_print_type_union_field_offset): New function.
154 (c_print_type_struct_field_offset): New function.
155 (c_print_type_no_offsets): New function.
156 (c_type_print_base_struct_union): New argument 'struct
157 print_offset_data *'. Print offsets and sizes for
158 struct/union/class fields.
159 * typeprint.c (const struct type_print_options
160 type_print_raw_options): Initialize 'print_offsets'.
161 (static struct type_print_options default_ptype_flags):
162 Likewise.
163 (struct print_offset_data print_offset_default_data): New
164 variable.
165 (whatis_exp): Handle '/o' option.
166 (_initialize_typeprint): Add '/o' flag to ptype's help.
167 * typeprint.h (struct print_offset_data): New struct.
168 (struct type_print_options) <print_offsets>: New field.
169
a27ed7d6
SDJ
1702017-12-15 Sergio Durigan Junior <sergiodj@redhat.com>
171
172 * c-typeprint.c (need_access_label_p): New function.
173 (c_type_print_base_struct_union): New function.
174 (c_type_print_base): Move code to handle
175 TYPE_CODE_{STRUCT,UNION} to the functions mentioned above.
176
68f81d60
RH
1772017-12-15 Richard Henderson <rth@redhat.com>
178 Uros Bizjak <ubizjak@gmail.com>
179
180 PR gdb/19061
181 * alpha-tdep.c (alpha_software_single_step): Call
182 alpha_deal_with_atomic_sequence here.
183 (set_gdbarch_software_single_step): Set to
184 alpha_software_single_step.
185 * nat/linux-ptrace.h [__alpha__]: Define GDB_ARCH_IS_TRAP_BRKPT
186 and GDB_ARCH_IS_TRAP_HWBKPT.
187
97d4fac1
YQ
1882017-12-15 Yao Qi <yao.qi@linaro.org>
189
190 * unittests/memory-map-selftests.c: Wrap test with HAVE_LIBEXPAT.
191
828d5846
XR
1922017-12-15 Xavier Roirand <roirand@adacore.com>
193
194 * ada-lang.c (ada_value_primitive_field): Handle field search
195 in case of homonyms.
196 (find_struct_field): Ditto.
197 (ada_search_struct_field): Ditto.
198 (ada_value_struct_elt): Ditto.
199 (ada_lookup_struct_elt_type): Ditto.
200
8e557e52
SM
2012017-12-14 Simon Marchi <simon.marchi@ericsson.com>
202
203 * python/py-breakpoint.c (bppy_init): Use 'O' format specifier
204 for "qualified" and use PyObject_IsTrue.
205
8af5c486
JK
2062017-12-14 Jan Kratochvil <jan.kratochvil@redhat.com>
207
208 * dwarf2read.c (dw2_debug_names_iterator::next): Support
209 DW_IDX_type_unit.
210 (debug_names::dwarf5_offset_size, unit_kind): New.
211 (debug_names::insert): Add parameter kind.
212 (debug_names::build): Support DW_IDX_type_unit.
213 (debug_names::recursively_write_psymbols): Update
214 (debug_names::write_psymbols caller.
215 (debug_names::write_one_signatured_type_data)
216 (debug_names::write_one_signatured_type): New.
217 (debug_names::index_key, debug_names::symbol_value)
218 (debug_names::write_psymbols): Add kind.
219 (debug_names::write_one_signatured_type): New.
220 (write_debug_names): Move dwarf5_offset_size to debug_names.
221 Use debug_names::write_one_signatured_type for type units.
222
79e8fcaa
JB
2232017-12-14 Joel Brobecker <brobecker@adacore.com>
224
225 * ada-lang.c (ada_value_equal): Add handling of typedef types
226 when comparing array objects.
227
e05fa6f9
JB
2282017-12-14 Joel Brobecker <brobecker@adacore.com>
229
230 * ada-tasks.c (read_atcb): Properly set task_info->ptid
231 when !target_has_execution as well.
232 (task_command): Remove error when !target_has_execution.
233
b89641ba
SM
2342017-12-13 Simon Marchi <simon.marchi@ericsson.com>
235
236 * location.h (string_to_event_location): Add match_type
237 parameter.
238 * location.c (string_to_event_location): Likewise.
239 * python/py-breakpoint.c (bppy_init): Handle qualified
240 parameter.
241
a22ecf70
PA
2422017-12-13 Pedro Alves <palves@redhat.com>
243
244 * completer.c (completion_tracker::maybe_add_completion): New
245 'text' and 'word' parameters. Use make_completion_match_str.
246 (completion_tracker::add_completion): New 'text' and 'word'
247 parameters. Pass down.
248 (completion_tracker::recompute_lowest_common_denominator): Change
249 parameter type to gdb::unique_xmalloc_ptr rval ref. Adjust.
250 * completer.h (completion_tracker::add_completion): New 'text' and
251 'word' parameters.
252 (completion_tracker::recompute_lowest_common_denominator): Change
253 parameter type to gdb::unique_xmalloc_ptr rval ref.
254 (completion_tracker::recompute_lowest_common_denominator): Change
255 parameter type to gdb::unique_xmalloc_ptr rval ref.
256 * symtab.c (completion_list_add_name): Pass down 'text' and 'word'
257 as well.
258
60a20c19
PA
2592017-12-13 Pedro Alves <palves@redhat.com>
260
261 * cli/cli-decode.c (complete_on_cmdlist, complete_on_enum): Use
262 make_completion_match_str.
263 * completer.c: Use gdb::unique_xmalloc_ptr and
264 make_completion_match_str.
265 (make_completion_match_str_1): New.
266 (make_completion_match_str(const char *, const char *,
267 const char *)): New.
268 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
269 const char *, const char *)): New.
270 * completer.h (make_completion_match_str(const char *,
271 const char *, const char *)): New.
272 (make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
273 const char *, const char *)): New.
274 * interps.c (interpreter_completer): Use make_completion_match_str.
275 * symtab.c (completion_list_add_name, add_filename_to_list): Use
276 make_completion_match_str.
277
96647014
SH
2782017-12-13 Stafford Horne <shorne@gmail.com>
279
280 * or1k-tdep.c (or1k_analyse_inst): Use _() wrapper for message
281 strings.
282 (or1k_unwind_pc): Use paddress() instead of %p.
283 (or1k_unwind_sp): Likewise.
284 (or1k_frame_cache): Use host_address_to_string()/paddress()
285 instead of %p and use _() wrapper for message strings.
286
3bbd9f18
SM
2872017-12-13 Simon Marchi <simon.marchi@ericsson.com>
288
289 * contrib/ari/gdb_ari.sh: Fix typo in help.
290
9937536c
JB
2912017-12-13 Joel Brobecker <brobecker@adacore.com>
292
293 * event-top.c (handle_line_of_input): Set server_command.
294
a994fec4
FJ
2952017-12-12 Stafford Horne <shorne@gmail.com>
296 Stefan Wallentowitz <stefan@wallentowitz.de>
297 Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
298 Franck Jullien <franck.jullien@gmail.com>
299 Jeremy Bennett <jeremy.bennett@embecosm.com>
300
301 * configure.tgt: Add targets for or1k and or1knd.
302 * or1k-tdep.c: New file.
303 * or1k-tdep.h: New file.
304 * features/Makefile: Add or1k.xml to build.
305 * features/or1k.xml: New file.
306 * features/or1k-core.xml: New file.
307 * features/or1k.c: Generated.
308
db9077b7
AM
3092017-12-12 Alan Modra <amodra@gmail.com>
310
311 PR tdep/22576
312 * ppc64-tdep.c (ppc64_plt_entry_point): Rewrite to take TOC-relative
313 PLT offset, and retrieve r2 from stack when executing in reverse.
314 (ppc64_standard_linkage1_target): Drop pc param. Calculate offset
315 rather than PLT address.
316 (ppc64_standard_linkage2_target): Likewise.
317 (ppc64_standard_linkage3_target): Likewise.
318 (ppc64_standard_linkage4_target): Likewise.
319 (ppc64_skip_trampoline_code_1): Adjust to suit.
320
a9334058
SM
3212017-12-11 Simon Marchi <simon.marchi@ericsson.com>
322
323 PR gdb/22556
324 * remote.c (remote_thread_name): Return NULL if name is empty.
325 (remote_threads_extra_info): Return NULL if extra info is empty.
326
3c0aa29a
PA
3272017-12-11 Pedro Alves <palves@redhat.com>
328
329 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index)
330 (elf_sym_fns_debug_names): Move to elfread.c.
331 * dwarf2read.c (dwarf2_initialize_objfile): Return a boolean
332 instead of a sym_fns and add 'index_kind' output parameter. Fill
333 the latter in with the index variant kind if using an index.
334 (enum dw_index_kind): Moved to symfile.h.
335 * elfread.c (elf_sym_fns_gdb_index, elf_sym_fns_debug_names)
336 (elf_sym_fns_lazy_psyms): Move from defs.h.
337 (elf_symfile_read): Adjust to new dwarf2_initialize_objfile
338 interface.
339 * symfile.h (enum class dw_index_kind): New, moved from
340 dwarf2read.c.
341 (dwarf2_initialize_objfile): Change prototype.
342
f2f9e7ec
UW
3432017-12-11 Ulrich Weigand <uweigand@de.ibm.com>
344
345 * target-float.c (mpfr_float_ops::from_target): Use mpfr_set_ui
346 instead of mpfr_set_si to convert mantissa bits.
347
08f49010
XR
3482017-12-11 Xavier Roirand <roirand@adacore.com>
349 Joel Brobecker <brobecker@adacore.com>
350
351 * ada-lang.c (ada_tag_value_at_base_address): Change the way
352 tagged type base address is computed.
353 (enum ada_primitive_types) <ada_primitive_type_storage_offset>:
354 New enumerate.
355 (ada_language_arch_info): Set the ada_primitive_type_storage_offset
356 element of lai->primitive_type_vector.
357
a3c5fafd
PA
3582017-12-08 Pedro Alves <palves@redhat.com>
359
360 * dwarf2read.c (mock_mapped_index): Reimplement as an extension of
361 mapped_index_base.
362 (check_match): Adjust to use mock_index directly.
363 (check_find_bounds_finds)
364 (test_mapped_index_find_name_component_bounds): Adjust to work
365 with a mapped_index_base.
366
44ed8f3e
PA
3672017-12-08 Pedro Alves <palves@redhat.com>
368
369 * dwarf2read.c (struct mapped_index_base): New, partially factored
370 out from ...
371 (struct mapped_index): ... this. Inherit mapped_index_base.
372 (mapped_index::symbol_name_slot_invalid):
373 (mapped_index::symbol_name_at): Add override marker.
374 (mapped_index::symbol_name_count): New.
375 (struct mapped_debug_names): Inherit mapped_index_base.
376 (mapped_debug_names::symbol_name_at): New.
377 (mapped_debug_names::symbol_name_count): New.
378 (mapped_index::find_name_components_bounds): Rename to ...
379 (mapped_index_base::find_name_components_bounds): ... this.
380 (mapped_index::build_name_components): Rename to ...
381 (mapped_index_base::build_name_components): ... this. Adjust to
382 use mapped_index_base::symbol_name_count and
383 mapped_index_base::symbol_name_slot_invalid.
384 (dw2_expand_symtabs_matching_symbol): Take a mapped_index_base
385 instead of a mapped_index. Use
386 dw2_expand_symtabs_matching_symbol.
387
f00a2de2
PA
3882017-12-08 Pedro Alves <palves@redhat.com>
389
390 * dwarf2read.c (mapped_index::symbol_table_slot): New.
391 (mapped_index::address_table): Now a gdb::array_view of const
392 gdb_byte.
393 (mapped_index::symbol_table): Now a gdb::array_view of
394 symbol_table_slot.
395 (mapped_index::address_table_size)
396 (mapped_index::symbol_table_slots): Delete.
397 (create_addrmap_from_index): Adjust.
398 (find_slot_in_mapped_hash): Adjust.
399 (read_index_from_section): Adjust.
400 (dwarf2_read_index): Adjust.
401
927aa2e7
JK
4022017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
403 Pedro Alves <palves@redhat.com>
404
405 * defs.h (elf_sym_fns_debug_names): New declaration.
406 * dwarf2read.c: Include "hash_enum.h".
407 (mapped_debug_names): New.
408 (struct dwarf2_per_objfile): Add debug_names, debug_aranges and
409 debug_names_table.
410 (dwarf2_elf_names): Add ".debug_names" and ".debug_aranges".
411 (struct dwz_file): Add debug_names.
412 (dwarf2_per_objfile::locate_sections): Handle debug_names and
413 debug_aranges.
414 (locate_dwz_sections): Handle debug_names.
415 (create_signatured_type_table_from_debug_names)
416 (create_addrmap_from_aranges): New.
417 (dwarf2_read_index): Update function comment.
418 (dwarf5_augmentation): Moved up.
419 (read_debug_names_from_section, create_cus_from_debug_names_list)
420 (create_cus_from_debug_names, dwarf2_read_debug_names): New.
421 (dwarf5_djb_hash): Moved up.
422 (dw2_debug_names_iterator): New.
423 (read_indirect_string_at_offset): New declaration.
424 (mapped_debug_names::namei_to_name)
425 (dw2_debug_names_iterator::find_vec_in_debug_names)
426 (dw2_debug_names_iterator::next, dw2_debug_names_lookup_symbol)
427 (dw2_debug_names_dump, dw2_debug_names_expand_symtabs_for_function)
428 (dw2_debug_names_expand_symtabs_matching, dwarf2_debug_names_functions):
429 New.
430 (dwarf2_initialize_objfile): Return also elf_sym_fns_debug_names.
431 (debug_names::djb_hash): Rename it to dwarf5_djb_hash.
432 (debug_names::build): Update djb_hash caller.
433 (write_debug_names): Move out and rename augmentation to
434 dwarf5_augmentation.
435 * elfread.c (elf_sym_fns_debug_names): New.
436 * psymtab.h (dwarf2_debug_names_functions): New declaration.
437 * symfile.h (struct dwarf2_debug_sections): Add debug_names and
438 debug_aranges.
439 * xcoffread.c (dwarf2_xcoff_names): Add debug_names and debug_aranges.
440
e5fa6583
PA
4412017-12-08 Pedro Alves <palves@redhat.com>
442
443 * common/hash_enum.h: New file.
444
4b514bc8
JK
4452017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
446
447 * dwarf2read.c (create_cu_from_index_list): New from ...
448 (create_cus_from_index_list): ... this function, use it.
449 (dw_expand_symtabs_matching_file_matcher)
450 (dw2_expand_symtabs_matching_one): New from ...
451 (dw2_expand_symtabs_matching): ... this function, use them.
452
abccd1e7
JK
4532017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
454
455 * defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move here
456 declarations from elfread.c.
457 (dwarf2_initialize_objfile): Change return value.
458 * elfread.c (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move these
459 declarations to defs.h.
460 (elf_symfile_read): Adjust dwarf2_initialize_objfile caller.
461 * symfile.h (dwarf2_initialize_objfile): Change return type.
462
437afbb8
JK
4632017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
464 Pedro Alves <palves@redhat.com>
465
466 * contrib/gdb-add-index.sh (index): Rename to ...
467 (index4): ... here.
468 (index5, debugstr, debugstrmerge, debugstrerr): New variables.
469 Support also .debug_names and .debug_str.
470 * dwarf2read.c: Include cmath, set, list.
471 (INDEX_SUFFIX): Rename to ...
472 (INDEX4_SUFFIX): ... here.
473 (INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
474 (file_write(FILE *, const void *, size_t)): New.
475 (file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
476 (data_buf::append_unsigned_leb128, data_buf::empty): New.
477 (data_buf::file_write): Use ::file_write.
478 (data_buf::c_str, dwarf5_djb_hash, debug_names)
479 (check_dwarf64_offsets): New.
480 (psyms_seen_size, write_gdbindex): New from
481 write_psymtabs_to_index code.
482 (dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
483 (enum dw_index_kind): New.
484 (write_psymtabs_to_index): New parameter index_kind. Support
485 filename_str and out_file_str. Move code to write_gdbindex,
486 possibly call write_debug_names.
487 (save_gdb_index_command): New parameter -dwarf-5.
488 (_initialize_dwarf2_read): Document the new parameter -dwarf-5.
489
6432ec65
JK
4902017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
491 Pedro Alves <palves@redhat.com>
492
493 * contrib/cc-with-tweaks.sh: Change interpreter to bash, incl. initial
494 comment.
495 (GDB_ADD_INDEX): New variable.
496 <$want_index>: Call $GDB_ADD_INDEX.
497
92469284
SDJ
4982017-12-08 Sergio Durigan Junior <sergiodj@redhat.com>
499
500 * dtrace-probe.c (dtrace_process_dof_probe): Do not declare a new
501 "expression_up" inside the TRY block.
502
f17d9474
YQ
5032017-12-08 Yao Qi <yao.qi@linaro.org>
504
505 * breakpoint.c (update_watchpoint): Call
506 address_significant.
507
a0de8c21
YQ
5082017-12-08 Yao Qi <yao.qi@linaro.org>
509
510 * breakpoint.c (adjust_breakpoint_address): Call
511 address_significant.
512
a738ea1d
YQ
5132017-12-08 Yao Qi <yao.qi@linaro.org>
514
515 * aarch64-tdep.c (aarch64_gdbarch_init): Install gdbarch
516 significant_addr_bit.
517 * gdbarch.sh (significant_addr_bit): New.
518 * gdbarch.c, gdbarch.h: Re-generated.
519 * target.c (memory_xfer_partial): Call address_significant.
520 * utils.c (address_significant): New function.
521 * utils.h (address_significant): Declare.
522
8e481c3b
TT
5232017-12-08 Tom Tromey <tom@tromey.com>
524
525 * printcmd.c (ui_printf): Update. Use std::vector.
526 * common/format.h (struct format_piece): Add constructor.
527 <string>: Now const.
528 (class format_pieces): New class.
529 (parse_format_string, free_format_pieces)
530 (free_format_pieces_cleanup): Remove.
531 * common/format.c (format_pieces::format_pieces): Rename from
532 parse_format_string. Update.
533 (free_format_pieces, free_format_pieces_cleanup): Remove.
534 * breakpoint.c (parse_cmd_to_aexpr): Update. Use std::vector.
535 * ax-gdb.h (gen_printf): Remove argument.
536 * ax-gdb.c (gen_printf): Remove "frags" argument.
537 (maint_agent_printf_command): Update. Use std::vector.
538
6b05c8bd
YQ
5392017-12-08 Yao Qi <yao.qi@linaro.org>
540
541 PR breakpionts/22567
542 * linespec.c (minsym_found): Set sal.section.
543
336ef6d2
AA
5442017-12-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
545
546 * configure.tgt (s390*-*-linux*): Add symfile-mem.o.
547
fa6eb693
KS
5482017-12-07 Keith Seitz <keiths@redhat.com>
549
550 PR breakpoints/22569
551 * location.c (string_to_explicit_location): When terminating
552 parsing early, break out of enclosing loop instead of returning.
553
883fd55a
KS
5542017-12-07 Keith Seitz <keiths@redhat.com>
555
556 * NEWS (New commands): Mention set/show print type nested-type-limit.
557 * c-typeprint.c (c_type_print_base): Print out nested types.
558 * dwarf2read.c (struct typedef_field_list): Rename to ...
559 (struct decl_field_list): ... this. Change all uses.
560 (struct field_info) <nested_types_list, nested_types_list_count>:
561 New fields.
562 (add_partial_symbol): Look for nested type definitions in C++, too.
563 (dwarf2_add_typedef): Rename to ...
564 (dwarf2_add_type_defn): ... this.
565 (type_can_define_types): New function.
566 Update assertion to use type_can_define_types.
567 Permit NULL for a field's name.
568 (process_structure_scope): Handle child DIEs of types that can
569 define types.
570 Copy the list of nested types into the type struct.
571 * gdbtypes.h (struct typedef_field): Rename to ...
572 (struct decl_field): ... this. Change all uses.
573 [is_protected, is_private]: New fields.
574 (struct cplus_struct_type) <nested_types, nested_types_count>: New
575 fields.
576 (TYPE_NESTED_TYPES_ARRAY, TYPE_NESTED_TYPES_FIELD)
577 (TYPE_NESTED_TYPES_FIELD_NAME, TYPE_NESTED_TYPES_FIELD_TYPE)
578 (TYPE_NESTED_TYPES_COUNT, TYPE_NESTED_TYPES_FIELD_PROTECTED)
579 (TYPE_NESTED_TYPES_FIELD_PRIVATE): New macros.
580 * typeprint.c (type_print_raw_options, default_ptype_flags): Add
581 default value for print_nested_type_limit.
582 (print_nested_type_limit): New static variable.
583 (set_print_type_nested_types, show_print_type_nested_types): New
584 functions.
585 (_initialize_typeprint): Register new commands for set/show
586 `print-nested-type-limit'.
587 * typeprint.h (struct type_print_options) [print_nested_type_limit]:
588 New field.
589
99598d71
TT
5902017-12-07 Tom Tromey <tom@tromey.com>
591
592 PR breakpoints/22511:
593 * breakpoint.c (commands_command_1): Don't throw an exception when
594 no commands have been read.
595
23a8d186
AS
5962017-12-07 Adam Stylinski <adam.stylinski@etegent.com>
597
598 PR c++/21222
599 * target-descriptions.c (print_c_tdesc::visit_pre): Change type of
600 range-for variable.
601
30970df7
SM
6022017-12-07 Simon Marchi <simon.marchi@ericsson.com>
603
604 * common/selftest.h (struct selftest): Add virtual destructor.
605
824cc835
PM
6062017-12-07 Phil Muldoon <pmuldoon@redhat.com>
607
608 * python/py-breakpoint.c (bppy_init): Use string_to_event_location
609 over basic location code. Implement explicit location keywords.
610 (bppy_init_validate_args): New function.
611 * NEWS: Document Python explicit breakpoint locations.
612
9c226a86
JB
6132017-12-07 Joel Brobecker <brobecker@adacore.com>
614
615 * MAINTAINERS: Restore target entries for m68hc11-elf,
616 score-elf and xstormy16-elf, incorrectly removed in a previous
617 patch meant to only update the list of active maintainers.
618
649a140c
PA
6192017-12-06 Pedro Alves <palves@redhat.com>
620
621 * break-catch-syscall.c (insert_catch_syscall)
622 (remove_catch_syscall): Adjust to pass reference to
623 inf_data->syscalls_counts directly via gdb::array_view.
624 * fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
625 and gdb::array_view.
626 * linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
627 * remote.c (remote_set_syscall_catchpoint): Likewise.
628 * target-debug.h (target_debug_print_bool): New.
629 (define target_debug_print_gdb_array_view_const_int): New.
630 * target-delegates.c: Regenerate.
631 * target.h (target_ops) <to_set_syscall_catchpoint>: Use
632 gdb::array_view and bool.
633 (target_set_syscall_catchpoint): Likewise.
634
9a93831c
SM
6352017-12-06 Simon Marchi <simon.marchi@ericsson.com>
636
637 * break-catch-syscall.c (catch_syscall_completer): Get pointers
638 to syscall group strings after building the string vector.
639
7cc244de
PA
6402017-12-06 Pedro Alves <palves@redhat.com>
641
642 * remote.c (remote_query_supported): Don't send "xmlRegisters=" if
643 "qXfer:features:read"" is disabled.
644 (remote_write_qxfer, remote_read_qxfer, remote_search_memory):
645 Check packet_config_support instead of packet->support directly.
646
858c9d13
SM
6472017-12-05 Simon Marchi <simon.marchi@ericsson.com>
648
649 * target-descriptions.c (struct tdesc_feature) <registers>: Use
650 tdesc_reg_up typedef.
651 (struct target_desc) <features>: Use tdesc_feature_up typedef.
652
d4a0e8b5
SM
6532017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
654
655 * target-descriptions.c (struct tdesc_type): Use default
656 destructor.
657 <u>: Remove.
658 <accept>: Remove.
659 (struct tdesc_type_builtin): New.
660 (struct tdesc_type_vector): New.
661 (struct tdesc_type_with_fields): New.
662 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
663 (tdesc_gdb_type): Remove.
664 (tdesc_register_type): Adjust.
665 (tdesc_create_vector): Create tdesc_type_vector.
666 (tdesc_create_struct): Create tdesc_type_with_fields.
667 (tdesc_set_struct_size): Change parameter type.
668 (tdesc_create_union): Create tdesc_type_with_fields.
669 (tdesc_create_flags): Likewise.
670 (tdesc_create_enum): Likewise.
671 (tdesc_add_field): Change parameter type.
672 (tdesc_add_typed_bitfield): Likewise.
673 (tdesc_add_bitfield): Likewise.
674 (tdesc_add_flag): Likewise.
675 (tdesc_add_enum_value): Likewise.
676 (print_c_tdesc) <visit>: Remove overload with tdesc_type
677 parameter, add overloads for tdesc_type_builtin,
678 tdesc_type_with_fields and tdesc_type_vector.
679 <m_printed_type>: Remove.
680 <m_printed_element_type, m_printed_type_with_fields>: Add.
681 * target-descriptions.h (tdesc_create_enum): Change return type.
682 (tdesc_add_typed_bitfield): Change parameter type.
683 (tdesc_add_enum_value): Change parameter type.
684 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
685 type to tdesc_type_with_fields.
686 (tdesc_start_struct): Adjust.
687 (tdesc_start_flags): Adjust.
688 (tdesc_start_enum): Adjust.
689 (tdesc_start_field): Adjust.
690 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
691 (struct tdesc_type_vector): Forward-declare.
692 (struct tdesc_type_with_fields): Forward-declare.
693 (tdesc_create_struct): Change return type.
694 (tdesc_create_union): Likewise.
695 (tdesc_create_flags): Likewise.
696 (tdesc_add_field): Change parameter type.
697 (tdesc_set_struct_size): Likewise.
698 (tdesc_add_bitfield): Likewise.
699 (tdesc_add_flag): Likewise.
700 * features: Re-generate C files.
701
f0cddbef
SM
7022017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
703
704 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
705 (struct tdesc_arch_reg): Add constructor.
706 (DEF_VEC_O (tdesc_arch_reg)): Remove.
707 (struct tdesc_arch_data): Initialize fields.
708 <arch_regs>: Change type to std::vector.
709 (target_find_description): Adjust.
710 (tdesc_find_type): Adjust.
711 (tdesc_data_init): Call tdesc_arch_data constructor.
712 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
713 (tdesc_data_cleanup): Free data with delete.
714 (tdesc_numbered_register): Adjust.
715 (tdesc_find_arch_register): Adjust.
716 (tdesc_use_registers): Adjust.
717
d05200d1
SM
7182017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
719
720 * target-descriptions.c (tdesc_type_field): Remove typedef.
721 (DEF_VEC_O (tdesc_type_field)): Remove.
722 (struct tdesc_type_field): Add constructor.
723 <name>: Change type to std::string.
724 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
725 kind uses it.
726 <~tdesc_type>: Destroy vector if the type kind uses it.
727 <u::u::fields>: Change type to std::vector.
728 (tdesc_gdb_type): Adjust.
729 (tdesc_add_field): Adjust.
730 (tdesc_add_typed_bitfield): Adjust.
731 (tdesc_add_field): Adjust.
732 (tdesc_add_enum_value): Adjust.
733 (class print_c_tdesc) <visit>: Adjust.
734
082b9140
SM
7352017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
736
737 * target-descriptions.c (struct tdesc_type) <name>: Change type
738 to std::string.
739 <~tdesc_type>: Don't manually free name.
740 <operator==>: Adjust.
741 (tdesc_named_type): Adjust.
742 (tdesc_find_type): Adjust.
743 (tdesc_gdb_type): Adjust.
744 (class print_c_tdesc) <visit>: Adjust.
745
53c934e9
SM
7462017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
747
748 * target-descriptions.c (tdesc_type_p): Remove typedef.
749 (DEF_VEC_P (tdesc_type_p)): Remove.
750 (struct tdesc_feature) <types>: Change type to std::vector.
751 <~tdesc_feature>: Replace with default implementation.
752 <accept>: Adjust.
753 (tdesc_named_type): Adjust.
754 (tdesc_create_vector): Adjust.
755 (tdesc_create_struct): Adjust.
756 (tdesc_create_union): Adjust.
757 (tdesc_create_flags): Adjust.
758 (tdesc_create_enum): Adjust.
759
a8142ee1
SM
7602017-12-05 Simon Marchi <simon.marchi@ericsson.com>
761
762 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
763 type of name_ parameter, adjust to std::string change.
764 <name, group, type>: Change type to std::string.
765 <~tdesc_reg>: Replace with default implementation.
766 <operator==>: Adjust.
767 (tdesc_find_register_early): Adjust.
768 (tdesc_register_name): Adjust.
769 (tdesc_register_type): Adjust.
770 (tdesc_register_in_reggroup_p): Adjust.
771 (class print_c_tdesc) <visit>: Adjust.
772 (class print_c_feature) <visit>: Adjust.
858c9d13
SM
773 * features/arc-arcompact.c: Re-generate.
774 * features/arc-v2.c: Re-generate.
a8142ee1 775
c9c895b9
SM
7762017-12-05 Simon Marchi <simon.marchi@ericsson.com>
777
778 * target-descriptions.c (tdesc_reg_p): Remove typedef.
779 (DEF_VEC_P (tdesc_reg_p)): Remove.
780 (struct tdesc_feature) <registers>: Change type to std::vector.
781 <~tdesc_feature>: Don't manually free registers.
782 <accept>: Adjust.
783 <operator==>: Adjust.
784 (tdesc_has_registers): Adjust.
785 (tdesc_find_register_early): Adjust.
786 (tdesc_use_registers): Adjust.
787 (tdesc_create_reg): Adjust.
788
f65ff9f9
SM
7892017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
790
791 * target-descriptions.c (tdesc_feature) <name>: Change type to
792 std::string.
793 <~tdesc_feature>: Don't manually free name.
794 <operator==>: Adjust.
795 (tdesc_find_feature): Adjust.
796 (tdesc_feature_name): Adjust.
797 (class print_c_tdesc) <visit_pre>: Adjust.
798 (class print_c_feature) <visit_pre>: Adjust.
799
3eea796c
SM
8002017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
801
802 * target-descriptions.c (tdesc_feature_p): Remove typedef.
803 (DEF_VEC_P (tdesc_feature_p)): Remove.
804 (struct target_desc) <features>: Change type to std::vector.
805 <~target_desc>: Replace with default implementation.
806 <accept>: Adjust.
807 <operator==>: Adjust.
808 (tdesc_has_registers): Adjust.
809 (tdesc_find_feature): Adjust.
810 (tdesc_use_registers): Adjust.
811 (tdesc_create_feature): Adjust.
812
40e2a983
SM
8132017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
814
815 * target-descriptions.c (arch_p): Remove typedef.
816 (DEF_VEC_P (arch_p)): Remove.
817 (struct target_desc) <compatible>: Change type to std::vector.
818 <~target_desc>: Don't manually free compatible.
819 (tdesc_compatible_p): Adjust.
820 (tdesc_add_compatible): Adjust.
821 (class print_c_tdesc) <visit_pre>: Adjust.
822
129c10bc
SM
8232017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
824
825 * target-descriptions.c (property_s): Remove typedef.
826 (DEF_VEC_O (property_s)): Remove.
827 (struct target_desc) <properties>: Make an std::vector.
828 <~target_desc>: Don't manually free properties.
829 (tdesc_property): Adjust.
830 (set_tdesc_property): Adjust.
831 (class print_c_tdesc) <visit_pre>: Adjust.
832
ed9376bd
SM
8332017-12-05 Simon Marchi <simon.marchi@ericsson.com>
834
835 * common/gdb_assert.h (gdb_static_assert): Redefine using
836 static_assert.
837
798a7429
SM
8382017-12-05 Simon Marchi <simon.marchi@ericsson.com>
839
840 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
841 unused variables.
842 (ada_is_redundant_range_encoding): Likewise.
843 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
844 Likewise.
845 * alpha-tdep.c (alpha_software_single_step): Likewise.
846 * arm-tdep.c (_initialize_arm_tdep): Likewise.
847 * auto-load.c (info_auto_load_cmd): Likewise.
848 * break-catch-syscall.c (insert_catch_syscall): Likewise.
849 (remove_catch_syscall): Likewise.
850 * breakpoint.c (condition_completer): Likewise.
851 (clear_command): Likewise.
852 (update_breakpoint_locations): Likewise.
853 * btrace.c (btrace_disable): Likewise.
854 (btrace_teardown): Likewise.
855 (btrace_maint_update_pt_packets): Likewise.
856 (maint_btrace_clear_cmd): Likewise.
857 * cli/cli-decode.c (lookup_cmd_1): Likewise.
858 (lookup_cmd_composition): Likewise.
859 * cli/cli-dump.c (scan_filename): Likewise.
860 (restore_command): Likewise.
861 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
862 * compile/compile-object-load.c (compile_object_load): Likewise.
863 * compile/compile-object-run.c (compile_object_run): Likewise.
864 * compile/compile.c (compile_to_object): Likewise.
865 * completer.c (filename_completer): Likewise.
866 (complete_files_symbols): Likewise.
867 (complete_expression): Likewise.
868 * corelow.c (core_open): Likewise.
869 * ctf.c (ctf_start): Likewise.
870 (ctf_write_status): Likewise.
871 (ctf_write_uploaded_tsv): Likewise.
872 (ctf_write_definition_end): Likewise.
873 (ctf_open_dir): Likewise.
874 (ctf_xfer_partial): Likewise.
875 (ctf_trace_find): Likewise.
876 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
877 Likewise.
878 * dwarf2loc.c (allocate_piece_closure): Likewise.
879 (indirect_pieced_value): Likewise.
880 (dwarf2_evaluate_loc_desc_full): Likewise.
881 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
882 (dw2_expand_symtabs_matching): Likewise.
883 (dw2_map_symbol_filenames): Likewise.
884 (read_and_check_comp_unit_head): Likewise.
885 (read_cutu_die_from_dwo): Likewise.
886 (lookup_dwo_unit): Likewise.
887 (read_comp_units_from_section): Likewise.
888 (dwarf2_compute_name): Likewise.
889 (handle_DW_AT_stmt_list): Likewise.
890 (create_cus_hash_table): Likewise.
891 (create_dwp_v2_section): Likewise.
892 (dwarf2_rnglists_process): Likewise.
893 (dwarf2_ranges_process): Likewise.
894 (dwarf2_record_block_ranges): Likewise.
895 (is_vtable_name): Likewise.
896 (read_formatted_entries): Likewise.
897 (skip_form_bytes): Likewise.
898 * elfread.c (elf_symtab_read): Likewise.
899 * exec.c (exec_file_command): Likewise.
900 * f-valprint.c (f_val_print): Likewise.
901 (info_common_command_for_block): Likewise.
902 * guile/guile.c (initialize_scheme_side): Likewise.
903 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
904 * guile/scm-cmd.c (cmdscm_completer): Likewise.
905 (gdbscm_register_command_x): Likewise.
906 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
907 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
908 * guile/scm-ports.c (file_port_magic): Likewise.
909 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
910 (ppscm_pretty_print_one_value): Likewise.
911 (ppscm_print_children): Likewise.
912 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
913 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
914 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
915 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
916 * i386-tdep.c (i386_register_reggroup_p): Likewise.
917 * infcmd.c (run_command_1): Likewise.
918 (until_next_fsm_clean_up): Likewise.
919 * linespec.c (linespec_complete): Likewise.
920 (find_label_symbols): Likewise.
921 * m2-valprint.c (m2_val_print): Likewise.
922 * memattr.c (require_user_regions): Likewise.
923 (lookup_mem_region): Likewise.
924 (disable_mem_command): Likewise.
925 (mem_delete): Likewise.
926 * mep-tdep.c (mep_register_name): Likewise.
927 (mep_analyze_prologue): Likewise.
928 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
929 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
930 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
931 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
932 * minidebug.c (lzma_open): Likewise.
933 * minsyms.c (lookup_minimal_symbol): Likewise.
934 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
935 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
936 (mips_o64_return_value): Likewise.
937 (mips_single_step_through_delay): Likewise.
938 (_initialize_mips_tdep): Likewise.
939 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
940 (nios2_software_single_step): Likewise.
941 * parse.c (find_minsym_type_and_address): Likewise.
942 * psymtab.c (psym_relocate): Likewise.
943 * python/py-breakpoint.c (bppy_get_commands): Likewise.
944 (gdbpy_breakpoint_modified): Likewise.
945 * python/py-infevents.c (create_inferior_call_event_object):
946 Likewise.
947 * python/py-record-btrace.c (btpy_list_item): Likewise.
948 * python/py-type.c (typy_str): Likewise.
949 * python/py-value.c (valpy_call): Likewise.
950 * python/python.c (do_start_initialization): Likewise.
951 * record-btrace.c (record_btrace_insn_history_range): Likewise.
952 (record_btrace_call_history_range): Likewise.
953 (record_btrace_record_method): Likewise.
954 (record_btrace_xfer_partial): Likewise.
955 (btrace_get_frame_function): Likewise.
956 * record-full.c (record_full_open): Likewise.
957 * record.c (get_context_size): Likewise.
958 * registry.h (DEFINE_REGISTRY): Likewise.
959 * remote-fileio.c (remote_fileio_request): Likewise.
960 * remote.c (remote_update_thread_list): Likewise.
961 (remote_check_symbols): Likewise.
962 (remote_commit_resume): Likewise.
963 (remote_interrupt): Likewise.
964 (remote_insert_breakpoint): Likewise.
965 (compare_sections_command): Likewise.
966 * rust-exp.y (super_name): Likewise.
967 (lex_string): Likewise.
968 (convert_ast_to_type): Likewise.
969 (convert_ast_to_expression): Likewise.
970 * rust-lang.c (rust_print_struct_def): Likewise.
971 (rust_print_type): Likewise.
972 (rust_evaluate_subexp): Likewise.
973 * rx-tdep.c (rx_register_type): Likewise.
974 * ser-event.c (serial_event_clear): Likewise.
975 * serial.c (serial_open): Likewise.
976 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
977 * symfile.c (section_is_overlay): Likewise.
978 (overlay_unmapped_address): Likewise.
979 (overlay_mapped_address): Likewise.
980 (simple_overlay_update_1): Likewise.
981 (simple_overlay_update): Likewise.
982 * symtab.c (symbol_find_demangled_name): Likewise.
983 (search_symbols): Likewise.
984 * target-descriptions.c (tdesc_predefined_type): Likewise.
985 * target.c (target_commit_resume): Likewise.
986 * thread.c (print_selected_thread_frame): Likewise.
987 * top.c (new_ui_command): Likewise.
988 (gdb_readline_no_editing): Likewise.
989 * tracefile-tfile.c (tfile_open): Likewise.
990 * tracepoint.c (create_tsv_from_upload): Likewise.
991 * utils.c (quit): Likewise.
992 (defaulted_query): Likewise.
993 * valarith.c (value_concat): Likewise.
994 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
995 * xml-tdesc.c (target_fetch_description_xml): Likewise.
996 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
997 (xtensa_pseudo_register_write): Likewise.
998
7403715e
TT
9992017-12-04 Tom Tromey <tom@tromey.com>
1000
1001 * NEWS: Mention Rust trait object inspection.
1002
50a1fdd5
PA
10032017-12-04 Pedro Alves <palves@redhat.com>
1004
1005 PR gdb/22499
1006 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
1007 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
1008 (vex2_prefix_p, vex3_prefix_p): New functions.
1009 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
1010 VEX3 prefixes.
1011 (fixup_riprel): Set VEX3.!B.
1012
1e97a227
SM
10132017-12-03 Simon Marchi <simon.marchi@ericsson.com>
1014
1015 * target.h (mem_region_vector): Remove.
1016 (struct target_ops) <to_memory_map>: Change return type to
1017 std::vector<mem_region>.
1018 * target-debug.h (target_debug_print_mem_region_vector): Rename
1019 to ...
1020 (target_debug_print_std_vector_mem_region): ... this.
1021 * target-delegates.c: Re-generate.
1022
10f64178
PA
10232017-12-03 Pedro Alves <palves@redhat.com>
1024
1025 * make-target-delegates (munge_type): Also munge '<', '>', and
1026 ':'. Avoid double underscores in identifiers, and trailing
1027 underscores.
1028 * target-debug.h
1029 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
1030 ...
1031 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
1032 * target-delegates.c: Regenerate.
1033
6d83e819
SM
10342017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1035
1036 * common/poison.h (XDELETE): Fix typo.
1037
97cbe998
SDJ
10382017-12-01 Andrew Cagney <cagney@redhat.com>
1039 Joel Brobecker <brobecker@adacore.com>
1040 Sergio Durigan Junior <sergiodj@redhat.com>
1041
1042 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
1043 feature.
1044 * coffread.c (coff_symfile_read): Do not map over sections with
1045 'coff_locate_sections' if readnever is on.
1046 * dwarf2read.c (dwarf2_has_info): Return 0 if
1047 readnever is on.
1048 * elfread.c (elf_symfile_read): Do not map over sections with
1049 'elf_locate_sections' if readnever is on.
1050 * main.c (validate_readnow_readnever): New function.
1051 (captured_main_1): Add support for --readnever.
1052 (print_gdb_help): Document --readnever.
1053 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
1054 flag.
1055 * symfile.c (readnever_symbol_files): New global.
1056 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
1057 'READNEVER_SYMBOL_FILES' is set.
1058 (validate_readnow_readnever): New function.
1059 (symbol_file_command): Handle '-readnever' option.
1060 Call 'validate_readnow_readnever'.
1061 (add_symbol_file_command): Handle '-readnever' option.
1062 Call 'validate_readnow_readnever'.
1063 (_initialize_symfile): Document new '-readnever' option for
1064 both 'symbol-file' and 'add-symbol-file' commands.
1065 * top.h (readnever_symbol_files): New extern global.
1066 * xcoffread.c (xcoff_initial_scan): Do not read debug
1067 information if readnever is on.
1068
40fc416f
SDJ
10692017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
1070
1071 * symfile.c (symbol_file_command): Call
1072 'symbol_file_add_main_1' only after processing all command
1073 line options.
1074 (add_symbol_file_command): Modify logic to make arguments
1075 position-independent.
1076
ec6a20c2
JB
10772017-12-01 Joel Brobecker <brobecker@adacore.com>
1078
1079 * ada-lang.c (symbol_list_obstack): Delete.
1080 (resolve_subexp): Make sure "candidates" gets xfree'ed.
1081 (ada_lookup_symbol_list_worker): Remove the limitation that
1082 the result is only good until the next call, now making it
1083 the responsibility of the caller to free the result when no
1084 longer needed. Adjust the function's intro comment accordingly.
1085 (ada_lookup_symbol_list): Adjust the function's intro comment.
1086 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
1087 (ada_lookup_encoded_symbol, get_var_value): Likewise.
1088 (_initialize_ada_language): Remove symbol_list_obstack
1089 initialization.
1090 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
1091 (write_var_or_type, write_name_assoc): Likewise.
1092
d0df06af
TT
10932017-12-01 Tom Tromey <tom@tromey.com>
1094
1095 * Makefile.in (all_deps_files): New variable.
1096 Include .Po files using all_deps_files.
1097
2ee0c9b3
JB
10982017-12-01 Joel Brobecker <brobecker@adacore.com>
1099
1100 * MAINTAINERS: Update list of maintainers, moving those who
1101 stepped down or became inactive to the "Past Maintainers"
1102 section.
1103
44122162
RO
11042017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1105
1106 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
1107 sys/proc.h.
1108 (NEW_PROC_API): Remove.
1109 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
1110 Likewise.
1111 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
1112 * configure: Regenerate.
1113 * config.in: Regenerate.
1114 * gdbserver/configure: Regenerate.
1115 * gdbserver/config.in: Regenerate.
1116
1117 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
1118 NEW_PROC_API test.
1119 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
1120
1121 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
1122
1123 * proc-api.c: Remove !NEW_PROC_API support.
1124 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
1125 Remove tests for macros always defined on Solaris.
1126 * proc-events.c: Remove !NEW_PROC_API support.
1127 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
1128 HAVE_SYS_USER_H tests.
1129 (init_syscall_table): Remove non-Solaris syscalls.
1130 Remove tests for syscalls present on all Solaris versions.
1131 Add missing Solaris 10+ syscalls.
1132 (signal_table): Remove non-Solaris signals.
1133 Remove tests for signals present on all Solaris versions.
1134 (fault_table): Remove non-Solaris faults.
1135 Remove tests for faults present on all Solaris versions.
1136 * proc-flags.c: Remove !NEW_PROC_API support.
1137 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
1138 Remove non-Solaris flags.
1139 * proc-why.c: Remove !NEW_PROC_API support.
1140 (pr_why_table): Remove meaningless comments.
1141 Remove tests for reasons present on all Solaris versions.
1142 Remove OSF/1 cases.
1143 (proc_prettyfprint_why): Likewise.
1144
1145 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
1146 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
1147 Remove WA_READ test, IRIX watchpoint support.
1148 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
1149 types. Change users.
1150 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
1151 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
1152 Change callers.
1153 Remove CTL_PROC_NAME_FMT tests.
1154 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
1155 users.
1156 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
1157 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
1158 (proc_modify_flag): Replace GDBRESET by PCUNSET.
1159 Remove PR_ASYNC, PR_KLC tests.
1160 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
1161 (proc_parent_pid): Remove PCWATCH etc. tests.
1162 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
1163 Remove PCAGENT test.
1164 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
1165 Remove SYS_lwpcreate || SYS_lwp_create test.
1166 (proc_get_current_thread): Likewise.
1167 [PIOCNTHR && PIOCTLIST]: Remove.
1168 [PIOCLSTATUS]: Remove.
1169 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
1170 [PRFS_STOPEXEC]: Remove.
1171 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
1172 (syscall_is_exit): Likewise.
1173 (syscall_is_exec): Likewise.
1174 (syscall_is_lwp_create): Likewise.
1175 Remove SYS_syssgi support.
1176 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
1177 [SYS_syssgi]: Remove.
1178 Remove non-Solaris cases, conditionals.
1179 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
1180 Remove.
1181 (procfs_init_inferior) [SYS_syssgi]: Remove.
1182 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
1183 (procfs_inferior_created) [SYS_syssgi]: Remove.
1184 (procfs_set_watchpoint): Remove !AIX5 test.
1185 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
1186 case.
1187 (mappingflags) [MA_PHYS]: Remove.
1188 (info_mappings_callback): Remove PCAGENT test.
1189 Remove PIOCOPENLWP || PCAGENT test.
1190
e8020e54
RO
11912017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1192
1193 * sol-thread.c (info_solthreads): Constify args.
1194 Cast args to void *.
1195
75059544
JB
11962017-11-29 John Baldwin <jhb@FreeBSD.org>
1197
1198 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
1199
f5a91472
JB
12002017-11-29 Joel Brobecker <brobecker@adacore.com>
1201
1202 * ada-lang.c (to_fixed_range_type): Make sure that the size
1203 of the range type being returned is the same as the size
1204 of the range type being fixed.
1205
bd69330d
PA
12062017-11-29 Pedro Alves <palves@redhat.com>
1207
1208 PR c++/19436
1209 * NEWS: Mention setting breakpoints on functions with C++ ABI
1210 tags.
1211 * completer.h (completion_match_for_lcd) <match,
1212 mark_ignored_range>: New methods.
1213 <finish>: Consider ignored ranges.
1214 <clear>: Clear ignored ranges.
1215 <m_ignored_ranges, m_finished_storage>: New fields.
1216 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1217 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1218 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1219 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1220 * language.c (default_symbol_name_matcher): Pass the
1221 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1222 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1223 * utils.c (skip_abi_tag): New function.
1224 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1225 Handle ABI tags.
1226 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1227 parameter.
1228
12292017-11-29 Pedro Alves <palves@redhat.com>
1230
1231 PR c++/19436
1232 * NEWS: Mention setting breakpoints on functions with C++ ABI
1233 tags.
1234 * completer.h (completion_match_for_lcd) <match,
1235 mark_ignored_range>: New methods.
1236 <finish>: Consider ignored ranges.
1237 <clear>: Clear ignored ranges.
1238 <m_ignored_ranges, m_finished_storage>: New fields.
1239 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
1240 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
1241 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1242 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
1243 * language.c (default_symbol_name_matcher): Pass the
1244 completion_match_for_lcd pointer to strncmp_iw_with_mode.
1245 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
1246 * utils.c (skip_abi_tag): New function.
1247 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
1248 Handle ABI tags.
1249 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
1250 parameter.
1251
a20714ff
PA
12522017-11-29 Pedro Alves <palves@redhat.com>
1253
1254 * NEWS: Mention that breakpoints on C++ functions are now set on
1255 on all namespaces/classes by default, and mention "break
1256 -qualified".
1257 * ax-gdb.c (agent_command_1): Adjust to pass a
1258 symbol_name_match_type to new_linespec_location.
1259 * breakpoint.c (parse_breakpoint_sals): Adjust to
1260 get_linespec_location's return type change.
1261 (strace_marker_create_sals_from_location): Adjust to pass a
1262 symbol_name_match_type to new_linespec_location.
1263 (strace_marker_decode_location): Adjust to get_linespec_location's
1264 return type change.
1265 (strace_command): Adjust to pass a symbol_name_match_type to
1266 new_linespec_location.
1267 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
1268 mention "-qualified".
1269 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
1270 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
1271 enumerator.
1272 (complete_address_and_linespec_locations): New parameter
1273 'match_type'. Pass it down.
1274 (explicit_options): Add "-qualified".
1275 (collect_explicit_location_matches): Pass the requested match type
1276 to the linespec completers. Handle MATCH_QUALIFIED.
1277 (location_completer): Handle "-qualified" combined with linespecs.
1278 * cp-support.c (cp_search_name_hash): New.
1279 (cp_symbol_name_matches_1): Implement wild matching for C++.
1280 (cp_fq_symbol_name_matches): Reimplement.
1281 (cp_get_symbol_name_matcher): Return different matchers depending
1282 on the lookup name's match type.
1283 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
1284 * cp-support.h (cp_search_name_hash): New declaration.
1285 * dwarf2read.c
1286 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
1287 symbols.
1288 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
1289 tests.
1290 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
1291 pass a symbol_name_match_type to new_linespec_location.
1292 * linespec.c (linespec_parse_basic): Lookup function symbols using
1293 the parser's symbol name match type.
1294 (convert_explicit_location_to_linespec): New
1295 symbol_name_match_type parameter. Pass it down to
1296 find_linespec_symbols.
1297 (convert_explicit_location_to_sals): Pass the location's name
1298 match type to convert_explicit_location_to_linespec.
1299 (parse_linespec): New match_type parameter. Save it in the
1300 parser.
1301 (linespec_parser_new): Default to symbol_name_match_type::WILD.
1302 (linespec_complete_function): New symbol_name_match_type
1303 parameter. Use it.
1304 (complete_linespec_component): Pass down the parser's recorded
1305 name match type.
1306 (linespec_complete_label): New symbol_name_match_type parameter.
1307 Use it.
1308 (linespec_complete): New symbol_name_match_type parameter. Save
1309 it in the parser and pass it down. Adjust to
1310 get_linespec_location's prototype change.
1311 (find_function_symbols, find_linespec_symbols): New
1312 symbol_name_match_type parameter. Pass it down instead of
1313 assuming symbol_name_match_type::WILD.
1314 * linespec.h (linespec_complete, linespec_complete_function)
1315 (linespec_complete_label): New symbol_name_match_type parameter.
1316 * location.c (event_location::linespec_location): Now a struct
1317 linespec_location.
1318 (EL_LINESPEC): Adjust.
1319 (initialize_explicit_location): Default to
1320 symbol_name_match_type::WILD.
1321 (new_linespec_location): New symbol_name_match_type parameter.
1322 Record it in the location.
1323 (get_linespec_location): Now returns a struct linespec_location.
1324 (new_explicit_location): Also copy func_name_match_type.
1325 (explicit_to_string_internal)
1326 (string_to_explicit_location): Handle "-qualified".
1327 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
1328 Copy symbol_name_match_type fields.
1329 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
1330 type change.
1331 (event_location_to_string): Adjust to LINESPEC_LOCATION type
1332 change. Handle "-qualfied".
1333 (string_to_explicit_location): Handle "-qualified".
1334 (string_to_event_location_basic): New symbol_name_match_type
1335 parameter. Pass it down.
1336 (string_to_event_location): Handle "-qualified".
1337 * location.h (struct linespec_location): New.
1338 (explicit_location::func_name_match_type): New field.
1339 (new_linespec_location): Now returns a const linespec_location *.
1340 (string_to_event_location_basic): New symbol_name_match_type
1341 parameter.
1342 (explicit_completion_info::saw_explicit_location_option): New
1343 field.
1344 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
1345 symbol_name_match_type to new_linespec_location.
1346 * python/py-breakpoint.c (bppy_init): Likewise.
1347 * python/python.c (gdbpy_decode_line): Likewise.
1348
a207cff2
PA
13492017-11-29 Pedro Alves <palves@redhat.com>
1350
1351 * ada-lang.c (ada_lookup_name_info::matches): Change type of
1352 parameter from completion_match to completion_match_result.
1353 Adjust.
1354 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
1355 * completer.c (completion_tracker::maybe_add_completion): Add
1356 match_for_lcd parameter and use it.
1357 (completion_tracker::add_completion): Likewise.
1358 * completer.h (class completion_match_for_lcd): New class.
1359 (completion_match_result::match_for_lcd): New field.
1360 (completion_match_result::set_match): New method.
1361 (completion_tracker): Add comments.
1362 (completion_tracker::add_completion): Add match_for_lcd parameter.
1363 (completion_tracker::reset_completion_match_result): Reset
1364 match_for_lcd too.
1365 (completion_tracker::maybe_add_completion): Add match_for_lcd
1366 parameter.
1367 (completion_tracker::m_lowest_common_denominator_unique): Extend
1368 comments.
1369 * cp-support.c (cp_symbol_name_matches_1)
1370 (cp_fq_symbol_name_matches): Change type of parameter from
1371 completion_match to completion_match_result. Adjust.
1372 * language.c (default_symbol_name_matcher): Change type of
1373 parameter from completion_match to completion_match_result.
1374 Adjust.
1375 * language.h (completion_match_for_lcd): Forward declare.
1376 (default_symbol_name_matcher): Change type of parameter from
1377 completion_match to completion_match_result.
1378 * symtab.c (compare_symbol_name): Adjust.
1379 (completion_list_add_name): Pass the match_for_lcd to the tracker.
1380 * symtab.h (ada_lookup_name_info::matches): Change type of
1381 parameter from completion_match to completion_match_result.
1382 (symbol_name_matcher_ftype): Likewise, and update comments.
1383
4024cf2b
PA
13842017-11-29 Pedro Alves <palves@redhat.com>
1385
1386 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
1387 * minsyms.c (msymbol_is_text): Delete.
1388 (msymbol_is_function): New function.
1389 * minsyms.h (msymbol_is_text): Delete.
1390 (msymbol_is_function): New declaration.
1391 * symtab.c (find_function_alias_target): Use msymbol_is_function.
1392
5dcf52c1
TT
13932017-11-29 Tom Tromey <tom@tromey.com>
1394
1395 * Makefile.in (distclean): Handle the case where rmdir fails.
1396
8ca2f0b9
TT
13972017-11-29 Tom Tromey <tom@tromey.com>
1398
1399 * symfile.c (_initialize_symfile): Update usage text for
1400 add-symbol-file, symbol-file, load.
1401
02ca603a
TT
14022017-11-29 Tom Tromey <tom@tromey.com>
1403
1404 * symfile.c (add_symbol_file_command): Error if some arguments to
1405 -s are missing. Change unrecognized-argument error message.
1406 (_initialize_symfile): Fix usage text for add-symbol-file.
1407
18ca7347
TT
14082017-11-27 Tom Tromey <tom@tromey.com>
1409
1410 * Makefile.in (REMOTE_OBS): Remove.
1411 (SFILES): Remove remote sources.
1412 (COMMON_SFILES): Add remote sources.
1413 (ALLDEPFILES): Remove dcache.c.
1414
66599a7d
TT
14152017-11-27 Tom Tromey <tom@tromey.com>
1416
1417 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
1418 variables.
1419 (SFILES): Use SUBDIR_TARGET_SRCS.
1420 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
1421 (CONFIG_SRC_SUBDIR): Add target.
1422 (%.o): Remove target rule.
1423
4f04fba8
TT
14242017-11-27 Tom Tromey <tom@tromey.com>
1425
1426 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
1427 registry.o, thread-fsm.o, debug.o.
1428 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
1429 thread-fsm.c, debug.c.
1430
b5adff3b
TT
14312017-11-27 Tom Tromey <tom@tromey.com>
1432
1433 * Makefile.in (COMMON_SFILES): New.
1434 (SFILES): Move some entries to COMMON_SFILES.
1435 (COMMON_OBS): Use COMMON_SFILES.
1436
afa0a411
TT
14372017-11-27 Tom Tromey <tom@tromey.com>
1438
1439 * Makefile.in (YYFILES): Update comment.
1440 (YYOBJ): Redefine.
1441
8fd8d003
TT
14422017-11-27 Tom Tromey <tom@tromey.com>
1443
1444 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
1445 (CONFIG_SRC_SUBDIR): Add python.
1446 (%.o): Remove python rule.
1447 (python/%.o): New rule.
1448 * configure: Rebuild.
1449 * configure.ac (CONFIG_OBS): Refer to python/python.o
1450
bd810fff
TT
14512017-11-27 Tom Tromey <tom@tromey.com>
1452
1453 * configure: Rebuild.
1454 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
1455 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
1456 (CONFIG_SRC_SUBDIR): Add guile.
1457 (%.o): Remove guile rule.
1458
75787ac1
TT
14592017-11-27 Tom Tromey <tom@tromey.com>
1460
1461 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
1462 (%.o): Remove unittests rule.
1463 (CONFIG_SRC_SUBDIR): Add unittests.
1464
5c8a9431
TT
14652017-11-27 Tom Tromey <tom@tromey.com>
1466
1467 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
1468 (CONFIG_SRC_SUBDIR): Add tui.
1469 (%.o): Remove tui rule.
1470
a26aa30c
TT
14712017-11-27 Tom Tromey <tom@tromey.com>
1472
1473 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
1474 (%.o): Remove compile rule.
1475 (CONFIG_SRC_SUBDIR): Add compile.
1476
6f3cdf9a
TT
14772017-11-27 Tom Tromey <tom@tromey.com>
1478
1479 * Makefile.in (SUBDIR_MI_OBS): Redefine.
1480 (%.o): Remove mi rule.
1481 (CONFIG_SRC_SUBDIR): Add mi.
1482 (COMMON_OBS): Use mi/mi-common.o
1483
f06afa53
TT
14842017-11-27 Tom Tromey <tom@tromey.com>
1485
1486 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
1487 (%.o): Remove cli rule.
1488 (CONFIG_SRC_SUBDIR): Add cli.
1489
b22c88c2
TT
14902017-11-27 Tom Tromey <tom@tromey.com>
1491
1492 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
1493 * configure: Rebuild.
1494 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
1495 (CONFIG_DEP_SUBDIR): New variable.
1496 (%.o): Add order-only dependency.
1497 ($(CONFIG_DEP_SUBDIR)): New target.
1498
ee9a09e9
DC
14992017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
1500
1501 PR gdb/21945
1502 * findcmd.c (_initialize_mem_search): Update find command help
1503 text.
1504
e8e7d10c
SM
15052017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
1506
1507 * python/python.c (do_start_initialization): Change progname
1508 type to gdb::unique_xmalloc_ptr. Release the pointer when using
1509 Python 2.
1510
6a997029
TT
15112017-11-26 Tom Tromey <tom@tromey.com>
1512
1513 * common/format.h: Add include guards.
1514
41272101
TT
15152017-11-26 Tom Tromey <tom@tromey.com>
1516
1517 * nat/linux-personality.h (class
1518 maybe_disable_address_space_randomization): New class.
1519 (maybe_disable_address_space_randomization): Don't declare
1520 function.
1521 * nat/linux-personality.c (restore_personality)
1522 (make_disable_asr_cleanup): Remove.
1523 (maybe_disable_address_space_randomization): Now a constructor.
1524 (~maybe_disable_address_space_randomization): New destructor.
1525 * linux-nat.c (linux_nat_create_inferior): Update.
1526
44287fd8
TT
15272017-11-26 Tom Tromey <tom@tromey.com>
1528
1529 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
1530
5ffd2cb7
UW
15312017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
1532
1533 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
1534 "cooked" register. Access only first four bytes of branch target
1535 registers.
1536
0e5457dc
SDJ
15372017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
1538
1539 PR gdb/22491
1540 * stap-probe.c (relocate_address): New function.
1541 (stap_probe::get_relocated_address): Use 'relocate_address'.
1542 (stap_probe::set_semaphore): Use 'relocate_address' and pass
1543 'm_sem_addr'.
1544 (stap_probe::clear_semaphore): Likewise.
1545
deeeba55
PA
15462017-11-25 Pedro Alves <palves@redhat.com>
1547
1548 * dictionary.c: Include "safe-ctype.h".
1549 * minsyms.c: Include "safe-ctype.h".
1550 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
1551
a81aaca0
PA
15522017-11-25 Pedro Alves <palves@redhat.com>
1553
1554 * completer.c (complete_line_internal_1): Skip spaces until the
1555 start of the command.
1556
0662b6a7
PA
15572017-11-24 Pedro Alves <palves@redhat.com>
1558
1559 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
1560 cp_fq_symbol_name_matches. Pass language_cplus to
1561 strncmp_with_mode.
1562 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
1563 (selftests::test_cp_symbol_name_cmp): New.
1564 (_initialize_cp_support): Register "cp_symbol_name_matches"
1565 selftests.
1566 * language.c (default_symbol_name_matcher): Pass language_minimal
1567 to strncmp_iw_with_mode.
1568 * utils.c: Include "cp-support.h" and <algorithm>.
1569 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
1570 (cp_is_operator): New functions.
1571 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
1572 skip whitespace in the symbol name when the lookup name doesn't
1573 have spaces, and vice versa.
1574 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
1575 * utils.h (strncmp_iw_with_mode): Add language parameter.
1576
e547c119
JB
15772017-11-24 Joel Brobecker <brobecker@adacore.com>
1578
1579 * ada-lang.c (ada_exception_message_1, ada_exception_message):
1580 New functions.
1581 (print_it_exception): If available, display the exception
1582 message as well.
1583 * NEWS: Document new feature.
1584
d7fcdff9
UW
15852017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1586
1587 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
1588
30649c14
PR
15892017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
1590
1591 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
1592 (dtrace_probe::is_enabled, dtrace_probe::enable)
1593 (dtrace_probe::disable): Remove keyword 'struct' at for-range
1594 variable
1595 * probe.c (gen_ui_out_table_header_info)
1596 (print_ui_out_not_applicables): Remove keyword 'struct' at
1597 for-range variable
1598
7696f5c9
AH
15992017-11-24 Alan Hayward <alan.hayward@arm.com>
1600
1601 * configure.tgt: Add arch/aarch64.o
1602
8172f16b
SM
16032017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1604
1605 * common/common-utils.h: Include poison.h.
1606 (xfree): Remove declaration, add definition with static_assert.
1607 * common/common-utils.c (xfree): Remove.
1608 * common/poison.h (IsMallocatable): Define.
1609 (IsFreeable): Define.
1610 (free): Delete for non-freeable types.
1611 (xnew): New.
1612 (XNEW): Undef and redefine.
1613 (xcnew): New.
1614 (XCNEW): Undef and redefine.
1615 (xdelete): New.
1616 (XDELETE): Undef and redefine.
1617 (xnewvec): New.
1618 (XNEWVEC): Undef and redefine.
1619 (xcnewvec): New.
1620 (XCNEWVEC): Undef and redefine.
1621 (xresizevec): New.
1622 (XRESIZEVEC): Undef and redefine.
1623 (xdeletevec): New.
1624 (XDELETEVEC): Undef and redefine.
1625 (xnewvar): New.
1626 (XNEWVAR): Undef and redefine.
1627 (xcnewvar): New.
1628 (XCNEWVAR): Undef and redefine.
1629 (xresizevar): New.
1630 (XRESIZEVAR): Undef and redefine.
1631
7aabaf9d
SM
16322017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1633
1634 * gdbthread.h (private_thread_info): Define structure type, add
1635 virtual pure destructor.
1636 (thread_info) <priv>: Change type to unique_ptr.
1637 <private_dtor>: Remove.
1638 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
1639 (private_thread_info::~private_thread_info): Provide default
1640 implementation.
1641 (thread_info::~thread_info): Don't call private_dtor nor
1642 manually free priv.
1643 * aix-thread.c (private_thread_info): Rename to ...
1644 (aix_thread_info): ... this.
1645 (get_aix_thread_info): New.
1646 (sync_threadlists): Adjust.
1647 (iter_tid): Adjust.
1648 (aix_thread_resume): Adjust.
1649 (aix_thread_fetch_registers): Adjust.
1650 (aix_thread_store_registers): Adjust.
1651 (aix_thread_extra_thread_info): Adjust.
1652 * darwin-nat.h (private_thread_info): Rename to ...
1653 (darwin_thread_info): ... this.
1654 (get_darwin_thread_info): New.
1655 * darwin-nat.c (darwin_init_thread_list): Adjust.
1656 (darwin_check_new_threads): Adjust.
1657 (thread_info_from_private_thread_info): Adjust.
1658 * linux-thread-db.c (private_thread_info): Rename to ...
1659 (thread_db_thread_info): ... this, initialize fields.
1660 (get_thread_db_thread_info): New.
1661 <dying>: Change type to bool.
1662 (update_thread_state): Adjust to type rename.
1663 (record_thread): Adjust to type rename an use of unique_ptr.
1664 (thread_db_pid_to_str): Likewise.
1665 (thread_db_extra_thread_info): Likewise.
1666 (thread_db_thread_handle_to_thread_info): Likewise.
1667 (thread_db_get_thread_local_address): Likewise.
1668 * nto-tdep.h (private_thread_info): Rename to ...
1669 (nto_thread_info): ... this, initialize fields.
1670 (get_nto_thread_info): New.
1671 <name>: Change type to std::string.
1672 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1673 use of unique_ptr.
1674 * nto-procfs.c (update_thread_private_data_name): Adjust to
1675 std::string change, allocate nto_private_thread_info with new.
1676 (update_thread_private_data): Adjust to unique_ptr.
1677 * remote.c (private_thread_info): Rename to ...
1678 (remote_thread_info): ... this, initialize data members with
1679 default values.
1680 <extra, name>: Change type to std::string.
1681 <thread_handle>: Change type to non-pointer.
1682 (free_private_thread_info): Remove.
1683 (get_private_info_thread): Rename to...
1684 (get_remote_thread_info): ... this, change return type, adjust to
1685 use of unique_ptr, use remote_thread_info constructor.
1686 (remote_add_thread): Adjust.
1687 (get_private_info_ptid): Rename to...
1688 (get_remote_thread_info): ...this, change return type.
1689 (remote_thread_name): Use get_remote_thread_info, adjust to
1690 change to std::string.
1691 (struct thread_item) <~thread_item>: Remove.
1692 <thread_handle>: Make non pointer.
1693 (start_thread): Adjust to thread_item::thread_handle type
1694 change.
1695 (remote_update_thread_list): Adjust to type name change, move
1696 strings from temporary to long-lived object instead of
1697 duplicating.
1698 (remote_threads_extra_info): Use get_remote_thread_info.
1699 (process_initial_stop_replies): Likewise.
1700 (resume_clear_thread_private_info): Likewise.
1701 (remote_resume): Adjust to type name change.
1702 (remote_commit_resume): Use get_remote_thread_info.
1703 (process_stop_reply): Adjust to type name change.
1704 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1705 (remote_stopped_by_hw_breakpoint): Likewise.
1706 (remote_stopped_by_watchpoint): Likewise.
1707 (remote_stopped_data_address): Likewise.
1708 (remote_core_of_thread): Likewise.
1709 (remote_thread_handle_to_thread_info): Use
1710 get_private_info_thread, adjust to thread_handle field type
1711 change.
1712
21fe1c75
SM
17132017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1714
1715 * remote.c (struct thread_item): Add constructor, disable copy
1716 construction and copy assignment, define default move
1717 construction and move assignment.
1718 <extra, name>: Change type to std::string.
1719 <core>: Initialize.
1720 <thread_handle>: Make non-pointer.
1721 (thread_item_t): Remove typedef.
1722 (DEF_VEC_O(thread_item_t)): Remove.
1723 (threads_listing_context) <contains_thread>: New method.
1724 <remove_thread>: New method.
1725 <items>: Change type to std::vector.
1726 (clear_threads_listing_context): Remove.
1727 (threads_listing_context_remove): Remove.
1728 (remote_newthread_step): Use thread_item constructor, adjust to
1729 change to std::vector.
1730 (start_thread): Use thread_item constructor, adjust to change to
1731 std::vector.
1732 (end_thread): Adjust to change to std::vector and std::string.
1733 (remote_get_threads_with_qthreadinfo): Use thread_item
1734 constructor, adjust to std::vector.
1735 (remote_update_thread_list): Adjust to change to std::vector and
1736 std::string, use threads_listing_context methods.
1737 (remove_child_of_pending_fork): Adjust.
1738 (remove_new_fork_children): Adjust.
1739 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1740 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1741 * unittests/rsp-low-selftests.c: New file.
1742 * common/rsp-low.h: Include common/byte-vector.h.
1743 (hex2bin): New overload.
1744 * common/rsp-low.c (hex2bin): New overload.
1745
089354bb
SM
17462017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1747
1748 * inferior.h (private_inferior): Define structure type, add
1749 virtual pure destructor.
1750 (inferior) <priv>: Change type to unique_ptr.
1751 * inferior.c (private_inferior::~private_inferior): Provide
1752 default implementation.
1753 (inferior::~inferior): Don't free priv field.
1754 (exit_inferior_1): Likewise.
1755 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1756 (darwin_exception_info): Remove typedef.
1757 (DEF_VEC_O (darwin_thread_t)); Remove.
1758 (private_inferior): Rename to ...
1759 (darwin_private_inferior): ... this, extend private_inferior.
1760 (get_darwin_inferior): New.
1761 <threads>: Change type to std::vector of darwin_thread_t pointers.
1762 * darwin-nat.c (darwin_check_new_threads): Adjust.
1763 (find_inferior_task_it): Adjust.
1764 (darwin_find_thread); Adjust.
1765 (darwin_suspend_inferior): Adjust.
1766 (darwin_resume_inferior): Adjust.
1767 (darwin_find_new_inferior): Adjust.
1768 (darwin_decode_notify_message): Adjust.
1769 (darwin_send_reply): Adjust.
1770 (darwin_resume_inferior_threads): Adjust.
1771 (darwin_suspend_inferior_threads): Adjust.
1772 (darwin_decode_message): Adjust.
1773 (darwin_wait): Adjust.
1774 (darwin_interrupt): Adjust.
1775 (darwin_deallocate_threads): Adjust.
1776 (darwin_mourn_inferior): Adjust, don't free private data.
1777 (darwin_reply_to_all_pending_messages): Adjust.
1778 (darwin_stop_inferior): Adjust.
1779 (darwin_setup_exceptions): Adjust.
1780 (darwin_kill_inferior): Adjust.
1781 (darwin_setup_request_notification): Adjust.
1782 (darwin_attach_pid): Adjust.
1783 (darwin_init_thread_list): Adjust.
1784 (darwin_setup_fake_stop_event): Adjust.
1785 (darwin_attach): Adjust.
1786 (darwin_detach): Adjust.
1787 (darwin_xfer_partial): Adjust.
1788 (set_enable_mach_exceptions): Adjust.
1789 (darwin_pid_to_exec_file): Adjust.
1790 (darwin_get_ada_task_ptid): Adjust.
1791 * darwin-nat-info.c (get_task_from_args): Adjust.
1792 (info_mach_ports_command): Adjust.
1793 (info_mach_region_command): Adjust.
1794 (info_mach_exceptions_command): Adjust.
1795 * remote.c (private_inferior): Rename to ...
1796 (remote_private_inferior): ... this, initialize fields.
1797 (get_remote_inferior); New.
1798 (remote_commit_resume): Use get_remote_inferior.
1799 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1800
d044bac8
PA
18012017-11-24 Pedro Alves <palves@redhat.com>
1802
1803 * NEWS: Mention linespecs and explicit locations, and completion
1804 improvements.
1805
e8d58cba
YQ
18062017-11-24 Yao Qi <yao.qi@linaro.org>
1807
1808 * regcache.c (regcache::dump): Remove footnote_register_size.
1809
a63f2d2f
YQ
18102017-11-24 Yao Qi <yao.qi@linaro.org>
1811
1812 * regcache.c (cooked_read_test): Add more test for readonly
1813 regcache.
1814
1b30aaa5
YQ
18152017-11-24 Yao Qi <yao.qi@linaro.org>
1816
1817 * gdbarch-selftests.c (test_target_has_registers): Move it to
1818 target.c.
1819 (test_target_has_stack): Likewise.
1820 (test_target_has_memory): Likewise.
1821 (test_target_prepare_to_store): Likewise.
1822 (test_target_store_registers): Likewise.
1823 (test_target_ops): Likewise.
1824 * regcache.c: Include selftest-arch.h and gdbthread.h.
1825 (target_ops_no_register): New class.
1826 (test_target_fetch_registers): New.
1827 (test_target_store_registers): New.
1828 (test_target_xfer_partial): New.
1829 (readwrite_regcache): New.
1830 (cooked_read_test): New.
1831 (_initialize_regcache): Register the test.
1832 * target.c: (test_target_has_registers): Moved from
1833 gdbarch-selftests.c.
1834 (test_target_has_stack): Likewise.
1835 (test_target_has_memory): Likewise.
1836 (test_target_prepare_to_store): Likewise.
1837 (test_target_store_registers): Likewise.
1838 * target.h (test_target_ops): New class.
1839
6654d750
AH
18402017-11-24 Alan Hayward <alan.hayward@arm.com>
1841
1842 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1843 selftest.
1844
49bdb7ee
AH
18452017-11-24 Alan Hayward <alan.hayward@arm.com>
1846
1847 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1848 * arch/aarch64.c (aarch64_create_target_description): Create
1849 new target description.
1850 * features/Makefile: Add new files.
1851 * features/aarch64.c: Remove file.
1852 * features/aarch64-core.c: New autogenerated file.
1853 * features/aarch64-fpu.c: New autogenerated file.
1854 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
da434ccb
AH
1855
18562017-11-24 Alan Hayward <alan.hayward@arm.com>
1857
1858 * Makefile.in: Add new files.
1859 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1860 aarch64_read_description.
1861 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1862 Call aarch64_read_description.
1863 * aarch64-tdep.c (aarch64_read_description): New function.
1864 (aarch64_gdbarch_init): Call aarch64_read_description.
1865 * aarch64-tdep.h (aarch64_read_description): New function.
1866 * arch/aarch64.c: New file.
1867 * configure.tgt: Add new files.
1868
98ead37e
YQ
18692017-11-24 Yao Qi <yao.qi@linaro.org>
1870
1871 * mi/mi-main.c (register_changed_p): Update.
1872 * value.c (value_contents_bits_eq): Change return type.
1873 (value_contents_eq): Likewise.
1874 * value.h: Update comments.
1875
62ad7ce7
YQ
18762017-11-24 Yao Qi <yao.qi@linaro.org>
1877
1878 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1879 local 'changed'. Remove error.
1880 (register_changed_p): Change return type to bool.
1881
506fe5f4
YQ
18822017-11-24 Yao Qi <yao.qi@linaro.org>
1883
1884 * arch/tic6x.c: New file.
1885 * arch/tic6x.h: New file.
1886 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1887 tic6x-core.xml and tic6x-gp.xml.
1888 * features/tic6x-c6xp.c: Generated.
1889 * features/tic6x-core.c: Generated.
1890 * features/tic6x-gp.c: Generated.
1891 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1892 "tic6x-".
1893
00ea2e2a
SM
18942017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1895
1896 * mi/mi-main.c (list_available_thread_groups): Change map value
1897 type to std::vector.
1898
f45e2a77
SM
18992017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1900
1901 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1902
bd046f64
SM
19032017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1904
1905 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1906 back to...
1907 <children_requested>: ... this.
1908 (varobj_get_num_children, varobj_update): Adjust.
1909
4c37490d
SM
19102017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1911
1912 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1913 (ada_value_has_mutated): Likewise.
1914 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1915 (c_is_path_expr_parent): Likewise.
1916 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1917 (mi_cmd_var_set_frozen): Likewise.
1918 (mi_cmd_var_update_iter): Likewise.
1919 (mi_cmd_var_update): Likewise.
1920 * varobj.c (pretty_printing): Likewise.
1921 (varobj_enable_pretty_printing): Likewise.
1922 (struct varobj_root) <floating, is_valid>: Likewise.
1923 (struct varobj_dynamic) <children_requested>: Likewise.
1924 (delete_variable): Likewise.
1925 (delete_variable_1): Likewise.
1926 (install_variable): Likewise.
1927 (update_type_if_necessary): Likewise.
1928 (install_new_value): Likewise.
1929 (value_of_root): Likewise.
1930 (is_root_p): Likewise.
1931 (varobj_create): Likewise.
1932 (varobj_delete): Likewise.
1933 (varobj_has_more): Likewise.
1934 (varobj_set_frozen): Likewise.
1935 (varobj_get_frozen): Likewise.
1936 (install_dynamic_child): Likewise.
1937 (dynamic_varobj_has_child_method): Likewise.
1938 (update_dynamic_varobj_children): Likewise.
1939 (varobj_get_num_children): Likewise.
1940 (varobj_list_children): Likewise.
1941 (is_path_expr_parent): Likewise.
1942 (varobj_default_is_path_expr_parent): Likewise.
1943 (varobj_is_dynamic_p): Likewise.
1944 (varobj_set_value): Likewise.
1945 (varobj_value_has_mutated): Likewise.
1946 (varobj_update): Likewise.
1947 (check_scope): Likewise.
1948 (value_of_root_1): Likewise.
1949 (varobj_value_get_print_value): Likewise.
1950 (varobj_editable_p): Likewise.
1951 (varobj_value_is_changeable_p): Likewise.
1952 (varobj_floating_p): Likewise.
1953 (varobj_default_value_is_changeable_p): Likewise.
1954 (varobj_invalidate_iter): Likewise.
1955 * varobj.h (struct varobj_update_result) <type_changed,
1956 children_changed, changed, value_installed>: Likewise.
1957 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1958 (struct lang_varobj_ops) <value_is_changeable_p,
1959 value_has_mutated, is_path_expr_parent>: Likewise.
1960 (varobj_delete): Likewise.
1961 (varobj_set_frozen): Likewise.
1962 (varobj_get_frozen): Likewise.
1963 (varobj_set_value): Likewise.
1964 (varobj_update): Likewise.
1965 (varobj_editable_p): Likewise.
1966 (varobj_floating_p): Likewise.
1967 (varobj_has_more): Likewise.
1968 (varobj_is_dynamic_p): Likewise.
1969 (varobj_default_value_is_changeable_p): Likewise.
1970 (varobj_value_is_changeable_p): Likewise.
1971 (varobj_is_anonymous_child): Likewise.
1972 (varobj_default_is_path_expr_parent): Likewise.
1973
9c23b42f
SDJ
19742017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1975
1976 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1977 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1978 <type_str>: Convert to 'std::string'.
1979 <expr>: Convert to 'expression_up'.
1980 (dtrace_probe_arg_s): Delete type and VEC.
1981 (dtrace_probe_enabler_s): Likewise.
1982 (struct dtrace_probe): Replace by...
1983 (class dtrace_static_probe_ops): ...this and...
1984 (class dtrace_probe): ...this.
1985 (dtrace_probe_is_linespec): Rename to...
1986 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1987 to reflect change.
1988 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1989 Adjust code. Create new instance of 'dtrace_probe'.
1990 (dtrace_build_arg_exprs): Rename to...
1991 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1992 reflect change.
1993 (dtrace_get_probes): Rename to...
1994 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1995 to reflect change.
1996 (dtrace_get_arg): Rename to...
1997 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1998 reflect change.
1999 (dtrace_probe_is_enabled): Rename to...
2000 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
2001 change.
2002 (dtrace_get_probe_address): Rename to...
2003 (dtrace_probe::get_relocated_address): ...this. Adjust code
2004 to reflect change.
2005 (dtrace_get_probe_argument_count): Rename to...
2006 (dtrace_probe::get_argument_count): ...this. Adjust code to
2007 reflect change.
2008 (dtrace_can_evaluate_probe_arguments): Rename to...
2009 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
2010 to reflect change.
2011 (dtrace_evaluate_probe_argument): Rename to...
2012 (dtrace_probe::evaluate_argument): ...this. Adjust code to
2013 reflect change.
2014 (dtrace_compile_to_ax): Rename to...
2015 (dtrace_probe::compile_to_ax): ...this. Adjust code to
2016 reflect change.
2017 (dtrace_probe_destroy): Delete.
2018 (dtrace_type_name): Rename to...
2019 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
2020 reflect change.
2021 (dtrace_probe::get_static_ops): New method.
2022 (dtrace_gen_info_probes_table_header): Rename to...
2023 (dtrace_static_probe_ops::gen_info_probes_table_header):
2024 ...this. Adjust code to reflect change.
2025 (dtrace_gen_info_probes_table_values): Rename to...
2026 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
2027 code to reflect change.
2028 (dtrace_enable_probe): Rename to...
2029 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
2030 change.
2031 (dtrace_disable_probe): Rename to...
2032 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
2033 change.
2034 (struct probe_ops dtrace_probe_ops): Delete.
2035 (info_probes_dtrace_command): Call 'info_probes_for_spops'
2036 instead of 'info_probes_for_ops'.
2037 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
2038 of 'all_probe_ops'.
2039
0e9ae10f
SDJ
20402017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
2041 Simon Marchi <simark@simark.ca>
2042
2043 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
2044 variable.
2045 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
2046 <aexpr>: Change type to 'expression_up'.
2047 (stap_probe_arg_s): Delete type and VEC.
2048 (struct stap_probe): Delete. Replace by...
2049 (class stap_static_probe_ops): ...this and...
2050 (class stap_probe): ...this. Rename variables to add 'm_'
2051 prefix. Do not use 'union' for arguments anymore.
2052 (stap_get_expected_argument_type): Receive probe name instead
2053 of 'struct stap_probe'. Adjust code.
2054 (stap_parse_probe_arguments): Rename to...
2055 (stap_probe::parse_arguments): ...this. Adjust code to
2056 reflect change.
2057 (stap_get_probe_address): Rename to...
2058 (stap_probe::get_relocated_address): ...this. Adjust code
2059 to reflect change.
2060 (stap_get_probe_argument_count): Rename to...
2061 (stap_probe::get_argument_count): ...this. Adjust code
2062 to reflect change.
2063 (stap_get_arg): Rename to...
2064 (stap_probe::get_arg_by_number'): ...this. Adjust code to
2065 reflect change.
2066 (can_evaluate_probe_arguments): Rename to...
2067 (stap_probe::can_evaluate_arguments): ...this. Adjust code
2068 to reflect change.
2069 (stap_evaluate_probe_argument): Rename to...
2070 (stap_probe::evaluate_argument): ...this. Adjust code
2071 to reflect change.
2072 (stap_compile_to_ax): Rename to...
2073 (stap_probe::compile_to_ax): ...this. Adjust code to
2074 reflect change.
2075 (stap_probe_destroy): Delete.
2076 (stap_modify_semaphore): Adjust comment.
2077 (stap_set_semaphore): Rename to...
2078 (stap_probe::set_semaphore): ...this. Adjust code to reflect
2079 change.
2080 (stap_clear_semaphore): Rename to...
2081 (stap_probe::clear_semaphore): ...this. Adjust code to
2082 reflect change.
2083 (stap_probe::get_static_ops): New method.
2084 (handle_stap_probe): Adjust code to create instance of
2085 'stap_probe'.
2086 (stap_get_probes): Rename to...
2087 (stap_static_probe_ops::get_probes): ...this. Adjust code to
2088 reflect change.
2089 (stap_probe_is_linespec): Rename to...
2090 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
2091 reflect change.
2092 (stap_type_name): Rename to...
2093 (stap_static_probe_ops::type_name): ...this. Adjust code to
2094 reflect change.
2095 (stap_gen_info_probes_table_header): Rename to...
2096 (stap_static_probe_ops::gen_info_probes_table_header):
2097 ...this. Adjust code to reflect change.
2098 (stap_gen_info_probes_table_values): Rename to...
2099 (stap_probe::gen_info_probes_table_values): ...this. Adjust
2100 code to reflect change.
2101 (struct probe_ops stap_probe_ops): Delete.
2102 (info_probes_stap_command): Use 'info_probes_for_spops'
2103 instead of 'info_probes_for_ops'.
2104 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
2105 of 'all_probe_ops'.
2106
935676c9
SDJ
21072017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
2108
2109 * break-catch-throw.c (fetch_probe_arguments): Use
2110 'probe.prob' instead of 'probe.probe'.
2111 * breakpoint.c (create_longjmp_master_breakpoint): Call
2112 'can_evaluate_arguments' and 'get_relocated_address' methods
2113 from probe.
2114 (create_exception_master_breakpoint): Likewise.
2115 (add_location_to_breakpoint): Use 'sal->prob' instead of
2116 'sal->probe'.
2117 (bkpt_probe_insert_location): Call 'set_semaphore' method from
2118 probe.
2119 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
2120 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
2121 of 'probe_ops'.
2122 (probe_key_free): Call 'delete' on probe.
2123 (check_exception_resume): Use 'probe.prob' instead of
2124 'probe.probe'.
2125 * location.c (string_to_event_location_basic): Call
2126 'probe_linespec_to_static_ops'.
2127 * probe.c (class any_static_probe_ops): New class.
2128 (any_static_probe_ops any_static_probe_ops): New variable.
2129 (parse_probes_in_pspace): Receive 'static_probe_ops' as
2130 argument. Adjust code to reflect change.
2131 (parse_probes): Use 'static_probe_ops' instead of
2132 'probe_ops'. Adjust code to reflect change.
2133 (find_probes_in_objfile): Call methods to get name and
2134 provider from probe.
2135 (find_probe_by_pc): Use 'result.prob' instead of
2136 'result.probe'. Call 'get_relocated_address' method from
2137 probe.
2138 (collect_probes): Adjust comment and argument list to receive
2139 'static_probe_ops' instead of 'probe_ops'. Adjust code to
2140 reflect change. Call necessary methods from probe.
2141 (compare_probes): Call methods to get name and provider from
2142 probes.
2143 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
2144 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
2145 adjust code accordingly.
2146 (print_ui_out_not_applicables): Likewise.
2147 (info_probes_for_ops): Rename to...
2148 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
2149 as argument instead of 'probe_ops'. Adjust code. Call
2150 necessary methods from probe.
2151 (info_probes_command): Use 'info_probes_for_spops'.
2152 (enable_probes_command): Pass correct argument to
2153 'collect_probes'. Call methods from probe.
2154 (disable_probes_command): Likewise.
2155 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
2156 (get_probe_argument_count): Move to
2157 'any_static_probe_ops::get_argument_count'.
2158 (can_evaluate_probe_arguments): Move to
2159 'any_static_probe_ops::can_evaluate_arguments'.
2160 (evaluate_probe_argument): Move to
2161 'any_static_probe_ops::evaluate_argument'.
2162 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
2163 'probe.probe'.
2164 (probe_linespec_to_ops): Rename to...
2165 (probe_linespec_to_static_ops): ...this. Adjust code.
2166 (probe_any_is_linespec): Rename to...
2167 (any_static_probe_ops::is_linespec): ...this.
2168 (probe_any_get_probes): Rename to...
2169 (any_static_probe_ops::get_probes): ...this.
2170 (any_static_probe_ops::type_name): New method.
2171 (any_static_probe_ops::gen_info_probes_table_header): New
2172 method.
2173 (compute_probe_arg): Use 'pc_probe.prob' instead of
2174 'pc_probe.probe'. Call methods from probe.
2175 (compile_probe_arg): Likewise.
2176 (std::vector<const probe_ops *> all_probe_ops): Delete.
2177 (std::vector<const static_probe_ops *> all_static_probe_ops):
2178 New variable.
2179 (_initialize_probe): Use 'all_static_probe_ops' instead of
2180 'all_probe_ops'.
2181 * probe.h (struct info_probe_column) <field_name>: Delete
2182 extraneous newline
2183 (info_probe_column_s): Delete type and VEC.
2184 (struct probe_ops): Delete. Replace with...
2185 (class static_probe_ops): ...this and...
2186 (clas probe): ...this.
2187 (struct bound_probe) <bound_probe>: Delete extraneous
2188 newline. Adjust constructor to receive 'probe' instead of
2189 'struct probe'.
2190 <probe>: Rename to...
2191 <prob>: ...this. Delete extraneous newline.
2192 <objfile>: Delete extraneous newline.
2193 (register_probe_ops): Delete unused prototype.
2194 (info_probes_for_ops): Rename to...
2195 (info_probes_for_spops): ...this. Adjust comment.
2196 (get_probe_address): Move to 'probe::get_address'.
2197 (get_probe_argument_count): Move to
2198 'probe::get_argument_count'.
2199 (can_evaluate_probe_arguments): Move to
2200 'probe::can_evaluate_arguments'.
2201 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
2202 * solib-svr4.c (struct svr4_info): Adjust comment.
2203 (struct probe_and_action) <probe>: Rename to...
2204 <prob>: ...this.
2205 (register_solib_event_probe): Receive 'probe' instead of
2206 'struct probe' as argument. Use 'prob' instead of 'probe'
2207 when applicable.
2208 (solib_event_probe_action): Call 'get_argument_count' method
2209 from probe. Adjust comment.
2210 (svr4_handle_solib_event): Adjust comment. Call
2211 'evaluate_argument' method from probe.
2212 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
2213 from probe.
2214 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
2215 'struct probe'. Call 'can_evaluate_arguments' from probe.
2216 * symfile.h: Forward declare 'class probe' instead of 'struct
2217 probe'.
2218 * symtab.h: Likewise.
2219 (struct symtab_and_line) <probe>: Rename to...
2220 <prob>: ...this.
2221 * tracepoint.c (start_tracing): Use 'prob' when applicable.
2222 Call probe methods.
2223 (stop_tracing): Likewise.
2224
8f6cb6c3
JB
22252017-11-22 Joel Brobecker <brobecker@adacore.com>
2226
2227 * ravenscar-thread.c (ravenscar_inferior_created): Remove
2228 trailing newline at end of string in call to warning.
2229
479f8de1
SM
22302017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2231
2232 * osdata.h: Include vector isntead of vec.h.
2233 (osdata_column_s): Remove typedef.
2234 (struct osdata_column): Add constructor.
2235 <name, value>: Change type to std::string.
2236 (DEF_VEC_O (osdata_column_s)): Remove.
2237 (osdata_item_s): Remove typedef.
2238 (struct osdata_item) <columns>: Change type to std::vector.
2239 (DEF_VEC_O (osdata_item_s)): Remove.
2240 (struct osdata): Add constructor.
2241 <type>: Change type to std::string.
2242 <items>: Change type to std::vector.
2243 (osdata_p): Remove typedef.
2244 (DEF_VEC_P (osdata_p)): Remove.
2245 (osdata_parse): Return a unique_ptr.
2246 (osdata_free): Remove.
2247 (make_cleanup_osdata_free): Remove.
2248 (get_osdata): Return a unique_ptr.
2249 (get_osdata_column): Return pointer to std::string, take a
2250 reference to osdata_item as parameter.
2251 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
2252 unique_ptr.
2253 <property_name>: Change type to std::string.
2254 (osdata_start_osdata): Allocate osdata with new and adjust.
2255 (osdata_start_item): Adjust.
2256 (osdata_start_column): Adjust.
2257 (osdata_end_column): Adjust.
2258 (clear_parsing_data): Remove.
2259 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
2260 (osdata_item_clear): Remove.
2261 (get_osdata): return a unique_ptr and adjust.
2262 (get_osdata_column): Return a pointer to std::string and adjust.
2263 (info_osdata): Adjust.
2264 * mi/mi-main.c: Include <map>.
2265 (free_vector_of_osdata_items): Remove.
2266 (list_available_thread_groups): Adjust, use std::map instead of
2267 splay tree.
2268
41bd68f5
SM
22692017-11-22 Simon Marchi <simon.marchi@ericsson.com>
2270
2271 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
2272 case in switch.
2273
7e2fd2f4
SM
22742017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2275
2276 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
2277
0604393c
SM
22782017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2279
2280 * varobj.h (struct varobj_update_result): Add constructor, add
2281 move constructor, disable copy and assign, initialize fields.
2282 <newobj>: Change type to std::vector.
2283 (varobj_update): Return std::vector.
2284 * varobj.c (install_dynamic_child): Change VEC parameters to
2285 std::vector and adjust.
2286 (update_dynamic_varobj_children): Likewise.
2287 (varobj_update): Return std::vector and adjust.
2288 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
2289
ddf0ea08
SM
22902017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2291
2292 * varobj.h (struct varobj) <parent>: Remove const.
2293 <children>: Change type to std::vector.
2294 (varobj_list_children): Return std::vector const reference.
2295 (varobj_restrict_range): Change parameter type to std::vector
2296 const reference.
2297 * varobj.c (varobj_has_more): Adjust.
2298 (varobj_restrict_range): Change parameter type to std::vector
2299 const reference and adjust.
2300 (install_dynamic_child): Adjust.
2301 (update_dynamic_varobj_children): Adjust.
2302 (varobj_list_children): Return std::vector const reference and
2303 adjust.
2304 (varobj_add_child): Adjust.
2305 (update_type_if_necessary): Adjust.
2306 (varobj_update): Adjust.
2307 (delete_variable_1): Adjust.
2308 * ada-varobj.c (ada_value_has_mutated): Adjust.
2309 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
2310
9e5b9d2b
SM
23112017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2312
2313 * varobj.h (struct varobj): Add constructor and destructor,
2314 initialize fields.
2315 * varobj.c (struct varobj_root): Initialize fields.
2316 (struct varobj_dynamic): Initialize fields.
2317 (varobj_create): Use unique_ptr instead of cleanup. Create
2318 varobj with new instead of new_root_variable.
2319 (delete_variable_1): Free variable with delete instead of
2320 free_variable.
2321 (create_child_with_value): Create variable with new instead of
2322 new_variable.
2323 (varobj::varobj): New.
2324 (varobj::~varobj): New (body mostly coming from free_variable).
2325 (new_variable): Remove.
2326 (free_variable): Remove.
2327 (do_free_variable_cleanup): Remove.
2328 (make_cleanup_free_variable): Remove.
2329
fc35dab1
UW
23302017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2331
2332 * core-regset.c: Remove file.
2333 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
2334
2400729e
UW
23352017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2336
2337 * NEWS: Document use of GNU MPFR.
2338 * README: Likewise.
2339
2340 * Makefile.in (LIBMPFR): Add define.
2341 (CLIBS): Add $(LIBMPFR).
2342 * configure.ac: Add --with-mpfr configure option.
2343 * configure: Regenerate.
2344 * config.in: Regenerate.
2345
2346 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
2347 (class mpfr_float_ops): New type.
2348 (mpfr_float_ops::from_target): Two new overloaded functions.
2349 (mpfr_float_ops::to_target): Likewise.
2350 (mpfr_float_ops::to_string): New function.
2351 (mpfr_float_ops::from_string): Likewise.
2352 (mpfr_float_ops::to_longest): Likewise.
2353 (mpfr_float_ops::from_longest): Likewise.
2354 (mpfr_float_ops::from_ulongest): Likewise.
2355 (mpfr_float_ops::to_host_double): Likewise.
2356 (mpfr_float_ops::from_host_double): Likewise.
2357 (mpfr_float_ops::convert): Likewise.
2358 (mpfr_float_ops::binop): Likewise.
2359 (mpfr_float_ops::compare): Likewise.
2360 (get_target_float_ops): Use mpfr_float_ops if available.
2361
7a26362d
UW
23622017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
2363
2364 * target-float.c: Do not include <math.h>.
2365 Include <cmath> and <limits>.
2366 (DOUBLEST): Do not define.
2367 (class target_float_ops): New type.
2368 (class host_float_ops): New templated type.
2369 (class decimal_float_ops): New type.
2370
2371 (floatformat_to_doublest): Rename to ...
2372 (host_float_ops<T>::from_target): ... this. Use template type T
2373 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2374 (host_float_ops<T>::from_target): New overload using a type argument.
2375 (floatformat_from_doublest): Rename to ...
2376 (host_float_ops<T>::to_target): ... this. Use template type T
2377 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
2378 (host_float_ops<T>::to_target): New overload using a type argument.
2379 (floatformat_printf_format): New function.
2380 (struct printf_length_modifier): New templated type.
2381 (floatformat_to_string): Rename to ...
2382 (host_float_ops<T>::to_string): ... this. Use type instead of
2383 floatformat argument. Use floatformat_printf_format and
2384 printf_length_modifier. Remove special handling of invalid numbers,
2385 infinities and NaN (moved to target_float_to_string).
2386 (struct scanf_length_modifier): New templated type.
2387 (floatformat_from_string): Rename to ...
2388 (host_float_ops<T>::from_string): ... this. Use type instead of
2389 floatformat argument. Use scanf_length_modifier.
2390 (floatformat_to_longest): Rename to ...
2391 (host_float_ops<T>::to_longest): ... this. Use type instead of
2392 floatformat argument. Handle out-of-range values deterministically.
2393 (floatformat_from_longest): Rename to ...
2394 (host_float_ops<T>::from_longest): ... this. Use type instead of
2395 floatformat argument.
2396 (floatformat_from_ulongest): Rename to ...
2397 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
2398 floatformat argument.
2399 (floatformat_to_host_double): Rename to ...
2400 (host_float_ops<T>::to_host_double): ... this. Use type instead of
2401 floatformat argument.
2402 (floatformat_from_host_double): Rename to ...
2403 (host_float_ops<T>::from_host_double): ... this. Use type instead of
2404 floatformat argument.
2405 (floatformat_convert): Rename to ...
2406 (host_float_ops<T>::convert): ... this. Use type instead of
2407 floatformat arguments. Remove handling of no-op conversions.
2408 (floatformat_binop): Rename to ...
2409 (host_float_ops<T>::binop): ... this. Use type instead of
2410 floatformat arguments.
2411 (floatformat_compare): Rename to ...
2412 (host_float_ops<T>::compare): ... this. Use type instead of
2413 floatformat arguments.
2414
2415 (match_endianness): Use type instead of length/byte_order arguments.
2416 (set_decnumber_context): Likewise.
2417 (decimal_from_number): Likewise. Update calls.
2418 (decimal_to_number): Likewise.
2419 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
2420 (decimal_float_ops::to_host_double): New dummy function.
2421 (decimal_float_ops::from_host_double): Likewise.
2422 (decimal_to_string): Rename to ...
2423 (decimal_float_ops::to_string): ... this. Use type instead of
2424 length/byte_order arguments. Update calls.
2425 (decimal_from_string): Rename to ...
2426 (decimal_float_ops::from_string): ... this. Use type instead of
2427 length/byte_order arguments. Update calls.
2428 (decimal_from_longest): Rename to ...
2429 (decimal_float_ops::from_longest): ... this. Use type instead of
2430 length/byte_order arguments. Update calls.
2431 (decimal_from_ulongest): Rename to ...
2432 (decimal_float_ops::from_ulongest): ... this. Use type instead of
2433 length/byte_order arguments. Update calls.
2434 (decimal_to_longest): Rename to ...
2435 (decimal_float_ops::to_longest): ... this. Use type instead of
2436 length/byte_order arguments. Update calls.
2437 (decimal_binop): Rename to ...
2438 (decimal_float_ops::binop): ... this. Use type instead of
2439 length/byte_order arguments. Update calls.
2440 (decimal_compare): Rename to ...
2441 (decimal_float_ops::compare): ... this. Use type instead of
2442 length/byte_order arguments. Update calls.
2443 (decimal_convert): Rename to ...
2444 (decimal_float_ops::convert): ... this. Use type instead of
2445 length/byte_order arguments. Update calls.
2446
2447 (target_float_same_category_p): New function.
2448 (target_float_same_format_p): Likewise.
2449 (target_float_format_length): Likewise.
2450 (enum target_float_ops_kind): New type.
2451 (get_target_float_ops_kind): New function.
2452 (get_target_float_ops): Three new overloaded functions.
2453
2454 (target_float_is_zero): Update call.
2455 (target_float_to_string): Add special handling of invalid numbers,
2456 infinities and NaN (moved from floatformat_to_string). Use
2457 target_float_ops callback.
2458 (target_float_from_string): Use target_float_ops callback.
2459 (target_float_to_longest): Likewise.
2460 (target_float_from_longest): Likewise.
2461 (target_float_from_ulongest): Likewise.
2462 (target_float_to_host_double): Likewise.
2463 (target_float_from_host_double): Likewise.
2464 (target_float_convert): Add special case for no-op conversions.
2465 Use target_float_ops callback.
2466 (target_float_binop): Use target_float_ops callback.
2467 (target_float_compare): Likewise.
2468
a9f26f60
YQ
24692017-11-22 Yao Qi <yao.qi@linaro.org>
2470
2471 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
2472
29f9a567
YQ
24732017-11-22 Yao Qi <yao.qi@linaro.org>
2474
2475 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
2476 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
2477
3b1b69bf
JG
24782017-11-21 Jerome Guitton <guitton@adacore.com>
2479
2480 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
2481 with event ptid from the lower layer before doing the
2482 ravenscar-specific update.
2483
54aa6c67
JB
24842017-11-21 Joel Brobecker <brobecker@adacore.com>
2485
2486 * ravenscar-thread.c (is_ravenscar_task): Also verify that
2487 the ptid's TID is nonzero.
2488
cf3fbed4
JB
24892017-11-21 Joel Brobecker <brobecker@adacore.com>
2490
2491 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
2492 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
2493 Make non-static. Change return type to char *. Adjust code
2494 accordingly. Rewrite the function's documentation.
2495 (read_atcb): Adjust call to get_tcb_types_info accordingly.
2496 * ravenscar-thread.c (ravenscar_inferior_created): Check that
2497 we have enough debugging information in the runtime to support
2498 Ada task debugging before we enable the ravenscar-thread layer.
2499
9edcc12f
JB
25002017-11-21 Joel Brobecker <brobecker@adacore.com>
2501
2502 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
2503 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
2504 * ravenscar-thread.c: Add into comment.
2505 (base_magic_null_ptid): Delete.
2506 (base_ptid): Change documentation.
2507 (ravenscar_active_task): Renames ravenscar_running_thread.
2508 All callers updated throughout.
2509 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
2510 (ravenscar_task_is_currently_active): Likewise.
2511 (get_base_thread_from_ravenscar_task): Ditto.
2512 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
2513 (ravenscar_runtime_initialized): Likewise.
2514 (get_running_thread_id): Add new parameter "cpu". Adjust
2515 implementation to handle this new parameter.
2516 (ravenscar_fetch_registers): Small adjustment to use
2517 is_ravenscar_task and ravenscar_task_is_currently_active in
2518 order to decide whether to use the target beneath or this
2519 module's arch_ops.
2520 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
2521 (ravenscar_stopped_by_sw_breakpoint): Use
2522 get_base_thread_from_ravenscar_task to get the underlying
2523 thread, rather than using base_ptid.
2524 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2525 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2526 Likewise.
2527 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
2528
65d40437
JB
25292017-11-21 Joel Brobecker <brobecker@adacore.com>
2530
2531 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
2532 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
2533 (get_tcb_types_info): Set fieldnos.base_cpu.
2534 (read_atcb): Set task_info->base_cpu.
2535 (info_task): Print "Base CPU" info if set by runtime.
2536
e02544b2
JB
25372017-11-21 Joel Brobecker <brobecker@adacore.com>
2538
2539 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
2540 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2541 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2542 New functions.
2543 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
2544 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
2545 to_stopped_data_address and to_core_of_thread fields of
2546 ravenscar_ops.
2547
ed0f4273
UW
25482017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
2549
2550 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
2551 (struct gdbarch_tdep): New member long_double_abi.
2552 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
2553 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
2554 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
2555 format depending on long_double_abi tdep member.
2556 (ppc_floatformat_for_type): Handle __ibm128 type.
2557
0fc76421
SM
25582017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
2559
2560 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
2561
e6b2f5ef
PA
25622017-11-21 Pedro Alves <palves@redhat.com>
2563
2564 * dwarf2read.c (mapped_index::find_name_components_bounds)
2565 <completion mode, upper bound>: Use std::lower_bound instead of
2566 std::upper_bound.
2567 (test_mapped_index_find_name_component_bounds): Remove incorrect
2568 "t1_fund" from expected symbols.
2569
5c58de74
PA
25702017-11-21 Pedro Alves <palves@redhat.com>
2571
2572 * dwarf2read.c (mapped_index::name_components_casing): New field.
2573 (mapped_index) <build_name_components,
2574 find_name_components_bounds): Declare new methods.
2575 (mapped_index::find_name_components_bounds)
2576 (mapped_index::build_name_components): New methods, factored out
2577 from dw2_expand_symtabs_matching_symbol.
2578 (check_find_bounds_finds)
2579 (test_mapped_index_find_name_component_bounds): New.
2580 (run_test): Rename to ...
2581 (test_dw2_expand_symtabs_matching_symbol): ... this.
2582 (run_test): Reimplement.
2583
e1ef7d7a
PA
25842017-11-21 Pedro Alves <palves@redhat.com>
2585
2586 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
2587 (symbol_end): Use cp_ident_is_alnum.
2588 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
2589 * dwarf2read.c (make_sort_after_prefix_name): New function.
2590 (dw2_expand_symtabs_matching_symbol): Use it.
2591 (test_symbols): Add more symbols.
2592 (run_test): Add tests.
2593
cf724bc9
TT
25942017-11-17 Tom Tromey <tom@tromey.com>
2595
2596 * symtab.h (enum symbol_subclass_kind): New.
2597 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
2598 Remove.
2599 <subclass>: New member.
2600 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
2601 * rust-lang.c (rust_get_trait_object_pointer): Update.
2602 * dwarf2read.c (read_func_scope): Update.
2603 (read_variable): Update.
2604
68e745e3
TT
26052017-11-17 Tom Tromey <tom@tromey.com>
2606
2607 * dwarf2read.c (read_func_scope): Update.
2608 * symtab.h (struct template_symbol): Derive from symbol.
2609 <base>: Remove.
2610
71a3c369
TT
26112017-11-17 Tom Tromey <tom@tromey.com>
2612
2613 * symtab.h (struct symbol) <is_rust_vtable>: New member.
2614 (struct rust_vtable_symbol): New.
2615 (find_symbol_at_address): Declare.
2616 * symtab.c (find_symbol_at_address): New function.
2617 * symfile.h (struct quick_symbol_functions)
2618 <find_compunit_symtab_by_address>: New member.
2619 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
2620 function.
2621 (debug_sym_quick_functions): Link to
2622 debug_qf_find_compunit_symtab_by_address.
2623 * rust-lang.c (rust_get_trait_object_pointer): New function.
2624 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
2625 rust_get_trait_object_pointer.
2626 * psymtab.c (psym_relocate): Clear psymbol_map.
2627 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
2628 functions.
2629 (psym_functions): Link to psym_find_compunit_symtab_by_address.
2630 * objfiles.h (struct objfile) <psymbol_map>: New member.
2631 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
2632 (process_die) <DW_TAG_variable>: New case. Call read_variable.
2633 (rust_containing_type, read_variable): New functions.
2634
7468702d
SM
26352017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2636
2637 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
2638
37269bc9
SM
26392017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2640
2641 * common/filestuff.c: Include <algorithm>.
2642 (open_fds): Change type to std::vector<int>.
2643 (do_mark_open_fd): Adjust.
2644 (unmark_fd_no_cloexec): Adjust.
2645 (do_close): Adjust.
2646
5c632425
SM
26472017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2648
2649 * breakpoint.c (output_thread_groups): Take an std::vector.
2650 (print_one_breakpoint_location): Adjust.
2651
ced9779b
JB
26522017-11-17 Joel Brobecker <brobecker@adacore.com>
2653
2654 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2655 (ada_evaluate_subexp_for_cast): New function.
2656 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2657 ada_evaluate_subexp_for_cast.
2658 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2659 eval_skip_value.
2660 * eval.c (evaluate_var_value): Make non-static.
2661 (evaluate_var_msym_value, eval_skip_value): Likewise.
2662 * value.h (evaluate_var_value, evaluate_var_msym_value)
2663 (eval_skip_value): Declare.
2664
b7e22850
JB
26652017-11-16 Joel Brobecker <brobecker@adacore.com>
2666
2667 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2668 Update all callers.
2669
9ccabccd
PA
26702017-11-16 Pedro Alves <palves@redhat.com>
2671
2672 * python/py-unwind.c (pyuw_sniffer): Translate
2673 PyExc_KeyboardInterrupt to a GDB Quit exception.
2674
d930703d
PA
26752017-11-16 Pedro Alves <palves@redhat.com>
2676
2677 * infrun.c (resume_cleanups): Delete.
2678 (resume): No longer install a resume_cleanups cleanup nor call
2679 QUIT.
2680 (proceed): Pass the terminal to the inferior.
2681 (keep_going_pass_signal): No longer install a resume_cleanups
2682 cleanup.
2683
38dc2859
PA
26842017-11-16 Pedro Alves <palves@redhat.com>
2685
2686 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2687 if the prompt is blocked.
2688
688fca4f
PA
26892017-11-16 Pedro Alves <palves@redhat.com>
2690
2691 * breakpoint.c (insert_bp_location): Replace bp_err and
2692 bp_err_message locals by a gdb_exception local.
2693
e2c33ac7
PA
26942017-11-16 Pedro Alves <palves@redhat.com>
2695
2696 * inflow.c (scoped_ignore_sigttou): New class.
2697 (child_terminal_ours_1, new_tty): Use it.
2698
d7236961
UW
26992017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2700
2701 * target-float.c (decimal_from_number): Add byte_order argument and
2702 call match_endianness. Error if unknown floating-point type.
2703 (decimal_to_number): Add byte_order argument and call match_endianness.
2704 (decimal_from_longest): Update call. Do not call match_endianness.
2705 (decimal_from_ulongest): Likewise.
2706 (decimal_binop): Likewise.
2707 (decimal_is_zero): Likewise.
2708 (decimal_compare): Likewise.
2709 (decimal_convert): Likewise.
2710
d8ae99a7
PM
27112017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2712
2713 * python/python.c (gdbpy_rbreak): New function.
2714 * NEWS: Document Python rbreak feature.
2715
c632b645
YQ
27162017-11-16 Yao Qi <yao.qi@linaro.org>
2717
2718 * features/tic6x-c62x.xml: Remove.
2719 * features/tic6x-c64x.xml: Remove.
2720 * features/tic6x-c64xp.xml: Remove.
2721
a014b87a
JB
27222017-11-15 John Baldwin <jhb@FreeBSD.org>
2723
2724 * symtab.h: Include <array>.
2725
94765011
JB
27262017-11-15 John Baldwin <jhb@FreeBSD.org>
2727
2728 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2729 (bsd_kvm_proc_cmd): Likewise.
2730
625ad440
SM
27312017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2732
2733 * tui/tui-win.c (window_name_completer): Replace VEC with
2734 std::vector.
2735
c0c11fa9
AC
27362017-11-15 Andrew Cagney <cagney@gnu.org>
2737
2738 * MAINTAINERS: Remove no-longer applicable entries.
2739
34a7ebaf
AC
27402017-11-15 Andrew Cagney <cagney@gnu.org>
2741
2742 * MAINTAINERS: Move self to Past Maintainers.
2743
5334ef39
YQ
27442017-11-15 Yao Qi <yao.qi@linaro.org>
2745
2746 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2747 * features/nios2-linux.c: Remove.
2748 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2749 initialize_tdesc_nios2_linux.
2750
a714b0d6
YQ
27512017-11-15 Yao Qi <yao.qi@linaro.org>
2752
2753 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2754 M68HC11_LAST_HARD_REG + 1.
2755
92ffd475
PC
27562017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2757
2758 PR gdb/22388
2759 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2760 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2761 Return TARGET_XFER_EOF if size of returned data is 0.
2762
07431908
SM
27632017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2764
2765 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2766 memory-map-selftests.c.
2767 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2768 * memory-map.c (memory_map_start_memory): Fix computation of hi
2769 address.
2770 * unittests/memory-map-selftests.c: New file.
2771
31432a67
JB
27722017-11-09 Joel Brobecker <brobecker@adacore.com>
2773
2774 * ada-lang.c: Fix some typos in the general command documenting
2775 how Ada expressions are being evaluated and how their result
2776 is printed.
2777
e793c052
TT
27782017-11-09 Tom Tromey <tom@tromey.com>
2779
2780 * psymtab.c (psymbol_hash): Do not hash string contents.
2781 (psymbol_compare): Add comment.
2782
7e8835c5
TT
27832017-11-09 Tom Tromey <tom@tromey.com>
2784
2785 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2786
286acbb5
JB
27872017-11-08 Joel Brobecker <brobecker@adacore.com>
2788
2789 * ada-exp.y (write_var_from_sym): Remove parameter
2790 "orig_left_context". Update all callers.
2791
b44ec619
SM
27922017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2793
2794 * tracepoint.h (class collection_list) <stringify>: Return
2795 std::vector<std::string>.
2796 (encode_actions_rsp): Change parameters to
2797 std::vector<std::string> *.
2798 * tracepoint.c (collection_list::stringify): Return
2799 std::vector<std::string> and adjust accordingly.
2800 (encode_actions_rsp): Changee parameters to
2801 std::vector<std::string> and adjust accordingly.
2802 * remote.c (free_actions_list),
2803 free_actions_list_cleanup_wrapper): Remove.
2804 (remote_download_tracepoint): Adjust to std::vector.
2805
2f4732b0
TT
28062017-11-08 Tom Tromey <tom@tromey.com>
2807
2808 * dwarf2read.c (symbolp): Remove typedef.
2809 (read_func_scope): Use std::vector.
2810 (process_structure_scope): Use std::vector.
2811
f9d67a22
PA
28122017-11-08 Pedro Alves <palves@redhat.com>
2813
2814 * ada-lang.c (ada_make_symbol_completion_list): Use
2815 completion_skip_symbol.
2816 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2817 (symbol_is_function_or_method(symbol*)): New.
2818 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2819 completion_skip_symbol.
2820 (default_collect_symbol_completion_matches_break_on): Use
2821 completion_skip_symbol. Pass down mode.
2822 (collect_file_symbol_completion_matches): Pass down mode.
2823 * symtab.h (symbol_is_function_or_method): New declarations.
2824 (completion_skip_symbol): New template function.
2825
56d87ef7
PA
28262017-11-08 Pedro Alves <palves@redhat.com>
2827
2828 * linespec.c (iterate_over_all_matching_symtabs): Add
2829 search_domain parameter. Pass it down to expand_symtabs_matching.
2830 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2831 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2832 search_domain.
2833 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2834 Pass it down.
2835 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2836 symbols.
2837 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2838 it down.
2839
1b026119
PA
28402017-11-08 Pedro Alves <palves@redhat.com>
2841
2842 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2843 text_len locals and don't pass them down.
2844 * symtab.c (completion_list_add_name): Remove
2845 sym_text/sym_text_len parameters and adjust.
2846 (completion_list_add_symbol, completion_list_add_msymbol)
2847 (completion_list_objc_symbol, completion_list_add_fields)
2848 (add_symtab_completions): Likewise.
2849 (default_collect_symbol_completion_matches_break_on)
2850 (collect_file_symbol_completion_matches): Remove sym_text_len
2851 local and don't pass it down.
2852 * symtab.h (completion_list_add_name): Remove
2853 sym_text/sym_text_len parameters.
2854
c62446b1
PA
28552017-11-08 Pedro Alves <palves@redhat.com>
2856
2857 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2858 unittests/lookup_name_info-selftests.c.
2859 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2860 * cp-support.c: Include "selftest.h".
2861 (cp_remove_params_1): Rename from cp_remove_params. Add
2862 'require_param' parameter, and handle it.
2863 (cp_remove_params): Reimplement.
2864 (cp_remove_params_if_any): New.
2865 (selftests::quote): New.
2866 (selftests::check_remove_params): New.
2867 (selftests::test_cp_remove_params): New.
2868 (_initialize_cp_support): Install
2869 selftests::test_cp_remove_params.
2870 * cp-support.h (cp_remove_params_if_any): Declare.
2871 * dwarf2read.c :Include "selftest.h".
2872 (dw2_expand_symtabs_matching_symbol): Use
2873 lookup_name_info::make_ignore_params.
2874 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2875 (selftests::dw2_expand_symtabs_matching::string_or_null)
2876 (selftests::dw2_expand_symtabs_matching::check_match)
2877 (selftests::dw2_expand_symtabs_matching::test_symbols)
2878 (selftests::dw2_expand_symtabs_matching::run_test): New.
2879 (_initialize_dwarf2_read): Register
2880 selftests::dw2_expand_symtabs_matching::run_test.
2881 * psymtab.c (psym_expand_symtabs_matching): Use
2882 lookup_name_info::make_ignore_params.
2883 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2884 If the lookup name wants to ignore parameters, strip them.
2885 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2886 code handling '('.
2887 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2888 (default_collect_symbol_completion_matches_break_on): Don't try to
2889 strip parameters.
2890 * symtab.h (lookup_name_info::lookup_name_info): Add
2891 'ignore_parameters' parameter.
2892 (lookup_name_info::ignore_parameters)
2893 (lookup_name_info::make_ignore_params): New methods.
2894 (lookup_name_info::m_ignore_parameters): New field.
2895 * unittests/lookup_name_info-selftests.c: New file.
2896
61920122
PA
28972017-11-08 Pedro Alves <palves@redhat.com>
2898
2899 * dwarf2read.c (dw2_expand_marked_cus)
2900 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2901 (dw2_expand_symtabs_matching): Move further below.
2902 (dw2_expand_marked_cus): Reindent.
2903
3f563c84
PA
29042017-11-08 Pedro Alves <palves@redhat.com>
2905
2906 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2907 (struct name_component): New.
2908 (mapped_index::name_components): New field.
2909 (mapped_index::symbol_name_at): New method.
2910 (dwarf2_read_index): Call mapped_index ctor.
2911 (dw2_map_matching_symbols): Add comment about name_components
2912 table.
2913 (dw2_expand_symtabs_matching): Factor part to...
2914 (dw2_expand_symtabs_matching_symbol): ... this new function.
2915 Build name components table, and lookup symbols in it before
2916 calling the name matcher.
2917 (dw2_expand_marked_cus): New, factored out from
2918 dw2_expand_symtabs_matching.
2919 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2920
b5ec771e
PA
29212017-11-08 Pedro Alves <palves@redhat.com>
2922
2923 * ada-lang.c (ada_encode): Rename to ..
2924 (ada_encode_1): ... this. Add throw_errors parameter and handle
2925 it.
2926 (ada_encode): Reimplement.
2927 (match_name): Delete, folded into full_name.
2928 (resolve_subexp): No longer pass the encoded name to
2929 ada_lookup_symbol_list.
2930 (should_use_wild_match): Delete.
2931 (name_match_type_from_name): New.
2932 (ada_lookup_simple_minsym): Use lookup_name_info and the
2933 language's symbol_name_matcher_ftype.
2934 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2935 (ada_add_block_renamings): Adjust to use lookup_name_info.
2936 (ada_lookup_name): New.
2937 (add_nonlocal_symbols, ada_add_all_symbols)
2938 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2939 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2940 (ada_name_for_lookup): Delete.
2941 (ada_lookup_encoded_symbol): Construct a verbatim name.
2942 (wild_match): Reverse sense of return type. Use bool.
2943 (full_match): Reverse sense of return type. Inline bits of old
2944 match_name here.
2945 (ada_add_block_symbols): Adjust to use lookup_name_info.
2946 (symbol_completion_match): Delete, folded into...
2947 (ada_lookup_name_info::matches): ... .this new method.
2948 (symbol_completion_add): Delete.
2949 (ada_collect_symbol_completion_matches): Add name_match_type
2950 parameter. Adjust to use lookup_name_info and
2951 completion_list_add_name.
2952 (get_var_value, ada_add_global_exceptions): Adjust to use
2953 lookup_name_info.
2954 (ada_get_symbol_name_cmp): Delete.
2955 (do_wild_match, do_full_match): New functions.
2956 (ada_lookup_name_info::ada_lookup_name_info): New method.
2957 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2958 functions.
2959 (ada_language_defn): Install ada_get_symbol_name_matcher.
2960 * ada-lex.l (processId): If name starts with '<', copy it
2961 verbatim.
2962 * block.c (block_iter_match_step, block_iter_match_first)
2963 (block_iter_match_next, block_lookup_symbol)
2964 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2965 lookup_name_info.
2966 * block.h (block_iter_match_first, block_iter_match_next)
2967 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2968 * c-lang.c (c_language_defn, cplus_language_defn)
2969 (asm_language_defn, minimal_language_defn): Adjust comments to
2970 refer to la_get_symbol_name_matcher.
2971 * completer.c (complete_files_symbols)
2972 (collect_explicit_location_matches, symbol_completer): Pass a
2973 symbol_name_match_type down.
2974 * completer.h (class completion_match, completion_match_result):
2975 New classes.
2976 (completion_tracker::reset_completion_match_result): New method.
2977 (completion_tracker::m_completion_match_result): New field.
2978 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2979 lookup_name_info.
2980 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2981 functions.
2982 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2983 * d-lang.c: Adjust comments to refer to
2984 la_get_symbol_name_matcher.
2985 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2986 Adjust to use lookup_name_info.
2987 (dict_iter_match_first, dict_iter_match_next)
2988 (iter_match_first_hashed, iter_match_next_hashed)
2989 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2990 with a lookup_name_info.
2991 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2992 Likewise.
2993 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2994 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2995 (gdb_index_symbol_name_matcher): New class.
2996 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2997 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2998 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2999 with a symbol_name_match_type.
3000 (f_language_defn): Adjust comments to refer to
3001 la_get_symbol_name_matcher.
3002 * go-lang.c (go_language_defn): Adjust comments to refer to
3003 la_get_symbol_name_matcher.
3004 * language.c (default_symbol_name_matcher)
3005 (language_get_symbol_name_matcher): New functions.
3006 (unknown_language_defn, auto_language_defn): Adjust comments to
3007 refer to la_get_symbol_name_matcher.
3008 * language.h (symbol_name_cmp_ftype): Delete.
3009 (language_defn) <la_collect_symbol_completion_matches>: Add match
3010 type parameter.
3011 <la_get_symbol_name_cmp>: Delete field.
3012 <la_get_symbol_name_matcher>: New field.
3013 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
3014 (default_symbol_name_matcher, language_get_symbol_name_matcher):
3015 Declare.
3016 * linespec.c (iterate_over_all_matching_symtabs)
3017 (iterate_over_file_blocks): Adjust to use lookup_name_info.
3018 (find_methods): Add language parameter, and use lookup_name_info
3019 and the language's symbol_name_matcher_ftype.
3020 (linespec_complete_function): Adjust.
3021 (lookup_prefix_sym): Use lookup_name_info.
3022 (add_all_symbol_names_from_pspace): Adjust.
3023 (find_superclass_methods): Add language parameter and pass it
3024 down.
3025 (find_method): Pass symbol language down.
3026 (find_linespec_symbols): Don't demangle or Ada encode here.
3027 (search_minsyms_for_name): Add lookup_name_info parameter.
3028 (add_matching_symbols_to_info): Add name_match_type parameter.
3029 Use lookup_name_info.
3030 * m2-lang.c (m2_language_defn): Adjust comments to refer to
3031 la_get_symbol_name_matcher.
3032 * minsyms.c: Include <algorithm>.
3033 (add_minsym_to_demangled_hash_table): Remove table parameter and
3034 add objfile parameter. Use search_name_hash, and add language to
3035 demangled languages vector.
3036 (struct found_minimal_symbols): New struct.
3037 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
3038 New functions.
3039 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
3040 input names here. Use lookup_name_info instead. Lookup up
3041 demangled names once for each language in the demangled names
3042 vector.
3043 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
3044 demangled names once for each language in the demangled names
3045 vector.
3046 (build_minimal_symbol_hash_tables): Adjust.
3047 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
3048 lookup_name_info.
3049 * objc-lang.c (objc_language_defn): Adjust comment to refer to
3050 la_get_symbol_name_matcher.
3051 * objfiles.h: Include <vector>.
3052 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
3053 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
3054 la_get_symbol_name_matcher.
3055 * p-lang.c (pascal_language_defn): Adjust comment to refer to
3056 la_get_symbol_name_matcher.
3057 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
3058 (match_partial_symbol): Use symbol_name_match_type,
3059 lookup_name_info and psymbol_name_matches.
3060 (lookup_partial_symbol): Use lookup_name_info.
3061 (map_block): Use symbol_name_match_type and lookup_name_info.
3062 (psym_map_matching_symbols): Use symbol_name_match_type.
3063 (psymbol_name_matches): New.
3064 (recursively_search_psymtabs): Use lookup_name_info and
3065 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
3066 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
3067 'kind' parameter to 'domain'.
3068 * rust-lang.c (rust_language_defn): Adjust comment to refer to
3069 la_get_symbol_name_matcher.
3070 * symfile-debug.c (debug_qf_map_matching_symbols)
3071 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
3072 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
3073 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
3074 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
3075 Adjust to use symbol_name_match_type.
3076 <expand_symtabs_matching>: Adjust to use lookup_name_info.
3077 (expand_symtabs_matching): Adjust to use lookup_name_info.
3078 * symmisc.c (maintenance_expand_symtabs): Use
3079 lookup_name_info::match_any ().
3080 * symtab.c (symbol_matches_search_name): New.
3081 (eq_symbol_entry): Adjust to use lookup_name_info and the
3082 language's matcher.
3083 (demangle_for_lookup_info::demangle_for_lookup_info): New.
3084 (lookup_name_info::match_any): New.
3085 (iterate_over_symbols, search_symbols): Use lookup_name_info.
3086 (compare_symbol_name): Add language, lookup_name_info and
3087 completion_match_result parameters, and use them.
3088 (completion_list_add_name): Make extern. Add language and
3089 lookup_name_info parameters. Use them.
3090 (completion_list_add_symbol, completion_list_add_msymbol)
3091 (completion_list_objc_symbol): Add lookup_name_info parameters and
3092 adjust. Pass down language.
3093 (completion_list_add_fields): Add lookup_name_info parameters and
3094 adjust. Pass down language.
3095 (add_symtab_completions): Add lookup_name_info parameters and
3096 adjust.
3097 (default_collect_symbol_completion_matches_break_on): Add
3098 name_match_type parameter, and use it. Use lookup_name_info.
3099 (default_collect_symbol_completion_matches)
3100 (collect_symbol_completion_matches): Add name_match_type
3101 parameter, and pass it down.
3102 (collect_symbol_completion_matches_type): Adjust.
3103 (collect_file_symbol_completion_matches): Add name_match_type
3104 parameter, and use lookup_name_info.
3105 * symtab.h: Include <string> and "common/gdb_optional.h".
3106 (enum class symbol_name_match_type): New.
3107 (class ada_lookup_name_info): New.
3108 (struct demangle_for_lookup_info): New.
3109 (class lookup_name_info): New.
3110 (symbol_name_matcher_ftype): New.
3111 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
3112 (symbol_matches_search_name): Declare.
3113 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
3114 (default_collect_symbol_completion_matches)
3115 (collect_symbol_completion_matches)
3116 (collect_file_symbol_completion_matches): Add name_match_type
3117 parameter.
3118 (iterate_over_symbols): Use lookup_name_info.
3119 (completion_list_add_name): Declare.
3120 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
3121 (strncmp_iw_with_mode): Now extern.
3122 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
3123 (strncmp_iw_with_mode): Declare.
3124
5ffa0793
PA
31252017-11-08 Keith Seitz <keiths@redhat.com>
3126 Pedro Alves <palves@redhat.com>
3127
3128 * ada-lang.c (ada_language_defn): Install
3129 default_search_name_hash.
3130 * buildsym.c (struct buildsym_compunit): <language>: New field.
3131 (finish_block_internal): Pass language when creating dictionaries.
3132 (start_buildsym_compunit, start_symtab): New language parameters.
3133 Use them.
3134 (restart_symtab): Pass down compilation unit's language.
3135 * buildsym.h (enum language): Forward declare.
3136 (start_symtab): New 'language' parameter.
3137 * c-lang.c (c_language_defn, cplus_language_defn)
3138 (asm_language_defn, minimal_language_defn): Install
3139 default_search_name_hash.
3140 * coffread.c (coff_start_symtab): Adjust.
3141 * d-lang.c (d_language_defn): Install default_search_name_hash.
3142 * dbxread.c (struct symloc): Add 'pst_language' field.
3143 (PST_LANGUAGE): Define.
3144 (start_psymtab, read_ofile_symtab): Use it.
3145 (process_one_symbol): New 'language' parameter. Pass it down.
3146 * dictionary.c (struct dictionary) <language>: New field.
3147 (DICT_LANGUAGE): Define.
3148 (dict_create_hashed, dict_create_hashed_expandable)
3149 (dict_create_linear, dict_create_linear_expandable): New parameter
3150 'language'. Set the dictionary's language.
3151 (iter_match_first_hashed): Adjust to rename.
3152 (insert_symbol_hashed): Assert we don't see mismatching
3153 languages. Adjust to rename.
3154 (dict_hash): Rename to ...
3155 (default_search_name_hash): ... this and make extern.
3156 * dictionary.h (struct language_defn): Forward declare.
3157 (dict_create_hashed): New parameter 'language'.
3158 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
3159 * f-lang.c (f_language_defn): Install default_search_name_hash.
3160 * go-lang.c (go_language_defn): Install default_search_name_hash.
3161 * jit.c (finalize_symtab): Pass compunit's language to dictionary
3162 creation.
3163 * language.c (unknown_language_defn, auto_language_defn):
3164 * language.h (language_defn::la_search_name_hash): New field.
3165 (default_search_name_hash): Declare.
3166 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
3167 * mdebugread.c (new_block): New parameter 'language'.
3168 * mdebugread.c (parse_symbol): Pass symbol language to block
3169 allocation.
3170 (psymtab_to_symtab_1): Pass down language.
3171 (new_symtab): Pass compunit's language to block allocation.
3172 * objc-lang.c (objc_language_defn): Install
3173 default_search_name_hash.
3174 * opencl-lang.c (opencl_language_defn):
3175 * p-lang.c (pascal_language_defn): Install
3176 default_search_name_hash.
3177 * rust-lang.c (rust_language_defn): Install
3178 default_search_name_hash.
3179 * stabsread.h (enum language): Forward declare.
3180 (process_one_symbol): Add 'language' parameter.
3181 * symtab.c (search_name_hash): New function.
3182 * symtab.h (search_name_hash): Declare.
3183 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
3184
2a1dde5d
PA
31852017-11-08 Pedro Alves <palves@redhat.com>
3186
3187 * cp-name-parser.y (main): Don't initialize extra_chars.
3188
95a6b0a1
TT
31892017-11-07 Tom Tromey <tom@tromey.com>
3190
3191 * event-top.h (command_handler): Constify.
3192 * record-full.c (cmd_record_full_start): Update.
3193 * thread.c (thread_apply_all_command): Update.
3194 * printcmd.c (eval_command): Update.
3195 * mi/mi-main.c (mi_execute_cli_command): Update.
3196 (mi_execute_async_cli_command): Update.
3197 * tui/tui-stack.c (tui_update_command): Update.
3198 * cli/cli-interp.c (safe_execute_command): Constify.
3199 * record.c (record_start): Update.
3200 (record_start, record_stop, cmd_record_start): Update.
3201 * record-btrace.c (cmd_record_btrace_bts_start): Update.
3202 (cmd_record_btrace_pt_start): Update.
3203 (cmd_record_btrace_start): Update.
3204 (cmd_record_btrace_start): Update.
3205 * reverse.c (exec_reverse_once): Update.
3206 * python/python.c (execute_gdb_command): Don't copy the command.
3207 * event-top.c (command_line_handler): Update.
3208 (command_handler): Constify.
3209 * defs.h (deprecated_call_command_hook): Constify.
3210 * cli/cli-script.h (execute_user_command): Constify.
3211 * cli/cli-script.c (execute_user_command): Constify.
3212 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
3213 (enum command_control_type): Update.
3214 * main.c (catch_command_errors): Remove non-const overload.
3215 (catch_command_errors_ftype): Remove.
3216 * python/py-cmd.c (cmdpy_function): Constify.
3217 * guile/scm-cmd.c (cmdscm_function): Constify.
3218 * cli/cli-dump.c (call_dump_func): Constify.
3219 * cli/cli-decode.c (do_const_cfunc): Constify.
3220 (do_sfunc): Constify.
3221 (cmd_func): Constify.
3222 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
3223 * top.h (execute_command): Constify.
3224 * top.c (execute_command): Constify.
3225 (execute_command_to_string): Constify.
3226 (deprecated_call_command_hook): Constify.
3227 * command.h (cmd_func): Constify.
3228 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
3229
eb4c3f4a
TT
32302017-11-07 Tom Tromey <tom@tromey.com>
3231
3232 * ada-lang.c (catch_ada_exception_command): Constify.
3233 (catch_assert_command): Constify.
3234 * break-catch-throw.c (catch_catch_command, catch_throw_command)
3235 (catch_rethrow_command): Constify.
3236 (catch_exception_command_1): Constify.
3237 * breakpoint.h (add_catch_command): Constify.
3238 * break-catch-syscall.c (catch_syscall_command_1): Constify.
3239 (catch_syscall_split_args): Constify.
3240 * break-catch-sig.c (catch_signal_command): Constify.
3241 (catch_signal_split_args): Constify.
3242 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
3243 cmd_const_sfunc_ftype.
3244 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
3245 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3246 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3247 (add_setshow_string_cmd, struct cmd_list_element)
3248 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3249 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3250 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
3251 Constify.
3252 (set_cmd_sfunc): Constify.
3253 (empty_sfunc): Constify.
3254 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
3255 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
3256 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
3257 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
3258 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
3259 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
3260 Constify.
3261 (set_cmd_sfunc): Constify.
3262 (cmd_sfunc_ftype): Remove.
3263 * compile/compile.c (set_compile_args): Constify.
3264 * infrun.c (set_disable_randomization): Constify.
3265 * infcmd.c (set_args_command, set_cwd_command): Constify.
3266 * breakpoint.c (set_condition_evaluation_mode): Constify.
3267 (add_catch_command): Constify.
3268 (catch_fork_command_1, catch_exec_command_1)
3269 (catch_load_command_1, catch_unload_command_1): Constify.
3270 (catch_load_or_unload): Constify.
3271 * guile/scm-param.c (pascm_set_func): Constify.
3272 (add_setshow_generic): Constify.
3273 * python/py-param.c (get_set_value): Constify.
3274 * top.h (set_verbose): Constify.
3275 * tui/tui-win.c (tui_set_var_cmd): Constify.
3276 * mi/mi-main.c (set_mi_async_command): Constify.
3277 * cli/cli-logging.c (set_logging_overwrite)
3278 (set_logging_redirect): Constify.
3279 * value.c (set_max_value_size): Constify.
3280 * valprint.c (set_input_radix, set_output_radix): Constify.
3281 * utils.c (set_width_command, set_height_command): Constify.
3282 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
3283 * tracepoint.c (set_disconnected_tracing)
3284 (set_circular_trace_buffer, set_trace_buffer_size)
3285 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
3286 * top.c (set_history_size_command, set_verbose, set_editing)
3287 (set_gdb_datadir, set_history_filename): Constify.
3288 * target.c (set_targetdebug, maint_set_target_async_command)
3289 (maint_set_target_non_stop_command, set_target_permissions)
3290 (set_write_memory_permission): Constify.
3291 (open_target): Constify.
3292 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
3293 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
3294 * symtab.c (set_symbol_cache_size_handler): Constify.
3295 * symfile.c (set_ext_lang_command): Constify.
3296 * symfile-debug.c (set_debug_symfile): Constify.
3297 * source.c (set_directories_command): Constify.
3298 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
3299 * serial.c (set_parity): Constify.
3300 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
3301 * remote.c (set_remote_exec_file, set_remotebreak)
3302 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
3303 * record.c (set_record_insn_history_size)
3304 (set_record_call_history_size): Constify.
3305 * record-full.c (set_record_full_insn_max_num): Constify.
3306 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
3307 * osabi.c (set_osabi): Constify.
3308 * mips-tdep.c (set_mips64_transfers_32bit_regs)
3309 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
3310 * maint.c (maintenance_set_profile_cmd): Constify.
3311 * linux-thread-db.c (set_libthread_db_search_path): Constify.
3312 * language.c (set_language_command, set_range_command)
3313 (set_case_command): Constify.
3314 * infrun.c (set_non_stop, set_observer_mode)
3315 (set_stop_on_solib_events, set_schedlock_func)
3316 (set_exec_direction_func): Constify.
3317 * infcmd.c (set_inferior_tty_command): Constify.
3318 * disasm.c (set_disassembler_options_sfunc): Constify.
3319 * demangle.c (set_demangling_command): Constify.
3320 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
3321 * cris-tdep.c (set_cris_version, set_cris_mode)
3322 (set_cris_dwarf2_cfi): Constify.
3323 * corefile.c (set_gnutarget_command): Constify.
3324 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
3325 (set_target_wide_charset_sfunc): Constify.
3326 * breakpoint.c (update_dprintf_commands): Constify.
3327 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
3328 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
3329 (set_disassembly_style_sfunc): Constify.
3330 * arch-utils.c (set_endian, set_architecture): Constify.
3331 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
3332 * agent.c (set_can_use_agent): Constify.
3333
5fed81ff
TT
33342017-11-07 Tom Tromey <tom@tromey.com>
3335
3336 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
3337 (go32_pde, go32_pte, go32_pte_for_address): Constify.
3338 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
3339 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
3340 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
3341 (parse_int_arg, show_thread_default_detach_sc_cmd)
3342 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
3343 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
3344 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
3345 (show_task_pause_cmd, set_task_detach_sc_cmd)
3346 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
3347 (set_noninvasive_cmd, set_thread_pause_cmd)
3348 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
3349 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
3350 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
3351 * windows-nat.c (display_selectors): Constify.
3352 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
3353 non-const "cfunc".
3354 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
3355 (cmd_cfunc_eq): Likewise.
3356 (struct cmd_list_element): Likewise.
3357 (do_cfunc): Remove.
3358 (cli_user_command_p): Update.
3359 * command.h (add_cmd): Remove non-const overload.
3360 (cmd_cfunc_ftype): Remove typedef.
3361 (cmd_cfunc_eq): Remove non-const overload.
3362 * value.c (show_values): Constify.
3363 * thread.c (thread_apply_all_command): Constify.
3364 * symfile.c (load_command): Constify.
3365 * source.c (directory_command): Constify.
3366 * maint.c (maintenance_internal_error)
3367 (maintenance_demangler_warning, maintenance_space_display)
3368 (maintenance_print_architecture, maintenance_translate_address)
3369 (maintenance_info_selftests, maintenance_internal_warning):
3370 Constify.
3371 * breakpoint.c (disable_trace_command, enable_trace_command):
3372 Constify.
3373 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
3374 Constify.
3375 (add_auto_load_safe_path): Constify.
3376 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
3377 * top.h (show_commands): Constify.
3378 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
3379 * sparc64-tdep.c (adi_examine_command): Constify.
3380 (adi_assign_command): Constify.
3381
1d12d88f
TT
33822017-11-07 Tom Tromey <tom@tromey.com>
3383
3384 * frame.h (info_locals_command, info_args_command): Constify.
3385 * auto-load.h (auto_load_info_scripts): Constify.
3386 * inferior.h (registers_info): Constify.
3387 * copying.c: Rebuild.
3388 * copying.awk: Constify generated commands.
3389 * auto-load.c (auto_load_info_scripts)
3390 (info_auto_load_gdb_scripts): Constify.
3391 * cli/cli-decode.c (struct cmd_list_element): Take a
3392 cmd_const_cfunc_ftype.
3393 * command.h (add_info): Take a cmd_const_cfunc_ftype.
3394 * tui/tui-win.c (tui_all_windows_info): Constify.
3395 * python/py-auto-load.c (info_auto_load_python_scripts):
3396 Constify.
3397 * cli/cli-cmds.c (show_command): Remove non-const overload.
3398 * tracepoint.c (info_tvariables_command, info_scope_command):
3399 Constify.
3400 (info_static_tracepoint_markers_command): Constify.
3401 * thread.c (info_threads_command): Constify.
3402 (print_thread_info_1): Constify.
3403 * target.c (info_target_command): Constify.
3404 * symtab.c (info_sources_command, info_functions_command)
3405 (info_types_command): Constify.
3406 (info_variables_command): Remove non-const overload.
3407 * symfile.c (info_ext_lang_command): Constify.
3408 * stack.c (info_frame_command, info_locals_command)
3409 (info_args_command): Constify.
3410 (backtrace_command): Remove non-const overload.
3411 * source.c (info_source_command, info_line_command): Constify.
3412 * solib.c (info_sharedlibrary_command): Constify.
3413 * skip.c (info_skip_command): Constify.
3414 * ser-go32.c (info_serial_command): Constify.
3415 * reverse.c (info_bookmarks_command): Constify.
3416 * printcmd.c (info_symbol_command, info_address_command)
3417 (info_display_command): Constify.
3418 * osdata.c (info_osdata_command): Constify.
3419 * objc-lang.c (info_selectors_command, info_classes_command):
3420 Constify.
3421 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
3422 * memattr.c (info_mem_command): Constify.
3423 * macrocmd.c (info_macro_command, info_macros_command): Constify.
3424 * linux-fork.c (info_checkpoints_command): Constify.
3425 * infrun.c (info_signals_command): Constify.
3426 * inflow.c (info_terminal_command): Constify.
3427 * inferior.c (info_inferiors_command): Constify.
3428 (print_inferior): Constify.
3429 * infcmd.c (info_program_command, info_all_registers_command)
3430 (info_registers_command, info_vector_command)
3431 (info_float_command): Constify.
3432 (registers_info): Constify.
3433 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
3434 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
3435 Constify.
3436 * f-valprint.c (info_common_command): Constify.
3437 * dcache.c (info_dcache_command): Constify.
3438 (dcache_info_1): Constify.
3439 * darwin-nat-info.c (info_mach_tasks_command)
3440 (info_mach_task_command, info_mach_ports_command)
3441 (info_mach_port_command, info_mach_threads_command)
3442 (info_mach_thread_command, info_mach_regions_command)
3443 (info_mach_regions_recurse_command, info_mach_region_command)
3444 (info_mach_exceptions_command): Constify.
3445 (get_task_from_args): Constify.
3446 * cp-support.c (info_vtbl_command): Constify.
3447 * breakpoint.c (info_watchpoints_command)
3448 (info_tracepoints_command): Constify.
3449 (info_breakpoints_command): Remove non-const overload.
3450 * avr-tdep.c (avr_io_reg_read_command): Constify.
3451 * auxv.c (info_auxv_command): Constify.
3452 * ada-tasks.c (info_tasks_command): Constify.
3453 (info_task): Constify.
3454 * ada-lang.c (info_exceptions_command): Constify.
3455
0b39b52e
TT
34562017-11-07 Tom Tromey <tom@tromey.com>
3457
3458 * solib.h (no_shared_libraries): Constify.
3459 * frame.h (return_command): Constify.
3460 * cli/cli-cmds.h (quit_command): Constify.
3461 * top.h (quit_command, execute_command): Constify.
3462 * target.h (flash_erase_command): Constify.
3463 * inferior.h (set_inferior_args, attach_command): Constify.
3464 * tracepoint.h (start_tracing, stop_tracing): Constify.
3465 * breakpoint.h (break_command, tbreak_command)
3466 (hbreak_command_wrapper, thbreak_command_wrapper)
3467 (rbreak_command_wrapper, watch_command_wrapper)
3468 (awatch_command_wrapper, rwatch_command_wrapper)
3469 (get_tracepoint_by_number): Constify.
3470 * symtab.c (info_variables_command, rbreak_command)
3471 (symtab_symbol_info): Constify.
3472 (info_variables_command): Add non-const overload.
3473 * top.c (dont_repeat_command): Constify.
3474 * breakpoint.c (ignore_command, commands_command)
3475 (condition_command, tbreak_command, hbreak_command)
3476 (thbreak_command, clear_command, break_command)
3477 (info_breakpoints_command, watch_command, rwatch_command)
3478 (awatch_command, trace_command, ftrace_command, strace_command)
3479 (trace_pass_command, break_range_command, dprintf_command)
3480 (agent_printf_command, get_tracepoint_by_number)
3481 (watch_maybe_just_location, trace_pass_command): Constify.
3482 (info_breakpoints_command): Add non-const overload.
3483 * tracefile.c (tsave_command): Constify.
3484 * infcmd.c (attach_command, disconnect_command, signal_command)
3485 (queue_signal_command, stepi_command, nexti_command)
3486 (finish_command, next_command, step_command, until_command)
3487 (advance_command, jump_command, continue_command, run_command)
3488 (start_command, starti_command, interrupt_command)
3489 (run_command_1, set_inferior_args, step_1): Constify.
3490 * inferior.c (add_inferior_command, remove_inferior_command)
3491 (clone_inferior_command): Constify.
3492 * linux-fork.c (checkpoint_command, restart_command): Constify.
3493 * windows-nat.c (signal_event_command): Constify.
3494 * guile/guile.c (guile_repl_command, guile_command): Constify.
3495 * printcmd.c (x_command, display_command, printf_command)
3496 (output_command, set_command, call_command, print_command)
3497 (eval_command): Constify.
3498 (non_const_set_command): Remove.
3499 (_initialize_printcmd): Update.
3500 * source.c (forward_search_command, reverse_search_command):
3501 Constify.
3502 * jit.c (jit_reader_load_command, jit_reader_unload_command):
3503 Constify.
3504 * infrun.c (handle_command): Constify.
3505 * memattr.c (mem_command): Constify.
3506 * stack.c (return_command, up_command, up_silently_command)
3507 (down_command, down_silently_command, frame_command)
3508 (backtrace_command, func_command, backtrace_command_1): Constify.
3509 (backtrace_command): Add non-const overload.
3510 * remote-sim.c (simulator_command): Constify.
3511 * exec.c (set_section_command): Constify.
3512 * tracepoint.c (tdump_command, trace_variable_command)
3513 (tstatus_command, tstop_command, tstart_command)
3514 (end_actions_pseudocommand, while_stepping_pseudocommand)
3515 (collect_pseudocommand, teval_pseudocommand, actions_command)
3516 (start_tracing, stop_tracing): Constify.
3517 * value.c (init_if_undefined_command): Constify.
3518 * tui/tui-stack.c (tui_update_command): Constify.
3519 * tui/tui-win.c (tui_refresh_all_command)
3520 (tui_set_tab_width_command, tui_set_win_height_command)
3521 (tui_set_focus_command, tui_scroll_forward_command)
3522 (tui_scroll_backward_command, tui_scroll_left_command)
3523 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
3524 (tui_set_win_height): Constify.
3525 * tui/tui-layout.c (tui_layout_command): Constify.
3526 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
3527 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
3528 (proc_untrace_sysexit_cmd): Constify.
3529 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
3530 (threadset_test_cmd, threadlist_update_test_cmd)
3531 (threadalive_test): Constify.
3532 * objc-lang.c (print_object_command): Constify.
3533 * command.h (add_com): Constify.
3534 * cli/cli-dump.c (restore_command): Constify.
3535 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
3536 (help_command, complete_command, shell_command, edit_command)
3537 (list_command, disassemble_command, make_command)
3538 (apropos_command, alias_command): Constify.
3539 * cli/cli-script.c (document_command, define_command)
3540 (while_command, if_command, validate_comname): Constify.
3541 * cli/cli-decode.c (struct cmd_list_element): Change type of
3542 "fun".
3543 * target.c (do_monitor_command, flash_erase_command): Constify.
3544 * regcache.c (reg_flush_command): Constify.
3545 * reverse.c (reverse_step, reverse_next, reverse_stepi)
3546 (reverse_nexti, reverse_continue, reverse_finish)
3547 (save_bookmark_command, goto_bookmark_command)
3548 (exec_reverse_once): Constify.
3549 * python/python.c (python_interactive_command, python_command):
3550 Constify.
3551 * typeprint.c (ptype_command, whatis_command, whatis_exp):
3552 Constify.
3553 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
3554 * gcore.c (gcore_command): Constify.
3555
85c4be7c
TT
35562017-11-07 Tom Tromey <tom@tromey.com>
3557
3558 * printcmd.c (x_command): Call set_repeat_arguments.
3559 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
3560 * top.c (repeat_arguments): New global.
3561 (set_repeat_arguments): New function.
3562 (execute_command): Handle repeat_arguments.
3563 (show_commands): Calls set_repeat_arguments.
3564 * command.h (set_repeat_arguments): Declare.
3565
022643b4
TT
35662017-11-07 Tom Tromey <tom@tromey.com>
3567
3568 * stack.c (backtrace_command): Use std::string.
3569 (backtrace_command_1): Make "count_exp" const.
3570
5614fb77
TT
35712017-11-07 Tom Tromey <tom@tromey.com>
3572
3573 * source.c (directory_switch, mod_path, add_path): Constify.
3574 * defs.h (add_path, mod_path, directory_switch): Constify.
3575 * mi/mi-cmd-env.c (env_mod_path): Constify.
3576
6be9a197
TT
35772017-11-07 Tom Tromey <tom@tromey.com>
3578
3579 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
3580 (run_command_1, continue_command, step_1, jump_command)
3581 (signal_command, until_command, advance_command, finish_command)
3582 (attach_command): Update.
3583
c2252c0d
TT
35842017-11-07 Tom Tromey <tom@tromey.com>
3585
3586 * command.h (set_cmd_cfunc): Don't declare.
3587 * cli/cli-decode.c (set_cmd_cfunc): Now static.
3588
1ee870c5
TT
35892017-11-07 Tom Tromey <tom@tromey.com>
3590
3591 * stack.c (select_frame_command): Constify.
3592 * cli/cli-decode.c (add_com_suppress_notification): Constify.
3593 * command.h (add_com_suppress_notification): Constify.
3594
ee7ddd71
TT
35952017-11-07 Tom Tromey <tom@tromey.com>
3596
3597 * breakpoint.c (stop_command): Constify.
3598 * cli/cli-decode.c (struct cmd_list_element): Constify.
3599 * command.h (add_abbrev_prefix_cmd): Constify.
3600
95e95a6d
PA
36012017-11-07 Pedro Alves <palves@redhat.com>
3602
3603 * breakpoint.c (extract_bp_kind): New enum.
3604 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
3605 factored out from ...
3606 (extract_bp_number_and_location): ... here.
3607 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
3608
cc638e86
PA
36092017-11-07 Pedro Alves <palves@redhat.com>
3610
3611 * breakpoint.c (extract_bp_number_and_location): Change return
3612 type to void. Throw error instead of warning.
3613 (enable_disable_command): Adjust.
3614
d0fe4701
XR
36152017-11-07 Xavier Roirand <roirand@adacore.com>
3616 Pedro Alves <palves@redhat.com>
3617
3618 * breakpoint.c (map_breakpoint_number_range): New, factored out
3619 from ...
3620 (map_breakpoint_numbers): ... here.
3621 (find_location_by_number): Change parameters from string to
3622 breakpoint number and location.
3623 (extract_bp_number_and_location): New function.
3624 (enable_disable_bp_num_loc)
3625 (enable_disable_breakpoint_location_range)
3626 (enable_disable_command): New functions, factored out ...
3627 (enable_command, disable_command): ... these functions, and
3628 adjusted to support ranges.
3629 * NEWS: Document enable/disable breakpoint location range feature.
3630
635dc5b2
LM
36312017-11-06 Luis Machado <luis.machado@linaro.org>
3632
3633 * MAINTAINERS (Write After Approval): Update my e-mail address.
3634
556e5da5
PA
36352017-11-06 Pedro Alves <palves@redhat.com>
3636
3637 * gnu-nat.c (gnu_terminal_init): Delete.
3638 (gnu_target): Don't install gnu_terminal_init.
3639 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
3640 (child_terminal_init): ... this function.
3641
d1928160
PA
36422017-11-06 Pedro Alves <palves@redhat.com>
3643
3644 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
3645 sgtty.h.
3646 * config.in, configure: Regenerate.
3647
6aa899ce
PA
36482017-11-06 Pedro Alves <palves@redhat.com>
3649
3650 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
3651 (async_init_signals): Adjust.
3652 (handle_stop_sig): Rename to ...
3653 (handle_sigtstp): ... this.
3654 (async_stop_sig): Rename to ...
3655 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3656 SIGTSTP path.
3657 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3658 instead of STOP_SIGNAL thoughout.
3659 (handle_stop_sig): Rename to ...
3660 (handle_sigtstp): ... this.
3661 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3662
a94799ac
PA
36632017-11-06 Pedro Alves <palves@redhat.com>
3664
3665 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3666 longer set flags twice in row.
3667
726e1356
PA
36682017-11-06 Pedro Alves <palves@redhat.com>
3669
3670 * Makefile.in (SER_HARDWIRE): Update comment.
3671 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3672 * common/gdb_termios.h: Delete file.
3673 * common/job-control.c: Include termios.h and unistd.h instead of
3674 gdb_termios.h.
3675 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3676 check.
3677 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3678 Remove sgtty code.
3679 * configure.ac: No longer check for termio.h and sgtty.h.
3680 * configure: Regenerate.
3681 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3682 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3683 Replace PROCESS_GROUP_TYPE references with pid_t references
3684 throughout.
3685 (gdb_getpgrp): Delete.
3686 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3687 (child_terminal_inferior): Remove comment. Remove sgtty code.
3688 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3689 gdb_getpgrp. Use serial_set_tty_state instead aof
3690 serial_noflush_set_tty_state. Remove sgtty code.
3691 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3692 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3693 (inferior_process_group): Now returns pid_t.
3694 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3695 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3696 * ser-event.c (serial_event_ops): Update.
3697 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3698 (dos_ops): Update.
3699 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3700 * ser-pipe.c (pipe_ops): Update.
3701 * ser-tcp.c (tcp_ops): Update.
3702 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3703 HAVE_TERMIOS checks.
3704 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3705 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3706 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3707 assume termios.
3708 (hardwire_noflush_set_tty_state): Delete.
3709 (hardwire_print_tty_state, hardwire_drain_output)
3710 (hardwire_flush_output, hardwire_flush_input)
3711 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3712 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3713 code, and assume termios.
3714 (hardwire_ops): Update.
3715 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3716 * serial.c (serial_noflush_set_tty_state): Delete.
3717 * serial.h (serial_noflush_set_tty_state): Delete.
3718 (serial_ops::noflush_set_tty_state): Delete.
3719
1cfb73db
UW
37202017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3721
3722 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3723 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3724 (COMMON_OBS): Remove doublest.o and dfp.o.
3725 Do not build target-float.c (instead of doublest.c)
3726 with -Wformat-nonliteral.
3727
3728 * doublest.c: Remove file.
3729 * doublest.h: Remove file.
3730 * dfp.c: Remove file.
3731 * dfp.h: Remove file.
3732
3733 * target-float.c: Do not include "doublest.h" and "dfp.h".
3734 (DOUBLEST): Move here from doublest.h.
3735 (enum float_kind): Likewise.
3736 (FLOATFORMAT_CHAR_BIT): Likewise.
3737 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3738 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3739 (floatformat_precision): Likewise.
3740 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3741 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3742 Likewise.
3743 (host_float_format, host_double_format, host_long_double_format):
3744 Likewise.
3745 (floatformat_to_string, floatformat_from_string): Likewise.
3746 (floatformat_to_doublest): Likewise. Also, inline the original
3747 convert_floatformat_to_doublest.
3748 (floatformat_from_doublest): Likewise. Also, inline the original
3749 convert_floatformat_from_doublest.
3750
3751 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3752 (MAX_DECIMAL_STRING): Move here from dfp.c.
3753 (match_endianness): Likewise.
3754 (set_decnumber_context, decimal_check_errors): Likewise.
3755 (decimal_from_number, decimal_to_number): Likewise.
3756 (decimal_to_string, decimal_from_string): Likewise. Make static.
3757 (decimal_from_longest, decimal_from_ulongest): Likewise.
3758 (decimal_to_longest): Likewise.
3759 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3760 (decimal_convert): Likewise.
3761
b07e9c46
UW
37622017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3763
3764 * doublest.c: Do not include "gdbtypes.h".
3765 (extract_typed_floating): Remove.
3766 (store_typed_floating): Remove.
3767 (convert_typed_floating): Remove.
3768 * doublest.h (struct type): Remove.
3769 (DOUBLEST_PRINT_FORMAT): Remove.
3770 (DOUBLEST_SCAN_FORMAT): Remove.
3771 (extract_typed_floating): Remove.
3772 (store_typed_floating): Remove.
3773 (convert_typed_floating): Remove.
3774
3775 * dfp.c (decimal_from_doublest): Remove.
3776 (decimal_to_doublest): Remove.
3777 * dfp.h: Do not include "doublest.h".
3778 (decimal_from_doublest): Remove.
3779 (decimal_to_doublest): Remove.
3780
3781 * value.c: Do not include "doublest.h" and "dfp.h".
3782 (value_as_double): Remove.
3783 (unpack_double): Remove.
3784 (value_from_double): Remove.
3785 (value_from_decfloat): Remove.
3786 * value.h: Do not include "doublest.h".
3787 (value_as_double): Remove.
3788 (unpack_double): Remove.
3789 (value_from_double): Remove.
3790 (value_from_decfloat): Remove.
3791
3b2ca824
UW
37922017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3793
3794 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3795 (i386_extract_return_value): Use target_float_convert.
3796 (i386_store_return_value): Likewise.
3797 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3798 (i387_value_to_register): Likewise.
3799 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3800 (ia64_register_to_value): Use target_float_convert.
3801 (ia64_value_to_register): Likewise.
3802 (ia64_extract_return_value): Likewise.
3803 (ia64_store_return_value): Likewise.
3804 (ia64_push_dummy_call): Likewise.
3805 * m68k-tdep.c: Include "target-float.h".
3806 (m68k_register_to_value): Use target_float_convert.
3807 (m68k_value_to_register): Likewise.
3808 (m68k_svr4_extract_return_value): Likewise.
3809 (m68k_svr4_store_return_value): Likewise.
3810 * ppc-sysv-tdep.c: Include "target-float.h".
3811 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3812 (do_ppc_sysv_return_value): Likewise.
3813 (ppc64_sysv_abi_push_freg): Likewise.
3814 (ppc64_sysv_abi_return_value_base): Likewise.
3815 * rs6000-aix-tdep.c: Include "target-float.h".
3816 (rs6000_push_dummy_call): Use target_float_convert.
3817 (rs6000_return_value): Likewise.
3818 * rs6000-lynx178-tdep.c: Include "target-float.h".
3819 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3820 (rs6000_lynx178_return_value): Likewise.
3821 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3822 (rs6000_register_to_value): Use target_float_convert.
3823 (rs6000_value_to_register): Likewise.
3824 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3825 (arm_extract_return_value): Use target_float_convert.
3826 (arm_store_return_value): Likewise.
3827 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3828 (sh_register_convert_to_virtual): Use target_float_convert.
3829 (sh_register_convert_to_raw): Likewise.
3830 * sh64-tdep.c: Include "target-float.h".
3831 (sh64_extract_return_value): Use target_float_convert.
3832 (sh64_register_convert_to_virtual): Likewise.
3833 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3834
14ad9311
UW
38352017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3836
3837 * target-float.c (floatformat_to_host_double): New function.
3838 (floatformat_from_host_double): Likewise.
3839 (target_float_to_host_double): Likewise.
3840 (target_float_from_host_double): Likewise.
3841 * target-float.h (target_float_to_host_double): Add prototype.
3842 (target_float_from_host_double): Likewise.
3843
3844 * guile/scm-value.c: Include "target-float.h".
3845 (gdbscm_value_to_real): Use target_float_to_host_double.
3846 Handle integer source values via value_as_long.
3847 * guile/scm-math.c: Include "target-float.h". Do not include
3848 "doublest.h", "dfp.h", and "expression.h".
3849 (vlscm_convert_typed_number): Use target_float_from_host_double.
3850 (vlscm_convert_number): Likewise.
3851
3852 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3853 (convert_value_from_python): Use target_float_from_host_double.
3854
50eff16b
UW
38552017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3856
3857 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3858 (cast_from_fixed): Likewise.
3859 (ada_scaling_type): New function.
3860 (ada_delta): Return value instead of DOUBLEST. Perform target
3861 arithmetic instead of host arithmetic.
3862 (scaling_factor): Rename to ...
3863 (ada_scaling_factor) ... this. Make non-static. Return value instead
3864 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3865 (ada_fixed_to_float): Remove.
3866 (ada_float_to_fixed): Remove.
3867 * ada-lang.h (ada_fixed_to_float): Remove.
3868 (ada_float_to_fixed): Remove.
3869 (ada_delta): Return value instead of DOUBLEST.
3870 (ada_scaling_factor): Add prototype.
3871
3872 * ada-typeprint.c: Include "target-float.h".
3873 (print_fixed_point_type): Perform target arithmetic instead of
3874 host arithmetic.
3875 * ada-valprint.c: Include "target-float.h".
3876 (ada_val_print_num): Perform target arithmetic instead of
3877 host arithmetic for fixed-point types.
3878
66c02b9e
UW
38792017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3880
3881 * target-float.c: Include <math.h>.
3882 (floatformat_binop): New function.
3883 (floatformat_compare): Likewise.
3884 (target_float_binop): Likewise.
3885 (target_float_compare): Likewise.
3886 * target-float.h: Include "expression.h".
3887 (target_float_binop): Add prototype.
3888 (target_float_compare): Likewise.
3889
3890 * valarith.c: Do not include "doublest.h" and "dfp.h".
3891 Include "common/byte-vector.h".
3892 (value_args_as_decimal): Remove, replace by ...
3893 (value_args_as_target_float): ... this function. Handle both
3894 binary and decimal target floating-point formats.
3895 (scalar_binop): Handle both binary and decimal FP using
3896 value_args_as_target_float and target_float_binop.
3897 (value_equal): Handle both binary and decimal FP using
3898 value_args_as_target_float and target_float_compare.
3899 (value_less): Likewise.
3900 (value_pos): Handle all scalar types as simple copy.
3901 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3902 * dfp.c (decimal_binop): Throw error instead of internal_error
3903 when called with an unsupported operation code.
3904
f69fdf9b
UW
39052017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3906
3907 * target-float.c (target_float_to_string): New function.
3908 (target_float_from_string): New function.
3909 * target-float.h (target_float_to_string): Add prototype.
3910 (target_float_from_string): Add prototype.
3911
3912 * valprint.c: Include "target-float.h". Do not include
3913 "doublest.h" and "dfp.h".
3914 (print_floating): Use target_float_to_string.
3915 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3916 (printf_floating): Use target_float_to_string.
3917 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3918 (print_i387_value): Use target_float_to_string.
3919 * mips-tdep.c: Include "target-float.h".
3920 (mips_print_fp_register): Use target_float_to_string.
3921 * sh64-tdep.c: Include "target-float.h".
3922 (sh64_do_fp_register): Use target_float_to_string.
3923
3924 * parse.c: Include "target-float.h". Do not include
3925 "doublest.h" and "dfp.h".
3926 (parse_float): Use target_float_from_string.
3927 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3928 (define_symbol): Use target_float_from_string.
3929 * gdbarch-selftests.c: Include "target-float.h".
3930 (register_to_value_test): Use target_float_from_string.
3931
70100014
UW
39322017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3933
3934 * Makefile.c (SFILES): Add target-float.c.
3935 (HFILES_NO_SRCDIR): Add target-float.h.
3936 (COMMON_OBS): Add target-float.o.
3937 * target-float.h: New file.
3938 * target-float.c: New file.
3939
3940 * doublest.c (floatformat_classify): Fix detection of float_zero.
3941
3942 * gdbtypes.c (is_floating_type): New function.
3943 * gdbtypes.h (is_floating_type): Add prototype.
3944
3945 * value.c: Do not include "floatformat.h".
3946 (unpack_double): Use target_float_is_valid.
3947 (is_floating_value): New function.
3948 * value.h (is_floating_value): Add prototype-
3949
3950 * valarith.c: Include "target-float.h".
3951 (value_logical_not): Use target_float_is_zero.
3952
3953 * python/py-value.c: Include "target-float.h".
3954 (valpy_nonzero): Use target_float_is_zero.
3955
ab4b1c46
TT
39562017-11-04 Tom Tromey <tom@tromey.com>
3957
3958 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3959
454dafbd
TT
39602017-11-04 Tom Tromey <tom@tromey.com>
3961
3962 * breakpoint.c (set_momentary_breakpoint): Return
3963 breakpoint_up.
3964 (until_break_command): Update.
3965 (new_until_break_fsm): Change argument types to
3966 breakpoint_up.
3967 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3968 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3969 Remove.
3970 * infcmd.c (finish_forward): Update.
3971 * breakpoint.h (set_momentary_breakpoint)
3972 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3973 (make_cleanup_delete_breakpoint): Remove.
3974 (struct breakpoint_deleter): New.
3975 (breakpoint_up): New typedef.
3976 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3977 (insert_exception_resume_breakpoint): Update.
3978 (insert_exception_resume_from_probe): Update.
3979 (insert_longjmp_resume_breakpoint): Update.
3980 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3981 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3982 * infcall.c (call_function_by_hand_dummy): Update
3983
331b71e5
TT
39842017-11-04 Tom Tromey <tom@tromey.com>
3985
3986 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3987
9f584b37
TT
39882017-11-04 Tom Tromey <tom@tromey.com>
3989
3990 * linux-tdep.c (linux_core_info_proc_mappings): Use
3991 gdb::def_vector.
3992 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3993 "size" argument.
3994 (linux_corefile_thread): Update.
3995 (linux_make_corefile_notes): Remove unused variable.
3996
779bc38e
TT
39972017-11-04 Tom Tromey <tom@tromey.com>
3998
3999 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
4000 gdb::byte_vector.
4001
ed2b3126
TT
40022017-11-04 Tom Tromey <tom@tromey.com>
4003
4004 * objfiles.c (do_free_objfile_cleanup): Remove.
4005 * compile/compile-object-load.c (compile_object_load): Update.
4006 * objfiles.h (make_cleanup_free_objfile): Remove.
4007
7f6743fd
TT
40082017-11-04 Tom Tromey <tom@tromey.com>
4009
4010 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
4011 (adi_read_versions): Change "tags" to "gdb_byte *".
4012 (adi_print_versions): Likewise.
4013
c80049d3
TT
40142017-11-04 Tom Tromey <tom@tromey.com>
4015
4016 * breakpoint.c
4017 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
4018 from start_rbreak_breakpoints.
4019 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
4020 * breakpoint.h (class scoped_rbreak_breakpoints): New.
4021 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
4022 * symtab.c (do_end_rbreak_breakpoints): Remove.
4023 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
4024
167b0be1
TT
40252017-11-04 Tom Tromey <tom@tromey.com>
4026
4027 * cp-namespace.c (reset_directive_searched): Remove.
4028 (cp_lookup_symbol_via_imports): Use scoped_restore.
4029 * cp-support.c (reset_directive_searched): Remove.
4030 (make_symbol_overload_list_using): Use scoped_restore.
4031 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
4032 (reset_directive_searched): Remove.
4033
5eae7aea
TT
40342017-11-04 Tom Tromey <tom@tromey.com>
4035
4036 * symfile.c (find_separate_debug_file_by_debuglink): Use
4037 unique_xmalloc_ptr.
4038
c6bcad5f
TT
40392017-11-04 Tom Tromey <tom@tromey.com>
4040
4041 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
4042 type of "info".
4043 (compute_stack_depth): Likewise.
4044 (do_compile_dwarf_expr_to_c): Use std::vector.
4045
20dcd8ca
TT
40462017-11-04 Tom Tromey <tom@tromey.com>
4047
4048 * compile/compile-object-load.c (link_callbacks_einfo): Use
4049 std::string.
4050
33c7c59d
TT
40512017-11-04 Tom Tromey <tom@tromey.com>
4052
4053 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
4054 Use scoped_free_pendings.
4055 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
4056 scoped_free_pendings.
4057 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
4058 (xcoff_initial_scan): Likewise.
4059 * buildsym.c (reset_symtab_globals): Update comment.
4060 (scoped_free_pendings): Rename from really_free_pendings.
4061 (prepare_for_building): Update comment.
4062 (buildsym_init): Likewise.
4063 * buildsym.h (class scoped_free_pendings): New class.
4064 (really_free_pendings): Don't declare.
4065
67fa57cf
UW
40662017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
4067
4068 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
4069 output when converting a zero value to a special byteorder format.
4070
f26ae15b
YQ
40712017-11-02 Yao Qi <yao.qi@linaro.org>
4072
4073 * frame.c (do_frame_register_read): Remove aspace.
4074 * jit.c (jit_frame_sniffer): Likwise.
4075 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
4076 * regcache.c (regcache::regcache): Pass nullptr.
4077 (regcache_print): Caller updated.
4078 * regcache.h (regcache::regcache): Remove one constructor
4079 parameter aspace.
4080
6c6e9412
YQ
40812017-11-02 Yao Qi <yao.qi@linaro.org>
4082
4083 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
4084
8b86c959
YQ
40852017-11-02 Yao Qi <yao.qi@linaro.org>
4086
4087 * breakpoint.c (insert_single_step_breakpoints): Update.
4088 * frame.c (struct frame_info) <aspace>: Add const.
4089 (frame_save_as_regcache): Add const.
4090 (get_frame_address_space): Return const address_space *.
4091 * frame.h (get_frame_address_space): Update declaration.
4092 * infrun.c (struct step_over_info) <aspace>: Add const.
4093 (set_step_over_info): Make aspace const.
4094 (displaced_step_prepare_throw): Change variable const.
4095 (resume): Likewise.
4096 (proceed): Likewise.
4097 (adjust_pc_after_break): Likewise.
4098 (save_waitstatus): Likewise.
4099 (handle_signal_stop): Likewise.
4100 (keep_going_pass_signal): Likewise.
4101 * jit.c (jit_frame_sniffer): Add const.
4102 * mips-tdep.c (mips_single_step_through_delay): Likewise.
4103 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
4104 * record-full.c (record_full_wait_1): Likewise.
4105 * regcache.c (regcache::regcache): Change parameter to const.
4106 * regcache.h (regcache::regcache): Likewise.
4107 (regcache::aspace): Return const address_space *.
4108 (regcache) <m_aspace>: Add const.
4109
a01bda52
YQ
41102017-11-02 Yao Qi <yao.qi@linaro.org>
4111
4112 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
4113 * frame.c (create_sentinel_frame): Likewise.
4114 * infrun.c (displaced_step_prepare_throw): Likewise.
4115 (resume): Likewise.
4116 (thread_still_needs_step_over_bp): Likewise.
4117 (proceed): Likewise.
4118 (do_target_wait): Likewise.
4119 (adjust_pc_after_break): Likewise.
4120 (handle_syscall_event): Likewise.
4121 (save_waitstatus): Likewise.
4122 (handle_inferior_event_1): Likewise.
4123 (handle_signal_stop): Likewise.
4124 (keep_going_pass_signal): Likewise.
4125 * linux-nat.c (status_callback): Likewise.
4126 (save_stop_reason): Likewise.
4127 (resume_stopped_resumed_lwps): Likewise.
4128 * record-full.c (record_full_exec_insn): Likewise.
4129 (record_full_wait_1): Likewise.
4130 * regcache.c (get_regcache_aspace): Remove.
4131 * regcache.h (get_regcache_aspace): Remove.
4132
d999647b
YQ
41332017-11-02 Yao Qi <yao.qi@linaro.org>
4134
4135 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
4136 (init_regcache_descr): Use gdbarch_num_regs.
4137 (regcache::regcache): Likewise.
4138 (regcache::get_register_status): Likewise.
4139 (regcache::assert_raw_regnum): Likewise.
4140 (regcache::cooked_read): Likewise.
4141 (regcache::cooked_read_value): Likewise.
4142 (regcache::cooked_write): Likewise.
4143 (regcache::dump): Likewise.
4144 (regcache::num_raw_registers): New method.
4145 * regcache.h (class regcache) <num_raw_registers>: New.
4146
4e888c28
YQ
41472017-11-02 Yao Qi <yao.qi@linaro.org>
4148
4149 * regcache.c (regcache::assert_regnum): New method.
4150 (regcache::invalidate): Call assert_regnum.
4151 (regcache::raw_update): Likewise.
4152 (regcache::raw_write): Likewise.
4153 (regcache::raw_read_part): Likewise.
4154 (regcache::raw_write_part): Likewise.
4155 (regcache::raw_supply): Likewise.
4156 (regcache::raw_supply_integer): Likewise.
4157 (regcache::raw_supply_zeroed): Likewise.
4158 (regcache::raw_collect): Likewise.
4159 (regcache::raw_collect_integer): Likewise.
4160 * regcache.h (regcache::assert_regnum): Declare.
4161
2e1b49b3
YQ
41622017-11-02 Yao Qi <yao.qi@linaro.org>
4163
4164 * regcache.c (regcache::dump): Remove code.
4165
6c5218df
YQ
41662017-11-02 Yao Qi <yao.qi@linaro.org>
4167
4168 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
4169 Remove.
4170 <sizeof_cooked_register_status>: Remove.
4171 (init_regcache_descr): Update.
4172 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
4173 (regcache::save): Likewise.
4174 (regcache::dump): Likewise.
4175
dcc31d28
JB
41762017-11-01 James Bowman <james.bowman@ftdichip.com>
4177
4178 * ft32-tdep.c (ft32_fetch_instruction): New function.
4179 (ft32_analyze_prologue): Use ft32_fetch_instruction().
4180
3a87ae65
SM
41812017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
4182
4183 * cli/cli-script.c (execute_control_command): Rename to ...
4184 (execute_control_command_1): ... this.
4185 (execute_control_command): New function.
4186
09b847f3
SM
41872017-10-31 Simon Marchi <simon.marchi@ericsson.com>
4188
4189 * tracepoint.c (tfind_command): Remove const_cast.
4190
f871c485
MG
41912017-10-30 Mike Gulick <mgulick@mathworks.com>
4192
4193 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
4194
b020ff80
SM
41952017-10-30 Simon Marchi <simon.marchi@ericsson.com>
4196
4197 * common/common-utils.h (in_inclusive_range): New function.
4198 * arm-tdep.c (arm_record_extension_space): Use
4199 in_inclusive_range.
4200 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
4201 * cris-tdep.c (cris_spec_reg_applicable): Use
4202 in_inclusive_range.
4203
1b81856f 42042017-10-30 Pedro Alves <palves@redhat.com>
175654b9 4205 Simon Marchi <simon.marchi@ericsson.com>
1b81856f
PA
4206
4207 * remote.c (remote_set_syscall_catchpoint): Build a std::string
4208 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
4209
31b833b3
PA
42102017-10-30 Pedro Alves <palves@redhat.com>
4211
4212 * common/common-utils.c (string_appendf, string_vappendf): New
4213 functions.
4214 * common/common-utils.h (string_appendf, string_vappendf): New
4215 declarations.
4216 * unittests/common-utils-selftests.c (string_appendf_func)
4217 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
4218 (string_vappendf_tests): New functions.
4219 (_initialize_common_utils_selftests): Register "string_appendf" and
4220 "string_vappendf tests".
4221
4a250334
PA
42222017-10-30 Pedro Alves <palves@redhat.com>
4223
4224 * unittests/common-utils-selftests.c (format_func): New typedef.
4225 (string_printf_tests, string_vprintf_tests): Tests factored out
4226 and merged to ...
4227 (test_format_func): ... this new function.
4228 (string_printf_tests, string_vprintf_tests): Reimplement on top of
4229 test_format_func.
4230
16c5c17e
SM
42312017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4232
4233 * darwin-nat.c: Remove include of gdb.h.
4234
7ca51576
SM
42352017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4236
4237 * xtensa-xtregs.c: Fix formatting issues.
4238
c1342859
SM
42392017-10-29 Simon Marchi <simon.marchi@ericsson.com>
4240
4241 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
4242
484d8d36
MD
42432017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
4244
4245 PR python/21213
4246 * python/py-infthread.c (thpy_get_inferior): Increment reference
4247 of inferior before returning it.
4248
b5540b5f
SM
42492017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4250
4251 * unittests/common-utils-selftests.c (format): Add
4252 ATTRIBUTE_PRINTF.
4253
5a9dcda1
SM
42542017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4255
4256 * xml-syscall.c (struct syscall_desc): Add constructor.
4257 <name>: Change type to std::string.
4258 (syscall_desc_up): New typedef.
4259 (syscall_desc_p): Remove typeder.
4260 (DEF_VEC_P(syscall_desc_p)): Remove.
4261 (struct syscall_group_desc): Add constructor.
4262 <name>: Change type to std::string.
4263 <syscalls>: Change type to std::vector.
4264 (syscall_group_desc_up): New typedef.
4265 (syscall_group_desc_p): Remove typedef.
4266 (DEF_VEC_P(syscall_group_desc_p)): Remove.
4267 (struct syscalls_info) <syscalls>: Change type to std::vector of
4268 unique_ptr.
4269 <groups>: Likewise.
4270 <my_gdb_datadir>: Change type to std::string.
4271 (syscalls_info_up): New typedef.
4272 (allocate_syscalls_info): Remove.
4273 (syscalls_info_free_syscalls_desc): Remove.
4274 (syscalls_info_free_syscall_group_desc): Remove.
4275 (free_syscalls_info): Remove.
4276 (make_cleanup_free_syscalls_info): Remove.
4277 (syscall_group_create_syscall_group_desc): Adjust.
4278 (syscall_group_add_syscall): Adjust.
4279 (syscall_create_syscall_desc): Adjust.
4280 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
4281 (init_syscalls_info): Adjust.
4282 (syscall_group_get_group_by_name): Adjust.
4283 (xml_get_syscall_number): Adjust.
4284 (xml_get_syscall_name): Adjust.
4285 (xml_list_of_syscalls): Adjust.
4286 (xml_list_syscalls_by_group): Adjust.
4287 (xml_list_of_groups): Adjust.
4288
45461e0d
SM
42892017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4290
4291 * probe.h: Don't include gdb_vecs.h.
4292 (DEF_VEC_P (probe_p)): Remove.
4293 (find_probes_in_objfile): Return an std::vector.
4294 * probe.c (find_probes_in_objfile): Likewise.
4295 * breakpoint.c (breakpoint_objfile_data)
4296 <longjmp_probes>: Change type to std::vector.
4297 <exception_probes>: Likewise.
4298 (free_breakpoint_probes): Don't manually free vectors.
4299 (create_longjmp_master_breakpoint): Adjust.
4300 (create_exception_master_breakpoint): Adjust.
4301 * solib-svr4.c (svr4_create_probe_breakpoints): Change
4302 parameter type, adjust.
4303 (svr4_create_solib_event_breakpoints): Adjust.
4304
43dce439
SM
43052017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4306
4307 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
4308 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
4309 with new.
4310 (free_breakpoint_probes): Rename to ...
4311 (free_breakpoint_objfile_data): ... this, and call delete on
4312 bp_objfile_data..
4313
6a1b9516
SM
43142017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
4315
4316 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
4317 (loaded_script_ptr): Remove typedef.
4318 (DEF_VEC_P (loaded_script_ptr)): Remove.
4319 (struct collect_matching_scripts_data): Add constructor.
4320 <scripts_p>: Change type to (pointer to) std::vector.
4321 (collect_matching_scripts_data): Adjust.
4322 (sort_scripts_by_name): Make suitable for std::sort.
4323 (print_scripts): Don't sort vector, adjust to std::vector.
4324 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
4325
593e3209
SM
43262017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4327
4328 * symfile.c (filename_language): Make struct, not typedef. Add
4329 constructor.
4330 <ext>: Change type to std::string.
4331 (DEF_VEC_O (filename_language)): Remove.
4332 (filename_language_table): Change type to std::vector.
4333 (add_filename_language): Adjust.
4334 (set_ext_lang_command): Adjust.
4335 (info_ext_lang_command): Adjust.
4336 (deduce_language_from_filename): Adjust.
4337 (class scoped_restore_filename_language_table): Remove.
4338 (test_filename_language): Use scoped_restore.
4339 (test_set_ext_lang_command): Use scoped_restore, adjust to
4340 std::vector change.
4341
32fa66eb
SM
43422017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4343
4344 * symfile.c: Include selftest.h.
4345 (class scoped_restore_filename_language_table): New.
4346 (test_filename_language): New test.
4347 (test_set_ext_lang_command): New test.
4348 (_initialize_symfile): Register tests.
4349
4a27f119
KS
43502017-10-27 Keith Seitz <keiths@redhat.com>
4351
4352 * breakpoint.c (print_breakpoint_location): Use the symbol saved
4353 in the bp_location, falling back to find_pc_sect_function when
4354 needed.
4355 (add_location_to_breakpoint): Save sal->symbol.
4356 * breakpoint.h (struct bp_location) <symbol>: New field.
4357 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
4358 * symtab.h (struct symtab_and_line) <symbol>: New field.
4359
a43f3893
PF
43602017-10-26 Patrick Frants <osscontribute@gmail.com>
4361
7453e6b2 4362 PR gdb/13669
a43f3893
PF
4363 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
4364 to rewind obstack.
4365
23cc4e1b
PA
43662017-10-26 Pedro Alves <palves@redhat.com>
4367
4368 * remote.c (remote_async_terminal_ours_p): Delete.
4369 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
4370 Remove references to 'remote_async_terminal_ours_p'.
4371
6abc18bb
YQ
43722017-10-26 Yao Qi <yao.qi@linaro.org>
4373
4374 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
4375
bd522513
YQ
43762017-10-26 Yao Qi <yao.qi@linaro.org>
4377
4378 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
4379 aspace const.
4380 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
4381 Likewise.
4382 * breakpoint.c (bpstat_check_location): Remove cast.
4383 (breakpoint_hit_catch_fork): Make aspce const.
4384 (breakpoint_hit_catch_solib): Likewise.
4385 (breakpoint_hit_catch_exec): Likewise.
4386 (breakpoint_hit_ranged_breakpoint): Likewise.
4387 (breakpoint_hit_watchpoint): Likewise.
4388 (base_breakpoint_breakpoint_hit): Likewise.
4389 (bkpt_breakpoint_hit): Likewise.
4390 (dprintf_breakpoint_hit): Likewise.
4391 (tracepoint_breakpoint_hit): Likewise.
4392 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
4393
accd0bcd
YQ
43942017-10-26 Yao Qi <yao.qi@linaro.org>
4395
4396 * breakpoint.c (breakpoint_location_address_match): Change
4397 "struct address_space *" to "const address_space".
4398 (breakpoint_location_address_range_overlap): Likewise.
4399 (breakpoint_here_p): Likewise.
4400 (breakpoint_in_range_p): Likewise.
4401 (moribund_breakpoint_here_p): Likewise.
4402 (bp_location_inserted_here_p): Likewise.
4403 (software_breakpoint_inserted_here_p): Likewise.
4404 (hardware_breakpoint_inserted_here_p): Likewise.
4405 (hardware_watchpoint_inserted_in_range): Likewise.
4406 (bpstat_check_location): Likewise.
4407 (bpstat_stop_status): Likewise.
4408 (breakpoint_address_match): Likewise.
4409 (breakpoint_address_match_range): Likewise.
4410 (breakpoint_location_address_match): Likewise.
4411 (breakpoint_location_address_range_overlap): Likewise.
4412 (insert_single_step_breakpoint): Likewise.
4413 (breakpoint_has_location_inserted_here): Likewise.
4414 (single_step_breakpoint_inserted_here_p): Likewise.
4415 (pc_at_non_inline_function): Likewise.
4416 * breakpoint.h (bpstat_stop_status): Update declaration.
4417 (breakpoint_here_p): Likewise.
4418 (breakpoint_in_range_p): Likewise.
4419 (moribund_breakpoint_here_p): Likewise.
4420 (breakpoint_inserted_here_p): Likewise.
4421 (software_breakpoint_inserted_here_p): Likewise.
4422 (hardware_breakpoint_inserted_here_p): Likewise.
4423 (breakpoint_has_location_inserted_here): Likewise.
4424 (single_step_breakpoint_inserted_here_p): Likewise.
4425 (hardware_watchpoint_inserted_in_range): Likewise.
4426 (breakpoint_address_match): Likewise.
4427 (insert_single_step_breakpoint): Likewise.
4428 (pc_at_non_inline_function): Likewise.
4429 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
4430 * record.c (record_check_stopped_by_breakpoint): Likewise.
4431 * record.h (record_check_stopped_by_breakpoint): Likewise.
4432 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
4433
ac7936df
YQ
44342017-10-25 Yao Qi <yao.qi@linaro.org>
4435
4436 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
4437 regcache->arch () instead get_regcache_arch.
4438 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
4439 Likewise.
4440 (aarch64_fbsd_store_inferior_registers): Likewise.
4441 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
4442 (store_gregs_to_thread): Likewise.
4443 (fetch_fpregs_from_thread): Likewise.
4444 (store_fpregs_to_thread): Likewise.
4445 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
4446 (aarch64_store_return_value): Likewise.
4447 (aarch64_software_single_step): Likewise.
4448 * aix-thread.c (aix_thread_wait): Likewise.
4449 (supply_reg32): Likewise.
4450 (supply_sprs64): Likewise.
4451 (supply_sprs32): Likewise.
4452 (fill_gprs64): Likewise.
4453 (fill_gprs32): Likewise.
4454 (fill_sprs64): Likewise.
4455 (fill_sprs32): Likewise.
4456 (store_regs_user_thread): Likewise.
4457 (store_regs_kernel_thread): Likewise.
4458 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
4459 (alphabsd_store_inferior_registers): Likewise.
4460 * alpha-tdep.c (alpha_extract_return_value): Likewise.
4461 (alpha_store_return_value): Likewise.
4462 (alpha_deal_with_atomic_sequence): Likewise.
4463 (alpha_next_pc): Likewise.
4464 (alpha_software_single_step): Likewise.
4465 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
4466 (amd64bsd_store_inferior_registers): Likewise.
4467 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
4468 Likewise.
4469 (amd64_linux_store_inferior_registers): Likewise.
4470 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
4471 (amd64_collect_native_gregset): Likewise.
4472 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
4473 (amd64obsd_collect_uthread): Likewise.
4474 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
4475 (amd64_collect_fpregset): Likewise.
4476 (amd64_supply_fxsave): Likewise.
4477 (amd64_supply_xsave): Likewise.
4478 (amd64_collect_fxsave): Likewise.
4479 (amd64_collect_xsave): Likewise.
4480 * arc-tdep.c (arc_write_pc): Likewise.
4481 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
4482 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
4483 (arm_fbsd_store_inferior_registers): Likewise.
4484 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
4485 (store_vfp_regs): Likewise.
4486 (arm_linux_fetch_inferior_registers): Likewise.
4487 (arm_linux_store_inferior_registers): Likewise.
4488 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
4489 (arm_linux_sigreturn_next_pc): Likewise.
4490 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
4491 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
4492 (fetch_register): Likewise.
4493 (store_register): Likewise.
4494 * arm-tdep.c (arm_is_thumb): Likewise.
4495 (displaced_in_arm_mode): Likewise.
4496 (bx_write_pc): Likewise.
4497 (arm_get_next_pcs_addr_bits_remove): Likewise.
4498 (arm_software_single_step): Likewise.
4499 (arm_extract_return_value): Likewise.
4500 (arm_store_return_value): Likewise.
4501 (arm_write_pc): Likewise.
4502 * bfin-tdep.c (bfin_extract_return_value): Likewise.
4503 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
4504 (bsd_uthread_store_registers): Likewise.
4505 * core-regset.c (fetch_core_registers): Likewise.
4506 * corelow.c (get_core_registers): Likewise.
4507 * cris-tdep.c (cris_store_return_value): Likewise.
4508 (cris_extract_return_value): Likewise.
4509 (find_step_target): Likewise.
4510 (find_step_target): Likewise.
4511 (cris_software_single_step): Likewise.
4512 * ctf.c (ctf_fetch_registers): Likewise.
4513 * darwin-nat.c (cancel_breakpoint): Likewise.
4514 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
4515 * frv-tdep.c (frv_extract_return_value): Likewise.
4516 * ft32-tdep.c (ft32_store_return_value): Likewise.
4517 (ft32_extract_return_value): Likewise.
4518 * go32-nat.c (fetch_register): Likewise.
4519 (go32_fetch_registers): Likewise.
4520 (go32_store_registers): Likewise.
4521 (store_register): Likewise.
4522 * h8300-tdep.c (h8300_extract_return_value): Likewise.
4523 (h8300_store_return_value): Likewise.
4524 * hppa-linux-nat.c (fetch_register): Likewise.
4525 (store_register): Likewise.
4526 (hppa_linux_fetch_inferior_registers): Likewise.
4527 (hppa_linux_store_inferior_registers): Likewise.
4528 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
4529 (i386_darwin_store_inferior_registers): Likewise.
4530 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
4531 (gnu_store_registers): Likewise.
4532 * i386-linux-nat.c (fetch_register): Likewise.
4533 (store_register): Likewise.
4534 (supply_gregset): Likewise.
4535 (fill_gregset): Likewise.
4536 (i386_linux_fetch_inferior_registers): Likewise.
4537 (i386_linux_store_inferior_registers): Likewise.
4538 (i386_linux_resume): Likewise.
4539 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
4540 Likewise.
4541 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
4542 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
4543 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
4544 (i386obsd_collect_uthread): Likewise.
4545 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4546 (i386_supply_gregset): Likewise.
4547 (i386_collect_gregset): Likewise.
4548 (i386_supply_fpregset): Likewise.
4549 (i386_collect_fpregset): Likewise.
4550 (i386_mpx_bd_base): Likewise.
4551 * i386-v4-nat.c (supply_fpregset): Likewise.
4552 (fill_fpregset): Likewise.
4553 * i387-tdep.c (i387_supply_fsave): Likewise.
4554 (i387_collect_fsave): Likewise.
4555 (i387_supply_fxsave): Likewise.
4556 (i387_collect_fxsave): Likewise.
4557 (i387_supply_xsave): Likewise.
4558 (i387_collect_xsave): Likewise.
4559 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
4560 (ia64_linux_store_registers): Likewise.
4561 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
4562 (ia64_extract_return_value): Likewise.
4563 (ia64_store_return_value): Likewise.
4564 (find_func_descr): Likewise.
4565 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
4566 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
4567 (inf_ptrace_store_registers): Likewise.
4568 * infrun.c (use_displaced_stepping): Likewise.
4569 (displaced_step_prepare_throw): Likewise.
4570 (resume): Likewise.
4571 (proceed): Likewise.
4572 (do_target_wait): Likewise.
4573 (adjust_pc_after_break): Likewise.
4574 (handle_inferior_event_1): Likewise.
4575 (handle_signal_stop): Likewise.
4576 (save_infcall_suspend_state): Likewise.
4577 (restore_infcall_suspend_state): Likewise.
4578 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
4579 * jit.c (jit_frame_prev_register): Likewise.
4580 * linux-nat.c (save_stop_reason): Likewise.
4581 (linux_nat_wait_1): Likewise.
4582 (resume_stopped_resumed_lwps): Likewise.
4583 * linux-record.c (record_linux_sockaddr): Likewise.
4584 (record_linux_msghdr): Likewise.
4585 (record_linux_system_call): Likewise.
4586 * linux-tdep.c (linux_collect_thread_registers): Likewise.
4587 * lm32-tdep.c (lm32_extract_return_value): Likewise.
4588 (lm32_store_return_value): Likewise.
4589 * m32c-tdep.c (m32c_read_flg): Likewise.
4590 (m32c_pseudo_register_read): Likewise.
4591 (m32c_pseudo_register_write): Likewise.
4592 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
4593 (m32r_linux_collect_gregset): Likewise.
4594 * m32r-tdep.c (m32r_store_return_value): Likewise.
4595 (m32r_extract_return_value): Likewise.
4596 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
4597 (m68kbsd_collect_fpregset): Likewise.
4598 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
4599 * m68k-linux-nat.c (fetch_register): Likewise.
4600 (old_fetch_inferior_registers): Likewise.
4601 (old_store_inferior_registers): Likewise.
4602 (store_regs): Likewise.
4603 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
4604 (m68k_svr4_store_return_value): Likewise.
4605 * m88k-tdep.c (m88k_store_arguments): Likewise.
4606 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
4607 (mi_cmd_data_write_register_values): Likewise.
4608 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
4609 (mips_fbsd_store_inferior_registers): Likewise.
4610 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
4611 (mips_fbsd_supply_gregs): Likewise.
4612 (mips_fbsd_collect_fpregs): Likewise.
4613 (mips_fbsd_collect_gregs): Likewise.
4614 (mips_fbsd_supply_fpregset): Likewise.
4615 (mips_fbsd_collect_fpregset): Likewise.
4616 (mips_fbsd_supply_gregset): Likewise.
4617 (mips_fbsd_collect_gregset): Likewise.
4618 * mips-linux-nat.c (supply_gregset): Likewise.
4619 (fill_gregset): Likewise.
4620 (supply_fpregset): Likewise.
4621 (fill_fpregset): Likewise.
4622 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
4623 (mips_fill_gregset): Likewise.
4624 (mips_supply_fpregset): Likewise.
4625 (mips_fill_fpregset): Likewise.
4626 (mips64_supply_gregset): Likewise.
4627 (micromips_linux_sigframe_validate): Likewise.
4628 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
4629 (mipsnbsd_fetch_inferior_registers): Likewise.
4630 (mipsnbsd_store_inferior_registers): Likewise.
4631 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
4632 (mipsnbsd_supply_gregset): Likewise.
4633 (mipsnbsd_iterate_over_regset_sections): Likewise.
4634 (mipsnbsd_supply_reg): Likewise.
4635 (mipsnbsd_supply_fpreg): Likewise.
4636 * mips-tdep.c (mips_in_frame_stub): Likewise.
4637 (mips_dummy_id): Likewise.
4638 (is_octeon_bbit_op): Likewise.
4639 (micromips_bc1_pc): Likewise.
4640 (extended_mips16_next_pc): Likewise.
4641 (mips16_next_pc): Likewise.
4642 (deal_with_atomic_sequence): Likewise.
4643 * moxie-tdep.c (moxie_process_readu): Likewise.
4644 * nios2-tdep.c (nios2_get_next_pc): Likewise.
4645 * nto-procfs.c (procfs_store_registers): Likewise.
4646 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
4647 (ppcfbsd_store_inferior_registers): Likewise.
4648 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
4649 (fetch_altivec_register): Likewise.
4650 (get_spe_registers): Likewise.
4651 (fetch_spe_register): Likewise.
4652 (fetch_altivec_registers): Likewise.
4653 (fetch_all_gp_regs): Likewise.
4654 (fetch_all_fp_regs): Likewise.
4655 (store_vsx_register): Likewise.
4656 (store_altivec_register): Likewise.
4657 (set_spe_registers): Likewise.
4658 (store_spe_register): Likewise.
4659 (store_altivec_registers): Likewise.
4660 (store_all_gp_regs): Likewise.
4661 (store_all_fp_regs): Likewise.
4662 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4663 (ppc_linux_collect_gregset): Likewise.
4664 (ppc_canonicalize_syscall): Likewise.
4665 (ppc_linux_record_signal): Likewise.
4666 (ppu2spu_prev_register): Likewise.
4667 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4668 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4669 (ppcobsd_store_registers): Likewise.
4670 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4671 Likewise.
4672 (ppc_ravenscar_generic_store_registers): Likewise.
4673 * procfs.c (procfs_fetch_registers): Likewise.
4674 (procfs_store_registers): Likewise.
4675 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4676 (ravenscar_store_registers): Likewise.
4677 (ravenscar_prepare_to_store): Likewise.
4678 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4679 * record-full.c (record_full_wait_1): Likewise.
4680 (record_full_registers_change): Likewise.
4681 (record_full_store_registers): Likewise.
4682 (record_full_core_fetch_registers): Likewise.
4683 (record_full_save): Likewise.
4684 (record_full_goto_insn): Likewise.
4685 * regcache.c (regcache_register_size): Likewise.
4686 (get_regcache_arch): Remove.
4687 (regcache_read_pc): Likewise.
4688 * regcache.h (get_regcache_arch): Remove.
4689 * remote-sim.c (gdbsim_fetch_register): Likewise.
4690 (gdbsim_store_register): Likewise.
4691 * remote.c (fetch_register_using_p): Likewise.
4692 (send_g_packet): Likewise.
4693 (remote_prepare_to_store): Likewise.
4694 (store_registers_using_G): Likewise.
4695 * reverse.c (save_bookmark_command): Likewise.
4696 (goto_bookmark_command): Likewise.
4697 * rs6000-aix-tdep.c (branch_dest): Likewise.
4698 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4699 (fetch_register): Likewise.
4700 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4701 (ppc_collect_reg): Likewise.
4702 (ppc_collect_gregset): Likewise.
4703 (ppc_collect_fpregset): Likewise.
4704 (ppc_collect_vsxregset): Likewise.
4705 (ppc_collect_vrregset): Likewise.
4706 (ppc_displaced_step_hw_singlestep): Likewise.
4707 (rs6000_pseudo_register_read): Likewise.
4708 (rs6000_pseudo_register_write): Likewise.
4709 * s390-linux-nat.c (supply_gregset): Likewise.
4710 (fill_gregset): Likewise.
4711 (s390_linux_fetch_inferior_registers): Likewise.
4712 * s390-linux-tdep.c (s390_write_pc): Likewise.
4713 (s390_software_single_step): Likewise.
4714 (s390_all_but_pc_registers_record): Likewise.
4715 (s390_linux_syscall_record): Likewise.
4716 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4717 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4718 (shnbsd_store_inferior_registers): Likewise.
4719 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4720 (sh_extract_return_value_fpu): Likewise.
4721 (sh_store_return_value_nofpu): Likewise.
4722 (sh_corefile_supply_regset): Likewise.
4723 (sh_corefile_collect_regset): Likewise.
4724 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4725 (sh64_store_return_value): Likewise.
4726 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4727 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4728 (sparc_store_inferior_registers): Likewise.
4729 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4730 (sparc_ravenscar_prepare_to_store): Likewise.
4731 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4732 (sparc_analyze_control_transfer): Likewise.
4733 (sparc_step_trap): Likewise.
4734 (sparc_software_single_step): Likewise.
4735 (sparc32_gdbarch_init): Likewise.
4736 (sparc_supply_rwindow): Likewise.
4737 (sparc_collect_rwindow): Likewise.
4738 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4739 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4740 (sparc64nbsd_collect_gregset): Likewise.
4741 (sparc64nbsd_supply_fpregset): Likewise.
4742 (sparc64nbsd_collect_fpregset): Likewise.
4743 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4744 (sparc64_supply_gregset): Likewise.
4745 (sparc64_collect_gregset): Likewise.
4746 (sparc64_supply_fpregset): Likewise.
4747 (sparc64_collect_fpregset): Likewise.
4748 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4749 * spu-tdep.c (spu_unwind_sp): Likewise.
4750 (spu2ppu_prev_register): Likewise.
4751 (spu_memory_remove_breakpoint): Likewise.
4752 * stack.c (return_command): Likewise.
4753 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4754 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4755 * tracefile.c (trace_save_ctf): Likewise.
4756 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4757 (do_windows_store_inferior_registers): Likewise.
4758 (windows_resume): Likewise.
4759 * xtensa-linux-nat.c (fill_gregset): Likewise.
4760 (supply_gregset_reg): Likewise.
4761 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4762 (xtensa_register_read_masked): Likewise.
4763 (xtensa_supply_gregset): Likewise.
4764 (xtensa_extract_return_value): Likewise.
4765 (xtensa_store_return_value): Likewise.
4766
edd079d9
UW
47672017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4768
4769 * doublest.c (floatformat_from_string): New function.
4770 * doublest.h (floatformat_from_string): Add prototype.
4771
4772 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4773 (OP_FLOAT): ... this.
4774 * expression.h: Do not include "doublest.h".
4775 (union exp_element): Replace doubleconst and decfloatconst by
4776 new element floatconst.
4777 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4778 (ada_evaluate_subexp): Likewise.
4779 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4780 OP_DOUBLE and OP_DECFLOAT.
4781 * expprint.c (print_subexp_standard): Likewise.
4782 (dump_subexp_body_standard): Likewise.
4783 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4784
4785 * parse.c: Include "dfp.h".
4786 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4787 (write_exp_elt_floatcst): New function.
4788 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4789 and OP_DECFLOAT.
4790 (operator_check_standard): Likewise.
4791 (parse_float): Do not accept suffix. Take type as input. Return bool.
4792 Return target format buffer instead of host DOUBLEST.
4793 Use floatformat_from_string and decimal_from_string to parse
4794 either binary or decimal floating-point types.
4795 (parse_c_float): Remove.
4796 * parser-defs.h: Do not include "doublest.h".
4797 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4798 (write_exp_elt_floatcst): Add prototype.
4799 (parse_float): Update prototype.
4800 (parse_c_float): Remove.
4801
4802 * c-exp.y: Do not include "dfp.h".
4803 (typed_val_float): Use byte buffer instead of DOUBLEST.
4804 (typed_val_decfloat): Remove.
4805 (DECFLOAT): Remove.
4806 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4807 (parse_number): Update to new parse_float interface.
4808 Parse suffixes and determine type before calling parse_float.
4809 Handle decimal and binary FP types the same way.
4810
4811 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4812 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4813 (parse_number): Update to new parse_float interface.
4814 Parse suffixes and determine type before calling parse_float.
4815
4816 * f-exp.y: Replace dval by typed_val_float.
4817 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4818 (parse_number): Use parse_float instead of atof.
4819
4820 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4821 (parse_go_float): Remove.
4822 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4823 (parse_number): Call parse_float instead of parse_go_float.
4824 Parse suffixes and determine type before calling parse_float.
4825
4826 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4827 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4828 (parse_number): Update to new parse_float interface.
4829 Parse suffixes and determine type before calling parse_float.
4830
4831 * m2-exp.y: Replace dval by byte buffer val.
4832 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4833 (parse_number): Call parse_float instead of atof.
4834
4835 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4836 (lex_number): Call parse_float instead of strtod.
4837 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4838 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4839 Use write_exp_elt_floatcst.
4840 (unit_testing): Remove static variable.
4841 (rust_type): Do not check unit_testing.
4842 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4843
4844 * ada-exp.y (type_float, type_double): Remove.
4845 (typed_val_float): Use byte buffer instead of DOUBLEST.
4846 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4847 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4848
cc628f3d
AH
48492017-10-25 Alan Hayward <alan.hayward@arm.com>
4850
4851 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4852 * arch/aarch64.h: New file.
4853
09a7c6aa
UW
48542017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4855
4856 * dfp.h (decimal_from_string): Use const reference for argument.
4857 * dfp.c (decimal_from_string): Likewise.
4858
8ba0dd51
UW
48592017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4860
4861 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4862 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4863 * mips-tdep.c (mips_print_fp_register): Likewise.
4864
16e812b2
UW
48652017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4866
4867 * common/format.h (enum argclass): Replace decfloat_arg by
4868 dec32float_arg, dec64float_arg, and dec128float_arg.
4869 * common/format.c (parse_format_string): Update to return
4870 new decimal float argument classes.
4871
4872 * printcmd.c (printf_decfloat): Rename to ...
4873 (printf_floating): ... this. Add argclass argument, and use it
4874 instead of parsing the format string again. Add support for
4875 binary floating-point values, using floatformat_to_string.
4876 Convert value to the target format if it doesn't already match.
4877 (ui_printf): Call printf_floating instead of printf_decfloat,
4878 also for double_arg / long_double_arg. Pass argclass.
4879
4880 * dfp.c (decimal_to_string): Add format string argument.
4881 * dfp.h (decimal_to_string): Likewise.
4882
4883 * doublest.c (floatformat_to_string): Add format string argument.
4884 * doublest.h (floatformat_to_string): Likewise.
4885
fdf0cbc2
UW
48862017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4887
4888 * doublest.c (floatformat_precision): New routine.
4889 (floatformat_to_string): Likewise.
4890 * doublest.c (floatformat_to_string): Add prototype.
4891
4892 * printcmd.c (print_scalar_formatted): Only call print_floating
4893 on floating-point types.
4894 * valprint.c: Do not include "floatformat.h".
4895 (generic_val_print_decfloat): Remove.
4896 (generic_val_print): Call generic_val_print_float for both
4897 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4898 (print_floating): Use floatformat_to_string. Handle decimal float.
4899 (print_decimal_floating): Remove, merge into floatformat_to_string.
4900 * value.h (print_decimal_floating): Remove.
4901
4902 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4903
5033013f
UW
49042017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4905
4906 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4907
a664f67e
SM
49082017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4909
4910 * memattr.h: Don't include vec.h.
4911 (struct mem_attrib): Initialize fields.
4912 <unknown>: New static method.
4913 (struct mem_region): Add constructors, operator<, initialize
4914 fields.
4915 * memattr.c: Include algorithm.
4916 (default_mem_attrib, unknown_mem_attrib): Remove.
4917 (user_mem_region_list): New global.
4918 (target_mem_region_list, mem_region_list): Change type to
4919 std::vector<mem_region>.
4920 (mem_use_target): Now a function.
4921 (target_mem_regions_valid): Change type to bool.
4922 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4923 (require_user_regions): Adjust.
4924 (require_target_regions): Adjust.
4925 (create_mem_region): Adjust.
4926 (lookup_mem_region): Adjust.
4927 (invalidate_target_mem_regions): Adjust.
4928 (mem_clear): Rename to...
4929 (user_mem_clear): ... this, and adjust.
4930 (mem_command): Adjust.
4931 (info_mem_command): Adjust.
4932 (mem_enable, enable_mem_command, mem_disable,
4933 disable_mem_command): Adjust.
4934 (mem_delete): Adjust.
4935 (delete_mem_command): Adjust.
4936 * memory-map.h (parse_memory_map): Return an std::vector.
4937 * memory-map.c (parse_memory_map): Likewise.
4938 (struct memory_map_parsing_data): Add constructor.
4939 <memory_map>: Point to std::vector.
4940 (memory_map_start_memory): Adjust.
4941 (memory_map_end_memory): Adjust.
4942 (memory_map_end_property): Adjust.
4943 (clear_result): Remove.
4944 * remote.c (remote_memory_map): Return an std::vector.
4945 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4946 Remove.
4947 (target_debug_print_mem_region_vector): New.
4948 * target-delegates.c: Regenerate.
4949 * target.h (mem_region_vector): New typedef.
4950 (to_memory_map): Return mem_region_vector.
4951 (target_memory_map): Return an std::vector.
4952 * target.c (target_memory_map): Return an std::vector.
4953 (flash_erase_command): Adjust.
4954
6e17c565
SM
49552017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4956
4957 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4958 Change type to std::string.
4959 (memory_map_start_property): Adjust.
4960 (memory_map_end_property): Adjust.
4961
cfba9872
SM
49622017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4963
4964 * infrun.h: Include common/byte-vector.h.
4965 (struct displaced_step_closure): New struct.
4966 (struct buf_displaced_step_closure): New struct.
4967 * infrun.c (displaced_step_closure::~displaced_step_closure):
4968 Provide default implementation.
4969 (displaced_step_clear): Deallocate step closure with delete.
4970 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4971 (aarch64_displaced_step_closure): ... this, extend
4972 displaced_step_closure.
4973 (aarch64_displaced_step_data) <dsc>: Change type to
4974 aarch64_displaced_step_closure.
4975 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4976 unique_ptr.
4977 (aarch64_displaced_step_fixup): Add cast for displaced step
4978 closure.
4979 * amd64-tdep.c (displaced_step_closure): Rename to ...
4980 (amd64_displaced_step_closure): ... this, extend
4981 displaced_step_closure.
4982 <insn_buf>: Change type to std::vector<gdb_byte>.
4983 <max_len>: Remove.
4984 (fixup_riprel): Change type of DSC parameter, adjust to type
4985 change of insn_buf.
4986 (fixup_displaced_copy): Change type of DSC parameter.
4987 (amd64_displaced_step_copy_insn): Instantiate
4988 amd64_displaced_step_closure.
4989 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4990 to type change of insn_buf.
4991 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4992 parameter DSC.
4993 (arm_linux_copy_svc): Likewise.
4994 (cleanup_kernel_helper_return): Likewise.
4995 (arm_catch_kernel_helper_return): Likewise.
4996 (arm_linux_displaced_step_copy_insn): Instantiate
4997 arm_displaced_step_closure.
4998 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4999 (displaced_read_reg): Change type of parameter DSC.
5000 (branch_write_pc): Likewise.
5001 (load_write_pc): Likewise.
5002 (alu_write_pc): Likewise.
5003 (displaced_write_reg): Likewise.
5004 (arm_copy_unmodified): Likewise.
5005 (thumb_copy_unmodified_32bit): Likewise.
5006 (thumb_copy_unmodified_16bit): Likewise.
5007 (cleanup_preload): Likewise.
5008 (install_preload): Likewise.
5009 (arm_copy_preload): Likewise.
5010 (thumb2_copy_preload): Likewise.
5011 (install_preload_reg): Likewise.
5012 (arm_copy_preload_reg): Likewise.
5013 (cleanup_copro_load_store): Likewise.
5014 (install_copro_load_store): Likewise.
5015 (arm_copy_copro_load_store) Likewise.
5016 (thumb2_copy_copro_load_store): Likewise.
5017 (cleanup_branch): Likewise.
5018 (install_b_bl_blx): Likewise.
5019 (arm_copy_b_bl_blx): Likewise.
5020 (thumb2_copy_b_bl_blx): Likewise.
5021 (thumb_copy_b): Likewise.
5022 (install_bx_blx_reg): Likewise.
5023 (arm_copy_bx_blx_reg): Likewise.
5024 (thumb_copy_bx_blx_reg): Likewise.
5025 (cleanup_alu_imm): Likewise.
5026 (arm_copy_alu_imm): Likewise.
5027 (thumb2_copy_alu_imm): Likewise.
5028 (cleanup_alu_reg): Likewise.
5029 (install_alu_reg): Likewise.
5030 (arm_copy_alu_reg): Likewise.
5031 (thumb_copy_alu_reg): Likewise.
5032 (cleanup_alu_shifted_reg): Likewise.
5033 (install_alu_shifted_reg): Likewise.
5034 (arm_copy_alu_shifted_reg): Likewise.
5035 (cleanup_load): Likewise.
5036 (cleanup_store): Likewise.
5037 (arm_copy_extra_ld_st): Likewise.
5038 (install_load_store): Likewise.
5039 (thumb2_copy_load_literal): Likewise.
5040 (thumb2_copy_load_reg_imm): Likewise.
5041 (arm_copy_ldr_str_ldrb_strb): Likewise.
5042 (cleanup_block_load_all): Likewise.
5043 (cleanup_block_store_pc): Likewise.
5044 (cleanup_block_load_pc): Likewise.
5045 (arm_copy_block_xfer): Likewise.
5046 (thumb2_copy_block_xfer): Likewise.
5047 (cleanup_svc): Likewise.
5048 (install_svc): Likewise.
5049 (arm_copy_svc): Likewise.
5050 (thumb_copy_svc): Likewise.
5051 (arm_copy_undef): Likewise.
5052 (thumb_32bit_copy_undef): Likewise.
5053 (arm_copy_unpred): Likewise.
5054 (arm_decode_misc_memhint_neon): Likewise.
5055 (arm_decode_unconditional): Likewise.
5056 (arm_decode_miscellaneous): Likewise.
5057 (arm_decode_dp_misc): Likewise.
5058 (arm_decode_ld_st_word_ubyte): Likewise.
5059 (arm_decode_media): Likewise.
5060 (arm_decode_b_bl_ldmstm): Likewise.
5061 (arm_decode_ext_reg_ld_st): Likewise.
5062 (thumb2_decode_dp_shift_reg): Likewise.
5063 (thumb2_decode_ext_reg_ld_st): Likewise.
5064 (arm_decode_svc_copro): Likewise.
5065 (thumb2_decode_svc_copro): Likewise.
5066 (install_pc_relative): Likewise.
5067 (thumb_copy_pc_relative_16bit): Likewise.
5068 (thumb_decode_pc_relative_16bit): Likewise.
5069 (thumb_copy_pc_relative_32bit): Likewise.
5070 (thumb_copy_16bit_ldr_literal): Likewise.
5071 (thumb_copy_cbnz_cbz): Likewise.
5072 (thumb2_copy_table_branch): Likewise.
5073 (cleanup_pop_pc_16bit_all): Likewise.
5074 (thumb_copy_pop_pc_16bit): Likewise.
5075 (thumb_process_displaced_16bit_insn): Likewise.
5076 (decode_thumb_32bit_ld_mem_hints): Likewise.
5077 (thumb_process_displaced_32bit_insn): Likewise.
5078 (thumb_process_displaced_insn): Likewise.
5079 (arm_process_displaced_insn): Likewise.
5080 (arm_displaced_init_closure): Likewise.
5081 (arm_displaced_step_fixup): Add cast for closure.
5082 * arm-tdep.h: Include infrun.h.
5083 (displaced_step_closure): Rename to ...
5084 (arm_displaced_step_closure): ... this, extend
5085 displaced_step_closure.
5086 <u::svc::copy_svc_os>: Change type of parameter DSC.
5087 <cleanup>: Likewise.
5088 (arm_process_displaced_insn): Likewise.
5089 (arm_displaced_init_closure): Likewise.
5090 (displaced_read_reg): Likewise.
5091 (displaced_write_reg): Likewise.
5092 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5093 Adjust.
5094 * i386-tdep.h: Include infrun.h.
5095 (i386_displaced_step_closure): New typedef.
5096 * i386-tdep.c (i386_displaced_step_copy_insn): Use
5097 i386_displaced_step_closure.
5098 (i386_displaced_step_fixup): Adjust.
5099 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
5100 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
5101 and unique_ptr.
5102 (ppc_displaced_step_fixup): Adjust.
5103 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
5104 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
5105 and unique_ptr.
5106 (s390_displaced_step_fixup): Adjust.
5107
b392b304
SM
51082017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
5109
5110 * interps.h (interp_resume, interp_suspend, interp_set_temp):
5111 Remove declarations.
5112
d5833c62
TT
51132017-10-20 Tom Tromey <tom@tromey.com>
5114
5115 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
5116 std::vector.
5117 (gdb_bfd_record_inclusion): Update.
5118 (bfdp): Remove typedef.
5119
06d5bbc8
TT
51202017-10-20 Tom Tromey <tom@tromey.com>
5121
5122 * gdb_bfd.c (gdb_bfd_ref): Use new.
5123 (struct gdb_bfd_data): Add constructor, destructor, and member
5124 initializers.
5125 (gdb_bfd_unref): Use delete.
5126
2712ce2e
TT
51272017-10-20 Tom Tromey <tom@tromey.com>
5128
5129 * exec.c (exec_file_attach): Use new_bfd_ref.
5130 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
5131 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
5132 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
5133 new_bfd_ref.
5134 * gdb_bfd.h (new_bfd_ref): New function.
5135
fcc8fb2f
PA
51362017-10-20 Pedro Alves <palves@redhat.com>
5137
5138 * main.c (captured_command_loop): Add attribute noinline.
5139
4c2287b0
SM
51402017-10-19 Simon Marchi <simon.marchi@ericsson.com>
5141
5142 * interps.c (struct interp_factory): Add constructor.
5143 (interp_factory_p): Remove typedef.
5144 (DEF_VEC_P(interp_factory_p)): Remove.
5145 (interpreter_factories): Change type to std::vector.
5146 (interp_factory_register): Adjust.
5147 (interp_lookup): Adjust.
5148 (interpreter_completer): Adjust.
5149
3d415c26
TT
51502017-10-19 Tom Tromey <tom@tromey.com>
5151
5152 * break-catch-syscall.c (catch_syscall_completer): Use
5153 std::string, gdb::unique_xmalloc_ptr.
5154
395423c4
TT
51552017-10-19 Tom Tromey <tom@tromey.com>
5156
5157 * infcall.c (call_function_by_hand_dummy): Use std::string.
5158
54f70bc1
TT
51592017-10-19 Tom Tromey <tom@tromey.com>
5160
5161 * mi/mi-main.c (mi_cmd_execute): Update.
5162 * top.h (prepare_execute_command): Return scoped_value_mark.
5163 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
5164 Add move constructor.
5165 * top.c (prepare_execute_command): Return scoped_value_mark.
5166 (execute_command): Update.
5167
63929e84
PA
51682017-10-19 Pedro Alves <palves@redhat.com>
5169
5170 * xml-support.c (xml_fetch_content_from_file): Check fread's
5171 return.
5172
a75868f5
PA
51732017-10-19 Pedro Alves <palves@redhat.com>
5174
5175 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
5176 async.
5177 (handle_error_fd): New function.
5178 (ser_base_async): Add/delete an event loop file handler for
5179 error_fd.
5180
2edf834e
PA
51812017-10-19 Pedro Alves <palves@redhat.com>
5182
5183 * xml-support.c (xml_fetch_content_from_file): Don't read in
5184 chunks. Instead use fseek to determine the file's size, and read
5185 it in one go.
5186
c8ba13ad
KS
51872017-11-18 Keith Seitz <keiths@redhat.com>
5188
5189 * c-exp.y (oper): Canonicalize conversion operators of user-defined
5190 types.
5191 Add whitespace to front of type name.
5192
37534686
KS
51932017-10-18 Keith Seitz <keiths@redhat.com>
5194
5195 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
5196 DW_AT_accessibility.
5197
28c7c158
YQ
51982017-10-18 Yao Qi <yao.qi@linaro.org>
5199
5200 * features/tic6x-c62x-linux.c: Remove.
5201
30f0b101
TT
52022017-10-17 Tom Tromey <tom@tromey.com>
5203
5204 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
5205 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
5206 (do_mixed_source_and_assembly): Likewise.
5207
57e12da9
TT
52082017-10-17 Tom Tromey <tom@tromey.com>
5209
5210 * regcache.c (regcache::xfer_part): Remove assertion.
5211
7b700999
PA
52122017-10-17 Pedro Alves <palves@redhat.com>
5213
5214 * xml-support.c (xml_fetch_content_from_file): Call
5215 unique_ptr::release() instead unique_ptr::get() when passing
5216 through xrealloc.
5217
d3037ba6
YQ
52182017-10-17 Yao Qi <yao.qi@linaro.org>
5219
5220 * regcache.c (regcache::xfer_part): Remove parameters read and
5221 write, add parameter is_raw. All callers are updated.
5222
83d5a34d
KS
52232017-10-16 Keith Seitz <keiths@redhat.com>
5224
5225 * c-typeprint.c (enum access_specifier): Moved here from
5226 c_type_print_base.
5227 (output_access_specifier): New function.
5228 (c_type_print_base): Consider typedefs when assessing
5229 whether access labels are needed.
5230 Use output_access_specifier as needed.
5231 Output access specifier for typedefs, if needed.
5232 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
5233 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
5234 fields.
5235 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
5236 accessor macros.
5237
87028b87
TT
52382017-10-16 Tom Tromey <tom@tromey.com>
5239
5240 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
5241 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
5242 * target.c (target_fileio_read_stralloc): Update.
5243 * sparc64-tdep.c (adi_is_addr_mapped): Update.
5244 * target.h (target_fileio_read_stralloc): Return
5245 unique_xmalloc_ptr.
5246
b7b030ad
TT
52472017-10-16 Tom Tromey <tom@tromey.com>
5248
5249 * xml-syscall.c (xml_init_syscalls_info): Update.
5250 * xml-support.c (xinclude_start_include): Update.
5251 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
5252 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
5253 (xml_fetch_content_from_file): Likewise.
5254 * osdata.c (get_osdata): Update.
5255 * target.h (target_read_stralloc, target_get_osdata): Return
5256 unique_xmalloc_ptr.
5257 * solib-aix.c (solib_aix_get_library_list): Update.
5258 * solib-target.c (solib_target_current_sos): Update.
5259 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
5260 * xml-tdesc.c (fetch_available_features_from_target): Update.
5261 (target_fetch_description_xml): Update.
5262 (file_read_description_xml): Update.
5263 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
5264 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
5265 (remote_pid_to_exec_file): Update.
5266 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
5267 (target_get_osdata): Likewise.
5268
b80406ac
TT
52692017-10-16 Tom Tromey <tom@tromey.com>
5270
5271 * remote.c (remote_register_number_and_offset): Use std::vector.
5272 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
5273 (putpkt_binary): Use gdb::def_vector.
5274 (compare_sections_command): Use gdb::byte_vector.
5275
a90ecff8
TT
52762017-10-16 Tom Tromey <tom@tromey.com>
5277
5278 * ppc-linux-nat.c (hwdebug_insert_point): Use
5279 gdb::unique_xmalloc_ptr, XDUP.
5280
2dc0e219
TT
52812017-10-16 Tom Tromey <tom@tromey.com>
5282
5283 * probe.c (parse_probes): Use std::string.
5284 (info_probes_for_ops, enable_probes_command)
5285 (disable_probes_command): Remove cleanups.
5286
b05628f0
TT
52872017-10-16 Tom Tromey <tom@tromey.com>
5288
5289 * buildsym.c (block_compar): Remove.
5290 (end_symtab_get_static_block): Use std::vector.
5291
a79b1bc6
SM
52922017-10-16 Simon Marchi <simon.marchi@ericsson.com>
5293
5294 * memrange.h (struct mem_range): Define operator< and operator==.
5295 (mem_range_s): Remove.
5296 (DEF_VEC_O (mem_range_s)): Remove.
5297 (normalize_mem_ranges): Change parameter type to std::vector.
5298 * memrange.c (compare_mem_ranges): Remove.
5299 (normalize_mem_ranges): Change parameter type to std::vector,
5300 adjust to vector change.
5301 * exec.c (section_table_available_memory): Return vector, remove
5302 parameter.
5303 (section_table_read_available_memory): Adjust to std::vector
5304 change.
5305 * remote.c (remote_read_bytes): Adjust to std::vector
5306 change.
5307 * tracepoint.h (traceframe_available_memory): Change parameter
5308 type to std::vector.
5309 * tracepoint.c (traceframe_available_memory): Change parameter
5310 type to std::vector, adjust.
5311 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
5312 std::vector change.
5313 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5314 unittests/memrange-selftests.c.
5315 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
5316 * gdb/unittests/memrange-selftests.c: New file.
5317
63f0e930
PA
53182017-10-16 Pedro Alves <palves@redhat.com>
5319
5320 * elfread.c (probe_key_free): Rename range-for variable.
5321 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
5322 (find_probe_by_pc, collect_probes): Rename range-for variable.
5323
c40c7bfc
YQ
53242017-10-16 Yao Qi <yao.qi@linaro.org>
5325
5326 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
5327 * features/tic6x-c62x.c: Remove.
5328 * features/tic6x-c64x-linux.c: Remove.
5329 * features/tic6x-c64x.c: Remove.
5330 * features/tic6x-c64xp-linux.c: Remove.
5331 * features/tic6x-c64xp.c: Remove.
5332 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
5333 initialize_tdesc_tic6x_*_linux functions.
5334 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
5335 initialize_tdesc_tic6x_* functions.
5336
df27ae6a
YQ
53372017-10-16 Yao Qi <yao.qi@linaro.org>
5338
5339 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
5340 tic6x-c62x.
5341 * regformats/tic6x-c62x.dat: Remove.
5342 * regformats/tic6x-c64x.dat: Remove.
5343 * regformats/tic6x-c64xp.dat: Remove.
5344
86766165
SM
53452017-10-15 Simon Marchi <simon.marchi@ericsson.com>
5346
5347 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
5348 (the !HAVE_LIBEXPAT version).
5349
824dfcc3
SM
53502017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5351
5352 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
5353 const.
5354
2098b393
SM
53552017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5356
5357 * target.h: Include tracepoint.h.
5358 (enum trace_find_type): Move to tracepoint.h.
5359 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
5360 * tracepoint.h: Don't include target.h
5361 (enum trace_find_type): Move from target.h.
5362 (parse_traceframe_info): Return a unique ptr.
5363 * tracepoint.c (current_traceframe_info): Change type to unique
5364 ptr.
5365 (free_traceframe_info): Remove.
5366 (clear_traceframe_info): Don't manually free
5367 current_traceframe_info.
5368 (free_result): Remove.
5369 (parse_traceframe_info): Return a unique ptr.
5370 (get_traceframe_info): Adjust to unique ptr.
5371 * ctf.c (ctf_traceframe_info): Return a unique ptr.
5372 * remote.c (remote_traceframe_info): Return a unique ptr.
5373 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
5374 ptr.
5375 * target-debug.h (target_debug_print_traceframe_info_up): New
5376 macro.
5377 * target-delegates.c: Regenerate.
5378
4cdd21a8
SM
53792017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5380
5381 * memrange.h (struct mem_range): Add constructors.
5382 * tracepoint.h (struct traceframe_info) <memory>: Change type to
5383 std::vector<mem_range>.
5384 * tracepoint.c (free_traceframe_info): Don't manually free
5385 vector.
5386 (traceframe_info_start_memory): Adjust to vector change.
5387 (traceframe_available_memory): Likewise.
5388 * tracefile-tfile.c (build_traceframe_info): Likewise.
5389 * ctf.c (ctf_traceframe_info): Likewise.
5390
d0d292a2
SM
53912017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5392
5393 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
5394 std::vector<int>.
5395 * tracepoint.c (free_traceframe_info): Deallocate with delete.
5396 (traceframe_info_start_tvar): Adjust to vector change.
5397 (parse_traceframe_info): Allocate with new.
5398 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
5399 vector change.
5400 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
5401 change.
5402 tfile_traceframe_info): Allocate with new.
5403 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
5404 change.
5405
8d3c73ef
SM
54062017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
5407
5408 * tracepoint.c (traceframe_info): Rename to...
5409 (current_traceframe_info): ...this.
5410 (clear_traceframe_info): Adjust.
5411 (get_traceframe_info): Adjust.
5412
b129dcac
SM
54132017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5414
5415 * nat/linux-osdata.c: Include algorithm.
5416 (compare_processes): Remove.
5417 (struct pid_pgid_entry): New struct.
5418 (linux_xfer_osdata_processgroups): Use std::vector instead of
5419 XNEWVEC.
5420
af5bf4ad
SM
54212017-10-14 Simon Marchi <simon.marchi@ericsson.com>
5422
5423 * objfiles.h: Don't include symfile.h.
5424 (struct partial_symbol): Remove forward-declaration.
5425 (struct objfile) <global_psymbols, static_psymbols>: Change type
5426 to std::vector<partial_symbol *>.
5427 * objfiles.c (objfile::objfile): Don't memset those fields.
5428 (objfile::~objfile): Don't free those fields.
5429 * psympriv.h (struct psymbol_allocation_list): Remove
5430 forward-declaration.
5431 (add_psymbol_to_list): Change psymbol_allocation_list parameter
5432 to std::vector.
5433 (start_psymtab_common): Change parameters to std::vector.
5434 * psymtab.c: Include algorithm.
5435 (require_partial_symbols): Call shrink_to_fit.
5436 (find_pc_sect_psymbol): Adjust to vector change.
5437 (match_partial_symbol): Likewise.
5438 (lookup_partial_symbol): Likewise.
5439 (psym_relocate): Likewise.
5440 (dump_psymtab): Likewise.
5441 (recursively_search_psymtabs): Likewise.
5442 (compare_psymbols): Remove.
5443 (sort_pst_symbols): Adjust to vector change.
5444 (start_psymtab_common): Likewise.
5445 (end_psymtab_common): Likewise.
5446 (psymbol_bcache_full): De-constify return value.
5447 (add_psymbol_to_bcache): Likewise.
5448 (extend_psymbol_list): Remove.
5449 (append_psymbol_to_list): Adjust to vector change.
5450 (add_psymbol_to_list): Likewise.
5451 (init_psymbol_list): Likewise.
5452 (maintenance_info_psymtabs): Likewise.
5453 (maintenance_check_psymtabs): Likewise.
5454 * symfile.h (struct psymbol_allocation_list): Remove.
5455 * symfile.c (reread_symbols): Adjust to vector change.
5456 * dbxread.c (start_psymtab): Change type of parameters.
5457 (dbx_symfile_read): Adjust to vector change.
5458 (read_dbx_symtab): Likewise.
5459 (start_psymtab): Change type of parameters.
5460 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
5461 (create_partial_symtab): Likewise.
5462 (add_partial_symbol): Likewise.
5463 (write_one_signatured_type): Likewise.
5464 (recursively_write_psymbols): Likewise.
5465 * mdebugread.c (parse_partial_symbols): Likewise.
5466 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
5467 (scan_xcoff_symtab): Adjust to vector change.
5468 (xcoff_initial_scan): Likewise.
5469
3ec5942f
SM
54702017-10-13 Simon Marchi <simon.marchi@ericsson.com>
5471
5472 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
5473
2399fe6a
YQ
54742017-10-13 Yao Qi <yao.qi@linaro.org>
5475
5476 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
5477 Remove s390x-*-expedite, add s390x-expedite.
5478
4bf3f4a8
YQ
54792017-10-13 Yao Qi <yao.qi@linaro.org>
5480
5481 * features/s390-gs-linux64.c: Regenerated.
5482 * features/s390x-gs-linux64.c: Regenerated.
5483
9e86da07
TT
54842017-10-13 Tom Tromey <tom@tromey.com>
5485
5486 * compile/compile-object-run.c (do_module_cleanup): Use delete.
5487 * solib.c (update_solib_list, reload_shared_libraries_1): Use
5488 delete.
5489 * symfile.c (symbol_file_add_with_addrs): Use new.
5490 (symbol_file_add_separate): Update comment.
5491 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
5492 * jit.c (jit_object_close_impl): Use new.
5493 (jit_unregister_code): Use delete.
5494 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
5495 (~objfile): Rename from free_objfile.
5496 (free_objfile_separate_debug, do_free_objfile_cleanup)
5497 (free_all_objfiles, objfile_purge_solibs): Use delete.
5498 * objfiles.h (struct objfile): Add constructor and destructor.
5499 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
5500 (allocate_objfile, free_objfile): Don't declare.
5501 (struct objstats): Add initializers.
5502
c2508e90
SM
55032017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5504
5505 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
5506 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
5507 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
5508 * gdbarch.h: Regenerate.
5509 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5510 Adjust comment.
5511 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
5512 (i386_displaced_step_fixup): Adjust comment.
5513 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
5514
a900ff72
TT
55152017-10-12 Tom Tromey <tom@tromey.com>
5516
5517 * prologue-value.h (pv_area::store_would_trash): Return bool.
5518 (pv_area::find_reg): Likewise.
5519 * prologue-value.c (pv_area::store_would_trash): Return bool.
5520 (pv_area::find_reg): Likewise.
5521
f7b7ed97
TT
55222017-10-12 Tom Tromey <tom@tromey.com>
5523
5524 * s390-linux-tdep.c (s390_store, s390_load)
5525 (s390_check_for_saved, s390_analyze_prologue): Update.
5526 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
5527 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
5528 * prologue-value.h (class pv_area): Move from prologue-value.c.
5529 Change names of members. Add constructor, destructor, member
5530 functions.
5531 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
5532 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
5533 (pv_area_fetch, pv_area_scan): Don't declare.
5534 * prologue-value.c (struct pv_area::area_entry): Now member of
5535 pv_area.
5536 (struct pv_area): Move to prologue-value.h.
5537 (pv_area::pv_area): Rename from make_pv_area.
5538 (pv_area::~pv_area): Rename from free_pv_area.
5539 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
5540 (clear_entries, find_entry, overlaps, store_would_trash, store)
5541 (fetch, find_reg, scan): Now member of pv_area.
5542 Remove "area" argument. Update.
5543 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
5544 Update.
5545 * mn10300-tdep.c (push_reg, check_for_saved)
5546 (mn10300_analyze_prologue): Update.
5547 * mep-tdep.c (is_arg_spill, check_for_saved)
5548 (mep_analyze_prologue): Update.
5549 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
5550 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
5551 (m32c_is_struct_return, m32c_analyze_prologue): Update.
5552 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
5553 Update.
5554 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
5555 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
5556
466eecee
SM
55572017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5558
5559 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
5560 * linux-nat.c (linux_nat_delete_thread): New variable.
5561 (lwp_free): Invoke linux_nat_delete_thread if set.
5562 (linux_nat_set_delete_thread): New function.
5563 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
5564 thread delete callback.
5565 * arm-linux-nat.c (arm_linux_delete_thread): New function.
5566 (_initialize_arm_linux_nat): Assign thread delete callback.
5567 * s390-linux-nat.c (s390_delete_thread): New function.
5568 (_initialize_s390_nat): Assign thread delete callback.
5569 * x86-linux-nat.c (x86_linux_add_target): Likewise.
5570 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
5571 function.
5572 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
5573 declaration.
5574 * nat/x86-linux.c (x86_linux_delete_thread): New function.
5575 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
5576
f71c8822
TT
55772017-10-09 Tom Tromey <tom@tromey.com>
5578
5579 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
5580 std::string.
5581 * tui/tui-layout.c (enum tui_status): Use std::string.
5582
981a3fb3
TT
55832017-10-11 Tom Tromey <tom@tromey.com>
5584
5585 * gdbthread.h (thread_command): Constify.
5586 * inferior.h (detach_command): Constify.
5587 * top.h (set_history, show_history): Constify.
5588 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
5589 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
5590 * bsd-kvm.c (bsd_kvm_cmd): Constify.
5591 * printcmd.c (set_command): Constify.
5592 (non_const_set_command): New function.
5593 * dcache.c (set_dcache_command, show_dcache_command): Constify.
5594 * breakpoint.c (enable_command, disable_command, delete_command)
5595 (catch_command, tcatch_command, set_breakpoint_cmd)
5596 (show_breakpoint_cmd): Constify.
5597 * macrocmd.c (macro_command): Constify.
5598 * infcmd.c (unset_command, kill_command, detach_command)
5599 (info_proc_cmd): Constify.
5600 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
5601 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
5602 (info_auto_load_cmd): Constify.
5603 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5604 (unset_tdesc_cmd): Constify.
5605 * ada-lang.c (set_ada_command, show_ada_command)
5606 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
5607 * guile/guile.c (set_guile_command, show_guile_command)
5608 (info_guile_command): Constify.
5609 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
5610 Constify.
5611 * skip.c (skip_command): Constify.
5612 * compile/compile.c (_initialize_compile): Constify.
5613 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
5614 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5615 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5616 (maint_btrace_pt_show_cmd): Constify.
5617 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
5618 Constify.
5619 * python/python.c (user_show_python, user_set_python): Constify.
5620 * mips-tdep.c (set_mips_command, show_mips_command)
5621 (set_mipsfpu_command): Constify.
5622 * record-btrace.c (cmd_record_btrace_start)
5623 (cmd_set_record_btrace, cmd_show_record_btrace)
5624 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
5625 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
5626 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
5627 Constify.
5628 * symfile.c (overlay_command): Constify.
5629 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
5630 * cli/cli-logging.c (set_logging_command, show_logging_command):
5631 Constify.
5632 * cli/cli-dump.c (dump_command, append_command)
5633 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5634 (tekhex_dump_command, binary_dump_command)
5635 (binary_append_command): Constify.
5636 * cli/cli-decode.c (struct cmd_list_element): Change type of
5637 "fun".
5638 * cli/cli-cmds.c (info_command, show_command, set_debug)
5639 (show_debug): Constify.
5640 (show_command): Add non-const overload.
5641 * top.c (set_history, show_history): Constify.
5642 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
5643 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
5644 * target.c (target_command): Constify.
5645 * sparc64-tdep.c (info_adi_command): Constify.
5646 * record-full.c (cmd_record_full_start): Constify.
5647 (set_record_full_command): Constify. Fix typo.
5648 (show_record_full_command): Constify.
5649 * thread.c (thread_command, thread_apply_command): Constify.
5650 * memattr.c (dummy_cmd): Constify.
5651 * value.c (function_command): Constify.
5652 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
5653 * probe.c (info_probes_command): Constify.
5654 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5655 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5656 (show_thread_cmd, set_thread_default_cmd)
5657 (show_thread_default_cmd): Constify.
5658 (check_empty): Constify.
5659 * tracepoint.c (tfind_command): Constify.
5660 * cp-support.c (maint_cplus_command): Constify.
5661 * windows-tdep.c (info_w32_command): Constify.
5662 * record.c (cmd_record_start, set_record_command)
5663 (show_record_command, info_record_command, cmd_record_goto):
5664 Constify.
5665 * ravenscar-thread.c (set_ravenscar_command)
5666 (show_ravenscar_command): Constify.
5667 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5668 Constify.
5669 (add_internal_problem_command): Remove casts.
5670 * arc-tdep.c (maintenance_print_arc_command): Constify.
5671 * valprint.c (set_print, show_print, set_print_raw)
5672 (show_print_raw): Constify.
5673 * maint.c (maintenance_command, maintenance_info_command)
5674 (maintenance_print_command, maintenance_set_cmd)
5675 (maintenance_show_cmd, set_per_command_cmd)
5676 (show_per_command_cmd, maintenance_check_command): Constify.
5677 * language.c (set_check, show_check): Constify.
5678 * typeprint.c (show_print_type, set_print_type): Constify.
5679 * go32-nat.c (go32_info_dos_command): Constify.
5680
fdf44873
TT
56812017-10-11 Tom Tromey <tom@tromey.com>
5682
5683 * breakpoint.c (prepare_re_set_context): Remove.
5684 (breakpoint_re_set_one): Update. Don't use cleanups.
5685 (breakpoint_re_set): Use scoped_restore, std::string, and
5686 scoped_restore_current_language.
5687
81b1e71c
TT
56882017-10-11 Tom Tromey <tom@tromey.com>
5689
5690 * breakpoint.c (commands_command_1): Use std::string.
5691 (cleanup_executing_breakpoints): Remove.
5692 (bpstat_do_actions_1): Use scoped_restore.
5693 (bpstat_check_watchpoint): Use std::string.
5694 (decode_static_tracepoint_spec): Likewise.
5695 (break_range_command): Likewise.
5696 (watch_command_1): Likewise.
5697 (compare_breakpoints): Change argument types.
5698 (clear_command): Use std::vector.
5699 (cleanup_executing_breakpoints): Remove.
5700 (update_global_location_list): Use unique_xmalloc_ptr.
5701 (strace_command): Remove unused declaration.
5702
4f9d9906
JB
57032017-10-11 John Baldwin <jhb@FreeBSD.org>
5704
5705 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5706 * NEWS: Mention new FreeBSD/arm native configuration.
5707 * configure.host: Add arm*-*-freebsd*.
5708 * configure.nat: Likewise.
5709 * arm-fbsd-nat.c: New file.
5710
7176dfd2
JB
57112017-10-11 John Baldwin <jhb@FreeBSD.org>
5712
5713 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5714 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5715 * NEWS: Mention new FreeBSD/arm target.
5716 * configure.tgt: Add arm*-*-freebsd*.
5717 * arm-fbsd-tdep.c: New file.
5718 * arm-fbsd-tdep.h: New file.
5719
fe220226
MR
57202017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5721
5722 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5723 `gdbarch_elfcore_write_linux_prpsinfo'.
5724 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5725 method.
5726 (elf_internal_linux_prpsinfo): Remove declaration.
5727 * gdbarch.h: Regenerate.
5728 * gdbarch.c: Regenerate.
5729
a2f63b2e
MR
57302017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5731
5732 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5733 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5734
458ca1d0
PA
57352017-10-11 Pedro Alves <palves@redhat.com>
5736
5737 * breakpoint.c (reattach_breakpoints): Delete.
5738 * breakpoint.h (reattach_breakpoints): Delete.
5739
905014d7
SM
57402017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5741
5742 * symfile.c (registered_sym_fns): Make struct, not typedef.
5743 (DEF_VEC_O (registered_sym_fns)): Remove.
5744 (symtab_fns): Change type to std::vector.
5745 (add_symtab_fns): Adjust.
5746 (find_sym_fns): Adjust.
5747
56d704da
AK
57482017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5749
5750 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5751 * arc-tdep.h (arc_arch_is_em): New function.
5752 (arc_arch_is_hs): Likewise.
5753
7fa29be9
EB
57542017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5755
5756 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5757 parentheses in the declaration.
5758 (macro_lookup_inclusion): Likewise.
5759 (macro_lookup_definition): Likewise.
5760 * p-lang.h (pascal_builtin_types): Likewise.
5761 * tui/tui-data.c (tui_win_list): Likewise.
5762 * tui/tui-data.h (tui_win_list): Likewise.
5763 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5764
d9b477e3
KB
57652017-10-11 Mark Rages <markrages@gmail.com>
5766
5767 * target-memory.c (block_boundaries): Fix for block address not
5768 aligned on block size.
5769
65630365
PA
57702017-10-10 Pedro Alves <palves@redhat.com>
5771 Tom Tromey <tom@tromey.com>
5772
5773 * breakpoint.c (struct captured_breakpoint_query_args)
5774 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5775 (print_breakpoint): New.
5776 * breakpoint.h (print_breakpoint): Declare.
5777 * common/common-exceptions.h (enum return_reason): Remove
5778 references to catch_exceptions.
5779 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5780 Delete.
5781 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5782 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5783 * gdb.h: Delete.
5784 * gdbthread.h (thread_select): Declare.
5785 * mi/mi-cmd-break.c: Don't include gdb.h.
5786 (breakpoint_notify): Use print_breakpoint.
5787 * mi/mi-cmd-catch.c: Don't include gdb.h.
5788 * mi/mi-interp.c: Don't include gdb.h.
5789 (mi_print_breakpoint_for_event): New.
5790 (mi_breakpoint_created, mi_breakpoint_modified): Use
5791 mi_print_breakpoint_for_event.
5792 * mi/mi-main.c: Don't include gdb.h.
5793 (mi_cmd_thread_select): Parse the global thread ID here. Use
5794 thread_select instead of gdb_thread_select.
5795 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5796 of using gdb_list_thread_ids.
5797 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5798 FILEIO_ENOSYS here.
5799 (remote_fileio_request): Use TRY/CATCH instead of
5800 catch_exceptions.
5801 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5802 (symbol_file_add_from_memory_wrapper): Delete.
5803 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5804 * thread.c: Don't include gdb.h.
5805 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5806 (thread_alive): Use thread_select.
5807 (do_captured_thread_select): Delete, parts salvaged as ...
5808 (thread_select): ... this new function.
5809 (gdb_thread_select): Delete.
5810
bf469271
PA
58112017-10-10 Pedro Alves <palves@redhat.com>
5812 Tom Tromey <tom@tromey.com>
5813
5814 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5815 and reverse logic.
5816 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5817 No longer macros. Instead ...
5818 (enum wp_check_result): They're now values of this new
5819 enumeration.
5820 (watchpoint_check): Change return type to wp_check_result and
5821 parameter type to bpstat.
5822 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5823 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5824 catch_errors. Reverse logic of watchpoint_check call.
5825 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5826 pointer as parameter.
5827 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5828 * common/common-exceptions.c (throw_exception_sjlj): Update
5829 comments to avoid mentioning catch_errors.
5830 * exceptions.c (catch_errors): Delete.
5831 * exceptions.h: Update comments to avoid mentioning catch_errors.
5832 (catch_errors_ftype, catch_errors): Delete.
5833 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5834 (hook_stop_stub): Delete.
5835 (restore_selected_frame): Change return type to void, and
5836 parameter type to const frame_id &.
5837 (restore_infcall_control_state): Use TRY/CATCH instead of
5838 catch_errors.
5839 * main.c (captured_command_loop): Return void and remove
5840 parameter. Remove references to catch_errors.
5841 (captured_main): Use TRY/CATCH instead of catch_errors.
5842 * objc-lang.c (objc_submethod_helper_data)
5843 (find_objc_msgcall_submethod_helper): Delete.
5844 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5845 catch_errors.
5846 * record-full.c (record_full_message): Return void.
5847 (record_full_message_args, record_full_message_wrapper): Delete.
5848 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5849 instead of catch_errors.
5850 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5851 parameter type to int.
5852 * solib-darwin.c (open_symbol_file_object): Ditto.
5853 * solib-dsbt.c (open_symbol_file_object): Ditto.
5854 * solib-frv.c (open_symbol_file_object): Ditto.
5855 * solib-svr4.c (open_symbol_file_object): Ditto.
5856 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5857 * solib.c (update_solib_list): Use TRY/CATCH instead of
5858 catch_errors.
5859 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5860 Change type.
5861 * symmisc.c (struct print_symbol_args): Remove.
5862 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5863 (print_symbol): Change type.
5864 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5865 and remove parameters.
5866 (catch_errors): New.
5867 (get_windows_debug_event): Adjust.
5868
1a56bfa5
TT
58692017-10-09 Tom Tromey <tom@tromey.com>
5870
5871 * mi/mi-main.c (free_splay_tree): Remove.
5872 (list_available_thread_groups): Use splay_tree_up.
5873 * common/gdb_splay_tree.h: New file.
5874
0c478e2d
TT
58752017-10-09 Tom Tromey <tom@tromey.com>
5876
5877 * mi/mi-main.c (do_nothing): Remove.
5878 (list_available_thread_groups): Update.
5879
cbd2b4e3
PA
58802017-10-09 Pedro Alves <palves@redhat.com>
5881
5882 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5883 reading registers when switching context.
5884
a181c0bf
JB
58852017-10-09 John Baldwin <jhb@FreeBSD.org>
5886
5887 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5888 (fbsd_convert_siginfo): Likewise.
5889 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5890
6e66f753
SM
58912017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5892
5893 * configure.ac (try_guile_versions): Remove guile-2.2.
5894 * configure: Regenerate.
5895
890e9790
TT
58962017-10-09 Tom Tromey <tom@tromey.com>
5897
5898 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5899 (COMPILE.pre): Use $(CXX).
5900
109483d9
PA
59012017-10-09 Pedro Alves <palves@redhat.com>
5902
5903 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5904 Use bool.
5905 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5906 * cp-support.h (cp_remove_params): Now returns a
5907 gdb::unique_xmalloc_ptr.
5908 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5909 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5910 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5911 returning a gdb::unique_xmalloc_ptr.
5912 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5913 * stack.c (find_frame_funname): Adjust to cp_remove_params
5914 returning a gdb::unique_xmalloc_ptr.
5915
791afaa2
TT
59162017-10-08 Tom Tromey <tom@tromey.com>
5917
5918 * dwarf2read.c (dwarf2_get_dwz_file): Use
5919 gdb::unique_xmalloc_ptr.
5920 (find_slot_in_mapped_hash): Likewise.
5921 (dwarf2_physname): Likewise.
5922 (create_dwo_unit_in_dwp_v1): Use std::string.
5923 (create_dwo_unit_in_dwp_v2): Likewise.
5924 (lookup_dwo_cutu): Likewise.
5925 (inherit_abstract_dies): Use std::vector.
5926 (read_array_type): Likewise.
5927 (dwarf_decode_macros): Remove unused declaration.
5928 (unsigned_int_compar): Remove.
5929 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5930 (psymtabs_addrmap_cleanup): Remove.
5931
30a9c02f
TT
59322017-10-08 Tom Tromey <tom@tromey.com>
5933
5934 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5935 * frame.h (frame_cleanup_after_sniffer): Declare.
5936 (frame_prepare_for_sniffer): Return void.
5937 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5938 type of argument.
5939 (frame_prepare_for_sniffer): Return void.
5940
757325a3
TT
59412017-10-08 Tom Tromey <tom@tromey.com>
5942
5943 * utils.h (make_cleanup_value_free): Remove.
5944 * utils.c (do_value_free, struct cleanup): Remove.
5945 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5946 Use gdb_value_up.
5947 * value.h (struct value_deleter): New.
5948 (gdb_value_up): New typedef.
5949
b9c04fb2
TT
59502017-10-08 Tom Tromey <tom@tromey.com>
5951
5952 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5953 (make_cleanup_free_search_symbols): Remove.
5954 (search_symbols): Return std::vector.
5955 (symbol_search::compare_search_syms): Now member of
5956 symbol_search. Change arguments.
5957 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5958 (symtab_symbol_info, rbreak_command): Update.
5959 * symtab.h (struct symbol_search) <next>: Remove.
5960 Add constructors.
5961 (symbol_search::operator<): New function.
5962 (symbol_search::operator==): New function.
5963 (search_symbols): Remove std::vector.
5964 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5965 (symbol_search::compare_search_syms): Declare.
5966
0d28b0a5
YQ
59672017-10-06 Yao Qi <yao.qi@linaro.org>
5968
5969 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5970 arch/aarch64-insn.o.
5971 Remove one rule.
5972 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5973
71917808
YQ
59742017-10-06 Yao Qi <yao.qi@linaro.org>
5975
5976 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5977 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5978 arch/arm-linux.o respectively.
5979 * configure.tgt: Likewise.
5980
2081b2b2
YQ
59812017-10-06 Yao Qi <yao.qi@linaro.org>
5982
5983 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5984 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5985
a1b85d28
PA
59862017-10-06 Pedro Alves <palves@redhat.com>
5987
5988 * windows-nat.c: Include <algorithm>.
5989
d97987e2
YQ
59902017-10-06 Yao Qi <yao.qi@linaro.org>
5991
5992 * configure.tgt (i386_tobjs): New variable.
5993 (amd64_tobjs): New variable.
5994 Set $cpu_obs and $os_obs.
5995
f38307f5
YQ
59962017-10-06 Yao Qi <yao.qi@linaro.org>
5997
5998 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5999 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
6000 (clean): Remove object files and dependency files.
6001 (distclean): Remove the directory.
6002 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6003 * configure: Re-generated.
6004 * configure.tgt: Replace amd64.o with arch/amd64.o.
6005
2f924de6
JM
60062017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
6007
6008 PR build/22188
6009 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
6010 and SETEND.
6011
2fd9d7ca
PA
60122017-10-05 Pedro Alves <palves@redhat.com>
6013
6014 * linux-nat.c (linux_child_follow_fork): When following the parent
6015 and detaching the child, consult the parent thread's architecture
6016 instead of the child's.
6017
d13b8493
UW
60182017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
6019
6020 * ax.h: Do not include "doublest.h".
6021 (union agent_val): Remove.
6022
3b4b2f16
UW
60232017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
6024
6025 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
6026 (decimal_to_string): Return std::string object.
6027 (decimal_from_string): Accept std::string object. Return bool.
6028 (decimal_from_integral, decimal_from_doublest): Remove.
6029 (decimal_from_longest): Add prototype.
6030 (decimal_from_ulongest): Likewise.
6031 (decimal_to_longest): Likewise.
6032 (decimal_from_doublest): Likewise.
6033 * dfp.c: Do not include "gdbtypes.h" or "value.h".
6034 (MAX_DECIMAL_STRING): Move here.
6035 (decimal_to_string): Return std::string object.
6036 (decimal_from_string): Accept std::string object. Return bool.
6037 (decimal_from_integral): Remove, replace by ...
6038 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
6039 (decimal_to_longest): New function.
6040 (decimal_from_floating): Remove, replace by ...
6041 (decimal_from_doublest): ... this new function.
6042 (decimal_to_doublest): Update to new decimal_to_string interface.
6043
6044 * value.c (unpack_long): Use decimal_to_longest.
6045 * valops.c (value_cast): Use decimal_from_doublest instead of
6046 decimal_from_floating. Use decimal_from_[u]longest isntead of
6047 decimal_from_integral.
6048 * valarith.c (value_args_as_decimal): Likewise.
6049 * valprint.c (print_decimal_floating): Update to new
6050 decimal_to_string interface.
6051 * printcmd.c (printf_decfloat): Likewise.
6052 * c-exp.y (parse_number): Update to new decimal_from_string interface.
6053
1841ee5d
UW
60542017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
6055
6056 * doublest.h: Do not include "floatformat.h". Remove stale comments.
6057 * gdbtypes.c: Include "floatformat.h".
6058 * value.c: Likewise.
6059 * m68k-tdep.c: Likewise.
6060
6061 * findvar.c: Do not include "floatformat.h".
6062 * amd64-darwin-tdep.c: Likewise.
6063 * arm-linux-tdep.c: Likewise.
6064 * i386-darwin-tdep.c: Likewise.
6065 * i387-tdep.c: Likewise.
6066 * m68k-linux-tdep.c: Likewise.
6067 * mep-tdep.c: Likewise.
6068 * mips-tdep.c: Likewise.
6069 * nios2-tdep.c: Likewise.
6070 * s390-linux-tdep.c: Likewise.
6071 * sparc-obsd-tdep.c: Likewise.
6072 * sparc-tdep.c: Likewise.
6073 * sparc64-tdep.c: Likewise.
6074 * spu-tdep.c: Likewise.
6075 * tic6x-tdep.c: Likewise.
6076 * tilegx-tdep.c: Likewise.
6077 * vax-tdep.c: Likewise.
6078 * xstormy16-tdep.c: Likewise.
6079 * xtensa-tdep.c: Likewise.
6080
6081 * top.c: Do not include "doublest.h".
6082 * aarch64-tdep.c: Likewise.
6083 * alpha-tdep.c: Likewise.
6084 * arm-linux-tdep.c: Likewise.
6085 * m68k-linux-tdep.c: Likewise.
6086 * tilegx-tdep.c: Likewise.
6087 * xstormy16-tdep.c: Likewise.
6088
a80a6471
JB
60892017-10-05 John Baldwin <jhb@FreeBSD.org>
6090
6091 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
6092 (mipsn32_fbsd_sigframe): Define.
6093 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
6094 for FreeBSD/mipsn32.
6095
12c4bd7f
JB
60962017-10-05 John Baldwin <jhb@FreeBSD.org>
6097
6098 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
6099 AT_HWCAP.
6100
c91933e9
TG
61012017-10-05 Tristan Gingold <tgingold@free.fr>
6102
6103 * MAINTAINERS (Misc): Update my email address.
6104
5cd63fda
PA
61052017-10-04 Pedro Alves <palves@redhat.com>
6106
6107 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
6108 it instead of target_gdbarch.
6109 (get_remote_state, get_remote_packet_size): Adjust
6110 get_remote_arch_state calls, passing down target_gdbarch
6111 explicitly.
6112 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
6113 'gdbarch' and use it instead of target_gdbarch.
6114 (get_memory_packet_size): Adjust get_remote_arch_state calls,
6115 passing down target_gdbarch explicitly.
6116 (struct stop_reply) <arch>: New field.
6117 (remote_parse_stop_reply): Use the stopped thread's architecture,
6118 not the current inferior's. Save the architecture in the
6119 stop_reply.
6120 (process_stop_reply): Use the stop reply's architecture.
6121 (process_g_packet, remote_fetch_registers)
6122 (remote_prepare_to_store, store_registers_using_G)
6123 (remote_store_registers): Adjust get_remote_arch_state calls,
6124 using the regcache's architecture.
6125 (remote_get_trace_status): Adjust get_remote_arch_state calls,
6126 passing down target_gdbarch explicitly.
6127 * spu-multiarch.c (spu_thread_architecture): Defer to the target
6128 beneath instead of calling target_gdbarch.
6129 * target.c (default_thread_architecture): Use the specified
6130 inferior's architecture, instead of the current inferior's
6131 architecture (via target_gdbarch).
6132
ed4227b7
PA
61332017-10-04 Pedro Alves <palves@redhat.com>
6134
6135 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
6136 case.
6137 (regcache_print): Handle !target_has_registers here instead.
6138
55b11ddf
PA
61392017-10-04 Pedro Alves <palves@redhat.com>
6140
6141 * frame.c (create_test_frame): Delete.
6142 * frame.h (create_test_frame): Delete.
6143 * gdbarch-selftests.c: Include gdbthread.h and target.h.
6144 (class regcache_test): Delete.
6145 (test_target_has_registers, test_target_has_stack)
6146 (test_target_has_memory, test_target_prepare_to_store)
6147 (test_target_store_registers): New functions.
6148 (test_target_ops): New class.
6149 (register_to_value_test): Error out if there's already a
6150 process_stratum (or higher) target pushed. Create a fuller mock
6151 environment, with mock target_ops, inferior, address space, thread
6152 and inferior_ptid.
6153 * progspace.c (struct address_space): Move to ...
6154 * progspace.h (struct address_space): ... here.
6155 * regcache.h (regcache::~regcache, regcache::raw_write)
6156 [GDB_SELF_TEST]: No longer virtual.
6157
4c71c105
SM
61582017-10-04 Simon Marchi <simon.marchi@ericsson.com>
6159
6160 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
6161
73dcd72d
PA
61622017-10-04 Pedro Alves <palves@redhat.com>
6163
6164 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
6165 out of 'between TRY and CATCH'.
6166
44704526
PA
61672017-10-04 Pedro Alves <palves@redhat.com>
6168
6169 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
6170 * common/common-exceptions.h (TRY): Open an outermost scope.
6171 Expand intro comment.
6172 (CATCH): Reindent.
6173 (END_CATCH): Close the outermost scope.
6174 * completer.c (complete_line_internal): Add missing END_CATCH.
6175
bc3b087d
SDJ
61762017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6177
6178 * NEWS (Changes since GDB 8.0): Add entry about new
6179 'set-cwd-on-gdbserver' feature.
6180 (New remote packets): Add entry for QSetWorkingDir.
6181 * common/common-inferior.h (set_inferior_cwd): New prototype.
6182 * infcmd.c (set_inferior_cwd): Remove "static".
6183 (show_cwd_command): Expand text to include remote debugging.
6184 * remote.c: Add PACKET_QSetWorkingDir.
6185 (remote_protocol_features) <QSetWorkingDir>: New entry for
6186 PACKET_QSetWorkingDir.
6187 (extended_remote_set_inferior_cwd): New function.
6188 (extended_remote_create_inferior): Call
6189 "extended_remote_set_inferior_cwd".
6190 (_initialize_remote): Call "add_packet_config_cmd" for
6191 QSetWorkingDir.
6192
d092c5a2
SDJ
61932017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6194
6195 * NEWS (New commands): Mention "set/show cwd".
6196 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
6197 "cd" command's help text.
6198 * common/common-inferior.h (get_inferior_cwd): New prototype.
6199 * infcmd.c (inferior_cwd_scratch): New global variable.
6200 (set_inferior_cwd): New function.
6201 (get_inferior_cwd): Likewise.
6202 (set_cwd_command): Likewise.
6203 (show_cwd_command): Likewise.
6204 (_initialize_infcmd): Add "set/show cwd" commands.
6205 * inferior.h (class inferior) <cwd>: New field.
6206 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
6207 (fork_inferior): Change inferior's cwd before its execution.
6208 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
6209 to CreateProcess.
6210
7da0a886
SDJ
62112017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6212
6213 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
6214 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
6215 (COMMON_OBS): Add gdb_tilde_expand.o.
6216 * common/gdb_tilde_expand.c: New file.
6217 * common/gdb_tilde_expand.h: Likewise.
6218
db8dd160
MR
62192017-10-03 Maciej W. Rozycki <macro@imgtec.com>
6220
6221 * gdbarch.sh (objfile): Remove duplicate declaration.
6222 * gdbarch.h: Regenerate.
6223
f8bfbf22
TT
62242017-10-03 Tom Tromey <tom@tromey.com>
6225
6226 * utils.c (internal_vproblem): Use string_vprintf.
6227
5178ed48
TT
62282017-10-03 Tom Tromey <tom@tromey.com>
6229
6230 * printcmd.c (info_symbol_command): Use std::string.
6231
8cff8730
TT
62322017-10-03 Tom Tromey <tom@tromey.com>
6233
6234 * top.c (gdb_safe_append_history): Use std::string.
6235
895b8f30
TT
62362017-10-03 Tom Tromey <tom@tromey.com>
6237
6238 * event-top.c (stdin_event_handler): Update.
6239 * main.c (captured_main_1): Update.
6240 * top.h (make_delete_ui_cleanup): Remove.
6241 (struct ui): Add constructor and destructor.
6242 (new_ui, delete_ui): Remove.
6243 * top.c (make_delete_ui_cleanup): Remove.
6244 (new_ui_command): Use std::unique_ptr.
6245 (delete_ui_cleanup): Remove.
6246 (ui::ui): Rename from new_ui. Update.
6247 (free_ui): Remove.
6248 (ui::~ui): Rename from delete_ui. Update.
6249
0efef640
TT
62502017-10-03 Tom Tromey <tom@tromey.com>
6251
6252 * symfile.c (load_progress): Use gdb::byte_vector.
6253
245ad7d3
TT
62542017-10-03 Tom Tromey <tom@tromey.com>
6255
6256 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
6257 declaration.
6258 * printcmd.c (x_command): Remove unused declaration.
6259 * symfile.c (symbol_file_command): Remove unused declaration.
6260
e05550d7
TT
62612017-10-03 Tom Tromey <tom@tromey.com>
6262
6263 * utils.c (internal_vproblem): Use std::string.
6264 (defaulted_query): Likewise.
6265
b95de2b7
TT
62662017-10-03 Tom Tromey <tom@tromey.com>
6267
6268 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
6269 * top.c (execute_command_to_string): Update.
6270 * utils.c (make_cleanup_restore_page_info): Remove.
6271 (do_restore_page_info_cleanup): Remove.
6272 (set_batch_flag_and_restore_page_info):
6273 New.
6274 (make_cleanup_restore_page_info): Remove.
6275 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6276 (~set_batch_flag_and_restore_page_info): New
6277 (make_cleanup_restore_uinteger): Remove.
6278 (make_cleanup_restore_integer): Remove.
6279 (struct restore_integer_closure): Remove.
6280 (restore_integer): Remove.
6281 * utils.h (struct set_batch_flag_and_restore_page_info): New
6282 class.
6283 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
6284 (make_cleanup_restore_page_info): Remove.
6285 (make_cleanup_restore_uinteger) Remove.
6286 (make_cleanup_restore_integer) Remove.
6287
07036511
TT
62882017-10-03 Tom Tromey <tom@tromey.com>
6289
6290 * record-full.h (record_full_gdb_operation_disable_set): Return
6291 scoped_restore_tmpl<int>.
6292 * infrun.c (adjust_pc_after_break): Update.
6293 (handle_signal_stop): Update.
6294 * record-full.c (record_full_gdb_operation_disable_set): Return
6295 scoped_restore_tmpl<int>.
6296 (record_full_wait_1, record_full_insert_breakpoint)
6297 (record_full_remove_breakpoint, record_full_save)
6298 (record_full_goto_insn): Update.
6299
45320ffa
TT
63002017-10-02 Tom Tromey <tom@tromey.com>
6301
6302 PR rust/22236:
6303 * rust-lang.c (rust_val_print_str): New function.
6304 (val_print_struct): Call it.
6305 (rust_subscript): Preserve name of slice type.
6306
b3e3859b
TT
63072017-10-02 Tom Tromey <tom@tromey.com>
6308
6309 * rust-lang.c (rust_subscript): Handle slices in
6310 EVAL_AVOID_SIDE_EFFECTS case.
6311
01af5e0d
TT
63122017-10-02 Tom Tromey <tom@tromey.com>
6313
6314 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
6315
888e3ddb
TT
63162017-10-02 Tom Tromey <tom@tromey.com>
6317
6318 * rust-lang.h (rust_slice_type): Add "extern".
6319
cc536b21
PA
63202017-10-02 Tom Tromey <tom@tromey.com>
6321 Pedro Alves <palves@redhat.com>
6322
6323 * ada-lang.h (ada_exc_info::operator<): Make const.
6324 (ada_exc_info::operator==): Make const.
6325 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
6326 Make const.
6327
386c8614
TT
63282017-09-29 Tom Tromey <tom@tromey.com>
6329
6330 * target.c (read_whatever_is_readable): Change type of "result".
6331 Update.
6332 (free_memory_read_result_vector): Remove.
6333 (read_memory_robust): Change return type. Update.
6334 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
6335 bin2hex, std::string.
6336 * target.h (memory_read_result_s): Remove typedef.
6337 (free_memory_read_result_vector): Remove.
6338 (read_memory_robust): Return std::vector.
6339
789c4b5e
TT
63402017-09-29 Tom Tromey <tom@tromey.com>
6341
6342 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
6343
ab816a27
TT
63442017-09-29 Tom Tromey <tom@tromey.com>
6345
6346 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
6347 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
6348 operator< and operator==.
6349 (ada_exceptions_list): Return a std::vector.
6350 * ada-lang.c (ada_exc_info::operator<): Rename from
6351 compare_ada_exception_info.
6352 (ada_exc_info::operator==): New.
6353 (sort_remove_dups_ada_exceptions_list): Change type of
6354 "exceptions".
6355 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
6356 (ada_add_global_exceptions): Likewise.
6357 (ada_exceptions_list_1): Return a std::vector.
6358 (ada_exceptions_list): Likewise.
6359
52f9abe4
TT
63602017-09-29 Tom Tromey <tom@tromey.com>
6361
6362 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
6363 'std::set *'.
6364 (print_one_inferior): Update.
6365 (free_vector_of_ints): Remove.
6366 (list_available_thread_groups): Change "ids" to std::set.
6367 (mi_cmd_list_thread_groups): Update.
6368 (struct collect_cores_data) <core>: Now a std::set.
6369 (collect_cores): Update.
6370 (unique): Remove.
6371 (print_one_inferior): Update.
6372
dcd5ddcc
TT
63732017-09-29 Tom Tromey <tom@tromey.com>
6374
6375 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
6376 (mi_execute_async_cli_command): Likewise.
6377 (mi_cmd_trace_frame_collected): Use field_fmt.
6378
45d288cc
TT
63792017-09-29 Tom Tromey <tom@tromey.com>
6380
6381 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
6382 gdb::byte_vector.
6383
6afe2f4a
TT
63842017-09-29 Tom Tromey <tom@tromey.com>
6385
6386 * mi/mi-parse.c (mi_parse): Remove unused declaration.
6387
9813429a
TT
63882017-09-29 Tom Tromey <tom@tromey.com>
6389
6390 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
6391
2d6960b4
TT
63922017-09-29 Tom Tromey <tom@tromey.com>
6393
6394 * varobj.h (varobj_gen_name): Return std::string.
6395 * varobj.c (varobj_gen_name): Return std::string.
6396 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
6397 (mi_cmd_var_delete): Don't copy "name".
6398
784c453a
TT
63992017-09-29 Tom Tromey <tom@tromey.com>
6400
6401 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
6402 (mi_cmd_break_insert_1): Update.
6403
a9bc57b9
TT
64042017-09-29 Tom Tromey <tom@tromey.com>
6405
6406 * target.h (make_scoped_defer_target_commit_resume): Update.
6407 * target.c (make_scoped_defer_target_commit_resume): Rename from
6408 make_cleanup_defer_target_commit_resume. Return a
6409 scoped_restore.
6410 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
6411
9754d8c4
TT
64122017-09-29 Tom Tromey <tom@tromey.com>
6413
6414 * main.c (captured_main_1): Remove unused declaration.
6415 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
6416
99ef965c
TT
64172017-09-29 Tom Tromey <tom@tromey.com>
6418
6419 * symtab.c (search_symbols): Remove unused outer cleanup.
6420 (make_source_files_completion_list): Remove unused declaration.
6421
42518ba7
TT
64222017-09-29 Tom Tromey <tom@tromey.com>
6423
6424 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
6425
726b2169
TT
64262017-09-29 Tom Tromey <tom@tromey.com>
6427
6428 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
6429 gdb::byte_vector.
6430
55b06432
TT
64312017-09-29 Tom Tromey <tom@tromey.com>
6432
6433 * complaints.c (vcomplaint): Use std::string.
6434
8abcee91
TT
64352017-09-29 Tom Tromey <tom@tromey.com>
6436
6437 * tracepoint.c (trace_variable_command): Use std::string.
6438 (encode_actions_1): Remove unused declarations.
6439 (create_tsv_from_upload): Use std::string.
6440
6ad94bc7
TT
64412017-09-29 Tom Tromey <tom@tromey.com>
6442
6443 * cp-support.c (gdb_demangle): Use std::string.
6444
2003f3d8
TT
64452017-09-29 Tom Tromey <tom@tromey.com>
6446
6447 * stack.c (parse_frame_specification): Use std::string
6448 (info_frame_command): Use gdb::unique_xmalloc_ptr.
6449
8f8accb5
TT
64502017-09-29 Tom Tromey <tom@tromey.com>
6451
6452 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
6453
200aa7b1
TT
64542017-09-29 Tom Tromey <tom@tromey.com>
6455
6456 * utils.c (vfprintf_maybe_filtered): Use std::string.
6457 (vfprintf_unfiltered): Likewise.
6458
606aae8a
TT
64592017-09-29 Tom Tromey <tom@tromey.com>
6460
6461 * event-top.c (top_level_prompt): Return std::string.
6462 (display_gdb_prompt): Update.
6463
bd413795
TT
64642017-09-29 Tom Tromey <tom@tromey.com>
6465
6466 * unittests/common-utils-selftests.c (format): New function.
6467 (string_vprintf_tests): New function.
6468 (_initialize_common_utils_selftests): Register new tests.
6469 * common/common-utils.c (string_vprintf): New function.
6470 * common/common-utils.h (string_vprintf): Declare.
6471
256642e8
PA
64722017-09-29 Pedro Alves <palves@redhat.com>
6473
6474 * common/rsp-low.c (unpack_varlen_hex): Constify.
6475 * common/rsp-low.h (unpack_varlen_hex): Constify.
6476 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6477 Constify.
6478 * remote.c (remote_set_permissions, read_ptid)
6479 (remote_current_thread, remote_get_threads_with_qthreadinfo)
6480 (remote_static_tracepoint_marker_at)
6481 (remote_static_tracepoint_markers_by_strid)
6482 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
6483 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
6484 (parse_tracepoint_definition, parse_tsv_definition)
6485 (parse_static_tracepoint_marker_definition): Constify.
6486 * tracepoint.h (parse_static_tracepoint_marker_definition)
6487 (parse_trace_status, parse_tracepoint_status)
6488 (parse_tracepoint_definition, parse_tsv_definition): Constify.
6489
b6bb3468
PA
64902017-09-29 Pedro Alves <palves@redhat.com>
6491
6492 * remote.c (target_buf, target_buf_size): Delete.
6493 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
6494 Use the connection's packet buffer instead.
6495 All callers adjusted.
6496 (_initialize_remote): Remove references to target_buf and
6497 target_buf_size.
6498
b2f8eb7a
PA
64992017-09-28 Pedro Alves <palves@redhat.com>
6500
6501 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6502 unittests/common-utils-selftests.c.
6503 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
6504 (COMMON_OBS): Remove utils-selftests.o.
6505 * utils-selftests.c: Move to ...
6506 * unittests/common-utils-selftests.c: ... here and rename self
6507 test to "string_printf".
6508
08302ed2
DE
65092017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
6510
6511 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
6512 having NULL cus or tus.
6513
96a5a1d3
UW
65142017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6515
6516 * arm-tdep.c: (convert_from_extended): Remove.
6517 (convert_to_extended): Likewise.
6518 (arm_extract_return_value): Use convert_typed_floating.
6519 (arm_store_return_value): Likewise.
6520
6521 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6522 * sh-tdep.c: Do not include "floatformat.h".
6523 (sh_littlebyte_bigword_type): New function.
6524 (sh_register_convert_to_virtual): Use convert_typed_floating.
6525 (sh_register_convert_to_raw): Likewise.
6526 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6527 (sh64_littlebyte_bigword_type): New function.
6528 (sh64_extract_return_value): Use convert_typed_floating.
6529 (sh64_register_convert_to_virtual): Likewise.
6530 (sh64_register_convert_to_raw): Likewise.
6531
0db7851f
UW
65322017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6533
6534 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
6535 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
6536
6537 * gdbtypes.h (union type_specific): Make field floatformat hold
6538 just a single struct floatformat, not an array.
6539 (floatformat_from_type): Move here.
6540 * gdbtypes.c (floatformat_from_type): Move here. Update to
6541 changed TYPE_FLOATFORMAT definition.
6542 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
6543 (recursive_dump_type): Likewise.
6544 (init_float_type): Install correct floatformat for byte order.
6545 (arch_float_type): Likewise.
6546
77b7c781
UW
65472017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6548
6549 * gdbtypes.c (init_type): Change incoming argument from
6550 length-in-bytes to length-in-bits. Assert length is a
6551 multiple of TARGET_CHAR_BITS.
6552 (arch_type, arch_flags_type): Likewise.
6553 (init_integer_type): Update call to init_type.
6554 (init_character_type): Likewise.
6555 (init_boolean_type): Likewise.
6556 (init_float_type): Likewise.
6557 (init_decfloat_type): Likewise.
6558 (init_complex_type): Likewise.
6559 (init_pointer_type): Likewise.
6560 (objfile_type): Likewise.
6561 (arch_integer_type): Update call to arch_type.
6562 (arch_character_type): Likewise.
6563 (arch_boolean_type): Likewise.
6564 (arch_float_type): Likewise.
6565 (arch_decfloat_type): Likewise.
6566 (arch_complex_type): Likewise.
6567 (arch_pointer_type): Likewise.
6568 (gdbtypes_post_init): Likewise.
6569
6570 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
6571 (read_base_type): Likewise.
6572 * mdebugread.c (basic_type): Likewise.
6573 * stabsread.c (dbx_init_float_type): Likewise.
6574 (rs6000_builtin_type): Likewise.
6575 (read_range_type): Likewise. Also, fix call to init_integer_type
6576 with erroneous length argument.
6577
6578 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
6579 * d-lang.c (build_d_types): Likewise.
6580 * f-lang.c (build_fortran_types): Likewise.
6581 * go-lang.c (build_go_types): Likewise.
6582 * opencl-lang.c (build_opencl_types): Likewise.
6583 * jit.c (finalize_symtab): Likewise.
6584 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
6585 (build_std_type_info_type): Likewise.
6586 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
6587 update call to arch_flags_type.
6588
6589 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
6590 arch_type.
6591 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
6592 * windows-tdep.c (windows_get_tlb_type): Likewise.
6593
6594 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
6595 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6596 * m32c-tdep.c (make_types): Likewise.
6597 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
6598 (rl78_psw_type): Update call to arch_flags_type.
6599 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
6600 * rx-tdep.c (rx_psw_type): Likewise.
6601 (rx_fpsw_type): Likewise.
6602 * sparc-tdep.c (sparc_psr_type): Likewise.
6603 (sparc_fsr_type): Likewise.
6604 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
6605 (sparc64_ccr_type): Likewise.
6606 (sparc64_fsr_type): Likewise.
6607 (sparc64_fprs_type): Likewise.
6608
f21b4d5c
TT
66092017-09-27 Tom Tromey <tom@tromey.com>
6610
6611 * findcmd.c (find_command): Constify.
6612
643c2ffa
TT
66132017-09-27 Tom Tromey <tom@tromey.com>
6614
6615 * ada-tasks.c (task_command_1, task_command): Constify.
6616
510e5e56
TT
66172017-09-27 Tom Tromey <tom@tromey.com>
6618
6619 * symtab.c (maintenance_print_symbol_cache)
6620 (maintenance_flush_symbol_cache)
6621 (maintenance_print_symbol_cache_statistics): Constify.
6622
e503b191
TT
66232017-09-27 Tom Tromey <tom@tromey.com>
6624
6625 * inferior.c (detach_inferior_command, kill_inferior_command)
6626 (inferior_command): Constify.
6627
4e001312
TT
66282017-09-27 Tom Tromey <tom@tromey.com>
6629
6630 * regcache.c (regcache_print, maintenance_print_registers)
6631 (maintenance_print_raw_registers)
6632 (maintenance_print_cooked_registers)
6633 (maintenance_print_register_groups)
6634 (maintenance_print_remote_registers): Constify.
6635
77763700
TT
66362017-09-27 Tom Tromey <tom@tromey.com>
6637
6638 * printcmd.c (map_display_numbers, undisplay_command)
6639 (enable_disable_display_command, enable_display_command)
6640 (disable_display_command): Constify.
6641
4495129a
TT
66422017-09-27 Tom Tromey <tom@tromey.com>
6643
6644 * breakpoint.h (delete_command): Don't declare.
6645 * breakpoint.c (delete_command, enable_once_command)
6646 (enable_count_command, enable_delete_command, breakpoint_1)
6647 (maintenance_info_breakpoints, stopin_command, stopat_command)
6648 (delete_command, delete_trace_command, save_breakpoints)
6649 (save_breakpoints_command, save_tracepoints_command): Constify.
6650
3088cf40
TT
66512017-09-27 Tom Tromey <tom@tromey.com>
6652
6653 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6654 (skip_ws, extract_identifier, macro_define_command)
6655 (macro_undef_command, macro_list_command): Constify.
6656
69f476a3
TT
66572017-09-27 Tom Tromey <tom@tromey.com>
6658
6659 * infcmd.c (environment_info, set_environment_command)
6660 (unset_environment_command, path_info, info_proc_cmd_1)
6661 (info_proc_cmd_mappings, info_proc_cmd_stat)
6662 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6663 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6664
c4a3e68e
TT
66652017-09-27 Tom Tromey <tom@tromey.com>
6666
6667 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6668 Constify.
6669
c9d31bd6
TT
66702017-09-27 Tom Tromey <tom@tromey.com>
6671
6672 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6673
1f3f85eb
TT
66742017-09-27 Tom Tromey <tom@tromey.com>
6675
6676 * demangle.c (demangle_command): Constify.
6677
9c504b5d
TT
66782017-09-27 Tom Tromey <tom@tromey.com>
6679
6680 * progspace.c (maintenance_info_program_spaces_command):
6681 Constify.
6682
6663cf91
TT
66832017-09-27 Tom Tromey <tom@tromey.com>
6684
6685 * compile/compile.c (check_raw_argument, compile_file_command)
6686 (compile_code_command, compile_print_command): Constify.
6687
34e5fa26
TT
66882017-09-27 Tom Tromey <tom@tromey.com>
6689
6690 * reggroups.c (maintenance_print_reggroups): Constify.
6691
8384c356
TT
66922017-09-27 Tom Tromey <tom@tromey.com>
6693
6694 * dwarf2read.c (save_gdb_index_command): Constify.
6695
884beb0c
TT
66962017-09-27 Tom Tromey <tom@tromey.com>
6697
6698 * stap-probe.c (info_probes_stap_command): Constify.
6699
e0b2930c
TT
67002017-09-27 Tom Tromey <tom@tromey.com>
6701
6702 * fork-child.c (unset_exec_wrapper_command): Constify.
6703
f938677d
TT
67042017-09-27 Tom Tromey <tom@tromey.com>
6705
6706 * btrace.c (get_uint, get_context_size, no_chunk)
6707 (maint_btrace_packet_history_cmd)
6708 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6709 (maint_info_btrace_cmd): Constify.
6710
8949cb87
TT
67112017-09-27 Tom Tromey <tom@tromey.com>
6712
6713 * reverse.c (delete_bookmark_command): Constify.
6714
ac88e2de
TT
67152017-09-27 Tom Tromey <tom@tromey.com>
6716
6717 * remote.c (set_memory_packet_size)
6718 (set_memory_write_packet_size, show_memory_write_packet_size)
6719 (set_memory_read_packet_size, show_memory_read_packet_size)
6720 (compare_sections_command, packet_command, remote_put_command)
6721 (remote_get_command, remote_delete_command): Constify.
6722
bd4c9dfe
TT
67232017-09-27 Tom Tromey <tom@tromey.com>
6724
6725 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6726 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6727 (set_mipsfpu_auto_command): Constify.
6728
5e93d4c6
TT
67292017-09-27 Tom Tromey <tom@tromey.com>
6730
6731 * cli/cli-cmds.h (cd_command): Constify.
6732 * cli/cli-cmds.c (cd_command): Constify.
6733
fc41a75b
TT
67342017-09-27 Tom Tromey <tom@tromey.com>
6735
6736 * thread.c (thread_name_command, thread_find_command): Constify.
6737
67810076
TT
67382017-09-27 Tom Tromey <tom@tromey.com>
6739
6740 * probe.c (enable_probes_command, disable_probes_command):
6741 Constify.
6742
1d8b34a7
TT
67432017-09-27 Tom Tromey <tom@tromey.com>
6744
6745 * symfile.c (symbol_file_command): Constify.
6746 * gdbcore.h (deprecated_file_changed_hook): Constify.
6747 * exec.c (deprecated_file_changed_hook, exec_file_command)
6748 (file_command): Constify.
6749 * defs.h (symbol_file_command): Constify.
6750
442019e1
TT
67512017-09-27 Tom Tromey <tom@tromey.com>
6752
6753 * remote-fileio.c (set_system_call_allowed)
6754 (show_system_call_allowed): Constify.
6755
2983f7cb
TT
67562017-09-27 Tom Tromey <tom@tromey.com>
6757
6758 * tracepoint.c (delete_trace_variable_command)
6759 (tfind_end_command, tfind_start_command, tfind_pc_command)
6760 (tfind_tracepoint_command, tfind_line_command)
6761 (tfind_range_command, tfind_outside_command): Constify.
6762
4fd41b24
TT
67632017-09-27 Tom Tromey <tom@tromey.com>
6764
6765 * ax-gdb.c (maint_agent_printf_command, agent_command)
6766 (agent_eval_command): Constify.
6767
f2fc3015
TT
67682017-09-27 Tom Tromey <tom@tromey.com>
6769
6770 * tracepoint.c (info_scope_command): Constify.
6771 * python/python.c (gdbpy_decode_line): Constify.
6772 * python/py-breakpoint.c (bppy_init): Constify.
6773 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6774 * location.h: (new_linespec_location)
6775 (string_to_event_location_basic, string_to_event_location):
6776 Constify.
6777 * location.c (new_linespec_location)
6778 (string_to_event_location_basic, string_to_event_location):
6779 Constify.
6780 * linespec.h (decode_line_with_current_source)
6781 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6782 * linespec.c (linespec_lex_to_end)
6783 (decode_line_with_current_source)
6784 (decode_line_with_last_displayed): Constify.
6785 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6786 Constify.
6787 * cli/cli-cmds.c (edit_command, list_command): Constify.
6788 * breakpoint.h (until_break_command, watch_command_wrapper)
6789 (awatch_command_wrapper, rwatch_command_wrapper)
6790 (init_ada_exception_breakpoint): Constify.
6791 * breakpoint.c (break_command_1, dprintf_command)
6792 (break_range_command, watch_command_wrapper)
6793 (rwatch_command_wrapper, awatch_command_wrapper)
6794 (until_break_command, init_ada_exception_breakpoint)
6795 (strace_marker_create_sals_from_location, trace_command)
6796 (ftrace_command, strace_command, struct tracepoint): Constify.
6797 * ax-gdb.c (agent_command_1): Constify.
6798 * ada-lang.c (ada_exception_sal): Constify.
6799
8c2f95f4
TT
68002017-09-27 Tom Tromey <tom@tromey.com>
6801
6802 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6803 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6804 (get_context_size, no_chunk, get_insn_history_modifiers)
6805 (cmd_record_insn_history, get_call_history_modifiers)
6806 (cmd_record_call_history): Constify.
6807
a0d65762
TT
68082017-09-27 Tom Tromey <tom@tromey.com>
6809
6810 * source.c (show_substitute_path_command)
6811 (unset_substitute_path_command, set_substitute_path_command):
6812 Constify.
6813
58971144
TT
68142017-09-27 Tom Tromey <tom@tromey.com>
6815
6816 * typeprint.c (maintenance_print_type): Constify.
6817 * maint.c (maintenance_dump_me, maintenance_demangle)
6818 (maintenance_time_display, maintenance_info_sections)
6819 (maintenance_print_statistics, maintenance_deprecate)
6820 (maintenance_undeprecate): Constify.
6821 (maintenance_do_deprecate): Constify. Use std::string.
6822 (maintenance_selftest): Constify.
6823 * gdbtypes.h (maintenance_print_type): Constify.
6824
c482f52c
TT
68252017-09-27 Tom Tromey <tom@tromey.com>
6826
6827 * hppa-tdep.c (unwind_command): Constify.
6828
e100df1a
TT
68292017-09-27 Tom Tromey <tom@tromey.com>
6830
6831 * target-descriptions.c (unset_tdesc_filename_cmd)
6832 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6833 Constify.
6834
31d56ade
TT
68352017-09-27 Tom Tromey <tom@tromey.com>
6836
6837 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6838
b961da0b
TT
68392017-09-27 Tom Tromey <tom@tromey.com>
6840
6841 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6842
e2d8ae16
TT
68432017-09-27 Tom Tromey <tom@tromey.com>
6844
6845 * tui/tui-regs.c (tui_reg_command): Constify.
6846
863779b0
TT
68472017-09-27 Tom Tromey <tom@tromey.com>
6848
6849 * skip.c (skip_file_command, skip_function_command)
6850 (skip_enable_command, skip_disable_command, skip_delete_command):
6851 Constify.
6852
cdb34d4a
TT
68532017-09-27 Tom Tromey <tom@tromey.com>
6854
6855 * record-btrace.c (cmd_record_btrace_bts_start)
6856 (cmd_record_btrace_pt_start): Constify.
6857
e99c83e7
TT
68582017-09-27 Tom Tromey <tom@tromey.com>
6859
6860 * symmisc.c (maintenance_print_symbols)
6861 (maintenance_print_msymbols, maintenance_print_objfiles)
6862 (maintenance_info_symtabs, maintenance_check_symtabs)
6863 (maintenance_expand_symtabs, maintenance_info_line_tables):
6864 Constify.
6865
32faf971
TT
68662017-09-27 Tom Tromey <tom@tromey.com>
6867
6868 * top.c (new_ui_command): Constify.
6869
2cf311eb
TT
68702017-09-27 Tom Tromey <tom@tromey.com>
6871
6872 * symfile.c (add_symbol_file_command)
6873 (remove_symbol_file_command, list_overlays_command)
6874 (map_overlay_command, unmap_overlay_command)
6875 (overlay_auto_command, overlay_manual_command)
6876 (overlay_off_command, overlay_load_command): Constify.
6877
e6738699
TT
68782017-09-27 Tom Tromey <tom@tromey.com>
6879
6880 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6881 (info_spu_mailbox_command, info_spu_dma_command)
6882 (info_spu_proxydma_command): Constify.
6883
aa360cd5
TT
68842017-09-27 Tom Tromey <tom@tromey.com>
6885
6886 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6887
898241a5
TT
68882017-09-27 Tom Tromey <tom@tromey.com>
6889
6890 * cli/cli-script.c (user_defined_command): Constify.
6891
2d0ac106
TT
68922017-09-27 Tom Tromey <tom@tromey.com>
6893
6894 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6895 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6896 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6897 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6898 (dump_binary_value, append_binary_memory, append_binary_value):
6899 Constify.
6900 (struct dump_context) <func>: Constify.
6901 (add_dump_command): Update.
6902
dede02ce
TT
69032017-09-27 Tom Tromey <tom@tromey.com>
6904
6905 * cli/cli-cmds.c (show_version, show_configuration)
6906 (source_command, show_user): Constify.
6907
d3cb6b99
TT
69082017-09-27 Tom Tromey <tom@tromey.com>
6909
6910 * target.c (maintenance_print_target_stack): Constify.
6911
1970a12f
TT
69122017-09-27 Tom Tromey <tom@tromey.com>
6913
6914 * interps.c (interpreter_exec_cmd): Constify.
6915
41243651
TT
69162017-09-27 Tom Tromey <tom@tromey.com>
6917
6918 * record-full.c (cmd_record_full_restore): Constify.
6919
4465d9db
TT
69202017-09-27 Tom Tromey <tom@tromey.com>
6921
6922 * memattr.c (enable_mem_command, disable_mem_command)
6923 (delete_mem_command): Constify.
6924
ad25e423
TT
69252017-09-27 Tom Tromey <tom@tromey.com>
6926
6927 * value.c (show_convenience): Constify.
6928
d64097b1
TT
69292017-09-27 Tom Tromey <tom@tromey.com>
6930
6931 * gdbcore.h (core_file_command): Update.
6932 * corefile.c (core_file_command): Constify.
6933
4d4589ef
TT
69342017-09-27 Tom Tromey <tom@tromey.com>
6935
6936 * user-regs.c (maintenance_print_user_registers): Constify.
6937
32a7bf17
TT
69382017-09-27 Tom Tromey <tom@tromey.com>
6939
6940 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6941
4a475551
TT
69422017-09-27 Tom Tromey <tom@tromey.com>
6943
6944 * cp-support.c (first_component_command): Constify.
6945
990b9f9f
TT
69462017-09-27 Tom Tromey <tom@tromey.com>
6947
6948 * psymtab.c (maintenance_print_psymbols)
6949 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6950 Constify.
6951
c281872e
TT
69522017-09-27 Tom Tromey <tom@tromey.com>
6953
6954 * windows-tdep.c (display_tib): Constify.
6955
5b64bf74
TT
69562017-09-27 Tom Tromey <tom@tromey.com>
6957
6958 * linux-fork.c (delete_checkpoint_command)
6959 (detach_checkpoint_command): Constify.
6960
4ada038f
TT
69612017-09-27 Tom Tromey <tom@tromey.com>
6962
6963 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6964
57f5a81b
TT
69652017-09-27 Tom Tromey <tom@tromey.com>
6966
6967 * arc-tdep.c (dump_arc_instruction_command): Constify.
6968
b0a8e6c4
TT
69692017-09-27 Tom Tromey <tom@tromey.com>
6970
6971 * valprint.c (set_radix, show_radix): Constify.
6972
8d97dc1c
TT
69732017-09-27 Tom Tromey <tom@tromey.com>
6974
6975 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6976
eb7c454d
TT
69772017-09-27 Tom Tromey <tom@tromey.com>
6978
6979 * command.h (not_just_help_class_command): Update.
6980 * cli/cli-decode.h (not_just_help_class_command): Update.
6981 * cli/cli-decode.c (not_just_help_class_command): Constify.
6982
e4e33335
TT
69832017-09-27 Tom Tromey <tom@tromey.com>
6984
6985 * gdb_bfd.c (maintenance_info_bfds): Constify.
6986
0450cc4c
TT
69872017-09-27 Tom Tromey <tom@tromey.com>
6988
6989 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6990 overloads.
6991 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6992 (do_const_cfunc): New function.
6993 (cmd_cfunc_eq): New overload.
6994 (cli_user_command_p): Check do_const_cfunc.
6995 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6996 const_cfunc.
6997 * command.h (add_cmd): Add const overload and no-function
6998 overload.
6999 (set_cmd_cfunc): Add const overload.
7000 (cmd_const_cfunc_ftype): Declare.
7001 (cmd_cfunc_eq): Add const overload.
7002 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
7003 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
7004 overload.
7005
a9bbfbd8
TT
70062017-09-27 Tom Tromey <tom@tromey.com>
7007
7008 * macroexp.c (get_next_token_for_substitution): New function.
7009 (substitute_args): Call it. Check for __VA_OPT__.
7010
5230b05a
WT
70112017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
7012 Pedro Alves <palves@redhat.com>
7013
7014 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
7015 producer_is_icc_lt_14.
7016 (producer_is_icc_lt_14): New function.
7017 (check_producer): Add code for checking version of ICC.
7018 (producer_is_icc): Move to producer.c.
7019 (read_structure_type): Restrict ICC workaround to ICC<14.
7020 * producer.c: Include selftest.h.
7021 (producer_is_icc, producer_parsing_tests, _initialize_producer):
7022 New functions.
7023 * producer.h (producer_is_icc): New declaration.
7024
b32b108a
WT
70252017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
7026
7027 * Makefile.in (SFILES): Add producer.c.
7028 (COMMON_OBS): Add producer.o
7029 * amd64-tdep.c (producer.h): Add new include.
7030 * dwarf2read.c (producer.h): Add new include.
7031 * producer.c: New file.
7032 * producer.h: New file.
7033 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
7034 producer.c.
7035 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
7036 producer.h.
7037
5007d765
MK
70382017-09-26 Matthias Klose <doko@ubuntu.com>
7039
7040 * configure.ac: Search ncursesw before ncurses.
7041 Check ncursesw/ncurses.h before ncurses/ncurses.h.
7042 * gdb_curses.h: Include <ncursesw/ncurses.h>
7043 * config.in, configure: Regenerate.
7044
281c4447
RO
70452017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7046
7047 PR gdb/22185
7048 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
7049 obsolete.
7050 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
7051 Remove i386sol2 support.
7052 * configure.nat <i386sol2>: Remove.
7053 <sol2-64>: Fold into ...
7054 <sol2>: ... this.
7055 Move common settings to default section.
7056 Add sol-thread.o.
7057 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
7058 x86_64-*-solaris2.1[0-9]*>: Rename to ...
7059 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
7060 <i[34567]86-*-solaris*>: Remove.
7061 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
7062
7063 * configure.ac: Remove wctype in libw check.
7064 (_MSE_INT_H): Don't define on Solaris 7-9.
7065 <solaris*>: Remove libthread_db.so.1 check.
7066 * configure: Regenerate.
7067 * config.in: Regenerate.
7068
7069 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
7070 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
7071 (gdb_ps_size_t): Remove.
7072 Use base types in users.
7073 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
7074
7075 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
7076
39b06c20
RO
70772017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7078
7079 PR build/22206
7080 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
7081 (adi_is_addr_mapped): Likewise.
7082 (PSR_ICC): Don't redefine.
7083 (PSR_IMPL): Likewise.
7084
6c3e20f1
TT
70852017-09-25 Tom Tromey <tom@tromey.com>
7086
7087 * regcache.c (regcache::dump): Use string_printf.
7088
b292235f
TT
70892017-09-25 Tom Tromey <tom@tromey.com>
7090
7091 * regcache.c (class regcache_invalidator): New.
7092 (struct register_to_invalidate): Remove.
7093 (make_cleanup_regcache_invalidate): Remove.
7094 (regcache::raw_write): Use regcache_invalidator.
7095
9ac86b52
TT
70962017-09-25 Tom Tromey <tom@tromey.com>
7097
7098 * spu-tdep.c (spu2ppu_sniffer): Update.
7099 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
7100 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
7101 Remove.
7102 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
7103 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
7104 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
7105 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
7106 (frame_pop): Update.
7107
c0e383c6
TT
71082017-09-25 Tom Tromey <tom@tromey.com>
7109
7110 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
7111 * regcache.h (regcache_xfree): Don't declare.
7112 * regcache.c (regcache_xfree): Remove.
7113 (do_regcache_xfree): Use delete.
7114 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
7115 * linux-fork.c (free_fork): Use delete.
7116 (fork_save_infrun_state): Likewise.
7117 * jit.c (jit_dealloc_cache): Use delete.
7118 * infrun.c (discard_infcall_suspend_state): Use delete.
7119
791199cc
TT
71202017-09-25 Tom Tromey <tom@tromey.com>
7121
7122 * regcache.h (regcache_xmalloc): Don't declare.
7123 (regcache_raw_set_cached_value): Update comment.
7124 * regcache.c (regcache_xmalloc): Remove.
7125 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
7126 * jit.c (jit_frame_sniffer): Use new.
7127 * frame.c (frame_save_as_regcache): Use new.
7128
289e23aa
AA
71292017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
7130
7131 * NEWS: Advertise support for guarded-storage registers on IBM z.
7132
1b63490c
AA
71332017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
7134
7135 * s390-linux-nat.c (have_regset_gs): New static variable.
7136 (s390_linux_fetch_inferior_registers): Handle guarded-storage
7137 control block and guarded-storage broadcast control regsets.
7138 (s390_read_description): Detect whether the target has
7139 guarded-storage support, return appropriate tdesc.
7140 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
7141 (features/s390x-gs-linux64.c): Likewise.
7142 (struct gdbarch_tdep) <have_gs>: New field.
7143 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
7144 (s390_gsbc_regset): New variables.
7145 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
7146 and s390_gsbc_regset, if applicable.
7147 (s390_core_read_description): Check whether core file was from a
7148 target with guarded-storage support; include appropriate regsets.
7149 (s390_gdbarch_init): Add registers for guarded-storage support.
7150 (_initialize_s390_tdep): Initialize new target descriptions that
7151 include registers for guarded-storage support.
7152 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
7153 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
7154 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
7155 (S390_NUM_REGS): Adjust macro definition.
7156 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
7157 (tdesc_s390x_gs_linux64): New declarations.
7158
96235dc1
AA
71592017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
7160
7161 * features/s390-gs-linux64.xml: New file.
7162 * features/s390-gs.xml: New file.
7163 * features/s390-gsbc.xml: New file.
7164 * features/s390x-gs-linux64.xml: New file.
7165 * features/Makefile (WHICH): Add s390-gs-linux64 and
7166 s390x-gs-linux64.
7167 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
7168 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
7169 * features/s390-gs-linux64.c: New generated file.
7170 * features/s390x-gs-linux64.c: New file.
7171 * regformats/s390-gs-linux64.dat: New file.
7172 * regformats/s390x-gs-linux64.dat: New file.
7173
b4a7c699
TT
71742017-09-23 Tom Tromey <tom@tromey.com>
7175
7176 * defs.h (make_cleanup_override_quit_handler): Don't declare.
7177
c2f97536
TT
71782017-09-22 Tom Tromey <tom@tromey.com>
7179
7180 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
7181 type to scoped_restore_tmpl.
7182 <scoped_input_handler>: Initialize m_quit_handler directly.
7183
43573013
SDJ
71842017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
7185
7186 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
7187 (cd_command): Likewise. Free "current_directory" before
7188 assigning to it.
7189 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
7190 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
7191 * top.c (gdb_dirbuf): Remove global declaration.
7192 * top.h (gdb_dirbuf): Likewise.
7193
6ec2e0f5
SDJ
71942017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
7195
7196 * gnulib/aclocal.m4: Regenerate.
7197 * gnulib/config.in: Regenerate.
7198 * gnulib/configure: Regenerate.
7199 * gnulib/import/Makefile.am: Regenerate.
7200 * gnulib/import/Makefile.in: Regenerate.
7201 * gnulib/import/assure.h: New file.
7202 * gnulib/import/at-func.c: Likewise
7203 * gnulib/import/chdir-long.c: New file.
7204 * gnulib/import/chdir-long.h: New file.
7205 * gnulib/import/cloexec.c: New file.
7206 * gnulib/import/cloexec.h: New file.
7207 * gnulib/import/close.c: New file.
7208 * gnulib/import/closedir.c: New file.
7209 * gnulib/import/dirent-private.h: New file.
7210 * gnulib/import/dup-safer.c: New file.
7211 * gnulib/import/dup.c: New file.
7212 * gnulib/import/dup2.c: New file.
7213 * gnulib/import/error.c: New file.
7214 * gnulib/import/error.h: New file.
7215 * gnulib/import/exitfail.c: New file.
7216 * gnulib/import/exitfail.h: New file.
7217 * gnulib/import/fchdir.c: New file.
7218 * gnulib/import/fcntl.c: New file.
7219 * gnulib/import/fcntl.in.h: New file.
7220 * gnulib/import/fd-hook.c: New file.
7221 * gnulib/import/fd-hook.h: New file.
7222 * gnulib/import/fd-safer.c: New file.
7223 * gnulib/import/fdopendir.c: New file.
7224 * gnulib/import/filename.h: New file.
7225 * gnulib/import/filenamecat-lgpl.c: New file.
7226 * gnulib/import/filenamecat.h: New file.
7227 * gnulib/import/fstat.c: New file.
7228 * gnulib/import/fstatat.c: New file.
7229 * gnulib/import/getcwd-lgpl.c: New file.
7230 * gnulib/import/getcwd.c: New file.
7231 * gnulib/import/getdtablesize.c: New file.
7232 * gnulib/import/getlogin_r.c: New file.
7233 * gnulib/import/getprogname.c: New file.
7234 * gnulib/import/getprogname.h: New file.
7235 * gnulib/import/gettext.h: New file.
7236 * gnulib/import/glob-libc.h: New file.
7237 * gnulib/import/glob.c: New file.
7238 * gnulib/import/glob.in.h: New file.
7239 * gnulib/import/intprops.h: New file.
7240 * gnulib/import/m4/chdir-long.m4: New file.
7241 * gnulib/import/m4/close.m4: New file.
7242 * gnulib/import/m4/closedir.m4: New file.
7243 * gnulib/import/m4/d-ino.m4: New file.
7244 * gnulib/import/m4/d-type.m4: New file.
7245 * gnulib/import/m4/dup.m4: New file.
7246 * gnulib/import/m4/dup2.m4: New file.
7247 * gnulib/import/m4/error.m4: New file.
7248 * gnulib/import/m4/fchdir.m4: New file.
7249 * gnulib/import/m4/fcntl.m4: New file.
7250 * gnulib/import/m4/fcntl_h.m4: New file.
7251 * gnulib/import/m4/fdopendir.m4: New file.
7252 * gnulib/import/m4/filenamecat.m4: New file.
7253 * gnulib/import/m4/fstat.m4: New file.
7254 * gnulib/import/m4/fstatat.m4: New file.
7255 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
7256 * gnulib/import/m4/getcwd-path-max.m4: New file.
7257 * gnulib/import/m4/getcwd.m4: New file.
7258 * gnulib/import/m4/getdtablesize.m4: New file.
7259 * gnulib/import/m4/getlogin_r.m4: New file.
7260 * gnulib/import/m4/getprogname.m4: New file.
7261 * gnulib/import/m4/glob.m4: New file.
7262 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7263 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7264 * gnulib/import/m4/mempcpy.m4: New file.
7265 * gnulib/import/m4/memrchr.m4: New file.
7266 * gnulib/import/m4/mode_t.m4: New file.
7267 * gnulib/import/m4/msvc-inval.m4: New file.
7268 * gnulib/import/m4/msvc-nothrow.m4: New file.
7269 * gnulib/import/m4/open.m4: New file.
7270 * gnulib/import/m4/openat.m4: New file.
7271 * gnulib/import/m4/opendir.m4: New file.
7272 * gnulib/import/m4/readdir.m4: New file.
7273 * gnulib/import/m4/realloc.m4: New file.
7274 * gnulib/import/m4/rewinddir.m4: New file.
7275 * gnulib/import/m4/save-cwd.m4: New file.
7276 * gnulib/import/m4/strdup.m4: New file.
7277 * gnulib/import/m4/strerror.m4: New file.
7278 * gnulib/import/m4/unistd-safer.m4: New file.
7279 * gnulib/import/mempcpy.c: New file.
7280 * gnulib/import/memrchr.c: New file.
7281 * gnulib/import/msvc-inval.c: New file.
7282 * gnulib/import/msvc-inval.h: New file.
7283 * gnulib/import/msvc-nothrow.c: New file.
7284 * gnulib/import/msvc-nothrow.h: New file.
7285 * gnulib/import/open.c: New file.
7286 * gnulib/import/openat-die.c: New file.
7287 * gnulib/import/openat-priv.h: New file.
7288 * gnulib/import/openat-proc.c: New file.
7289 * gnulib/import/openat.c: New file.
7290 * gnulib/import/openat.h: New file.
7291 * gnulib/import/opendir.c: New file.
7292 * gnulib/import/pipe-safer.c: New file.
7293 * gnulib/import/readdir.c: New file.
7294 * gnulib/import/realloc.c: New file.
7295 * gnulib/import/rewinddir.c: New file.
7296 * gnulib/import/save-cwd.c: New file.
7297 * gnulib/import/save-cwd.h: New file.
7298 * gnulib/import/strdup.c: New file.
7299 * gnulib/import/strerror-override.c: New file.
7300 * gnulib/import/strerror-override.h: New file.
7301 * gnulib/import/strerror.c: New file.
7302 * gnulib/import/unistd--.h: New file.
7303 * gnulib/import/unistd-safer.h: New file.
7304 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
7305 "getcwd" and "glob".
7306 * ser-tcp.c: Undefine "close" before redefining it.
7307
432ae719
SM
73082017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7309
7310 * guile/scm-value.c (gdbscm_value_address): Initialize address,
7311 get rid of res_val.
7312
4fa7574e
RO
73132017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7314
7315 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
7316 <sol2,sparc>: Likewise.
7317 <sol2-64,i386>: Likewise.
7318
7319 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
7320 -Wdeprecated-declarations on *-*-solaris*.
7321 * configure: Regenerate.
7322
7323 * procfs.c: Include "nat/inferior.h".
7324 (procfs_info_proc): Fix typo.
7325
f6327dcb
KB
73262017-09-21 Kevin Buettner <kevinb@redhat.com>
7327
7328 * remote.c (vector): Include.
7329 (struct private_thread_info): Add field, thread_handle.
7330 (free_private_thread_info): Deallocate storage associated with
7331 thread handle.
7332 (get_private_info_thread): Initialize `thread_handle' field.
7333 (struct thread_item): Add field, thread_handle.
7334 (clear_threads_listing_context): Deallocate storage associated
7335 with thread handle.
7336 (start_thread): Add support for "handle" attribute.
7337 (thread_attributes): Add "handle".
7338 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
7339 field.
7340 (remote_update_thread_list): Update thread_handle.
7341 (remote_thread_handle_to_thread_info): New function.
7342 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
7343
fbbe5337
KB
73442017-09-21 Kevin Buettner <kevinb@redhat.com>
7345
7346 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
7347 function.
7348 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
7349 * python/python-internal.h (thread_object_type): Declare.
7350
e04ee09e
KB
73512017-09-21 Kevin Buettner <kevinb@redhat.com>
7352
7353 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
7354 (target_thread_handle_to_thread_info): Declare.
7355 * target.c (target_thread_handle_to_thread_info): New function.
7356 * target-delegates.c: Regenerate.
7357 * gdbthread.h (find_thread_by_handle): Declare.
7358 * thread.c (find_thread_by_handle): New function.
7359 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
7360 function.
7361 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
7362
1e5b66ed
SM
73632017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7364
7365 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
7366
ebe48ba0
SM
73672017-09-21 Simon Marchi <simon.marchi@ericsson.com>
7368
7369 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
7370
0a0bf5dc
YQ
73712017-09-21 Yao Qi <yao.qi@linaro.org>
7372
7373 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
7374 to gdb_target_obs.
7375
d1b0a7bf
TT
73762017-09-20 Tom Tromey <tom@tromey.com>
7377
7378 * breakpoint.c (struct counted_command_line): Remove.
7379 (breakpoint_commands): Update.
7380 (alloc_counted_command_line, incref_counted_command_line)
7381 (decref_counted_command_line, do_cleanup_counted_command_line)
7382 (make_cleanup_decref_counted_command_line): Remove.
7383 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
7384 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
7385 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
7386 (save_breakpoints): Update.
7387 * breakpoint.h (counted_command_line): Now a typedef to
7388 shared_ptr.
7389 (struct breakpoint) <commands>: Now a counted_command_line.
7390 (struct bpstats) <command>: Likewise.
7391
48649e1b
TT
73922017-09-20 Tom Tromey <tom@tromey.com>
7393
7394 * breakpoint.c (struct commands_info, do_map_commands_command):
7395 Remove.
7396 (commands_command_1): Update.
7397 (iterate_over_related_breakpoints): Take a function_view.
7398 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
7399 (delete_command): Update.
7400 (map_breakpoint_numbers): Take a function_view.
7401 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
7402 (disable_command): Update.
7403 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
7404 (enable_command): Update.
7405 (struct disp_data, do_enable_breakpoint_disp)
7406 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
7407 (do_map_enable_delete_breakpoint): Remove.
7408 (enable_once_command, enable_count_command, enable_delete_command)
7409 (delete_trace_variable_command): Update.
7410
04afa70c
TT
74112017-09-20 Tom Tromey <tom@tromey.com>
7412
7413 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
7414 (bpstat_clear): Use delete.
7415 (bpstats): New constructors.
7416 (bpstat_copy, bpstat_stop_status): Use new.
7417 (dprintf_after_condition_true): Update.
7418 * breakpoint.h (bpstats::bpstats): Add constructors.
7419 (bpstats::~bpstats): Add destructor.
7420
c83833f4
PA
74212017-09-20 Pedro Alves <palves@redhat.com>
7422
7423 * eval.c (make_params): Delete, refactored as ...
7424 (class fake_method): ... this new type's ctor.
7425 (fake_method::~fake_method): New.
7426 (evaluate_subexp_standard): Use 'fake_method'.
7427
223ffa71
TT
74282017-09-20 Tom Tromey <tom@tromey.com>
7429
7430 * windows-nat.c (get_windows_debug_event, windows_wait)
7431 (do_initial_windows_stuff, windows_attach): Update.
7432 * utils.c (vwarning, internal_vproblem): Update.
7433 (ui_unregister_input_event_handler_cleanup)
7434 (prepare_to_handle_input): Remove.
7435 (class scoped_input_handler): New.
7436 (defaulted_query, prompt_for_continue): Update.
7437 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
7438 Update.
7439 * top.c (undo_terminal_modifications_before_exit): Update.
7440 * target/target.h (target_terminal_init, target_terminal_inferior)
7441 (target_terminal_ours): Don't declare.
7442 (class target_terminal): New.
7443 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
7444 (target_terminal_ours_for_output)
7445 (make_cleanup_restore_target_terminal): Don't declare.
7446 (target_terminal_info): Remove.
7447 * target.c (enum terminal_state, terminal_state): Remove.
7448 (target_terminal::terminal_state): Define.
7449 (target_terminal::init): Rename from target_terminal_init.
7450 (target_terminal::inferior): Rename from
7451 target_terminal_inferior.
7452 (target_terminal::ours): Rename from target_terminal_ours.
7453 (target_terminal::ours_for_output): Rename from
7454 target_terminal_ours_for_output.
7455 (target_terminal::info): New method.
7456 (cleanup_restore_target_terminal)
7457 (make_cleanup_restore_target_terminal): Remove.
7458 * solib.c (handle_solib_event): Update.
7459 * remote.c (remote_serial_quit_handler): Update.
7460 (remote_terminal_inferior, remote_wait_as): Update.
7461 * record-full.c (record_full_wait_1): Update.
7462 * nto-procfs.c (procfs_create_inferior): Update.
7463 * nat/fork-inferior.c (startup_inferior): Update.
7464 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
7465 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
7466 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
7467 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
7468 (mi_breakpoint_created, mi_breakpoint_deleted)
7469 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
7470 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7471 (mi_user_selected_context_changed, report_initial_inferior):
7472 Update.
7473 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
7474 (linux_nat_terminal_inferior): Update.
7475 * infrun.c (follow_fork_inferior)
7476 (handle_vfork_child_exec_or_exit, do_target_resume)
7477 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
7478 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
7479 Update.
7480 * inflow.c (child_terminal_init, info_terminal_command): Update.
7481 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
7482 (attach_command): Update.
7483 * infcall.c (call_thread_fsm_should_stop): Update.
7484 * gnu-nat.c (gnu_attach): Update.
7485 * extension.c (struct active_ext_lang_state)
7486 (restore_active_ext_lang): Update.
7487 * exceptions.c (print_flush): Update.
7488 * event-top.c (async_enable_stdin, default_quit_handler): Update.
7489 (struct quit_handler_cleanup_data, restore_quit_handler)
7490 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
7491 Remove.
7492 * cp-support.c (gdb_demangle): Update.
7493 * breakpoint.c (update_inserted_breakpoint_locations)
7494 (insert_breakpoint_locations, handle_jit_event)
7495 (disable_breakpoints_in_unloaded_shlib): Update.
7496 * annotate.c (annotate_breakpoints_invalid)
7497 (annotate_frames_invalid): Update.
7498
013af3fc
TT
74992017-09-20 Tom Tromey <tom@tromey.com>
7500
7501 * main.c (catch_command_errors): Rename from
7502 catch_command_errors_const.
7503 (captured_main_1): Update.
7504
06871ae8
PA
75052017-09-20 Pedro Alves <palves@redhat.com>
7506
7507 * cli/cli-cmds.c (list_command): Use print_sal_location.
7508 (print_sal_location): New function.
7509 (ambiguous_line_spec): Use print_sal_location.
7510 * linespec.c (symbol_to_sal): Record the symbol in the sal.
7511 * symtab.c (find_function_start_sal): Likewise.
7512 * symtab.h (symtab_and_line::symbol): New field.
7513
e5f25bc5
PA
75142017-09-20 Pedro Alves <palves@redhat.com>
7515
7516 * linespec.c (minsym_found): Handle non-text minsyms.
7517 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
7518
1b7fa39e
WT
75192017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7520
7521 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
7522 backslash.
7523
37dd0825
WT
75242017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7525
7526 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
7527 vmovups instead vmovaps.
7528 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
7529
4e5a4f58
JB
75302017-09-19 John Baldwin <jhb@FreeBSD.org>
7531
7532 * NEWS (Changes since GDB 8.0): Add starti.
7533 * infcmd.c (enum run_break): New.
7534 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
7535 case.
7536 (run_command): Use enum run_how.
7537 (start_command): Likewise.
7538 (starti_command): New function.
7539 (RUN_ARGS_HELP): New macro.
7540 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
7541 commands. Add starti command.
7542
aa70c9f1
YQ
75432017-09-19 Yao Qi <yao.qi@linaro.org>
7544
7545 * Makefile.in (monitor.o): Remove the rule.
7546
d6541620
YQ
75472017-09-19 Yao Qi <yao.qi@linaro.org>
7548
7549 * annotate.h (struct annotate_arg_emitter): Use
7550 DISABLE_COPY_AND_ASSIGN.
7551 * common/refcounted-object.h (refcounted_object): Likewise.
7552 * completer.h (struct completion_result): Likewise.
7553 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
7554 * filename-seen-cache.h (filename_seen_cache): Likewise.
7555 * gdbcore.h (thread_section_name): Likewise.
7556 * gdb_regex.h (compiled_regex): Likewise.
7557 * gdbthread.h (scoped_restore_current_thread): Likewise.
7558 * inferior.h (scoped_restore_current_inferior): Likewise.
7559 * jit.c (jit_reader): Likewise.
7560 * linespec.h (struct linespec_result): Likewise.
7561 * mi/mi-parse.h (struct mi_parse): Likewise.
7562 * nat/fork-inferior.c (execv_argv): Likewise.
7563 * progspace.h (scoped_restore_current_program_space): Likewise.
7564 * python/python-internal.h (class gdbpy_enter): Likewise.
7565 * regcache.h (regcache): Likewise.
7566 * target-descriptions.c (struct tdesc_reg): Likewise.
7567 (struct tdesc_type): Likewise.
7568 (struct tdesc_feature): Likewise.
7569 * ui-out.h (ui_out_emit_type): Likewise.
7570
0615127c
SM
75712017-09-18 Simon Marchi <simon.marchi@ericsson.com>
7572
7573 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
7574 label abort_expression.
7575
5e187554
SM
75762017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7577
7578 * common/buffer.c (buffer_xml_printf): Adjust.
7579 * common/xml-utils.c (xml_escape_text): Change return type to
7580 std::string, update code accordingly.
7581 * common/xml-utils.h (xml_escape_text): Change return type to
7582 std::string.
7583 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
7584 * windows-tdep.c (windows_xfer_shared_library): Adjust.
7585 * unittests/xml-utils-selftests.c (test_xml_escape_text):
7586 Adjust.
7587
c3d7b541
SM
75882017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7589
7590 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
7591 (SUBDIR_UNITTESTS_OBS): Add new object file.
7592 * unittests/xml-utils-selftests.c: New file.
7593
1526853e
SM
75942017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7595
7596 * common/selftest.h (selftest): New struct/interface.
7597 (register_test): Add name parameter, add new overload.
7598 (run_tests): Add filter parameter.
7599 (for_each_selftest_ftype): New typedef.
7600 (for_each_selftest): New declaration.
7601 * common/selftest.c (tests): Change type to
7602 map<string, unique_ptr<selftest>>.
7603 (simple_selftest): New struct.
7604 (register_test): New function.
7605 (register_test): Add name parameter and use it.
7606 (run_tests): Add filter parameter and use it. Add prints.
7607 Adjust to vector -> map change.
7608 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
7609 registering selftests.
7610 * arm-tdep.c (_initialize_arm_tdep): Likewise.
7611 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
7612 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
7613 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
7614 * findvar.c (_initialize_findvar): Likewise.
7615 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
7616 * maint.c (maintenance_selftest): Update call to run_tests.
7617 (maintenance_info_selftests): New function.
7618 (_initialize_maint_cmds): Register "maintenance info selftests"
7619 command. Update "maintenance selftest" doc.
7620 * regcache.c (_initialize_regcache): Add names when registering
7621 selftests.
7622 * rust-exp.y (_initialize_rust_exp): Likewise.
7623 * selftest-arch.c (gdbarch_selftest): New struct.
7624 (gdbarch_tests): Remove.
7625 (register_test_foreach_arch): Add name parameter. Call
7626 register_test.
7627 (tests_with_arch): Remove, move most content to
7628 gdbarch_selftest::operator().
7629 (_initialize_selftests_foreach_arch): Remove.
7630 * selftest-arch.h (register_test_foreach_arch): Add name
7631 parameter.
7632 (run_tests_with_arch): New declaration.
7633 * utils-selftests.c (_initialize_utils_selftests): Add names
7634 when registering selftests.
7635 * utils.c (_initialize_utils): Likewise.
7636 * unittests/array-view-selftests.c
7637 (_initialize_array_view_selftests): Likewise.
7638 * unittests/environ-selftests.c (_initialize_environ_selftests):
7639 Likewise.
7640 * unittests/function-view-selftests.c
7641 (_initialize_function_view_selftests): Likewise.
7642 * unittests/offset-type-selftests.c
7643 (_initialize_offset_type_selftests): Likewise.
7644 * unittests/optional-selftests.c
7645 (_initialize_optional_selftests): Likewise.
7646 * unittests/scoped_restore-selftests.c
7647 (_initialize_scoped_restore_selftests): Likewise.
7648 * NEWS: Document "maintenance selftest" and "maint info
7649 selftests".
7650
5846367a
SM
76512017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7652
7653 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7654 scoped_restore.
7655
bd77e8ff
SM
76562017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7657
7658 * mi/mi-main.c (mi_load_progress): Make uiout variable
7659 a unique_ptr.
7660
26a67918
PA
76612017-09-15 Pedro Alves <palves@redhat.com>
7662
7663 * compile/compile-c-types.c (convert_enum, convert_int)
7664 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7665
3f8a7804
SM
76662017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7667
7668 * dwarf2read.c (copy_string): Remove.
7669 (parse_macro_definition): Replace copy_string with savestring.
7670
8d200706
YQ
76712017-09-15 Yao Qi <yao.qi@linaro.org>
7672
7673 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7674 gdb_target_obs.
7675 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7676 Likewise.
7677 (i[34567]86-*-linux*): Likewise.
7678
d185219d
SM
76792017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7680
7681 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7682 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7683 <stack>: Change type to std::vector.
7684 <stack_len, stack_allocated>: Remove.
7685 <grow_stack>: Remove.
7686 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7687 (dwarf_expr_context::~dwarf_expr_context): Remove.
7688 (dwarf_expr_context::grow_stack): Remove.
7689 (dwarf_expr_context::push): Adjust.
7690 (dwarf_expr_context::pop): Adjust.
7691 (dwarf_expr_context::fetch): Adjust.
7692 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7693 (dwarf_expr_context::stack_empty_p): Adjust.
7694 (dwarf_expr_context::execute_stack_op): Adjust.
7695
eccd80d6
SM
76962017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7697
7698 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7699 return type to bool.
7700 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7701
69009882
SM
77022017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7703
7704 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7705 Change type to bool.
7706 (dwarf_stack_value) <in_stack_memory>: Likewise.
7707 (dwarf_expr_context) <push_address>: Change parameter type to
7708 bool.
7709 <fetch_in_stack_memory>: Change return type to bool.
7710 <push>: Change parameter type to bool.
7711 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7712 to bool.
7713 (dwarf_expr_context::push_address): Likewise.
7714 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7715 to bool.
7716 (dwarf_expr_context::execute_stack_op): Adjust.
7717 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7718
1e467161
SM
77192017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7720
7721 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7722 (struct dwarf_expr_context) <n_pieces>: Remove.
7723 <pieces>: Change type to std::vector.
7724 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7725 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7726 pieces.
7727 (dwarf_expr_context::add_piece): Adjust.
7728 * dwarf2loc.c (struct piece_closure): Initialize fields.
7729 <n_pieces>: Remove.
7730 <pieces>: Change type to std::vector.
7731 (allocate_piece_closure): Adjust, change parameter to
7732 std::vector rvalue and std::move it to piece_closure.
7733 (rw_pieced_value): Adjust.
7734 (check_pieced_synthetic_pointer): Adjust.
7735 (indirect_synthetic_pointer): Adjust.
7736 (coerce_pieced_ref): Adjust.
7737 (free_pieced_value_closure): Adjust. Use delete to free
7738 piece_closure.
7739 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7740 to allocate_piece_closure.
7741 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7742
0782db84
SM
77432017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7744
7745 * probe.h (probe_ops_cp): Remove typedef.
7746 (DEF_VEC_P (probe_ops_cp)): Remove.
7747 (all_probe_ops): Change type to std::vector.
7748 * probe.c (info_probes_for_ops): Adjust to vector change.
7749 (probe_linespec_to_ops): Likewise.
7750 (all_probe_ops): Change type to std::vector.
7751 (_initialize_probe): Adjust to vector change.
7752 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7753 * elfread.c (elf_get_probes): Likewise.
7754 * stap-probe.c (_initialize_stap_probe): Likewise.
7755
1eac6bea
SM
77562017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7757
7758 * probe.h (struct bound_probe): Define constructors.
7759 * probe.c (bound_probe_s): Remove typedef.
7760 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7761 (collect_probes): Change return type to std::vector, remove
7762 cleanup.
7763 (compare_probes): Return bool, change parameter type. Change
7764 semantic to "less than".
7765 (gen_ui_out_table_header_info): Change parameter to std::vector
7766 and update.
7767 (exists_probe_with_pops): Likewise.
7768 (info_probes_for_ops): Update to std::vector change.
7769 (enable_probes_command): Likewise.
7770 (disable_probes_command): Likewise.
7771
aaa63a31
SM
77722017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7773
7774 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7775 vec to std::vector.
7776 * probe.c (parse_probes_in_pspace): Update.
7777 (find_probes_in_objfile): Update.
7778 (find_probe_by_pc): Update.
7779 (collect_probes): Update.
7780 (probe_any_get_probes): Update.
7781 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7782 return type to reference to std::vector.
7783 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7784 std::vector and update.
7785 (dtrace_process_dof): Likewise.
7786 (dtrace_get_probes): Likewise.
7787 * elfread.c (elf_get_probes): Change return type to std::vector,
7788 store an std::vector in bfd_data.
7789 (probe_key_free): Update to std::vector.
7790 * stap-probe.c (handle_stap_probe): Change parameter to
7791 std::vector and update.
7792 (stap_get_probes): Likewise.
7793 * symfile-debug.c (debug_sym_get_probes): Change return type to
7794 std::vector and update.
7795
cb85b21b
TT
77962017-09-11 Tom Tromey <tom@tromey.com>
7797
7798 * breakpoint.c (program_breakpoint_here_p): Update.
7799 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7800 from make_show_memory_breakpoints_cleanup. Return a
7801 scoped_restore_tmpl<int>.
7802 (restore_show_memory_breakpoints): Remove.
7803 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7804 * mem-break.c (memory_validate_breakpoint): Update.
7805 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7806 (ia64_memory_remove_breakpoint): Update.
7807 (ia64_breakpoint_from_pc): Update.
7808 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7809 from make_show_memory_breakpoints_cleanup.
7810
8fbc99ef
TT
78112017-09-11 Tom Tromey <tom@tromey.com>
7812
7813 * d-namespace.c (d_lookup_symbol): Use std::string.
7814 (find_symbol_in_baseclass): Likewise.
7815
50feb4bd
TT
78162017-09-11 Tom Tromey <tom@tromey.com>
7817
7818 * ctf.c (ctf_start): Use std::string.
7819
c6dc63a1
TT
78202017-09-11 Tom Tromey <tom@tromey.com>
7821
7822 * ada-lang.c (is_known_support_routine): Update.
7823 (ada_unhandled_exception_name_addr_from_raise): Update.
7824 * guile/scm-frame.c (gdbscm_frame_name): Update.
7825 * python/py-frame.c (frapy_name): Update.
7826 (frapy_function): Update.
7827 * stack.h (find_frame_funname): Update.
7828 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7829 (print_frame): Update.
7830
d6b9b80f
TT
78312017-09-11 Tom Tromey <tom@tromey.com>
7832
7833 * findcmd.c (put_bits): Take a gdb::byte_vector.
7834 (parse_find_args): Return gdb::byte_vector. "args" now const.
7835 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7836 cleanups.
7837 (find_command): Update.
7838
a9921622
TT
78392017-09-11 Tom Tromey <tom@tromey.com>
7840
7841 * cli/cli-script.c (class scoped_restore_hook_in): New.
7842 (clear_hook_in_cleanup): Remove.
7843 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7844 scoped_restore_hook_in.
7845
be0d7abb
TT
78462017-09-11 Tom Tromey <tom@tromey.com>
7847
7848 * cli/cli-script.c (restore_interp): Remove.
7849 (read_command_lines): Use scoped_restore_interp.
7850 * interps.c (scoped_restore_interp::set_temp): Rename from
7851 interp_set_temp.
7852 * interps.h (class scoped_restore_interp): New.
7853 (interp_set_temp): Remove.
7854
00f675ff
TT
78552017-09-11 Tom Tromey <tom@tromey.com>
7856
7857 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7858 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7859 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7860 scoped_restore.
7861 (mi_cmd_break_insert_1): Update.
7862 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7863 scoped_restore.
7864
cb791d59
TT
78652017-09-11 Tom Tromey <tom@tromey.com>
7866
7867 * demangle.c (demangle_command): Update.
7868 * breakpoint.c (disable_command): Update.
7869 (enable_command): Update.
7870 (find_location_by_number): Make "number" const. Use
7871 get_number_trailer.
7872 * cli/cli-utils.c (extract_arg): Return std::string.
7873 * probe.c (parse_probe_linespec): Update. Change types.
7874 (collect_probes): Take string arguments.
7875 (parse_probe_linespec): Likewise.
7876 (info_probes_for_ops): Update.
7877 (enable_probes_command): Update.
7878 (disable_probes_command): Update.
7879 * break-catch-sig.c (catch_signal_split_args): Update.
7880 * mi/mi-parse.c (mi_parse): Update.
7881
2039bd9f
TT
78822017-09-11 Tom Tromey <tom@tromey.com>
7883
7884 * language.h (language_enum): Make argument const.
7885 * language.c (language_enum): Make argument const.
7886
f1735a53
TT
78872017-09-11 Tom Tromey <tom@tromey.com>
7888
7889 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7890 as function.
7891 (skip_to_space): Rename from skip_to_space_const.
7892 * common/common-utils.c (skip_to_space): New function.
7893 (skip_to_space): Rename from skip_to_space_const.
7894 * cli/cli-utils.h (get_number): Rename from get_number_const.
7895 (extract_arg): Rename from extract_arg_const.
7896 * cli/cli-utils.c (get_number): Rename from get_number_const.
7897 (extract_arg): Rename from extract_arg_const.
7898 (number_or_range_parser::get_number): Use ::get_number.
7899 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7900 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7901 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7902 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7903 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7904 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7905 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7906 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7907
7d221d74
TT
79082017-09-11 Tom Tromey <tom@tromey.com>
7909
7910 * python/python.c (do_start_initialization): Use
7911 py-event-types.def to initialize types.
7912 Define all object type structures.
7913 * python/python-internal.h: Don't declare event initialization
7914 functions.
7915 * python/py-threadevent.c (thread_event_object_type): Don't
7916 define.
7917 * python/py-stopevent.c (stop_event_object_type): Don't define.
7918 * python/py-signalevent.c (signal_event_object_type): Don't
7919 declare or define.
7920 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7921 (clear_objfiles_event_object_type): Don't declare or define.
7922 * python/py-infevents.c (inferior_call_pre_event_object_type)
7923 (inferior_call_post_event_object_type)
7924 (register_changed_event_object_type)
7925 (memory_changed_event_object_type): Don't declare or define.
7926 * python/py-inferior.c (new_thread_event_object_type)
7927 (new_inferior_event_object_type)
7928 (inferior_deleted_event_object_type): Don't declare or define.
7929 * python/py-exitedevent.c (exited_event_object_type): Don't
7930 declare or define.
7931 * python/py-evts.c (gdbpy_initialize_py_events): Use
7932 py-all-events.def.
7933 * python/py-events.h (thread_event_object_type): Don't declare.
7934 (events_object): Use py-all-events.def.
7935 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7936 py-event-types.def.
7937 * python/py-event-types.def: New file.
7938 * python/py-continueevent.c (create_continue_event_object): Don't
7939 declare or define.
7940 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7941 declare or define.
7942 * python/py-all-events.def: New file.
7943
35c61a1d
TT
79442017-09-11 Tom Tromey <tom@tromey.com>
7945
7946 * python/py-threadevent.c (create_thread_event_object): Return
7947 gdbpy_ref.
7948 * python/py-stopevent.h (create_stop_event_object)
7949 (create_breakpoint_event_object, create_signal_event_object):
7950 Update.
7951 * python/py-stopevent.c (create_stop_event_object): Return
7952 gdbpy_ref.
7953 (emit_stop_event): Update.
7954 * python/py-signalevent.c (create_signal_event_object): Return
7955 gdbpy_ref.
7956 * python/py-infevents.c (create_inferior_call_event_object):
7957 Update.
7958 * python/py-event.h (create_event_object)
7959 (create_thread_event_object): Update.
7960 * python/py-event.c (create_event_object): Return gdbpy_ref.
7961 * python/py-continueevent.c: Return gdbpy_ref.
7962 * python/py-bpevent.c (create_breakpoint_event_object): Return
7963 gdbpy_ref.
7964
7c96f8c1
TT
79652017-09-11 Tom Tromey <tom@tromey.com>
7966
7967 PR python/15622:
7968 * NEWS: Add entry.
7969 * python/python.c (do_start_initialization): Initialize new event
7970 types.
7971 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7972 (gdbpy_initialize_inferior_deleted_event)
7973 (gdbpy_initialize_new_thread_event): Declare.
7974 * python/py-threadevent.c (create_thread_event_object): Add option
7975 "thread" parameter.
7976 * python/py-inferior.c (new_thread_event_object_type)
7977 (new_inferior_event_object_type)
7978 (inferior_deleted_event_object_type): Declare.
7979 (python_new_inferior, python_inferior_deleted): New functions.
7980 (add_thread_object): Emit new_thread event.
7981 (gdbpy_initialize_inferior): Attach new functions to corresponding
7982 observers.
7983 (new_thread, new_inferior, inferior_deleted): Define new event
7984 types.
7985 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7986 registries.
7987 * python/py-events.h (events_object) <new_inferior,
7988 inferior_deleted, new_thread>: New fields.
7989 * python/py-event.h (create_thread_event_breakpoint): Add optional
7990 "thread" parameter.
7991
72542b8e
AB
79922017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7993
7994 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7995 check current_ui instead.
7996 (internal_vproblem): Likewise.
7997
0d64823e
SM
79982017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7999
8000 * thread.c (print_thread_info_1): Remove unnecessary calls to
8001 uiout->is_mi_like_p.
8002
eb1e02fd
TT
80032017-09-09 Tom Tromey <tom@tromey.com>
8004
8005 * namespace.h (add_using_directive): Update.
8006 * namespace.c (add_using_directive): Change type of excludes to
8007 std::vector.
8008 * dwarf2read.c (read_import_statement): Use std::vector.
8009 (read_namespace): Update.
8010 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
8011
0fc21fd8
TT
80122017-09-09 Tom Tromey <tom@tromey.com>
8013
8014 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
8015
49663d05
TT
80162017-09-09 Tom Tromey <tom@tromey.com>
8017
8018 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
8019
0b868b60
TT
80202017-09-09 Tom Tromey <tom@tromey.com>
8021
8022 * stack.c (func_command): Use gdb::def_vector.
8023
c0470d48
TT
80242017-09-09 Tom Tromey <tom@tromey.com>
8025
8026 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
8027 ui_out_emit_list, ui_out_emit_tuple.
8028 (mi_cmd_var_update): Likewise.
8029
ca5909c7
TT
80302017-09-09 Tom Tromey <tom@tromey.com>
8031
8032 * mi/mi-interp.c (mi_user_selected_context_changed): Use
8033 ui_out_redirect_pop.
8034 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
8035 ui_out_redirect_pop.
8036 * utils.c (do_ui_out_redirect_pop)
8037 (make_cleanup_ui_out_redirect_pop): Remove.
8038 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
8039 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
8040 * ui-out.h (ui_out_redirect_pop): New class.
8041
e6a2252a
TT
80422017-09-09 Tom Tromey <tom@tromey.com>
8043
8044 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
8045 (list_available_thread_groups, mi_cmd_list_thread_groups)
8046 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
8047 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
8048 Likewise.
8049
393702cd
TT
80502017-09-09 Tom Tromey <tom@tromey.com>
8051
8052 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
8053 ui_out_emit_tuple.
8054
76f9c9cf
TT
80552017-09-09 Tom Tromey <tom@tromey.com>
8056
8057 * target.c (flash_erase_command): Use ui_out_emit_tuple.
8058 * stack.c (print_frame): Use ui_out_emit_tuple.
8059 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
8060 (info_spu_mailbox_command, info_spu_dma_command)
8061 (info_spu_proxydma_command): Likewise.
8062 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
8063 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
8064 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
8065 ui_out_emit_tuple.
8066 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
8067
dc9fe180
TT
80682017-09-09 Tom Tromey <tom@tromey.com>
8069
8070 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
8071 (class ui_out_emit_table): Update comment.
8072 * ui-out.c (do_cleanup_table_end)
8073 (make_cleanup_ui_out_table_begin_end): Remove.
8074 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
8075 (info_spu_dma_cmdlist): Likewise.
8076 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
8077 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
8078 ui_out_emit_table.
8079
f8cc3da6
TT
80802017-09-09 Tom Tromey <tom@tromey.com>
8081
8082 * thread.c (print_thread_info_1): Use ui_out_emit_table,
8083 ui_out_emit_list, gdb::optional.
8084
481695ed
JB
80852017-09-09 John Baldwin <jhb@FreeBSD.org>
8086
8087 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
8088 prototype.
8089 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
8090 prototype.
8091 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
8092 prototype.
8093 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
8094 * ada-exp.y: Remove _initialize_ada_exp prototype.
8095 * ada-lang.c: Remove _initialize_ada_language prototype.
8096 * ada-tasks.c: Remove _initialize_tasks prototype.
8097 * addrmap.c: Remove _initialize_addrmap prototype.
8098 * agent.c: Remove _initialize_agent prototype.
8099 * aix-thread.c: Remove _initialize_aix_thread prototype.
8100 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
8101 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
8102 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
8103 prototype.
8104 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
8105 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
8106 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
8107 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
8108 prototype.
8109 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
8110 prototype.
8111 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
8112 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
8113 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
8114 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
8115 prototype.
8116 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
8117 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
8118 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
8119 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
8120 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
8121 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
8122 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
8123 prototype.
8124 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
8125 prototype.
8126 * annotate.c: Remove _initialize_annotate prototype.
8127 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
8128 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
8129 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
8130 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
8131 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
8132 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
8133 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
8134 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
8135 prototype.
8136 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
8137 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
8138 * auto-load.c: Remove _initialize_auto_load prototype.
8139 * auxv.c: Remove _initialize_auxv prototype.
8140 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
8141 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
8142 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
8143 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
8144 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
8145 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
8146 prototype.
8147 * break-catch-throw.c: Remove _initialize_break_catch_throw
8148 prototype.
8149 * breakpoint.c: Remove _initialize_breakpoint prototype.
8150 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
8151 * btrace.c: Remove _initialize_btrace prototype.
8152 * charset.c: Remove _initialize_charset prototype.
8153 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
8154 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
8155 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
8156 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
8157 * cli/cli-script.c: Remove _initialize_cli_script prototype.
8158 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
8159 * coffread.c: Remove _initialize_coffread prototype.
8160 * compile/compile.c: Remove _initialize_compile prototype.
8161 * complaints.c: Remove _initialize_complaints prototype.
8162 * completer.c: Remove _initialize_completer prototype.
8163 * copying.awk: Remove _initialize_copying prototype.
8164 * copying.c: Regenerate.
8165 * core-regset.c: Remove _initialize_core_regset prototype.
8166 * corefile.c: Remove _initialize_core prototype.
8167 * corelow.c: Remove _initialize_corelow prototype.
8168 * cp-abi.c: Remove _initialize_cp_abi prototype.
8169 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
8170 * cp-support.c: Remove _initialize_cp_support prototype.
8171 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
8172 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
8173 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
8174 * ctf.c: Remove _initialize_ctf prototype.
8175 * d-lang.c: Remove _initialize_d_language prototype.
8176 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
8177 prototype.
8178 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
8179 * dbxread.c: Remove _initialize_dbxread prototype.
8180 * dcache.c: Remove _initialize_dcache prototype.
8181 * demangle.c: Remove _initialize_demangler prototype.
8182 * disasm-selftests.c: Remove _initialize_disasm_selftests
8183 prototype.
8184 * disasm.c: Remove _initialize_disasm prototype.
8185 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
8186 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
8187 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
8188 prototype.
8189 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
8190 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
8191 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
8192 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
8193 * elfread.c: Remove _initialize_elfread prototype.
8194 * exec.c: Remove _initialize_exec prototype.
8195 * extension.c: Remove _initialize_extension prototype.
8196 * f-lang.c: Remove _initialize_f_language prototype.
8197 * f-valprint.c: Remove _initialize_f_valprint prototype.
8198 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
8199 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
8200 * filesystem.c: Remove _initialize_filesystem prototype.
8201 * findcmd.c: Remove _initialize_mem_search prototype.
8202 * fork-child.c: Remove _initialize_fork_child prototype.
8203 * frame-base.c: Remove _initialize_frame_base prototype.
8204 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
8205 * frame.c: Remove _initialize_frame prototype.
8206 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
8207 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
8208 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
8209 * gcore.c: Remove _initialize_gcore prototype.
8210 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
8211 * gdbarch.c: Regenerate.
8212 * gdbarch.sh: Remove _initialize_gdbarch prototype.
8213 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
8214 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
8215 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
8216 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
8217 * go-lang.c: Remove _initialize_go_language prototype.
8218 * go32-nat.c: Remove _initialize_go32_nat prototype.
8219 * guile/guile.c: Remove _initialize_guile prototype.
8220 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
8221 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
8222 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
8223 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
8224 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
8225 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
8226 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
8227 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
8228 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
8229 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
8230 prototype.
8231 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
8232 prototype.
8233 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
8234 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
8235 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
8236 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
8237 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
8238 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
8239 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
8240 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
8241 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
8242 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
8243 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
8244 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
8245 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
8246 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
8247 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
8248 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
8249 prototype.
8250 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
8251 prototype.
8252 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
8253 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
8254 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
8255 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
8256 * infcall.c: Remove _initialize_infcall prototype.
8257 * infcmd.c: Remove _initialize_infcmd prototype.
8258 * inferior.c: Remove _initialize_inferiors prototype.
8259 * inflow.c: Remove _initialize_inflow prototype.
8260 * infrun.c: Remove _initialize_infrun prototype.
8261 * interps.c: Remove _initialize_interpreter prototype.
8262 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
8263 * jit.c: Remove _initialize_jit prototype.
8264 * language.c: Remove _initialize_language prototype.
8265 * linux-fork.c: Remove _initialize_linux_fork prototype.
8266 * linux-nat.c: Remove _initialize_linux_nat prototype.
8267 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
8268 * linux-thread-db.c: Remove _initialize_thread_db prototype.
8269 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
8270 * m2-lang.c: Remove _initialize_m2_language prototype.
8271 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
8272 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
8273 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
8274 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
8275 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
8276 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8277 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8278 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
8279 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
8280 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
8281 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
8282 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
8283 * machoread.c: Remove _initialize_machoread prototype.
8284 * macrocmd.c: Remove _initialize_macrocmd prototype.
8285 * macroscope.c: Remove _initialize_macroscope prototype.
8286 * maint.c: Remove _initialize_maint_cmds prototype.
8287 * mdebugread.c: Remove _initialize_mdebugread prototype.
8288 * memattr.c: Remove _initialize_mem prototype.
8289 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
8290 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
8291 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
8292 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
8293 * mi/mi-main.c: Remove _initialize_mi_main prototype.
8294 * microblaze-linux-tdep.c: Remove
8295 _initialize_microblaze_linux_tdep prototype.
8296 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
8297 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
8298 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
8299 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
8300 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
8301 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
8302 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
8303 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
8304 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
8305 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
8306 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
8307 prototype.
8308 * mipsread.c: Remove _initialize_mipsread prototype.
8309 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
8310 prototype.
8311 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
8312 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
8313 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
8314 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
8315 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
8316 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
8317 prototype.
8318 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
8319 * nto-procfs.c: Remove _initialize_procfs prototype.
8320 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
8321 * objc-lang.c: Remove _initialize_objc_language prototype.
8322 * objfiles.c: Remove _initialize_objfiles prototype.
8323 * observer.c: Remove observer_test_first_notification_function,
8324 observer_test_second_notification_function,
8325 observer_test_third_notification_function, and
8326 _initialize_observer prototypes.
8327 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
8328 * osabi.c: Remove _initialize_gdb_osabi prototype.
8329 * osdata.c: Remove _initialize_osdata prototype.
8330 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
8331 * parse.c: Remove _initialize_parse prototype.
8332 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
8333 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
8334 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
8335 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
8336 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
8337 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
8338 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
8339 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
8340 * printcmd.c: Remove _initialize_printcmd prototype.
8341 * probe.c: Remove _initialize_probe prototype.
8342 * proc-api.c: Remove _initialize_proc_api prototype.
8343 * proc-events.c: Remove _initialize_proc_events prototype.
8344 * proc-service.c: Remove _initialize_proc_service prototype.
8345 * procfs.c: Remove _initialize_procfs prototype.
8346 * psymtab.c: Remove _initialize_psymtab prototype.
8347 * python/python.c: Remove _initialize_python prototype.
8348 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
8349 * record-btrace.c: Remove _initialize_record_btrace prototype.
8350 * record-full.c: Remove _initialize_record_full prototype.
8351 * record.c: Remove _initialize_record prototype.
8352 * regcache.c: Remove _initialize_regcache prototype.
8353 * reggroups.c: Remove _initialize_reggroup prototype.
8354 * remote-notif.c: Remove _initialize_notif prototype.
8355 * remote-sim.c: Remove _initialize_remote_sim prototype.
8356 * remote.c: Remove _initialize_remote prototype.
8357 * reverse.c: Remove _initialize_reverse prototype.
8358 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
8359 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
8360 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
8361 prototype.
8362 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
8363 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
8364 * rust-exp.y: Remove _initialize_rust_exp prototype.
8365 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
8366 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
8367 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
8368 * score-tdep.c: Remove _initialize_score_tdep prototype.
8369 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
8370 prototype.
8371 * ser-go32.c: Remove _initialize_ser_dos prototype.
8372 * ser-mingw.c: Remove _initialize_ser_windows prototype.
8373 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
8374 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
8375 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
8376 * serial.c: Remove _initialize_serial prototype.
8377 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
8378 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
8379 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
8380 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
8381 * skip.c: Remove _initialize_step_skip prototype.
8382 * sol-thread.c: Remove _initialize_sol_thread prototype.
8383 * solib-aix.c: Remove _initialize_solib_aix prototype.
8384 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
8385 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
8386 * solib-frv.c: Remove _initialize_frv_solib prototype.
8387 * solib-spu.c: Remove _initialize_spu_solib prototype.
8388 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
8389 * solib-target.c: Remove _initialize_solib_target prototype.
8390 * solib.c: Remove _initialize_solib prototype.
8391 * source.c: Remove _initialize_source prototype.
8392 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
8393 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
8394 prototype.
8395 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
8396 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
8397 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
8398 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
8399 prototype.
8400 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
8401 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
8402 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
8403 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
8404 prototype.
8405 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
8406 prototype.
8407 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
8408 prototype.
8409 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
8410 prototype.
8411 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
8412 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
8413 prototype.
8414 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
8415 prototype.
8416 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
8417 prototype.
8418 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
8419 prototype.
8420 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
8421 prototype.
8422 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
8423 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
8424 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
8425 * stabsread.c: Remove _initialize_stabsread prototype.
8426 * stack.c: Remove _initialize_stack prototype.
8427 * stap-probe.c: Remove _initialize_stap_probe prototype.
8428 * std-regs.c: Remove _initialize_frame_reg prototype.
8429 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
8430 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
8431 * symfile.c: Remove _initialize_symfile prototype.
8432 * symmisc.c: Remove _initialize_symmisc prototype.
8433 * symtab.c: Remove _initialize_symtab prototype.
8434 * target-dcache.c: Remove _initialize_target_dcache prototype.
8435 * target-descriptions.c: Remove _initialize_target_descriptions
8436 prototype.
8437 * thread.c: Remove _initialize_thread prototype.
8438 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
8439 prototype.
8440 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
8441 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
8442 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
8443 prototype.
8444 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
8445 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
8446 * tracefile.c: Remove _initialize_tracefile prototype.
8447 * tracepoint.c: Remove _initialize_tracepoint prototype.
8448 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
8449 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
8450 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
8451 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
8452 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
8453 * tui/tui-win.c: Remove _initialize_tui_win prototype.
8454 * tui/tui.c: Remove _initialize_tui prototype.
8455 * typeprint.c: Remove _initialize_typeprint prototype.
8456 * user-regs.c: Remove _initialize_user_regs prototype.
8457 * utils.c: Remove _initialize_utils prototype.
8458 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
8459 * valarith.c: Remove _initialize_valarith prototype.
8460 * valops.c: Remove _initialize_valops prototype.
8461 * valprint.c: Remove _initialize_valprint prototype.
8462 * value.c: Remove _initialize_values prototype.
8463 * varobj.c: Remove _initialize_varobj prototype.
8464 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
8465 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
8466 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
8467 * windows-nat.c: Remove _initialize_windows_nat,
8468 _initialize_check_for_gdb_ini, and _initialize_loadable
8469 prototypes.
8470 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
8471 * xcoffread.c: Remove _initialize_xcoffread prototype.
8472 * xml-support.c: Remove _initialize_xml_support prototype.
8473 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
8474 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
8475 prototype.
8476 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
8477 prototype.
8478 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
8479
a611b5cb
KS
84802017-09-08 Keith Seitz <keiths@redhat.com>
8481
8482 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
8483 field.
8484
469412dd
CW
84852017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
8486
8487 * f-valprint.c (f_val_print): Remove check for one byte
8488 sized integers. Remove printing of character type.
8489
a5ad232b
FP
84902017-09-08 Frank Penczek <frank.penczek@intel.com>
8491 Christoph Weinmann <christoph.t.weinmann@intel.com>
8492 Bernhard Heckel <bernhard.heckel@intel.com>
8493
8494 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
8495 to maintain proper indentation when printing pointers/refs.
8496
e5014227
JB
84972017-09-07 Joel Brobecker <brobecker@adacore.com>
8498
8499 GDB 8.0.1 released.
8500
63c99141
JB
85012017-09-07 Joel Brobecker <brobecker@adacore.com>
8502
8503 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
8504
69c1e056
TT
85052017-09-05 Tom Tromey <tom@tromey.com>
8506
8507 * parse.c (funcall_chain): Now a std::vector.
8508 (start_arglist, end_arglist): Simplify.
8509 (free_funcalls): Remove.
8510 (parse_exp_in_context_1): Remove cleanup.
8511
fef704bf
TT
85122017-09-05 Tom Tromey <tom@tromey.com>
8513
8514 * go-exp.y (go_parse): Don't create a cleanup.
8515
5613c585
TT
85162017-09-05 Tom Tromey <tom@tromey.com>
8517
8518 * d-exp.y (PrimaryExpression): Use std::string.
8519 (d_parse): Don't create a cleanup.
8520
eae49211
TT
85212017-09-05 Tom Tromey <tom@tromey.com>
8522
8523 * utils.c (do_clear_parser_state): Remove.
8524 (make_cleanup_clear_parser_state): Remove.
8525 * p-exp.y (pascal_parse): Use scoped_restore.
8526 * m2-exp.y (m2_parse): Use scoped_restore.
8527 * f-exp.y (f_parse): Use scoped_restore.
8528 * d-exp.y (d_parse): Use scoped_restore.
8529 * c-exp.y (c_parse): Use scoped_restore.
8530 * ada-exp.y (ada_parse): Use scoped_restore.
8531 * utils.h (make_cleanup_clear_parser_state): Remove.
8532
73b9be8b
KS
85332017-09-06 Keith Seitz <keiths@redhat.com>
8534
8535 * dwarf2read.c (dw2_linkage_name_attr): New function.
8536 (dw2_linkage_name): New function.
8537 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
8538 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
8539 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
8540
a102602b
KR
85412017-09-06 Kamil Rytarowski <n54@gmx.com>
8542
8543 * config/djgpp/djconfig.sh: Correct shell portability issue.
8544
28ad437d
KR
85452017-09-06 Kamil Rytarowski <n54@gmx.com>
8546
8547 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
8548
351787dd
JB
85492017-09-06 John Baldwin <jhb@FreeBSD.org>
8550
8551 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
8552 * NEWS: Mention new FreeBSD/mips native configuration.
8553 * configure.host: Add aarch64*-*-freebsd*.
8554 * configure.nat: Likewise.
8555 * aarch64-fbsd-nat.c: New file.
8556
c0f84956
JB
85572017-09-06 John Baldwin <jhb@FreeBSD.org>
8558
8559 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
8560 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
8561 * NEWS: Mention new FreeBSD/aarch64 target.
8562 * configure.tgt: Add aarch64*-*-freebsd*.
8563 * aarch64-fbsd-tdep.c: New file.
8564 * aarch64-fbsd-tdep.h: New file.
8565
7610297a
KR
85662017-09-06 Kamil Rytarowski <n54@gmx.com>
8567
8568 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
8569
fbd1b771
JK
85702017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8571
8572 * parse.c (find_minsym_type_and_address): Don't relocate addresses
8573 of TLS symbols.
8574
5ca79eae
PW
85752017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8576
8577 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
8578 call.
8579
bf93d7ba
SM
85802017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8581
8582 * infrun.c (follow_exec): Call add_thread after
8583 target_find_description.
8584
1bb7c059
SM
85852017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8586
8587 * infrun.c (handle_inferior_event_1): When exec'ing, read
8588 stop_pc after follow_exec.
8589
fc809827
SM
85902017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8591
8592 * remote.c (process_g_packet): Update error message.
8593
d2fcdd85
YQ
85942017-09-05 Yao Qi <yao.qi@linaro.org>
8595
8596 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
8597 targets.
8598
e69570ee
PA
85992017-09-05 Pedro Alves <palves@redhat.com>
8600
8601 * eval.c (eval_call, evaluate_funcall): New functions, factored
8602 out from ...
8603 (evaluate_subexp_standard): ... this.
8604
22916b07
YQ
86052017-09-05 Yao Qi <yao.qi@linaro.org>
8606
8607 * amd64-tdep.c (amd64_target_description): Create target
8608 descriptions.
8609 (_initialize_amd64_tdep): Don't call functions
8610 initialize_tdesc_amd64_*. Add self tests.
8611 * arch/amd64.c (amd64_create_target_description): Add parameter
8612 is_linux. Call set_tdesc_osabi if is_linux is true.
8613 * arch/amd64.h (amd64_create_target_description): Update the
8614 declaration.
8615 * arch/i386.c (i386_create_target_description): Add parameter
8616 is_linux. Call set_tdesc_osabi if is_linux is true.
8617 * arch/i386.h (i386_create_target_description): Update
8618 declaration.
8619 * configure.tgt: Add i386.o to gdb_target_obs.
8620 * features/Makefile (XMLTOC): Remove i386/*.xml.
8621 * features/i386/amd64-avx-avx512.c: Remove.
8622 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
8623 * features/i386/amd64-avx-mpx.c: Remove.
8624 * features/i386/amd64-avx.c: Remove.
8625 * features/i386/amd64-mpx.c: Remove.
8626 * features/i386/amd64.c: Remove.
8627 * features/i386/i386-avx-avx512.c: Remove.
8628 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
8629 * features/i386/i386-avx-mpx.c: Remove.
8630 * features/i386/i386-avx.c: Remove.
8631 * features/i386/i386-mmx.c: Remove.
8632 * features/i386/i386-mpx.c: Remove.
8633 * features/i386/i386.c: Remove.
8634 * i386-tdep.c: Don't include features/i386/i386*.c., include
8635 target-descriptions.h and arch/i386.h.
8636 (i386_target_description): Create target descriptions.
8637 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
8638 functions. Do self tests.
8639
0854b7b1
YQ
86402017-09-05 Yao Qi <yao.qi@linaro.org>
8641
8642 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
8643 * features/i386/amd64-avx-avx512-linux.c: Removed.
8644 * features/i386/amd64-avx-linux.c: Removed.
8645 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
8646 * features/i386/amd64-avx-mpx-linux.c: Removed.
8647 * features/i386/amd64-linux.c: Removed.
8648 * features/i386/amd64-mpx-linux.c: Removed.
8649 * features/i386/x32-avx-avx512-linux.c: Removed.
8650 * features/i386/x32-avx-linux.c: Removed.
8651 * features/i386/x32-linux.c: Removed.
8652
b4570e4b
YQ
86532017-09-05 Yao Qi <yao.qi@linaro.org>
8654
8655 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8656 features/i386/*.c.
8657 (amd64_linux_read_description): Call
8658 amd64_create_target_description.
8659 * arch/amd64.c: New file.
8660 * arch/amd64.h: New file.
8661 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8662 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8663
6c73f67f
YQ
86642017-09-05 Yao Qi <yao.qi@linaro.org>
8665
8666 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8667 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8668 (amd64_linux_read_description): Create target descriptions.
8669 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8670 functions. Add unit tests.
8671 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8672 x32-core.xml.
8673 * features/i386/64bit-avx.c: Generated.
8674 * features/i386/64bit-avx512.c: Generated.
8675 * features/i386/64bit-core.c: Generated.
8676 * features/i386/64bit-linux.c: Generated.
8677 * features/i386/64bit-mpx.c: Generated.
8678 * features/i386/64bit-pkeys.c: Generated.
8679 * features/i386/64bit-segments.c: Generated.
8680 * features/i386/64bit-sse.c: Generated.
8681 * features/i386/x32-core.c: Generated.
8682 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8683 c files for amd64-linux and x32-linux.
8684
9d3d478b
YQ
86852017-09-05 Yao Qi <yao.qi@linaro.org>
8686
8687 * amd64-linux-tdep.c (amd64_linux_read_description): New
8688 function.
8689 (amd64_linux_core_read_description): Call
8690 amd64_linux_read_description.
8691 (amd64_linux_init_abi): Likewise.
8692 (amd64_x32_linux_init_abi): Likewise.
8693 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8694 * x86-linux-nat.c (x86_linux_read_description): Call
8695 amd64_linux_read_description.
8696
b9f1d50f
YQ
86972017-09-05 Yao Qi <yao.qi@linaro.org>
8698
8699 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8700 comments.
8701
188c9e6d
YQ
87022017-09-05 Yao Qi <yao.qi@linaro.org>
8703
8704 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8705 * features/i386/i386-avx-avx512-linux.c: Remove.
8706 * features/i386/i386-avx-linux.c: Remove.
8707 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8708 * features/i386/i386-avx-mpx-linux.c: Remove.
8709 * features/i386/i386-linux.c: Remove.
8710 * features/i386/i386-mmx-linux.c: Remove.
8711 * features/i386/i386-mpx-linux.c: Remove.
8712
5f035c07
YQ
87132017-09-05 Yao Qi <yao.qi@linaro.org>
8714
8715 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8716 (SFILES): Add arch/i386.c.
8717 (HFILES_NO_SRCDIR): Add arch/i386.h.
8718 * arch/i386.c: New file.
8719 * arch/i386.h: New file.
8720 * arch/tdesc.h (allocate_target_description): Declare.
8721 (set_tdesc_architecture): Declare.
8722 (set_tdesc_osabi): Declare.
8723 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8724 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8725 include arch/i386.h.
8726 (i386_linux_read_description): Remove code and call
8727 i386_create_target_description.
8728 (set_tdesc_architecture): New function.
8729 (set_tdesc_osabi): New function.
8730 * target-descriptions.h (allocate_target_description): Remove.
8731
0abe8a89
YQ
87322017-09-05 Yao Qi <yao.qi@linaro.org>
8733
8734 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8735 * target-descriptions.c (tdesc_create_feature): Likewise, and
8736 adjust code.
8737 * features/i386/32bit-avx.c: Re-generated.
8738 * features/i386/32bit-avx512.c: Re-generated.
8739 * features/i386/32bit-core.c: Re-generated.
8740 * features/i386/32bit-linux.c: Re-generated.
8741 * features/i386/32bit-mpx.c: Re-generated.
8742 * features/i386/32bit-pkeys.c: Re-generated.
8743 * features/i386/32bit-sse.c: Re-generated.
8744
0a188386
YQ
87452017-09-05 Yao Qi <yao.qi@linaro.org>
8746
8747 * regformats/regdef.h (struct reg): Override operator == and !=.
8748
f49ff000
YQ
87492017-09-05 Yao Qi <yao.qi@linaro.org>
8750
8751 * arch/tdesc.h: New file.
8752 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8753 * target-descriptions.c: Update comments.
8754 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8755 declarations.
8756 * features/i386/32bit-avx.c: Re-generated.
8757 * features/i386/32bit-avx512.c: Re-generated.
8758 * features/i386/32bit-core.c: Re-generated.
8759 * features/i386/32bit-linux.c: Re-generated.
8760 * features/i386/32bit-mpx.c: Re-generated.
8761 * features/i386/32bit-pkeys.c: Re-generated.
8762 * features/i386/32bit-sse.c: Re-generated.
8763
f7000548
YQ
87642017-09-05 Yao Qi <yao.qi@linaro.org>
8765
8766 * regformats/regdat.sh: Update generated code.
8767
c9a5e2a5
YQ
87682017-09-05 Yao Qi <yao.qi@linaro.org>
8769
8770 * regformats/regdat.sh: Adjust code order.
8771
d6b687ac
SM
87722017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8773
8774 * expprint.c (dump_subexp_body_standard): Use constant format
8775 string in fprintf_filtered call.
8776
a379bfd0
JB
87772017-09-04 John Baldwin <jhb@FreeBSD.org>
8778
8779 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8780 NetBSD/i386.
8781 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8782
f7efc967
JB
87832017-09-04 John Baldwin <jhb@FreeBSD.org>
8784
8785 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8786
c49fbc6c
JB
87872017-09-04 John Baldwin <jhb@FreeBSD.org>
8788
8789 * bsd-kvm.o: Define _KMEMUSER.
8790 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8791 * configure: Regenerate.
8792
26562e73
JB
87932017-09-04 John Baldwin <jhb@FreeBSD.org>
8794
8795 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8796 * i386-fbsd-nat.c: Likewise.
8797
31cf1487
JB
87982017-09-04 John Baldwin <jhb@FreeBSD.org>
8799
8800 * unittests/array-view-selftests.c: Add include of <array>.
8801
5b9f8a7c
JB
88022017-09-04 John Baldwin <jhb@FreeBSD.org>
8803
8804 * spu-tdep.c (flush_ea_cache): Add missing argument to
8805 call_function_by_hand.
8806
d69cf9b2
PA
88072017-09-04 Pedro Alves <palves@redhat.com>
8808
8809 * NEWS (Safer support for debugging with no debug info): New.
8810
3693fdb3
PA
88112017-09-04 Pedro Alves <palves@redhat.com>
8812
8813 * c-exp.y (function_method, function_method_void): Add current
8814 instance flags to TYPE_INSTANCE.
8815 * dwarf2read.c (check_modifier): New.
8816 (compute_delayed_physnames): Assert that only C++ adds delayed
8817 physnames. Mark fn_fields as const/volatile depending on
8818 physname.
8819 * eval.c (make_params): New type_instance_flags parameter. Use
8820 it as the new type's instance flags.
8821 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8822 flags element and pass it to make_params.
8823 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8824 instance flags element.
8825 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8826 * gdbtypes.h: Include "enum-flags.h".
8827 (type_instance_flags): New enum-flags type.
8828 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8829 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8830 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8831 (follow_type_instance_flags): New function.
8832 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8833 * parser-defs.h (follow_type_instance_flags): Declare.
8834 * valops.c (value_struct_elt_for_reference): const/volatile must
8835 match too.
8836
e68cb8e0
PA
88372017-09-04 Pedro Alves <palves@redhat.com>
8838
8839 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8840 function/method scopes; lookup the nested name as a function local
8841 static variable.
8842
858be34c
PA
88432017-09-04 Pedro Alves <palves@redhat.com>
8844
8845 (%type <voidval>): Add function_method.
8846 * c-exp.y (exp): New production for calls with no arguments.
8847 (function_method, function_method_void_or_typelist): New
8848 productions.
8849 (exp): New production for "method()::static_var".
8850 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8851 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8852 Handle OP_FUNC_STATIC_VAR.
8853 * parse.c (operator_length_standard):
8854 Handle OP_FUNC_STATIC_VAR.
8855
dd5901a6
PA
88562017-09-04 Pedro Alves <palves@redhat.com>
8857
8858 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8859 handling.
8860 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8861 Ditto.
8862 * parse.c (operator_length_standard, operator_check_standard):
8863 Ditto.
8864 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8865
46a4882b
PA
88662017-09-04 Pedro Alves <palves@redhat.com>
8867
8868 * ax-gdb.c: Include "typeprint.h".
8869 (gen_expr_for_cast): New function.
8870 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8871 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8872 type is unknown.
8873 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8874 nodebug_data_symbol.
8875 * eval.c: Include "typeprint.h".
8876 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8877 Error out if symbol has unknown type.
8878 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8879 evaluate_subexp_for_cast.
8880 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8881 OP_VAR_MSYM_VALUE.
8882 (evaluate_subexp_for_cast): New function.
8883 * gdbtypes.c (init_nodebug_var_type): New function.
8884 (objfile_type): Use it to initialize types of variables with no
8885 debug info.
8886 * typeprint.c (error_unknown_type): New.
8887 * typeprint.h (error_unknown_type): New declaration.
8888 * compile/compile-c-types.c (convert_type_basic): Handle
8889 TYPE_CODE_ERROR; warn and fallback to int for variables with
8890 unknown type.
8891
fe13dfec
PA
88922017-09-04 Pedro Alves <palves@redhat.com>
8893
8894 * eval.c (evaluate_var_value): New function, factored out from ...
8895 (evaluate_subexp_standard): ... here.
8896
d008ee21
PA
88972017-09-04 Pedro Alves <palves@redhat.com>
8898
8899 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8900 Remove useless assignments to 'op'.
8901
827d0c51
PA
89022017-09-04 Pedro Alves <palves@redhat.com>
8903
8904 * eval.c (eval_skip_value): New function.
8905 (evaluate_subexp_standard): Use it.
8906
2c5a2be1
PA
89072017-09-04 Pedro Alves <palves@redhat.com>
8908
8909 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8910 function name from symbol/minsym and pass it to
8911 error_call_unknown_return_type.
8912
74ea4be4
PA
89132017-09-04 Pedro Alves <palves@redhat.com>
8914
8915 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8916 * ax-gdb.c (gen_msym_var_ref): New function.
8917 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8918 * eval.c (evaluate_var_msym_value): New function.
8919 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8920 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8921 to call_function_by_hand.
8922 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8923 Handle OP_VAR_MSYM_VALUE.
8924 (union exp_element) <msymbol>: New field.
8925 * minsyms.h (struct type): Forward declare.
8926 (find_minsym_type_and_address): Declare.
8927 * parse.c (write_exp_elt_msym): New function.
8928 (write_exp_msymbol): Delete, refactored as ...
8929 (find_minsym_type_and_address): ... this new function.
8930 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8931 (operator_length_standard, operator_check_standard): Handle
8932 OP_VAR_MSYM_VALUE.
8933 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8934
7022349d
PA
89352017-09-04 Pedro Alves <palves@redhat.com>
8936
8937 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8938 TYPE_GNU_IFUNC specially here. Throw error if return type is
8939 unknown.
8940 * ada-typeprint.c (print_func_type): Handle functions with unknown
8941 return type.
8942 * c-typeprint.c (c_type_print_base): Handle functions and methods
8943 with unknown return type.
8944 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8945 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8946 * compile/compile-c-types.c: Include "objfiles.h".
8947 (convert_func): For functions with unknown return type, warn and
8948 default to int.
8949 * compile/compile-object-run.c (compile_object_run): Adjust call
8950 to call_function_by_hand_dummy.
8951 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8952 call_function_by_hand.
8953 * eval.c (evaluate_subexp_standard): Adjust calls to
8954 call_function_by_hand. Handle functions and methods with unknown
8955 return type. Pass expect_type to call_function_by_hand.
8956 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8957 return type.
8958 * gcore.c (call_target_sbrk): Adjust call to
8959 call_function_by_hand.
8960 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8961 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8962 an integer address type instead of nodebug.
8963 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8964 call_function_by_hand.
8965 * infcall.c (error_call_unknown_return_type): New function.
8966 (call_function_by_hand): New "default_return_type" parameter.
8967 Pass it down.
8968 (call_function_by_hand_dummy): New "default_return_type"
8969 parameter. Use it instead of defaulting to int. If there's no
8970 default and the return type is unknown, throw an error. If
8971 there's a default return type, and the called function has no
8972 debug info, then assume the function is prototyped.
8973 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8974 New "default_return_type" parameter.
8975 (error_call_unknown_return_type): New declaration.
8976 * linux-fork.c (call_lseek): Cast return type of lseek.
8977 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8978 call_function_by_hand.
8979 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8980 calls to call_function_by_hand.
8981 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8982 return type.
8983 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8984 (value_nsstring, print_object_command): Adjust calls to
8985 call_function_by_hand.
8986 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8987 functions with unknown return type.
8988 (pascal_type_print_func_varspec_suffix): New function.
8989 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8990 TYPE_CODE_METHOD>: Use it.
8991 * python/py-value.c (valpy_call): Adjust call to
8992 call_function_by_hand.
8993 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8994 call_function_by_hand.
8995 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8996 call_function_by_hand.
8997 * valops.c (value_allocate_space_in_inferior): Adjust call to
8998 call_function_by_hand.
8999 * typeprint.c (type_print_unknown_return_type): New function.
9000 * typeprint.h (type_print_unknown_return_type): New declaration.
9001
54990598
PA
90022017-09-04 Pedro Alves <palves@redhat.com>
9003
9004 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
9005 types with more than one parameter as prototyped.
9006
9a24775b
PA
90072017-09-04 Pedro Alves <palves@redhat.com>
9008
9009 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
9010 (disassemble_command): Use gdb_disassembly_flags instead of bare
9011 int.
9012 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
9013 (dump_insns, do_mixed_source_and_assembly_deprecated)
9014 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
9015 Use gdb_disassembly_flags instead of bare int.
9016 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
9017 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
9018 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
9019 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
9020 (enum gdb_disassembly_flag): ... values of this new enumeration.
9021 (gdb_disassembly_flags): Define.
9022 (gdb_disassembly)
9023 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
9024 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
9025 gdb_disassembly_flags instead of bare int.
9026 * record-btrace.c (btrace_insn_history)
9027 (record_btrace_insn_history, record_btrace_insn_history_range)
9028 (record_btrace_insn_history_from): Use gdb_disassembly_flags
9029 instead of bare int.
9030 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
9031 Use gdb_disassembly_flags instead of bare int.
9032 * target-debug.h (target_debug_print_gdb_disassembly_flags):
9033 Define.
9034 * target-delegates.c: Regenerate.
9035 * target.c (target_insn_history, target_insn_history_from)
9036 (target_insn_history_range): Use gdb_disassembly_flags instead of
9037 bare int.
9038 * target.h: Include "disasm.h".
9039 (struct target_ops) <to_insn_history, to_insn_history_from,
9040 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
9041 int.
9042 (target_insn_history, target_insn_history_from)
9043 (target_insn_history_range): Use gdb_disassembly_flags instead of
9044 bare int.
9045
80a65e9b
SM
90462017-09-04 Simon Marchi <simon.marchi@ericsson.com>
9047
9048 * cli/cli-script.c (build_command_line): For if/while commands,
9049 check whether args is empty.
9050
6b66338c
SM
90512017-09-04 Simon Marchi <simon.marchi@ericsson.com>
9052
9053 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
9054 (enum command_control_type): Likewise.
9055 (struct command_line): Likewise.
9056 (free_command_lines): Likewise.
9057 (struct command_lines_deleter): Likewise.
9058 (command_line_up): Likewise.
9059 (read_command_lines): Likewise.
9060 (read_command_lines_1): Likewise.
9061 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
9062 (enum command_control_type): Likewise.
9063 (struct command_line): Likewise.
9064 (free_command_lines): Likewise.
9065 (struct command_lines_deleter): Likewise.
9066 (command_line_up): Likewise.
9067 (read_command_lines): Likewise.
9068 (read_command_lines_1): Likewise.
9069 * breakpoint.h: Include cli/cli-script.h.
9070 * extension-priv.h: Likewise.
9071 * gdbcmd.h: Likewise.
9072
51abb421
PA
90732017-09-04 Pedro Alves <palves@redhat.com>
9074
9075 * ada-lang.c (is_known_support_routine): Move sal declaration to
9076 where it is initialized.
9077 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
9078 (parse_breakpoint_sals, decode_static_tracepoint_spec)
9079 (clear_command, update_static_tracepoint): Remove init_sal
9080 references. Move declarations closer to initializations.
9081 * cli/cli-cmds.c (list_command): Move sal declarations closer to
9082 initializations.
9083 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
9084 references. Move sal declarations closer to initializations.
9085 * frame.c (find_frame_sal): Return a symtab_and_line via function
9086 return instead of output parameter. Remove init_sal references.
9087 * frame.h (find_frame_sal): Return a symtab_and_line via function
9088 return instead of output parameter.
9089 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
9090 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
9091 instead of memset.
9092 (gdbscm_find_pc_line): Remove init_sal reference.
9093 * infcall.c (call_function_by_hand_dummy): Remove init_sal
9094 references. Move declarations closer to initializations.
9095 * infcmd.c (set_step_frame): Update. Move declarations closer to
9096 initializations.
9097 (finish_backward): Remove init_sal references. Move declarations
9098 closer to initializations.
9099 * infrun.c (process_event_stop_test, handle_step_into_function)
9100 (insert_hp_step_resume_breakpoint_at_frame)
9101 (insert_step_resume_breakpoint_at_caller): Likewise.
9102 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
9103 (symbol_to_sal): Likewise.
9104 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
9105 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
9106 to its initialization.
9107 * reverse.c (save_bookmark_command): Use new/delete. Remove
9108 init_sal references. Move declarations closer to initializations.
9109 * source.c (get_current_source_symtab_and_line): Remove brace
9110 initialization.
9111 (set_current_source_symtab_and_line): Now takes the sal by const
9112 reference. Remove brace initialization.
9113 (line_info): Remove init_sal reference.
9114 * source.h (set_current_source_symtab_and_line): Now takes a
9115 symtab_and_line via const reference.
9116 * stack.c (set_current_sal_from_frame): Adjust.
9117 (print_frame_info): Adjust.
9118 (get_last_displayed_sal): Return the sal via function return
9119 instead of via output parameter. Simplify.
9120 (frame_info): Adjust.
9121 * stack.h (get_last_displayed_sal): Return the sal via function
9122 return instead of via output parameter.
9123 * symtab.c (init_sal): Delete.
9124 (find_pc_sect_line): Remove init_sal references. Move
9125 declarations closer to initializations.
9126 (find_function_start_sal): Remove init_sal references. Move
9127 declarations closer to initializations.
9128 * symtab.h (struct symtab_and_line): In-class initialize all
9129 fields.
9130 * tracepoint.c (set_traceframe_context)
9131 (print_one_static_tracepoint_marker): Remove init_sal references.
9132 Move declarations closer to initializations.
9133 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
9134 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
9135 declarations closer to initializations.
9136 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
9137 init_sal references. Adjust.
9138
6c5b2ebe
PA
91392017-09-04 Pedro Alves <palves@redhat.com>
9140
9141 * ax-gdb.c (agent_command_1): Use range-for.
9142 * break-catch-throw.c (re_set_exception_catchpoint): Update.
9143 * breakpoint.c: Include "common/array-view.h".
9144 (init_breakpoint_sal, create_breakpoint_sal): Change sals
9145 parameter from struct symtabs_and_lines to
9146 array_view<symtab_and_line>. Adjust. Use range-for. Update.
9147 (breakpoint_sals_to_pc): Change sals parameter from struct
9148 symtabs_and_lines to std::vector reference.
9149 (check_fast_tracepoint_sals): Change sals parameter from struct
9150 symtabs_and_lines to std::array_view. Use range-for.
9151 (decode_static_tracepoint_spec): Return a std::vector instead of
9152 symtabs_and_lines. Update.
9153 (create_breakpoint): Update.
9154 (break_range_command, until_break_command, clear_command): Update.
9155 (base_breakpoint_decode_location, bkpt_decode_location)
9156 (bkpt_probe_create_sals_from_location)
9157 (bkpt_probe_decode_location, tracepoint_decode_location)
9158 (tracepoint_probe_decode_location)
9159 (strace_marker_create_sals_from_location): Return a std::vector
9160 instead of symtabs_and_lines.
9161 (strace_marker_create_breakpoints_sal): Update.
9162 (strace_marker_decode_location): Return a std::vector instead of
9163 symtabs_and_lines. Update.
9164 (update_breakpoint_locations): Change struct symtabs_and_lines
9165 parameters to gdb::array_view. Adjust.
9166 (location_to_sals): Return a std::vector instead of
9167 symtabs_and_lines. Update.
9168 (breakpoint_re_set_default): Use std::vector instead of struct
9169 symtabs_and_lines.
9170 (decode_location_default): Return a std::vector instead of
9171 symtabs_and_lines. Update.
9172 * breakpoint.h: Include "common/array-view.h".
9173 (struct breakpoint_ops) <decode_location>: Now returns a
9174 std::vector instead of returning a symtabs_and_lines via output
9175 parameter.
9176 (update_breakpoint_locations): Change sals parameters to use
9177 gdb::array_view.
9178 * cli/cli-cmds.c (edit_command, list_command): Update to use
9179 std::vector and gdb::array_view.
9180 (ambiguous_line_spec): Adjust to use gdb::array_view and
9181 range-for.
9182 (compare_symtabs): Rename to ...
9183 (cmp_symtabs): ... this. Change parameters to symtab_and_line
9184 const reference and adjust.
9185 (filter_sals): Rewrite using std::vector and standard algorithms.
9186 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
9187 (jump_command): Update to use std::vector.
9188 * linespec.c (struct linespec_state) <canonical_names>: Update
9189 comment.
9190 (add_sal_to_sals_basic): Delete.
9191 (add_sal_to_sals, filter_results, convert_results_to_lsals)
9192 (decode_line_2, create_sals_line_offset)
9193 (convert_address_location_to_sals, convert_linespec_to_sals)
9194 (convert_explicit_location_to_sals, parse_linespec)
9195 (event_location_to_sals, decode_line_full, decode_line_1)
9196 (decode_line_with_current_source)
9197 (decode_line_with_last_displayed, decode_objc)
9198 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
9199 (linespec_result::~linespec_result): Adjust to use std::vector
9200 instead of symtabs_and_lines.
9201 * linespec.h (linespec_sals::sals): Now a std::vector.
9202 (struct linespec_result): Use std::vector, bool, and in-class
9203 initialization.
9204 (decode_line_1, decode_line_with_current_source)
9205 (decode_line_with_last_displayed): Return std::vector.
9206 * macrocmd.c (info_macros_command): Use std::vector.
9207 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
9208 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
9209 std::vector.
9210 * probe.h (parse_probes): Return a std::vector.
9211 * python/python.c (gdbpy_decode_line): Use std::vector and
9212 gdb::array_view.
9213 * source.c (select_source_symtab, line_info): Use std::vector.
9214 * stack.c (func_command): Use std::vector.
9215 * symtab.h (struct symtabs_and_lines): Delete.
9216 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
9217
7c44b49c
PA
92182017-09-04 Pedro Alves <palves@redhat.com>
9219
9220 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9221 unittests/array-view-selftests.c.
9222 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
9223 * common/array-view.h: New file.
9224 * unittests/array-view-selftests.c: New file.
9225
e439fa14
PA
92262017-09-04 Pedro Alves <palves@redhat.com>
9227
9228 * cli/cli-cmds.c (edit_command): Pass message to
9229 ambiguous_line_spec.
9230 (list_command): Pass message to ambiguous_line_spec. Say
9231 "first"/"last" instead of "start" and "end" to be consistent with
9232 the manual.
9233 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
9234 them to print formatted message.
9235
7525b645
PA
92362017-09-04 Pedro Alves <palves@redhat.com>
9237
9238 * btrace.c (ftrace_add_pt): Pass btrace_insn to
9239 ftrace_update_insns by reference instead of pointer.
9240
badc0020
YQ
92412017-09-04 Yao Qi <yao.qi@linaro.org>
9242
9243 * i386-go32-tdep.c: Include x86-xstate.h.
9244 (i386_go32_init_abi): Call i386_target_description.
9245 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
9246 if xcr0 is X86_XSTATE_X87_MASK.
9247 * i386-tdep.h (tdesc_i386): Remove the declaration.
9248 (tdesc_i386_mmx): Likewise.
9249
d78bdb54
YQ
92502017-09-04 Yao Qi <yao.qi@linaro.org>
9251
9252 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
9253 X86_XSTATE_SSE_MASK instead of 0.
9254
ca1fa5ee
YQ
92552017-09-04 Yao Qi <yao.qi@linaro.org>
9256
9257 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
9258 i386_target_description.
9259 * i386-fbsd-nat.c (i386fbsd_read_description): Call
9260 i386_target_description.
9261 * i386-tdep.c (i386_gdbarch_init): Likewise.
9262
2434b019
YQ
92632017-09-04 Yao Qi <yao.qi@linaro.org>
9264
9265 * amd64-darwin-tdep.c: Include "x86-xstate.h".
9266 (x86_darwin_init_abi_64): Call amd64_target_description.
9267 * amd64-dicos-tdep.c: Likewise.
9268 * amd64-fbsd-nat.c: Likewise.
9269 * amd64-fbsd-tdep.c: Likewise.
9270 * amd64-nbsd-tdep.c: Likewise.
9271 * amd64-obsd-tdep.c: Likewise.
9272 * amd64-sol2-tdep.c: Likewise.
9273 * amd64-windows-tdep.c: Likewise.
9274 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
9275
0860c437
SM
92762017-09-04 Simon Marchi <simon.marchi@ericsson.com>
9277
9278 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
9279 (btrace_function) <insn>: Change type to use std::vector.
9280 * btrace.c (ftrace_debug, ftrace_call_num_insn,
9281 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
9282 ftrace_update_insns, ftrace_compute_global_level_offset,
9283 btrace_stitch_bts, btrace_clear, btrace_insn_get,
9284 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
9285 change to std::vector.
9286 (ftrace_update_insns): Adjust to change to std::vector, change
9287 type of INSN parameter.
9288 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
9289 * record-btrace.c (btrace_call_history_insn_range,
9290 btrace_compute_src_line_range,
9291 record_btrace_frame_prev_register): Adjust to change to
9292 std::vector.
9293 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
9294 to change to std::vector.
9295
0638b7f9
TT
92962017-09-03 Tom Tromey <tom@tromey.com>
9297
9298 * corefile.c (reopen_exec_file): Use std::string.
9299
8f84fb0e
TT
93002017-09-03 Tom Tromey <tom@tromey.com>
9301
9302 * compile/compile.c (compile_register_name_mangled): Return
9303 std::string.
9304 * compile/compile-loc2c.c (pushf_register_address): Update.
9305 (pushf_register): Update.
9306 * compile/compile-c-types.c (convert_array): Update.
9307 * compile/compile-c-symbols.c (generate_vla_size): Update.
9308 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
9309 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
9310 (convert_one_symbol): Update.
9311 (generate_c_for_for_one_variable): Update.
9312 * compile/compile-c-support.c (c_get_range_decl_name): Return a
9313 std::string.
9314 (generate_register_struct): Update.
9315 * compile/compile-internal.h (c_get_range_decl_name): Return a
9316 std::string.
9317 (compile_register_name_mangled): Return std::string.
9318
18e9961f
TT
93192017-09-03 Tom Tromey <tom@tromey.com>
9320
9321 * utils.c (perror_string): Return a std::string.
9322 (throw_perror_with_name, perror_warning_with_name): Update.
9323
45343786
TT
93242017-09-03 Tom Tromey <tom@tromey.com>
9325
9326 * demangle.c (demangle_command): Use std::string,
9327 unique_xmalloc_ptr.
9328
b57af503
TT
93292017-09-03 Tom Tromey <tom@tromey.com>
9330
9331 * cli/cli-setshow.c (do_set_command): Use std::string.
9332
6eecf35f
TT
93332017-09-03 Tom Tromey <tom@tromey.com>
9334
9335 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
9336
56496dd4
TT
93372017-09-03 Tom Tromey <tom@tromey.com>
9338
9339 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
9340
e91a1fa7
TT
93412017-09-03 Tom Tromey <tom@tromey.com>
9342
9343 * mi/mi-cmd-env.c (env_execute_cli_command): Use
9344 gdb::unique_xmalloc_ptr.
9345
7ffd83d7
TT
93462017-09-03 Tom Tromey <tom@tromey.com>
9347
9348 * thread.c (print_thread_info_1): Use string_printf.
9349 (thread_apply_command, thread_apply_all_command): Use
9350 std::string.
9351
1ccbe998
TT
93522017-09-03 Tom Tromey <tom@tromey.com>
9353
9354 * valprint.c (val_print_string): Update.
9355 * gdbcore.h (memory_error_message): Return std::string.
9356 * corefile.c (memory_error_message): Return std::string.
9357 (memory_error): Update.
9358 * breakpoint.c (insert_bp_location): Update.
9359
23fdd69e
SM
93602017-09-03 Simon Marchi <simon.marchi@ericsson.com>
9361
9362 * target/waitstatus.h (target_waitstatus_to_string): Change
9363 return type to std::string.
9364 * target/waitstatus.c (target_waitstatus_to_string): Return
9365 std::string.
9366 * target.h (target_waitstatus_to_string): Remove declaration.
9367 * infrun.c (resume, clear_proceed_status_thread,
9368 print_target_wait_results, do_target_wait, save_waitstatus,
9369 stop_all_threads): Adjust.
9370 * record-btrace.c (record_btrace_wait): Adjust.
9371 * target-debug.h
9372 (target_debug_print_struct_target_waitstatus_p): Adjust.
9373
5c811d30
JK
93742017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
9375
9376 PR gdb/22046
9377 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
9378 detection.
9379
0a2dde4a
SDJ
93802017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
9381
9382 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
9383 for setting/unsetting environment variables on the remote target.
9384 (New remote packets): Add entries for QEnvironmentHexEncoded,
9385 QEnvironmentUnset and QEnvironmentReset.
9386 * common/environ.c (gdb_environ::operator=): Extend method to
9387 handle m_user_set_env_list and m_user_unset_env_list.
9388 (gdb_environ::clear): Likewise.
9389 (match_var_in_string): Change type of first parameter from 'char
9390 *' to 'const char *'.
9391 (gdb_environ::set): Extend method to handle
9392 m_user_set_env_list and m_user_unset_env_list.
9393 (gdb_environ::unset): Likewise.
9394 (gdb_environ::clear_user_set_env): New method.
9395 (gdb_environ::user_set_envp): Likewise.
9396 (gdb_environ::user_unset_envp): Likewise.
9397 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
9398 m_user_unset_env_list on move constructor/assignment.
9399 (unset): Add new default parameter 'update_unset_list = true'.
9400 (clear_user_set_env): New method.
9401 (user_set_envp): Likewise.
9402 (user_unset_envp): Likewise.
9403 (m_user_set_env_list): New std::set.
9404 (m_user_unset_env_list): Likewise.
9405 * common/rsp-low.c (hex2str): New function.
9406 (bin2hex): New overload for bin2hex function.
9407 * common/rsp-low.c (hex2str): New prototype.
9408 (str2hex): New overload prototype.
9409 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
9410 QEnvironmentUnset and QEnvironmentReset.
9411 (remote_protocol_features): Add QEnvironmentHexEncoded,
9412 QEnvironmentUnset and QEnvironmentReset packets.
9413 (send_environment_packet): New function.
9414 (extended_remote_environment_support): Likewise.
9415 (extended_remote_create_inferior): Call
9416 extended_remote_environment_support.
9417 (_initialize_remote): Add QEnvironmentHexEncoded,
9418 QEnvironmentUnset and QEnvironmentReset packet configs.
9419 * unittests/environ-selftests.c (gdb_selftest_env_var):
9420 New variable.
9421 (test_vector_initialization): New function.
9422 (test_init_from_host_environ): Likewise.
9423 (test_reinit_from_host_environ): Likewise.
9424 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
9425 Likewise.
9426 (test_unset_set_empty_vector): Likewise.
9427 (test_vector_clear): Likewise.
9428 (test_std_move): Likewise.
9429 (test_move_constructor):
9430 (test_self_move): Likewise.
9431 (test_set_unset_reset): Likewise.
9432 (run_tests): Rewrite in terms of the functions above.
9433
654670a4
WP
94342017-08-31 Weimin Pan <weimin.pan@oracle.com>
9435
9436 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
9437 (adi_available): Use a temp variable of type CORE_ADDR as argument
9438 3 when calling target_auxv_search.
9439 (adi_normalize_address): Use masks and xor operators to calculate
9440 normalized address.
9441 (adi_read_versions, adi_write_versions, adi_print_versions)
9442 (do_examine, do_assign): Use paddress.
9443
7755ddb7
JB
94442017-08-29 John Baldwin <jhb@FreeBSD.org>
9445
9446 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
9447 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
9448 out of loop and add supply of FIR.
9449 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
9450 add collect of FIR.
9451
fd437cbc
SM
94522017-08-28 Simon Marchi <simon.marchi@ericsson.com>
9453
3804a343 9454 PR gdb/21827
fd437cbc
SM
9455 * cli/cli-script.c (define_command): Don't convert command name
9456 to lower case.
9457
988f6b3d
JB
94582017-08-25 Joel Brobecker <brobecker@adacore.com>
9459
9460 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
9461 Update all callers accordingly. Remove all code blocks handling
9462 the case where DISPP is not NULL.
9463
663c44ac
JK
94642017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9465
9466 PR symtab/22003
9467 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
9468 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9469 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
9470
f1902523
JK
94712017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9472
9473 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
9474 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
9475 (read_comp_units_from_section): New parameter abbrev_section, use
9476 read_and_check_comp_unit_head, allocate signatured_type if needed.
9477 (create_all_comp_units): Update read_comp_units_from_section caller.
9478
87215ad1
SDJ
94792017-08-23 Pedro Alves <palves@redhat.com>
9480
9481 PR remote/21852
9482 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
9483 to null_ptid and switch to thread without reading the registers
9484 after adding the inferior.
9485
6e41ddec
JK
94862017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9487
9488 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
9489 compile-gcc.
9490 * compile/compile.c (compile_gcc, show_compile_gcc): New.
9491 (compile_to_object): Implement compile_gcc.
9492 (_initialize_compile): Install "set compile-gcc". Initialize
9493 compile_gcc.
9494
e68c32d5
JK
94952017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9496
9497 * compile/compile.c (compile_to_object): Conditionally call
9498 set_verbose. Conditionally call compile or compile_v0.
9499
58afddc6
WP
95002017-08-07 Weimin Pan <weimin.pan@oracle.com>
9501
9502 * sparc64-tdep.h: (adi_normalize_address): New export.
9503 * sparc-nat.h: (open_adi_tag_fd): New export.
9504 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
9505 * sparc64-linux-tdep.c:
9506 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
9507 (sparc64_linux_handle_segmentation_fault): New function.
9508 (sparc64_linux_init_abi): Register
9509 sparc64_linux_handle_segmentation_fault
9510 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
9511 (sparc64_addr_bits_remove): New function.
9512 (sparc64_init_abi): Register sparc64_addr_bits_remove.
9513 (MAX_PROC_NAME_SIZE): New macro.
9514 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
9515 (sparc64adilist): New variable.
9516 (adi_proc_list): New variable.
9517 (find_adi_info): New function.
9518 (add_adi_info): New function.
9519 (get_adi_info_proc): New function.
9520 (get_adi_info): New function.
9521 (info_adi_command): New function.
9522 (read_maps_entry): New function.
9523 (adi_available): New function.
9524 (adi_normalize_address): New function.
9525 (adi_align_address): New function.
9526 (adi_convert_byte_count): New function.
9527 (adi_tag_fd): New function.
9528 (adi_is_addr_mapped): New function.
9529 (adi_read_versions): New function.
9530 (adi_write_versions): New function.
9531 (adi_print_versions): New function.
9532 (do_examine): New function.
9533 (do_assign): New function.
9534 (adi_examine_command): New function.
9535 (adi_assign_command): New function.
9536 (_initialize_sparc64_adi_tdep): New function.
9537
11db9430
SM
95382017-08-22 Simon Marchi <simon.marchi@ericsson.com>
9539
9540 * breakpoint.c (breakpoints_info): Rename to ...
9541 (info_breakpoints_command): ... this.
9542 (watchpoints_info): Rename to ...
9543 (info_watchpoints_command): ... this.
9544 (tracepoints_info): Rename to ...
9545 (info_tracepoints_command): ... this.
9546 (_initialize_breakpoint): Adjust.
9547 * dcache.c (dcache_info): Rename to ...
9548 (info_display_command): ... this.
9549 (_initialize_dcache): Adjust.
9550 * frame.h (args_info): Rename to ...
9551 (info_args_command): ... this.
9552 (locals_info): Rename to ...
9553 (info_locals_command): ... this.
9554 * infcmd.c (nofp_registers_info): Rename to ...
9555 (info_registers_command): ... this.
9556 (float_info): Rename to ...
9557 (info_float_command): ... this.
9558 (program_info): Rename to ...
9559 (info_program_command): ... this.
9560 (all_registers_info): Rename to ...
9561 (info_all_registers_command): ... this.
9562 (vector_info): Rename to ...
9563 (info_vector_command): ... this.
9564 (float_info): Rename to ...
9565 (info_float_command): ... this.
9566 (_initialize_infcmd): Adjust.
9567 * inferior.h (term_info): Rename to ...
9568 (info_terminal_command): ... this.
9569 * inflow.c (term_info): Rename to ...
9570 (info_terminal_command): ... this.
9571 (_initialize_inflow): Adjust.
9572 * infrun.c (signals_info): Rename to ...
9573 (info_signals_command): ... this.
9574 (_initialize_infrun): Adjust.
9575 * objc-lang.c (classes_info): Rename to ...
9576 (info_classes_command): ... this.
9577 (selectors_info): Rename to ...
9578 (info_selectors_command): ... this.
9579 (_initialize_objc_language): Adjust.
9580 * printcmd.c (sym_info): Rename to ...
9581 (info_symbol_command): ... this.
9582 (address_info): Rename to ...
9583 (info_address_command): ... this.
9584 (display_info): Rename to ...
9585 (info_display_command): ... this.
9586 (_initialize_printcmd): Adjust.
9587 * reverse.c (bookmarks_info): Rename to ...
9588 (info_breakpoints_command): ... this.
9589 (_initialize_reverse): Adjust.
9590 * ser-go32.c (dos_info): Rename to ...
9591 (info_serial_command): ... this.
9592 (_initialize_ser_dos): Adjust.
9593 * skip.c (skip_info): Rename to ...
9594 (info_skip_command): ... this.
9595 (_initialize_step_skip): Adjust.
9596 * source.c (line_info): Rename to ...
9597 (info_line_command): ... this.
9598 (source_info): Rename to ...
9599 (info_source_command)
9600 * stack.c (frame_info): Rename to ...
9601 (info_frame_command): ... this.
9602 (locals_info): Rename to ...
9603 (info_locals_command): ... this.
9604 (args_info): Rename to ...
9605 (info_args_command): ... this.
9606 (_initialize_stack): Adjust.
9607 * symtab.c (sources_info): Rename to ...
9608 (info_sources_command): ... this.
9609 (variables_info): Rename to ...
9610 (info_variables_command): ... this.
9611 (functions_info): Rename to ...
9612 (info_functions_command): ... this.
9613 (types_info): Rename to ...
9614 (info_types_command): ... this.
9615 (_initialize_symtab): Adjust.
9616 * target.c (target_info): Rename to ...
9617 (info_target_command): ... this.
9618 (initialize_targets): Adjust.
9619 * tracepoint.c (tvariables_info): Rename to ...
9620 (info_tvariables_command): ... this.
9621 (scope_info): Rename to ...
9622 (info_scope_command): ... this.
9623 (trace_dump_actions): Adjust.
9624 (_initialize_tracepoint): Adjust.
9625
b270e6f9
TT
96262017-08-22 Tom Tromey <tom@tromey.com>
9627
9628 * breakpoint.h (install_breakpoint): Update.
9629 * breakpoint.c (add_solib_catchpoint): Update.
9630 (install_breakpoint): Change argument to a std::unique_ptr.
9631 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
9632 (create_breakpoint_sal, create_breakpoint): Update.
9633 (watch_command_1, catch_exec_command_1)
9634 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
9635 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
9636 Return the breakpoint.
9637 (set_raw_breakpoint_without_location, set_raw_breakpoint)
9638 (new_single_step_breakpoint): Update.
9639 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
9640 std::unique_ptr.
9641 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9642 std::unique_ptr.
9643 * break-catch-sig.c (create_signal_catchpoint): Use
9644 std::unique_ptr.
9645 * ada-lang.c (create_ada_exception_catchpoint): Use
9646 std::unique_ptr.
9647
36bd8eaa
TT
96482017-08-22 Tom Tromey <tom@tromey.com>
9649
9650 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
9651
56f37645
TT
96522017-08-22 Tom Tromey <tom@tromey.com>
9653
9654 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9655 (lookup_partial_symbol): Update.
9656
0b581c69
TT
96572017-08-22 Tom Tromey <tom@tromey.com>
9658
9659 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9660 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9661 (find_and_open_source, symtab_to_fullname): Update.
9662 * psymtab.c (psymtab_to_fullname): Update.
9663
14278e1f
TT
96642017-08-22 Tom Tromey <tom@tromey.com>
9665
9666 * exec.c (exec_file_attach): Update.
9667 * linux-thread-db.c (try_thread_db_load): Update.
9668 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9669 * utils.c (gdb_realpath): Change return type.
9670 (gdb_realpath_keepfile): Update.
9671 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9672 (_initialize_utils): Register the new self test.
9673 * source.c (openp): Update.
9674 (find_and_open_source): Update.
9675 * nto-tdep.c (nto_find_and_open_solib): Update.
9676 * main.c (set_gdb_data_directory): Update.
9677 (captured_main_1): Update.
9678 * dwarf2read.c (dwarf2_get_dwz_file): Update
9679 (dw2_map_symbol_filenames): Update.
9680 * auto-load.c (auto_load_safe_path_vec_update): Update.
9681 (filename_is_in_auto_load_safe_path_vec): Change type of
9682 "filename_realp".
9683 (auto_load_objfile_script): Update.
9684 (file_is_auto_load_safe): Update. Use std::string.
9685 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9686
4971c9a7
TT
96872017-08-22 Tom Tromey <tom@tromey.com>
9688
9689 * utils.c (gdb_realpath_keepfile): Return a
9690 gdb::unique_xmalloc_ptr.
9691 * exec.c (exec_file_attach): Update.
9692 * utils.h (gdb_realpath_keepfile): Return a
9693 gdb::unique_xmalloc_ptr.
9694
e3e41d58
TT
96952017-08-22 Tom Tromey <tom@tromey.com>
9696
9697 * compile/compile.c (compile_file_command): Use
9698 gdb::unique_xmalloc_ptr, std::string.
9699 * utils.c (gdb_abspath): Change return type.
9700 * source.c (openp): Update.
9701 * objfiles.c (allocate_objfile): Update.
9702 * main.c (set_gdb_data_directory): Update.
9703 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9704
0d999a6e
ZZ
97052017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9706
9707 * cli-cmds.c (list_commands): List actual code around more than
9708 one location.
9709
329d5e7e
JB
97102017-08-21 John Baldwin <jhb@FreeBSD.org>
9711
9712 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9713
bf223d3e
PA
97142017-08-21 Pedro Alves <palves@redhat.com>
9715
9716 PR gdb/19487
9717 * c-exp.y (variable production): Handle function aliases.
9718 * minsyms.c (msymbol_is_text): New function.
9719 * minsyms.h (msymbol_is_text): Declare.
9720 * symtab.c (find_function_alias_target): New function.
9721 * symtab.h (find_function_alias_target): Declare.
9722
c973d0aa
PA
97232017-08-21 Pedro Alves <palves@redhat.com>
9724
9725 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9726 typedefs.
9727 * typeprint.c (whatis_exp): If handling "whatis", and expression
9728 is OP_TYPE, strip one typedef level. Otherwise don't strip
9729 typedefs here.
9730 * valops.c (value_cast): Save "to" type before resolving
9731 stubs/typedefs. Use that type as resulting value's type.
9732
2989a365
TT
97332017-08-18 Tom Tromey <tom@tromey.com>
9734 Pedro Alves <palves@redhat.com>
9735
9736 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9737 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9738 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9739 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9740 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9741 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9742 (linux_get_siginfo_data): Add "thread" argument. Use
9743 scoped_restore.
9744 * linux-nat.c (linux_child_follow_fork)
9745 (check_stopped_by_watchpoint): Use scoped_restore.
9746 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9747 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9748 (restore_inferior_ptid, save_inferior_ptid): Remove.
9749 * btrace.c (btrace_fetch): Use scoped_restore.
9750 * bsd-uthread.c (bsd_uthread_fetch_registers)
9751 (bsd_uthread_store_registers): Use scoped_restore.
9752 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9753 scoped_restore.
9754 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9755 (aix_thread_xfer_partial): Use scoped_restore.
9756 * inferior.h (save_inferior_ptid): Remove.
9757
e60eb288
YQ
97582017-08-18 Yao Qi <yao.qi@linaro.org>
9759
9760 PR tdep/21818
9761 * arm-tdep.c (gdb_print_insn_arm): Mark
9762 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9763
6d580b63
YQ
97642017-08-18 Yao Qi <yao.qi@linaro.org>
9765
9766 * NEWS: Mention GDBserver's new option "--selftest".
9767 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9768 * selftest.c: Move it to common/selftest.c.
9769 * selftest.h: Move it to common/selftest.h.
9770 * selftest-arch.c (reset): New function.
9771 (tests_with_arch): Call reset.
9772
86dcbf50
YQ
97732017-08-18 Yao Qi <yao.qi@linaro.org>
9774
9775 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9776 instead of exception_fprintf and printf_filtered.
9777
7649770c
YQ
97782017-08-18 Yao Qi <yao.qi@linaro.org>
9779
9780 * selftest.c (register_self_test): Rename it to
9781 selftests::register_test.
9782 (run_self_tests): selftest::run_tests.
9783 * selftest.h: Update declarations.
9784 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9785 selftests::register_test_foreach_arch.
9786 * selftest-arch.h: Update declaration.
9787 * aarch64-tdep.c: Update.
9788 * arm-tdep.c: Likewise.
9789 * disasm-selftests.c: Likewise.
9790 * dwarf2loc.c: Likewise.
9791 * dwarf2-frame.c: Likewise.
9792 * findvar.c: Likewise.
9793 * gdbarch-selftests.c: Likewise.
9794 * maint.c (maintenance_selftest): Likewise.
9795 * regcache.c: Likewise.
9796 * rust-exp.y: Likewise.
9797 * selftest-arch.c: Likewise.
9798 * unittests/environ-selftests.c: Likewise.
9799 * unittests/function-view-selftests.c: Likewise.
9800 * unittests/offset-type-selftests.c: Likewise.
9801 * unittests/optional-selftests.c: Likewise.
9802 * unittests/scoped_restore-selftests.c: Likewise.
9803 * utils-selftests.c: Likewise.
9804
b0cba12e
PA
98052017-08-17 Pedro Alves <palves@redhat.com>
9806
9807 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9808 local.
9809
4c8aa72d
PA
98102017-08-17 Pedro Alves <palves@redhat.com>
9811
9812 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9813 field.
9814 (reset_die_in_process): Delete, replaced by ...
9815 (process_die_scope): ... this new class. Make it responsible for
9816 freeing cu->line_header too.
9817 (process_die): Use process_die_scope.
9818 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9819 cu->line_header_die_owner. Don't release the line header if it's
9820 owned by the CU.
9821 (setup_type_unit_groups): Make the CU/DIE own the line header.
9822 Don't release the line header here.
9823
ba713918
AL
98242017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9825
9826 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9827
44d0fb3a
RK
98282017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9829
9830 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9831 Single-Key mode
9832
a5afdb16
RK
98332017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9834
9835 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9836 mode command list.
9837
47613aeb
SH
98382017-08-15 Stafford Horne <shorne@gmail.com>
9839
9840 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9841
9c3cc999
SH
98422017-08-15 Stafford Horne <shorne@gmail.com>
9843
9844 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9845
206726fb
SDJ
98462017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9847
9848 PR gdb/21954
9849 * infcmd.c (unset_environment_command): Use the 'clear' method on
9850 the environment instead of resetting it.
9851
0335ac6d
JB
98522017-08-15 John Baldwin <jhb@FreeBSD.org>
9853
9854 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9855 platforms.
9856
d3abe1c8
TT
98572017-08-14 Tom Tromey <tom@tromey.com>
9858
9859 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9860 (print_binary_chars): Likewise.
9861 (BITS_IN_BYTES): Remove.
9862
d6382fff
TT
98632017-08-14 Tom Tromey <tom@tromey.com>
9864
9865 PR gdb/21675
9866 * valprint.c (LOW_ZERO): Change value to 034.
9867 (print_octal_chars): Add static_asserts for octal constants.
9868 * printcmd.c (print_scalar_formatted): Add 'd' case.
9869
f978cb06
TT
98702017-08-11 Tom Tromey <tom@tromey.com>
9871
9872 * symfile.c (add_symbol_file_command): Use std::vector.
9873
2f5404b3
TT
98742017-08-14 Tom Tromey <tom@tromey.com>
9875
9876 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9877 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9878 std::move.
9879 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9880
de7985c3
PA
98812017-08-11 Pedro Alves <palves@redhat.com>
9882
9883 * infrun.c (process_event_stop_test): Adjust
9884 function_name_is_marked_for_skip call.
9885 * skip.c: Include <list>.
9886 (skiplist_entry): Make it a class with private fields, and
9887 getters/setters.
9888 (skiplist_entry_chain): Delete.
9889 (skiplist_entries): New.
9890 (skiplist_entry_count): Delete.
9891 (highest_skiplist_entry_num): New.
9892 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9893 (add_skiplist_entry): Delete.
9894 (skiplist_entry::skiplist_entry): New.
9895 (skiplist_entry::add_entry): New.
9896 (skip_file_command, skip_function): Adjust.
9897 (compile_skip_regexp): Delete.
9898 (skip_command): Don't compile regexp here. Adjust to use
9899 skiplist_entry::add_entry.
9900 (skip_info): Adjust to use range-for and getters.
9901 (skip_enable_command, skip_disable_command): Adjust to use
9902 range-for and setters.
9903 (skip_delete_command): Adjust to use std::list.
9904 (add_skiplist_entry): Delete.
9905 (skip_file_p): Delete, refactored as ...
9906 (skiplist_entry::do_skip_file_p): ... this new method.
9907 (skip_gfile_p): Delete, refactored as ...
9908 (skiplist_entry::do_gskip_file_p): ... this new method.
9909 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9910 (skiplist_entry::skip_function_p): ... this new method.
9911 (function_name_is_marked_for_skip): Now returns bool, and takes
9912 the function sal by const reference. Adjust to use range-for and
9913 skiplist_entry methods.
9914 (_initialize_step_skip): Remove references to
9915 skiplist_entry_chain, skiplist_entry_count.
9916 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9917 takes the function sal by const reference.
9918
be7d3cd5
YQ
99192017-08-11 Yao Qi <yao.qi@linaro.org>
9920
9921 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9922 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9923 (dwarf2_frame_cache):
9924 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9925 RETURN_MASK_ALL and set *this_case to NULL.
9926 * frame-unwind.h: Update comments.
9927
1c90d9f0
YQ
99282017-08-11 Yao Qi <yao.qi@linaro.org>
9929
9930 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9931 (dwarf2_frame_state_copy_regs): Remove.
9932 (dwarf2_frame_state_free_regs): Remove.
9933 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9934 (dwarf2_restore_rule): Call method .alloc_regs instead of
9935 dwarf2_frame_state_alloc_regs.
9936 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9937 constructor. Call std::move.
9938 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9939 (dwarf2_frame_cache): Likewise.
9940
9941 [GDB_SELF_TEST]: Include selftest.h and
9942 selftest-arch.h.
9943 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9944 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9945 execute_cfa_program_test.
9946
9947 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9948 copy ctor, assignment operator, move assignment.
9949 <alloc_regs>: New method.
9950 <swap>: New method.
9951 (struct dwarf2_frame_state): Delete dtor.
9952 (dwarf2_frame_state_alloc_regs): Remove declaration.
9953 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9954 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9955
afe37d6b
YQ
99562017-08-11 Yao Qi <yao.qi@linaro.org>
9957
9958 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9959 (dwarf2_frame_state::dwarf2_frame_state): New.
9960 (dwarf2_frame_state::~dwarf2_frame_state): New.
9961 (dwarf2_fetch_cfa_info): Update.
9962 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9963 rather than a pointer. Update code.
9964 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9965 dtor.
9966 <data_align, code_align, retaddr_column>: Change them to const.
9967 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9968 to bool.
9969
b348037f
YQ
99702017-08-11 Yao Qi <yao.qi@linaro.org>
9971
9972 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9973 <loc.exp>: New field.
9974 * dwarf2-frame.c (execute_cfa_program): Update.
9975 (dwarf2_frame_prev_register): Update.
9976
e7c9de26
PA
99772017-08-10 Pedro Alves <palves@redhat.com>
9978
9979 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9980
e8c6b620
JB
99812017-08-09 John Baldwin <jhb@FreeBSD.org>
9982
9983 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9984 (fbsd_pending_children): Use std::list.
9985 (fbsd_remember_child): Likewise.
9986 (fbsd_is_child_pending): Likewise.
9987 (fbsd_pending_vfork_done): Use std::forward_list.
9988 (fbsd_add_vfork_done): Likewise.
9989 (fbsd_is_vfork_done_pending): Likewise.
9990 (fbsd_next_vfork_done): Likewise.
9991
e4a26669
JB
99922017-08-09 John Baldwin <jhb@FreeBSD.org>
9993
9994 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9995 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9996 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9997 for `mapfilename'.
9998 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 9999 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 10000
142311d3
JB
100012017-08-09 John Baldwin <jhb@FreeBSD.org>
10002
10003 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
10004 "filestuff.h".
10005 (fbsd_find_memory_regions): Fix `mapfile' initialization.
10006
42fa2e0e
TT
100072017-08-09 Tom Tromey <tom@tromey.com>
10008
10009 * skip.c (skiplist_entry): New constructor.
10010 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
10011 (skiplist_entry::file_is_glob): Now bool.
10012 (skiplist_entry::file, skiplist_entry::function): Now
10013 std::string.
10014 (make_skip_entry): Return a unique_ptr. Use new.
10015 (free_skiplist_entry, free_skiplist_entry_cleanup)
10016 (make_free_skiplist_entry_cleanup): Remove.
10017 (skip_command, skip_disable_command, add_skiplist_entry)
10018 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
10019 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
10020 (function_name_is_marked_for_skip): Update.
10021 (skip_delete_command): Update. Use delete.
10022
cd3af38d
JW
100232017-08-09 Jiong Wang <jiong.wang@arm.com>
10024
10025 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
10026 (aarch64_linux_core_read_description): New function.
10027 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
10028
29592bde
PA
100292017-08-09 Pedro Alves <palves@redhat.com>
10030
10031 * cp-name-parser.y (cp_comp_to_string): Return a
10032 gdb::unique_xmalloc_ptr<char>.
10033 * cp-support.c (replace_typedefs_qualified_name)
10034 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
10035 (cp_canonicalize_string_full): Use op= instead of explicit
10036 convertion.
10037 (cp_class_name_from_physname, method_name_from_physname)
10038 (cp_func_name, cp_remove_params): Adjust to use
10039 gdb::unique_xmalloc_ptr<char>.
10040 * cp-support.h (cp_comp_to_string): Return a
10041 gdb::unique_xmalloc_ptr<char>.
10042 * python/py-type.c (typy_lookup_type): Adjust to use
10043 gdb::unique_xmalloc_ptr<char>.
10044
b3340438
L
100452017-08-09 H.J. Lu <hongjiu.lu@intel.com>
10046
10047 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
10048
e88e8651
YQ
100492017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
10050 Yao Qi <yao.qi@linaro.org>
10051
10052 * cp-support.c (cp_canonicalize_string_full): Use
10053 gdb::unique_xmalloc_ptr<char>.
10054 (cp_canonicalize_string): Likewise.
10055
f5a29eb0
YQ
100562017-08-09 Yao Qi <yao.qi@linaro.org>
10057
10058 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
10059 * regformats/i386/amd64-avx-avx512.dat: Remove.
10060 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
10061 * regformats/i386/amd64-avx-mpx.dat:Remove.
10062 * regformats/i386/amd64-avx.dat: Remove.
10063 * regformats/i386/amd64-mpx.dat: Remove.
10064 * regformats/i386/i386-avx-avx512.dat: Remove.
10065 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
10066 * regformats/i386/i386-avx-mpx.dat: Remove.
10067 * regformats/i386/i386-mmx.dat: Remove.
10068 * regformats/i386/i386-mpx.dat: Remove.
10069
57757c2f
YQ
100702017-08-09 Yao Qi <yao.qi@linaro.org>
10071
10072 * amd64-tdep.h (tdesc_x32): Remove the declaration.
10073 * amd64-tdep.c: Don't include features/i386/x32*.c.
10074 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
10075 functions.
10076 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
10077 and i386/x32-avx-avx512.
10078 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
10079 and i386/x32.xml.
10080 * features/i386/x32-avx-avx512.c: Removed.
10081 * features/i386/x32-avx-avx512.xml: Removed.
10082 * features/i386/x32-avx.c: Removed.
10083 * features/i386/x32-avx.xml: Removed.
10084 * features/i386/x32.c: Removed.
10085 * features/i386/x32.xml: Removed.
10086 * regformats/i386/x32-avx-avx512.dat: Removed.
10087 * regformats/i386/x32-avx.dat: Removed.
10088 * regformats/i386/x32.dat: Removed.
10089
ba7b109b
MR
100902017-08-07 Maciej W. Rozycki <macro@imgtec.com>
10091
10092 PR breakpoints/21886
10093 * mem-break.c (default_memory_insert_breakpoint): Use
10094 `->placed_address' rather than `->reqstd_address' for the
10095 breakpoint location.
10096
e347efc3
MR
100972017-08-07 Maciej W. Rozycki <macro@imgtec.com>
10098
10099 * arch-utils.c (default_print_insn): Remove arch/mach/endian
10100 assertions.
10101
0dba2a6c
MR
101022017-08-07 Maciej W. Rozycki <macro@imgtec.com>
10103
10104 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
10105 a union of `tdep_info', `tdesc_data' and `id'.
10106 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
10107 rather than `info.tdep_info'.
10108 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
10109 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
10110 * i386-tdep.c (i386_gdbarch_init): Likewise.
10111 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
10112 * mips-tdep.c (mips_gdbarch_init): Likewise.
10113 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10114 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
10115 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
10116 `info.tdep_info'.
10117 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
10118 `info.tdep_info'.
10119 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10120 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
10121 `info.tdep_info'.
10122 * spu-tdep.c (spu_gdbarch_init): Likewise.
10123 * gdbarch.h: Regenerate.
10124
16eb6b2d
LS
101252017-08-07 Leszek Swirski <leszeks@google.com>
10126
7b005726 10127 PR symtab/20899
16eb6b2d
LS
10128 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
10129
74cbb09e
SM
101302017-08-07 Simon Marchi <simon.marchi@ericsson.com>
10131
10132 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
10133 (gdbsim_open): Rename gdb_argv args object to argv.
10134
ee0c3293
TT
101352017-08-05 Tom Tromey <tom@tromey.com>
10136
10137 * compile/compile-object-load.c (compile_object_load): Use
10138 gdb::unique_xmalloc_ptr.
10139 * cli/cli-dump.c (scan_filename): Rename from
10140 scan_filename_with_cleanup. Change return type.
10141 (scan_expression): Rename from scan_expression_with_cleanup.
10142 Change return type.
10143 (dump_memory_to_file, dump_value_to_file, restore_command):
10144 Use gdb::unique_xmalloc_ptr. Update.
10145 * cli/cli-cmds.c (find_and_open_script): Use
10146 gdb::unique_xmalloc_ptr.
10147 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
10148 * symmisc.c (maintenance_print_symbols)
10149 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
10150 * symfile.c (symfile_bfd_open, generic_load)
10151 (add_symbol_file_command, remove_symbol_file_command): Use
10152 gdb::unique_xmalloc_ptr.
10153 * source.c (openp): Use gdb::unique_xmalloc_ptr.
10154 * psymtab.c (maintenance_print_psymbols): Use
10155 gdb::unique_xmalloc_ptr.
10156 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
10157 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
10158 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
10159 (reload_shared_libraries_1): Likewise.
10160
3232fabd
TT
101612017-08-05 Tom Tromey <tom@tromey.com>
10162
10163 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
10164 (rust_op_vector, rust_set_vector): New typedefs.
10165 (current_parser): New global.
10166 (work_obstack): Change to pointer type. Update all users.
10167 (rust_ast, pstate): Remove globals.
10168 (struct rust_parser): New.
10169 (%union) <params, field_inits>: Change type.
10170 (start, tuple_expr, unit_expr, struct_expr_list, literal)
10171 (field_expr, expr_list, maybe_expr_list, type_list): Update.
10172 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
10173 (convert_params_to_types, convert_params_to_expression): Change
10174 type of "params".
10175 (ast_string): Change type of "fields".
10176 (rust_parse): Make a rust_parser. Remove cleanups.
10177 (rust_lex_tests): Make and install an auto_obstack.
10178
f02fd774
YQ
101792017-08-04 Yao Qi <yao.qi@linaro.org>
10180
10181 * configure.srv (ipa_x32_linux_regobj): New.
10182 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
10183 instead of X86_TDESC_AVX512.
10184 (initialize_low_tracepoint): Call
10185 init_registers_x32_avx_avx512_linux.
10186
91975afd
YQ
101872017-08-04 Yao Qi <yao.qi@linaro.org>
10188
10189 * utils.h (gdb_argv): Add namespace std for nullptr_t.
10190
2331fa3a
RK
101912017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
10192
10193 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
10194
744e4fe1
TT
101952017-08-03 Tom Tromey <tom@tromey.com>
10196
10197 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
10198 Remove.
10199 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
10200
1c034b67
TT
102012017-08-03 Tom Tromey <tom@tromey.com>
10202
10203 * python/py-param.c (compute_enum_values): Use gdb_argv.
10204
773a1edc
TT
102052017-08-03 Tom Tromey <tom@tromey.com>
10206
10207 * utils.h (struct gdb_argv_deleter): New.
10208 (gdb_argv): New class.
10209 * utils.c (gdb_argv::reset): New method.
10210 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
10211 * tracefile.c (tsave_command): Use gdb_argv.
10212 * top.c (new_ui_command): Use gdb_argv.
10213 * symmisc.c (maintenance_print_symbols)
10214 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
10215 * symfile.c (symbol_file_command, generic_load)
10216 (remove_symbol_file_command): Use gdb_argv.
10217 * stack.c (backtrace_command): Use gdb_argv.
10218 * source.c (add_path, show_substitute_path_command)
10219 (unset_substitute_path_command, set_substitute_path_command):
10220 Use gdb_argv.
10221 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
10222 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
10223 * remote.c (extended_remote_run, remote_put_command)
10224 (remote_get_command, remote_delete_command): Use gdb_argv.
10225 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
10226 (gdbsim_open): Use gdb_argv.
10227 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
10228 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
10229 * procfs.c (procfs_info_proc): Use gdb_argv.
10230 * interps.c (interpreter_exec_cmd): Use gdb_argv.
10231 * infrun.c (handle_command): Use gdb_argv.
10232 * inferior.c (add_inferior_command, clone_inferior_command):
10233 Use gdb_argv.
10234 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
10235 * exec.c (exec_file_command): Use gdb_argv.
10236 * cli/cli-cmds.c (alias_command): Use gdb_argv.
10237 * compile/compile.c (build_argc_argv): Use gdb_argv.
10238
0d50bde3
TT
102392017-08-03 Tom Tromey <tom@tromey.com>
10240
10241 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
10242
7f968c89
TT
102432017-08-03 Tom Tromey <tom@tromey.com>
10244
10245 * python/python.c (compute_python_string): Return std::string.
10246 (gdbpy_eval_from_control_command): Update.
10247 (do_start_initialization): Use std::string.
10248 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
10249 xstrprintf.
10250 * python/py-breakpoint.c (local_setattro): Use string_printf, not
10251 xstrprintf.
10252
3c9ebddd
TT
102532017-08-03 Tom Tromey <tom@tromey.com>
10254
10255 * top.h (do_restore_instream_cleanup): Remove.
10256 * top.c (do_restore_instream_cleanup): Remove.
10257 (read_command_file): Use scoped_restore.
10258 * cli/cli-script.c (execute_user_command): Use scoped_restore.
10259
b51b225e
TT
102602017-08-03 Tom Tromey <tom@tromey.com>
10261
10262 * cli/cli-script.c (execute_user_command)
10263 (execute_control_command): Use scoped_restore.
10264
ac991630
TT
102652017-08-03 Tom Tromey <tom@tromey.com>
10266
10267 * cli/cli-script.c (do_restore_user_call_depth): Remove.
10268 (execute_user_command): Remove user_call_depth; use
10269 user_args_stack's size instead.
10270
898e0c8e
TT
102712017-08-03 Tom Tromey <tom@tromey.com>
10272
10273 * top.h (in_user_command): Remove.
10274 * top.c (in_user_command): Remove.
10275 * cli/cli-script.c (do_restore_user_call_depth)
10276 (execute_user_command): Update.
10277
26fcd5d7
TT
102782017-08-03 Tom Tromey <tom@tromey.com>
10279
10280 * valops.c (search_struct_method): Use gdb::byte_vector.
10281 * valarith.c (value_concat): Use std::vector.
10282 * target.c (memory_xfer_partial): Use gdb::byte_vector.
10283 (simple_search_memory): Likewise.
10284 * printcmd.c (find_string_backward): Use gdb::byte_vector.
10285 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
10286 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
10287 * elfread.c (elf_rel_plt_read): Use std::string.
10288 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
10289 * cli/cli-dump.c (restore_section_callback): Use
10290 gdb::byte_vector.
10291
7c218e6c
TT
102922017-08-03 Tom Tromey <tom@tromey.com>
10293
10294 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
10295
31b68d4a
TT
102962017-08-03 Tom Tromey <tom@tromey.com>
10297
10298 * tui/tui-regs.c (tui_restore_gdbout): Remove.
10299 (tui_register_format): Use scoped_restore.
10300
2ec845e7
TT
103012017-08-03 Tom Tromey <tom@tromey.com>
10302
10303 * reverse.c (exec_direction_default): Remove.
10304 (exec_reverse_once): Use scoped_restore.
10305 * remote.c (restore_remote_timeout): Remove.
10306 (remote_flash_erase, remote_flash_write, remote_flash_done)
10307 (readchar, remote_serial_write): Use scoped_restore.
10308 * cli/cli-script.c (struct source_cleanup_lines_args)
10309 (source_cleanup_lines): Remove.
10310 (script_from_file): Use scoped_restore.
10311 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
10312 (source_command): Use scoped_restore.
10313
b3bc8453
TT
103142017-08-03 Tom Tromey <tom@tromey.com>
10315
10316 * utils.h (make_cleanup_free_so): Remove.
10317 * utils.c (do_free_so, make_cleanup_free_so): Remove.
10318 * solist.h (struct so_deleter): New.
10319 (so_list_up): New typedef.
10320 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
10321
e3ad2841
TT
103222017-08-03 Tom Tromey <tom@tromey.com>
10323
10324 * utils.h (make_cleanup_restore_current_language): Remove.
10325 * utils.c (do_restore_current_language)
10326 (make_cleanup_restore_current_language): Remove.
10327 * parse.c (parse_exp_in_context_1)
10328 (parse_expression_with_language): Use
10329 scoped_restore_current_language.
10330 * mi/mi-main.c (mi_cmd_execute): Use
10331 scoped_restore_current_language.
10332 * language.h (scoped_restore_current_language): New class.
10333
b80cf838
TT
103342017-08-03 Tom Tromey <tom@tromey.com>
10335
10336 * compile/compile.c (cleanup_unlink_file): Remove.
10337 (compile_to_object): Use gdb::unlinker.
10338 (eval_compile_command): Likewise.
10339
fad0444a
TT
103402017-08-03 Tom Tromey <tom@tromey.com>
10341
10342 * utils.h (make_cleanup_fclose): Remove.
10343 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
10344
6e7bc05c
TT
103452017-08-03 Tom Tromey <tom@tromey.com>
10346
10347 * top.c (open_terminal_stream): Return gdb_file_up.
10348 (new_ui_command): Update.
10349
4a45905b
TT
103502017-08-03 Tom Tromey <tom@tromey.com>
10351
10352 * source.c (print_source_lines_base, forward_search_command)
10353 (reverse_search_command): Use gdb_file_up.
10354
7cd06d6e
TT
103552017-08-03 Tom Tromey <tom@tromey.com>
10356
10357 * fbsd-nat.c (fbsd_find_memory_regions): Update.
10358
ed166945
TT
103592017-08-03 Tom Tromey <tom@tromey.com>
10360
10361 * cli/cli-cmds.c (find_and_open_script): Change return type.
10362 Remove "streamp" and "full_path" parameters.
10363 (source_script_with_search): Update.
10364 * auto-load.c (source_script_file): Update.
10365 * cli/cli-cmds.h (find_and_open_script): Change type.
10366 (open_script): New struct.
10367
d419f42d
TT
103682017-08-03 Tom Tromey <tom@tromey.com>
10369
10370 * xml-support.c (xml_fetch_content_from_file): Update.
10371 * ui-file.c (stdio_file::open): Update.
10372 * tracefile-tfile.c (tfile_start): Update.
10373 * remote.c (remote_file_put, remote_file_get): Update.
10374 * nat/linux-procfs.c (linux_proc_get_int)
10375 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
10376 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
10377 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
10378 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
10379 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
10380 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
10381 * linux-nat.c (linux_proc_pending_signals): Update.
10382 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
10383 (file_closer): Remove.
10384 * compile/compile.c (compile_to_object): Update.
10385 * common/filestuff.h (struct gdb_file_deleter): New.
10386 (gdb_file_up): New typedef.
10387 (gdb_fopen_cloexec): Change return type.
10388 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
10389 * cli/cli-dump.c (fopen_with_cleanup): Remove.
10390 (dump_binary_file, restore_binary_file): Update.
10391 * auto-load.c (auto_load_objfile_script_1): Update.
10392
4a2b031d
TT
103932017-08-03 Tom Tromey <tom@tromey.com>
10394
10395 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
10396 (info_static_tracepoint_markers_command): Likewise.
10397 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
10398 * skip.c (skip_info): Use ui_out_emit_table.
10399 * progspace.c (print_program_space): Use ui_out_emit_table.
10400 * osdata.c (info_osdata): Use ui_out_emit_table.
10401 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
10402 ui_out_emit_table.
10403 * linux-thread-db.c (info_auto_load_libthread_db): Use
10404 ui_out_emit_table.
10405 * inferior.c (print_inferior): Use ui_out_emit_table.
10406 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
10407 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
10408 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
10409 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
10410 * ui-out.h (class ui_out_emit_table): New.
10411
a4f320fd
MR
104122017-08-02 Maciej W. Rozycki <macro@imgtec.com>
10413
10414 * mips-tdep.c (mips_fpu_type_str): New function.
10415 (mips_dump_tdep): Call it.
10416
a2f1f308
MR
104172017-08-01 Maciej W. Rozycki <macro@imgtec.com>
10418
10419 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
10420 `->mips_fpu_type'.
10421
7e5ed83b
XR
104222017-07-31 Xavier Roirand <roirand@adacore.com>
10423
10424 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
10425
4c9dc811
XR
104262017-07-27 Xavier Roirand <roirand@adacore.com>
10427
10428 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
10429
27d41eac
YQ
104302017-07-26 Yao Qi <yao.qi@linaro.org>
10431
10432 * cli/cli-cmds.c (maintenancechecklist): New variable.
10433 * gdbcmd.h (maintenancechecklist): Declare it.
10434 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
10435 Call i386_linux_read_description with different masks.
10436 * maint.c (maintenance_check_command): New function.
10437 (_initialize_maint_cmds): Call add_prefix_cmd.
10438 * target-descriptions.c (tdesc_reg): override operator != and ==.
10439 (tdesc_type): Likewise.
10440 (tdesc_feature): Likewise.
10441 (target_desc): Likewise.
10442 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
10443 (maintenance_check_xml_descriptions): New function.
10444 (_initialize_target_descriptions) Add command "xml-descriptions".
10445 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
10446
ea03d0d3
YQ
104472017-07-26 Yao Qi <yao.qi@linaro.org>
10448
10449 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
10450 Include features/i386/32bit-*.c.
10451 (i386_linux_read_description): Generate target description if it
10452 doesn't exist.
10453 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
10454 functions.
10455 * features/i386/32bit-linux.c: Re-generated.
10456 * features/i386/32bit-sse.c: Likewise.
10457 * target-descriptions.c (print_c_feature::visit): Print code to
10458 set register number if needed.
10459 (print_c_feature) <m_next_regnum>: New field.
10460
25aa13e5
YQ
104612017-07-26 Yao Qi <yao.qi@linaro.org>
10462
10463 * features/Makefile (CFILES): Rename with TDESC_CFILES.
10464 (FEATURE_XMLFILES): New.
10465 (FEATURE_CFILES): New.
10466 New rules.
10467 (clean-cfiles): Remove generated c files.
10468 * features/i386/32bit-avx.c: Generated.
10469 * features/i386/32bit-avx512.c: Generated.
10470 * features/i386/32bit-core.c: Generated.
10471 * features/i386/32bit-linux.c: Generated.
10472 * features/i386/32bit-mpx.c: Generated.
10473 * features/i386/32bit-pkeys.c: Generated.
10474 * features/i386/32bit-sse.c: Generated.
10475 * target-descriptions.c: Include algorithm.
10476 (tdesc_element_visitor): Add method visit_end.
10477 (print_c_tdesc): Implement visit_end.
10478 (print_c_tdesc:: m_filename_after_features): Move it to
10479 protected.
10480 (print_c_feature): New class.
10481 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
10482 name starts with "i386/32bit-".
10483
6eb1e6a8
YQ
104842017-07-26 Yao Qi <yao.qi@linaro.org>
10485
10486 * target-descriptions.c (tdesc_element_visitor): New class.
10487 (tdesc_element): New class.
10488 (tdesc_reg): Inherit from tdesc_element.
10489 (tdesc_reg::accept): New function.
10490 (tdesc_type): Inherit from tdesc_element.
10491 (tdesc_type::accept): New function.
10492 (tdesc_feature): Inherit from tdesc_element.
10493 (tdesc_feature::accept): New function.
10494 (target_desc): Inherit from tdesc_element.
10495 (target_desc::target_desc): New.
10496 (target_desc::~target_desc): New.
10497 (target_desc::accept): New.
10498 (allocate_target_description): Use new.
10499 (free_target_description): Use delete.
10500 (print_c_tdesc): New class.
10501 (maint_print_c_tdesc_cmd): Adjust.
10502
10503 * features/aarch64.c: Re-generated.
10504 * features/arc-arcompact.c: Re-generated.
10505 * features/arc-v2.c: Re-generated.
10506 * features/arm/arm-with-iwmmxt.c: Re-generated.
10507 * features/arm/arm-with-m.c: Re-generated.
10508 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
10509 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
10510 * features/arm/arm-with-neon.c: Re-generated.
10511 * features/arm/arm-with-vfpv2.c: Re-generated.
10512 * features/arm/arm-with-vfpv3.c: Re-generated.
10513 * features/i386/amd64-avx-avx512.c: Re-generated.
10514 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10515 * features/i386/amd64-avx.c: Re-generated.
10516 * features/i386/amd64-avx-linux.c: Re-generated.
10517 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
10518 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10519 * features/i386/amd64-avx-mpx.c: Re-generated.
10520 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
10521 * features/i386/amd64.c: Re-generated.
10522 * features/i386/amd64-linux.c: Re-generated.
10523 * features/i386/amd64-mpx.c: Re-generated.
10524 * features/i386/amd64-mpx-linux.c: Re-generated.
10525 * features/i386/i386-avx-avx512.c: Re-generated.
10526 * features/i386/i386-avx-avx512-linux.c: Re-generated.
10527 * features/i386/i386-avx.c: Re-generated.
10528 * features/i386/i386-avx-linux.c: Re-generated.
10529 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
10530 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
10531 * features/i386/i386-avx-mpx.c: Re-generated.
10532 * features/i386/i386-avx-mpx-linux.c: Re-generated.
10533 * features/i386/i386.c: Re-generated.
10534 * features/i386/i386-linux.c: Re-generated.
10535 * features/i386/i386-mmx.c: Re-generated.
10536 * features/i386/i386-mmx-linux.c: Re-generated.
10537 * features/i386/i386-mpx.c: Re-generated.
10538 * features/i386/i386-mpx-linux.c: Re-generated.
10539 * features/i386/x32-avx-avx512.c: Re-generated.
10540 * features/i386/x32-avx-avx512-linux.c: Re-generated.
10541 * features/i386/x32-avx.c: Re-generated.
10542 * features/i386/x32-avx-linux.c: Re-generated.
10543 * features/i386/x32.c: Re-generated.
10544 * features/i386/x32-linux.c: Re-generated.
10545 * features/microblaze.c: Re-generated.
10546 * features/microblaze-with-stack-protect.c: Re-generated.
10547 * features/mips64-dsp-linux.c: Re-generated.
10548 * features/mips64-linux.c: Re-generated.
10549 * features/mips-dsp-linux.c: Re-generated.
10550 * features/mips-linux.c: Re-generated.
10551 * features/nds32.c: Re-generated.
10552 * features/nios2.c: Re-generated.
10553 * features/nios2-linux.c: Re-generated.
10554 * features/rs6000/powerpc-32.c: Re-generated.
10555 * features/rs6000/powerpc-32l.c: Re-generated.
10556 * features/rs6000/powerpc-403.c: Re-generated.
10557 * features/rs6000/powerpc-403gc.c : Re-generated.
10558 * features/rs6000/powerpc-405.c: Re-generated.
10559 * features/rs6000/powerpc-505.c: Re-generated.
10560 * features/rs6000/powerpc-601.c: Re-generated.
10561 * features/rs6000/powerpc-602.c: Re-generated.
10562 * features/rs6000/powerpc-603.c: Re-generated.
10563 * features/rs6000/powerpc-604.c: Re-generated.
10564 * features/rs6000/powerpc-64.c: Re-generated.
10565 * features/rs6000/powerpc-64l.c: Re-generated.
10566 * features/rs6000/powerpc-7400.c: Re-generated.
10567 * features/rs6000/powerpc-750.c: Re-generated.
10568 * features/rs6000/powerpc-860.c: Re-generated.
10569 * features/rs6000/powerpc-altivec32.c: Re-generated.
10570 * features/rs6000/powerpc-altivec32l.c: Re-generated.
10571 * features/rs6000/powerpc-altivec64.c: Re-generated.
10572 * features/rs6000/powerpc-altivec64l.c: Re-generated.
10573 * features/rs6000/powerpc-cell32l.c: Re-generated.
10574 * features/rs6000/powerpc-cell64l.c: Re-generated.
10575 * features/rs6000/powerpc-e500.c: Re-generated.
10576 * features/rs6000/powerpc-e500l.c: Re-generated.
10577 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
10578 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
10579 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
10580 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
10581 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
10582 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
10583 * features/rs6000/powerpc-vsx32.c: Re-generated.
10584 * features/rs6000/powerpc-vsx32l.c: Re-generated.
10585 * features/rs6000/powerpc-vsx64.c: Re-generated.
10586 * features/rs6000/powerpc-vsx64l.c: Re-generated.
10587 * features/rs6000/rs6000.c: Re-generated.
10588 * features/s390-linux32.c: Re-generated.
10589 * features/s390-linux32v1.c: Re-generated.
10590 * features/s390-linux32v2.c: Re-generated.
10591 * features/s390-linux64.c: Re-generated.
10592 * features/s390-linux64v1.c: Re-generated.
10593 * features/s390-linux64v2.c: Re-generated.
10594 * features/s390-te-linux64.c: Re-generated.
10595 * features/s390-tevx-linux64.c: Re-generated.
10596 * features/s390-vx-linux64.c: Re-generated.
10597 * features/s390x-linux64.c: Re-generated.
10598 * features/s390x-linux64v1.c: Re-generated.
10599 * features/s390x-linux64v2.c: Re-generated.
10600 * features/s390x-te-linux64.c: Re-generated.
10601 * features/s390x-tevx-linux64.c: Re-generated.
10602 * features/s390x-vx-linux64.c: Re-generated.
10603 * features/sparc/sparc32-solaris.c: Re-generated.
10604 * features/sparc/sparc64-solaris.c: Re-generated.
10605 * features/tic6x-c62x.c: Re-generated.
10606 * features/tic6x-c62x-linux.c: Re-generated.
10607 * features/tic6x-c64x.c: Re-generated.
10608 * features/tic6x-c64x-linux.c: Re-generated.
10609 * features/tic6x-c64xp.c: Re-generated.
10610 * features/tic6x-c64xp-linux.c: Re-generated.
10611
35b4818d
YQ
106122017-07-26 Yao Qi <yao.qi@linaro.org>
10613
10614 * i386-linux-tdep.c (i386_linux_read_description): New function.
10615 (i386_linux_core_read_description): Call
10616 i386_linux_read_description.
10617 * i386-linux-tdep.h (i386_linux_read_description): Declare.
10618 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
10619 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
10620 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
10621 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
10622 * x86-linux-nat.c (x86_linux_read_description): Call
10623 i386_linux_read_description.
10624
8e2141c6
YQ
106252017-07-26 Yao Qi <yao.qi@linaro.org>
10626
10627 * NEWS: Mention it.
10628 * features/Makefile (%.c: %.xml): Pass the xml file name to
10629 command "maint print c-tdesc".
10630 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
10631 name from 'arg'.
10632
b468ff4c
YQ
106332017-07-26 Yao Qi <yao.qi@linaro.org>
10634
10635 * target-descriptions.c (target_desc): Add ctor and dtor. Do
10636 in-class initialization.
10637 (tdesc_create_feature): Call new instead of XCNEW.
10638 (free_target_description): Ue delete.
10639
b9c0e1b4
JB
106402017-07-25 John Baldwin <jhb@FreeBSD.org>
10641
10642 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
10643
a04b5337
YQ
106442017-07-25 Yao Qi <yao.qi@linaro.org>
10645
10646 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
10647 constant.
10648 (amd64_x32_init_abi): Likewise.
10649 * amd64-tdep.h (amd64_init_abi): Update declaration.
10650 (amd64_x32_init_abi): Likewise.
10651
02ad7fc2
YQ
106522017-07-25 Yao Qi <yao.qi@linaro.org>
10653
10654 PR tdep/21717
10655 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10656 condition for FPSCR.
10657 (arm_linux_store_inferior_registers): Likewise.
10658
b6f48cb0
TT
106592017-07-22 Tom Tromey <tom@tromey.com>
10660
10661 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10662 <syscalls_counts>: Now a std::vector.
10663 (get_catch_syscall_inferior_data): Use "new".
10664 (catch_syscall_inferior_data_cleanup): Use "delete".
10665 (insert_catch_syscall, remove_catch_syscall)
10666 (clear_syscall_counts): Update.
10667
e12c9b7a
TT
106682017-07-22 Tom Tromey <tom@tromey.com>
10669
10670 * break-catch-syscall.c (syscall_catchpoint)
10671 <syscalls_to_be_caught>: Now a std::vector<int>
10672 (~syscall_catchpoint): Remove.
10673 (insert_catch_syscall, remove_catch_syscall)
10674 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10675 (print_mention_catch_syscall, print_recreate_catch_syscall):
10676 Update.
10677 (create_syscall_event_catchpoint): Change type of "filter"
10678 parameter.
10679 (catch_syscall_split_args): Return a std::vector.
10680 (catch_syscall_command_1, catching_syscall_number_1): Update.
10681
4fa8aeac
TT
106822017-07-22 Tom Tromey <tom@tromey.com>
10683
10684 * break-catch-throw.c (struct exception_catchpoint)
10685 <exception_rx>: Now a std::string.
10686 (~exception_catchpoint): Remove.
10687 (print_one_detail_exception_catchpoint): Update.
10688 (handle_gnu_v3_exceptions): Change type of except_rx.
10689 (extract_exception_regexp): Return a std::string.
10690 (catch_exception_command_1): Update.
10691
f746a154
TT
106922017-07-22 Tom Tromey <tom@tromey.com>
10693
10694 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10695 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10696 std::vector.
10697 <catch_all>: Now a bool.
10698 (~signal_catchpoint): Remove.
10699 (signal_catchpoint_insert_location)
10700 (signal_catchpoint_remove_location)
10701 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10702 (signal_catchpoint_print_mention)
10703 (signal_catchpoint_print_recreate)
10704 (signal_catchpoint_explains_signal): Update.
10705 (create_signal_catchpoint): Change type of "filter" and
10706 "catch_all".
10707 (catch_signal_split_args): Return a std::vector. Change type of
10708 "catch_all".
10709 (catch_signal_command): Update.
10710
47e77640
PA
107112017-07-20 Pedro Alves <palves@redhat.com>
10712
10713 * ada-lang.c (ada_language_defn): Make extern.
10714 (_initialize_ada_language): Remove add_language call.
10715 * c-lang.c (c_language_defn, cplus_language_defn)
10716 (asm_language_defn, minimal_language_defn): Make extern.
10717 (_initialize_c_language): Delete.
10718 * completer.c (compare_cstrings): Delete, moved to utils.h.
10719 * d-lang.c (d_language_defn): Make extern.
10720 (_initialize_d_language): Remove add_language calls.
10721 * defs.h (enum language): Add comment.
10722 * f-lang.c (f_language_defn): Make extern.
10723 (_initialize_f_language): Remove add_language call.
10724 * go-lang.c (go_language_defn): Make extern.
10725 (_initialize_go_language): Remove add_language call.
10726 * language.c: Include <algorithm>.
10727 (languages): Redefine as const array.
10728 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10729 (set_language_command): Handle "local". Use for-range loop.
10730 (set_language): Remove loop.
10731 (language_enum): Rewrite.
10732 (language_def, language_str): Remove loops.
10733 (add_language): Delete.
10734 (add_set_language_command): New, based on add_languages.
10735 (skip_language_trampoline): Adjust.
10736 (local_language_defn): Delete.
10737 (language_gdbarch_post_init): Adjust.
10738 (_initialize_language): Remove add_language calls. Call
10739 add_set_language_command.
10740 * language.h (add_language): Delete.
10741 (auto_language_defn)
10742 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10743 (asm_language_defn, c_language_defn, cplus_language_defn)
10744 (d_language_defn, f_language_defn, go_language_defn)
10745 (m2_language_defn, objc_language_defn, opencl_language_defn)
10746 (pascal_language_defn, rust_language_defn): Declare.
10747 * m2-lang.c (m2_language_defn): Make extern.
10748 (_initialize_m2_language): Remove add_language call.
10749 * objc-lang.c (objc_language_defn): Make extern.
10750 (_initialize_objc_language): Remove add_language call.
10751 * opencl-lang.c (opencl_language_defn): Make extern.
10752 (_initialize_opencl_language): Remove add_language call.
10753 * p-lang.c (pascal_language_defn): Make extern.
10754 (_initialize_pascal_language): Delete.
10755 * rust-lang.c (rust_language_defn): Make extern.
10756 (_initialize_rust_language): Delete.
10757 * utils.h (compare_cstrings): New static inline function.
10758
edb0c9cb
PA
107592017-07-20 Pedro Alves <palves@redhat.com>
10760
10761 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10762 (get_var_value): Constify parameters.
10763 (get_int_var_value): Change prototype.
10764 (to_fixed_range_type): Adjust.
10765 * ada-lang.h (get_int_var_value): Change prototype.
10766
a778f165
PA
107672017-07-20 Pedro Alves <palves@redhat.com>
10768
10769 * dwarf2read.c (dw2_lookup_symbol): Use
10770 SYMBOL_MATCHES_SEARCH_NAME.
10771 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10772
42edd901
PA
107732017-07-20 Pedro Alves <palves@redhat.com>
10774
10775 * block.c (block_iter_name_step, block_iter_name_first)
10776 (block_iter_name_next): Delete.
10777 (block_lookup_symbol_primary): Adjust to use
10778 dict_iter_match_first/dict_iter_match_next.
10779 * block.h (block_iter_name_first, block_iter_name_next): Delete
10780 declarations.
10781 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10782 dict_iter_match_first/dict_iter_match_next.
10783
cf325299
PA
107842017-07-20 Pedro Alves <palves@redhat.com>
10785
10786 * cp-support.c (cp_find_first_component_aux): Add missing case for
10787 end of string.
10788
c5ed0576
DB
107892017-07-18 David Blaikie <dblaikie@gmail.com>
10790
10791 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10792 of dwo_cu's dwo_file.
10793
27841e76
YQ
107942017-07-18 Yao Qi <yao.qi@linaro.org>
10795
10796 * remote.c (store_registers_using_G): Remove one line comment.
10797
cfb7e58b
YQ
107982017-07-18 Yao Qi <yao.qi@linaro.org>
10799
10800 * regcache.c (regcache_cpy): Simplify it.
10801 (regcache::cpy_no_passthrough): Remove it.
10802 * regcache.h (cpy_no_passthrough): Remove it.
10803 (regcache_dup, regcache_cpy): Update comments.
10804
386535dd
PA
108052017-07-18 Pedro Alves <palves@redhat.com>
10806
10807 * remote-sim.c (sim_command_completer): Adjust to work with a
10808 completion_tracker instead of a VEC.
10809
c45ec17c
PA
108102017-07-17 Pedro Alves <palves@redhat.com>
10811
10812 * completer.c (complete_source_filenames): New function.
10813 (complete_address_and_linespec_locations): New function.
10814 (location_completer): Use complete_address_and_linespec_locations.
10815 (completion_tracker::build_completion_result): Honor the tracker's
10816 request to suppress append.
10817 * completer.h (completion_tracker::suppress_append_ws)
10818 (completion_tracker::set_suppress_append_ws): New methods.
10819 (completion_tracker::m_suppress_append_ws): New field.
10820 (complete_source_filenames): New declaration.
10821 * linespec.c (linespec_complete_what): New.
10822 (struct ls_parser) <complete_what, completion_word,
10823 completion_quote_char, completion_quote_end, completion_tracker>:
10824 New fields.
10825 (string_find_incomplete_keyword_at_end): New.
10826 (linespec_lexer_lex_string): Record quote char. If in completion
10827 mode, don't throw.
10828 (linespec_lexer_consume_token): Advance the completion word point.
10829 (linespec_lexer_peek_token): Save/restore completion info.
10830 (save_stream_and_consume_token): New.
10831 (set_completion_after_number): New.
10832 (linespec_parse_basic): Set what to complete next depending on
10833 token. Handle function and label completions specially.
10834 (parse_linespec): Disable objc shortcut in completion mode. Set
10835 what to complete next depending on token type. Skip keyword if in
10836 completion mode.
10837 (complete_linespec_component, linespec_complete): New.
10838 * linespec.h (linespec_complete): Declare.
10839
be966d42
PA
108402017-07-17 Pedro Alves <palves@redhat.com>
10841
10842 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10843 Handle 'operator<' / 'operator<<'.
10844
a2459270
PA
108452017-07-17 Pedro Alves <palves@redhat.com>
10846
10847 * completer.c (collect_explicit_location_matches): Handle
10848 MATCH_LABEL.
10849 (convert_explicit_location_to_linespec): New, factored out from
10850 ...
10851 (convert_explicit_location_to_sals): ... this.
10852 (complete_label): New.
10853 (linespec_complete_label, find_label_symbols_in_block): New.
10854 (find_label_symbols): Add completion_mode parameter and adjust to
10855 call find_label_symbols_in_block.
10856 * linespec.h (linespec_complete_label): Declare.
10857
c6756f62
PA
108582017-07-17 Pedro Alves <palves@redhat.com>
10859
10860 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10861 complete_symbol_mode parameter.
10862 * cli/cli-cmds.c (complete_command): Get the completion result out
10863 of the handle_brkchars tracker if used a custom word point.
10864 * completer.c: Include "linespec.h".
10865 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10866 (advance_to_expression_complete_word_point): New.
10867 (completion_tracker::completes_to_completion_word): New.
10868 (complete_files_symbols): Pass down
10869 complete_symbol_mode::EXPRESSION.
10870 (explicit_options, probe_options): New.
10871 (collect_explicit_location_matches): Complete on the
10872 explictit_loc->foo instead of word. Use
10873 linespec_complete_function. Handle MATCH_LINE. Handle offering
10874 keyword and options completions.
10875 (backup_text_ptr): Delete.
10876 (skip_keyword): New.
10877 (complete_explicit_location): Remove 'word' parameter. Add
10878 language, quoted_arg_start and quoted_arg_end parameters.
10879 Rewrite, parsing left to right.
10880 (location_completer): Rewrite.
10881 (location_completer_handle_brkchars): New function.
10882 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10883 (enum complete_line_internal_reason): Adjust comments.
10884 (completion_tracker::discard_completions): New.
10885 (completer_handle_brkchars_func_for_completer): Handle
10886 location_completer.
10887 (gdb_custom_word_point_brkchars)
10888 (gdb_org_rl_basic_quote_characters): New.
10889 (gdb_completion_word_break_characters_throw)
10890 (completion_find_completion_word): Handle trackers that use a
10891 custom word point.
10892 (completion_tracker::advance_custom_word_point_by): New.
10893 (completion_tracker::build_completion_result): Don't rely on
10894 readline appending the quote char.
10895 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10896 use a custom word point.
10897 (gdb_rl_attempted_completion_function): Restore
10898 rl_basic_quote_characters.
10899 * completer.h (class completion_tracker): Extend intro comment.
10900 (completion_tracker::set_quote_char)
10901 (completion_tracker::quote_char)
10902 (completion_tracker::set_use_custom_word_point)
10903 (completion_tracker::use_custom_word_point)
10904 (completion_tracker::custom_word_point)
10905 (completion_tracker::set_custom_word_point)
10906 (completion_tracker::advance_custom_word_point_by)
10907 (completion_tracker::completes_to_completion_word)
10908 (completion_tracker::discard_completions): New methods.
10909 (completion_tracker::m_quote_char)
10910 (completion_tracker::m_use_custom_word_point)
10911 (completion_tracker::m_custom_word_point): New fields.
10912 (advance_to_expression_complete_word_point): Declare.
10913 * f-lang.c (f_collect_symbol_completion_matches): Add
10914 complete_symbol_mode parameter.
10915 * language.h (struct language_defn)
10916 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10917 parameter.
10918 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10919 (linespec_complete_function): New function.
10920 (linespec_lexer_lex_keyword): Adjust.
10921 * linespec.h (linespec_keywords, linespec_complete_function): New
10922 declarations.
10923 * location.c (find_end_quote): New function.
10924 (explicit_location_lex_one): Add explicit_completion_info
10925 parameter. Save quoting info. Don't throw if being called for
10926 completion. Don't handle Ada operators here.
10927 (is_cp_operator, skip_op_false_positives, first_of)
10928 (explicit_location_lex_one_function): New function.
10929 (string_to_explicit_location): Replace 'dont_throw' parameter with
10930 an explicit_completion_info pointer parameter. Handle it. Don't
10931 use explicit_location_lex_one to lex function names. Use
10932 explicit_location_lex_one_function instead.
10933 * location.h (struct explicit_completion_info): New.
10934 (string_to_explicit_location): Replace 'dont_throw' parameter with
10935 an explicit_completion_info pointer parameter.
10936 * symtab.c (default_collect_symbol_completion_matches_break_on):
10937 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10938 (default_collect_symbol_completion_matches)
10939 (collect_symbol_completion_matches): Add complete_symbol_mode
10940 parameter.
10941 (collect_symbol_completion_matches_type): Pass down
10942 complete_symbol_mode::EXPRESSION.
10943 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10944 parameter. Handle LINESPEC mode.
10945 * symtab.h (complete_symbol_mode): New.
10946 (default_collect_symbol_completion_matches_break_on)
10947 (default_collect_symbol_completion_matches)
10948 (collect_symbol_completion_matches)
10949 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10950 parameter.
10951
1d550c82
PA
109522017-07-17 Pedro Alves <palves@redhat.com>
10953
10954 * utils.c (enum class strncmp_iw_mode): New.
10955 (strcmp_iw): Rename to ...
10956 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10957 parameters. Handle them.
10958 (strncmp_iw): New.
10959 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10960 * utils.h (strncmp_iw): Declare.
10961 (strcmp_iw): Move describing comments here.
10962
8090b426
PA
109632017-07-17 Pedro Alves <palves@redhat.com>
10964
10965 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10966 CP_OPERATOR_STR.
10967 * c-typeprint.c (is_type_conversion_operator): Use
10968 CP_OPERATOR_STR.
10969 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10970 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10971 CP_OPERATOR_LEN.
10972 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10973 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10974 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10975 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10976 CP_OPERATOR_STR.
10977 * location.c: Include "cp-support.h".
10978 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10979 CP_OPERATOR_STR.
10980 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10981 CP_OPERATOR_LEN.
10982
6a2c1b87
PA
109832017-07-17 Pedro Alves <palves@redhat.com>
10984
10985 * cli/cli-cmds.c (complete_command): Use a completion tracker
10986 along with completion_find_completion_word for handle_brkchars
10987 phase.
10988 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10989 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10990 (struct gdb_rl_completion_word_info): New.
10991 (gdb_rl_find_completion_word): New.
10992 (completion_find_completion_word): New.
10993 * completer.h (completion_find_completion_word): Declare.
10994
eb3ff9a5
PA
109952017-07-17 Pedro Alves <palves@redhat.com>
10996
10997 * ada-lang.c (symbol_completion_match): Adjust comments.
10998 (symbol_completion_add): Replace vector parameter with
10999 completion_tracker parameter. Use it.
11000 (ada_make_symbol_completion_list): Rename to...
11001 (ada_collect_symbol_completion_matches): ... this. Add
11002 completion_tracker parameter and use it.
11003 (ada_language_defn): Adjust.
11004 * break-catch-syscall.c (catch_syscall_completer): Adjust
11005 prototype and work with completion_tracker instead of VEC.
11006 * breakpoint.c (condition_completer): Adjust prototype and work
11007 with completion_tracker instead of VEC.
11008 * c-lang.c (c_language_defn, cplus_language_defn)
11009 (asm_language_defn, minimal_language_defn): Adjust to renames.
11010 * cli/cli-cmds.c (complete_command): Rework using
11011 completion_tracker. Catch exceptions when completing.
11012 * cli/cli-decode.c (integer_unlimited_completer)
11013 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
11014 with completion_tracker instead of VEC.
11015 * command.h (struct completion_tracker): Forward declare.
11016 (completer_ftype, completer_handle_brkchars_ftype): Change
11017 types.
11018 (complete_on_cmdlist, complete_on_enum): Adjust.
11019 * completer.c: Include <algorithm>.
11020 (struct gdb_completer_state): New.
11021 (current_completion): New global.
11022 (readline_line_completion_function): Delete.
11023 (noop_completer, filename_completer)
11024 (filename_completer_handle_brkchars, complete_files_symbols)
11025 (linespec_location_completer): Adjust to work with a
11026 completion_tracker instead of a VEC.
11027 (string_or_empty): New.
11028 (collect_explicit_location_matches): Adjust to work with a
11029 completion_tracker instead of a VEC.
11030 (explicit_location_completer): Rename to ...
11031 (complete_explicit_location): ... this and adjust to work with a
11032 completion_tracker instead of a VEC.
11033 (location_completer): Adjust to work with a completion_tracker
11034 instead of a VEC.
11035 (add_struct_fields): Adjust to work with a completion_list instead
11036 of VEC.
11037 (expression_completer): Rename to ...
11038 (complete_expression): ... this and adjust to work with a
11039 completion_tracker instead of a VEC. Use complete_files_symbols.
11040 (expression_completer): Reimplement on top of complete_expression.
11041 (symbol_completer): Adjust to work with a completion_tracker
11042 instead of a VEC.
11043 (enum complete_line_internal_reason): Add describing comments.
11044 (complete_line_internal_normal_command): Adjust to work with a
11045 completion_tracker instead of a VEC.
11046 (complete_line_internal): Rename to ...
11047 (complete_line_internal_1): ... this and adjust to work with a
11048 completion_tracker instead of a VEC. Assert TEXT is NULL in the
11049 handle_brkchars phase.
11050 (new_completion_tracker): Delete.
11051 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
11052 complete_line_internal_1.
11053 (free_completion_tracker): Delete.
11054 (INITIAL_COMPLETION_HTAB_SIZE): New.
11055 (completion_tracker::completion_tracker)
11056 (completion_tracker::~completion_tracker): New.
11057 (maybe_add_completion): Delete.
11058 (completion_tracker::maybe_add_completion)
11059 (completion_tracker::add_completion)
11060 (completion_tracker::add_completions): New.
11061 (throw_max_completions_reached_error): Delete.
11062 (complete_line): Adjust to work with a completion_tracker instead
11063 of a VEC. Don't create a completion_tracker_t or check for max
11064 completions here.
11065 (command_completer, command_completer_handle_brkchars)
11066 (signal_completer, reg_or_group_completer_1)
11067 (reg_or_group_completer, default_completer_handle_brkchars):
11068 Adjust to work with a completion_tracker.
11069 (gdb_completion_word_break_characters_throw): New.
11070 (gdb_completion_word_break_characters): Reimplement.
11071 (line_completion_function): Delete.
11072 (completion_tracker::recompute_lowest_common_denominator)
11073 (expand_preserving_ws)
11074 (completion_tracker::build_completion_result)
11075 (completion_result::completion_result)
11076 (completion_result::completion_result)
11077 (completion_result::~completion_result)
11078 (completion_result::completion_result)
11079 (completion_result::release_match_list, compare_cstrings)
11080 (completion_result::sort_match_list)
11081 (completion_result::reset_match_list)
11082 (gdb_rl_attempted_completion_function_throw)
11083 (gdb_rl_attempted_completion_function): New.
11084 * completer.h (completion_list, struct completion_result)
11085 (class completion_tracker): New.
11086 (complete_line): Add completion_tracker parameter.
11087 (readline_line_completion_function): Delete.
11088 (gdb_rl_attempted_completion_function): New.
11089 (noop_completer, filename_completer, expression_completer)
11090 (location_completer, symbol_completer, command_completer)
11091 (signal_completer, reg_or_group_completer): Update prototypes.
11092 (completion_tracker_t, new_completion_tracker)
11093 (make_cleanup_free_completion_tracker): Delete.
11094 (enum maybe_add_completion_enum): Delete.
11095 (maybe_add_completion): Delete.
11096 (throw_max_completions_reached_error): Delete.
11097 * corefile.c (complete_set_gnutarget): Adjust to work with a
11098 completion_tracker instead of a VEC.
11099 * cp-abi.c (cp_abi_completer): Adjust to work with a
11100 completion_tracker instead of a VEC.
11101 * d-lang.c (d_language_defn): Adjust.
11102 * disasm.c (disassembler_options_completer): Adjust to work with a
11103 completion_tracker instead of a VEC.
11104 * f-lang.c (f_make_symbol_completion_list): Rename to ...
11105 (f_collect_symbol_completion_matches): ... this. Adjust to work
11106 with a completion_tracker instead of a VEC.
11107 (f_language_defn): Adjust.
11108 * go-lang.c (go_language_defn): Adjust.
11109 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
11110 Adjust to work with a completion_tracker instead of a VEC.
11111 * infrun.c (handle_completer): Likewise.
11112 * interps.c (interpreter_completer): Likewise.
11113 * interps.h (interpreter_completer): Likewise.
11114 * language.c (unknown_language_defn, auto_language_defn)
11115 (local_language_defn): Adjust.
11116 * language.h (language_defn::la_make_symbol_completion_list):
11117 Rename to ...
11118 (language_defn::la_collect_symbol_completion_matches): ... this
11119 and adjust to work with a completion_tracker instead of a VEC.
11120 * m2-lang.c (m2_language_defn): Adjust.
11121 * objc-lang.c (objc_language_defn): Adjust.
11122 * opencl-lang.c (opencl_language_defn): Adjust.
11123 * p-lang.c (pascal_language_defn): Adjust.
11124 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
11125 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
11126 with a completion_tracker.
11127 * rust-lang.c (rust_language_defn): Adjust.
11128 * symtab.c (free_completion_list, do_free_completion_list)
11129 (return_val, completion_tracker): Delete.
11130 (completion_list_add_name, completion_list_add_symbol)
11131 (completion_list_add_msymbol, completion_list_objc_symbol)
11132 (completion_list_add_fields, add_symtab_completions): Add
11133 completion_tracker parameter and use it.
11134 (default_make_symbol_completion_list_break_on_1): Rename to...
11135 (default_collect_symbol_completion_matches_break_on): ... this.
11136 Add completion_tracker parameter and use it instead of allocating
11137 a completion tracker here.
11138 (default_make_symbol_completion_list_break_on): Delete old
11139 implementation.
11140 (default_make_symbol_completion_list): Delete.
11141 (default_collect_symbol_completion_matches): New.
11142 (make_symbol_completion_list): Delete.
11143 (collect_symbol_completion_matches): New.
11144 (make_symbol_completion_type): Rename to ...
11145 (collect_symbol_completion_matches_type): ... this. Add
11146 completion_tracker parameter and use it instead of VEC.
11147 (make_file_symbol_completion_list_1): Rename to...
11148 (collect_file_symbol_completion_matches): ... this. Add
11149 completion_tracker parameter and use it instead of VEC.
11150 (make_file_symbol_completion_list): Delete.
11151 (add_filename_to_list): Use completion_list instead of a VEC.
11152 (add_partial_filename_data::list): Now a completion_list.
11153 (make_source_files_completion_list): Work with a completion_list
11154 instead of a VEC.
11155 * symtab.h: Include "completer.h".
11156 (default_make_symbol_completion_list_break_on)
11157 (default_make_symbol_completion_list, make_symbol_completion_list)
11158 (make_symbol_completion_type, make_file_symbol_completion_list)
11159 (make_source_files_completion_list): Delete.
11160 (default_collect_symbol_completion_matches_break_on)
11161 (default_collect_symbol_completion_matches)
11162 (collect_symbol_completion_matches)
11163 (collect_symbol_completion_matches_type)
11164 (collect_file_symbol_completion_matches)
11165 (make_source_files_completion_list): New.
11166 * top.c (init_main): Don't install a rl_completion_entry_function
11167 hook. Install a rl_attempted_completion_function hook instead.
11168 * tui/tui-layout.c (layout_completer): Adjust to work with a
11169 completion_tracker.
11170 * tui/tui-regs.c (tui_reggroup_completer):
11171 * tui/tui-win.c (window_name_completer, focus_completer)
11172 (winheight_completer): Adjust to work with a completion_tracker.
11173 * value.c: Include "completer.h".
11174 (complete_internalvar): Adjust to work with a completion_tracker.
11175 * value.h (complete_internalvar): Likewise.
11176
6e1dbf8c
PA
111772017-07-17 Pedro Alves <palves@redhat.com>
11178
11179 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
11180 renames.
11181 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
11182 comments to completer_ftype's declaration.
11183 <completer_handle_brkchars>: Change type to
11184 completer_handle_brkchars_ftype.
11185 * command.h (completer_ftype): Add describing comment and give
11186 names to parameters.
11187 (completer_ftype_void): Rename to ...
11188 (completer_handle_brkchars_ftype) ... this. Add describing comment.
11189 (set_cmd_completer_handle_brkchars): Adjust.
11190 * completer.c (filename_completer_handle_brkchars): New function.
11191 (complete_line_internal_normal_command): New function, factored
11192 out from ...
11193 (complete_line_internal): ... here.
11194 (command_completer_handle_brkchars)
11195 (default_completer_handle_brkchars)
11196 (completer_handle_brkchars_func_for_completer): New functions.
11197 * completer.h (set_gdb_completion_word_break_characters): Delete
11198 declaration.
11199 (completer_handle_brkchars_func_for_completer): New declaration.
11200 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
11201 completer_handle_brkchars_func_for_completer.
11202
78b13106
PA
112032017-07-17 Pedro Alves <palves@redhat.com>
11204
11205 * completer.c (symbol_completer): New function, based on
11206 make_symbol_completion_list_fn.
11207 * completer.h (symbol_completer): New declaration.
11208 * guile/scm-cmd.c (cmdscm_completers): Adjust.
11209 * python/py-cmd.c (completers): Adjust.
11210 * symtab.c (make_symbol_completion_list_fn): Delete.
11211 * symtab.h (make_symbol_completion_list_fn): Delete.
11212 * cli/cli-decode.c (add_cmd): Adjust.
11213
bbf2f4df
PA
112142017-07-17 Pedro Alves <palves@redhat.com>
11215
11216 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
11217 * dwarf2read.c: Include "filename-seen-cache.h".
11218 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
11219 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
11220 * filename-seen-cache.c: New file.
11221 * filename-seen-cache.h: New file.
11222 * symtab.c: Include "filename-seen-cache.h".
11223 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
11224 (create_filename_seen_cache, clear_filename_seen_cache)
11225 (delete_filename_seen_cache, filename_seen): Delete, parts moved
11226 to filename-seen-cache.h/filename-seen-cache.c.
11227 (output_source_filename, sources_info)
11228 (maybe_add_partial_symtab_filename)
11229 (make_source_files_completion_list): Adjust to use
11230 filename_seen_cache.
11231
330cdd98
PA
112322017-07-17 Pedro Alves <palves@redhat.com>
11233
11234 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
11235 fields.
11236 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
11237 dwarf2_debug_sections*)): New.
11238 (dwarf2_per_objfile::dwarf2_per_objfile(const
11239 dwarf2_per_objfile&)): Declare as deleted.
11240 (dwarf2_per_objfile::operator=): Declare as deleted.
11241 (dwarf2_per_objfile::dwarf2_per_objfile)
11242 (dwarf2_per_objfile::~dwarf2_per_objfile)
11243 (dwarf2_per_objfile::free_cached_comp_units): New.
11244 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
11245 ctor. Call dwarf2_per_objfile's ctor manually.
11246 (dwarf2_locate_sections): Deleted/refactored as ...
11247 (dwarf2_per_objfile::locate_sections): ... this new method.
11248 (free_cached_comp_units): Defer to
11249 dwarf2_per_objfile::free_cached_comp_units.
11250 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
11251
8880f2a9
TT
112522017-07-14 Tom Tromey <tom@tromey.com>
11253
11254 PR rust/21764:
11255 * rust-exp.y (convert_ast_to_expression): Add "want_type"
11256 parameter.
11257 <UNOP_SIZEOF>: Split into separate case.
11258 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
11259
65547233
TT
112602017-07-14 Tom Tromey <tom@tromey.com>
11261
11262 PR rust/21763:
11263 * symtab.c (symbol_matches_domain): Add language_rust to special
11264 case.
11265 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
11266 treat LOC_TYPEDEF symbols as variables.
11267
8f14146e
PA
112682017-07-14 Pedro Alves <palves@redhat.com>
11269
11270 * symtab.c (make_file_symbol_completion_list_1): Iterate over
11271 symtabs matching all symtabs with SRCFILE as file name instead of
11272 only considering the first hit, with lookup_symtab.
11273
2347965c
SM
112742017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11275
11276 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
11277 operator_name parameters.
11278 (gen_expr): Update function call.
11279
40f4af28
SM
112802017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11281
11282 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
11283 parameter.
11284 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
11285 Likewise.
11286 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
11287 parameter, use agent_expr::gdbarch instead, update function
11288 calls.
11289 (locexpr_tracepoint_var_ref): Likewise.
11290 (loclist_tracepoint_var_ref): Likewise.
11291 * ax-gdb.c (gen_trace_static_fields): Likewise.
11292 (gen_traced_pop): Likewise.
11293 (gen_frame_args_address): Likewise.
11294 (gen_frame_locals_address): Likewise.
11295 (gen_var_ref): Likewise.
11296 (gen_struct_ref_recursive): Likewise.
11297 (gen_static_field): Likewise.
11298 (gen_maybe_namespace_elt): Likewise.
11299 (gen_expr): Likewise.
11300 (gen_trace_for_var): Likewise.
11301 (gen_trace_for_expr): Likewise.
11302 (gen_trace_for_return_address): Likewise.
11303
053f8057
SM
113042017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11305
11306 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
11307 parameter.
11308 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
11309
6661ad48
SM
113102017-07-14 Simon Marchi <simon.marchi@ericsson.com>
11311
11312 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
11313 from ax, update calls.
11314 (gen_usual_arithmetic): Likewise.
11315 (gen_integral_promotions): Likewise.
11316 (gen_bitfield_ref): Likewise.
11317 (gen_primitive_field): Likewise.
11318 (gen_struct_ref_recursive): Likewise.
11319 (gen_struct_ref): Likewise.
11320 (gen_maybe_namespace_elt): Likewise.
11321 (gen_struct_elt_for_reference): Likewise.
11322 (gen_namespace_elt): Likewise.
11323 (gen_aggregate_elt_ref): Likewise.
11324 (gen_expr): Get gdbarch from ax, update calls.
11325 (gen_expr_binop_rest): Likewise.
11326
c55a47e7
PA
113272017-07-13 Pedro Alves <palves@redhat.com>
11328
11329 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
11330 as default tdesc.
11331 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
11332 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
11333 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
11334 tdesc_amd64_linux as default tdesc. Get final tdesc from the
11335 tdep.
11336 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
11337 Get final tdesc from the tdep.
11338 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
11339 default tdesc.
11340 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
11341 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
11342 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
11343 Use it as default tdesc.
11344 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
11345 down to amd_init_abi. No longer handle fallback tdesc here.
11346 * amd64-tdep.h (tdesc_x32): Declare.
11347 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
11348 parameter.
11349 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
11350 as default tdesc.
11351
55efceab
AA
113522017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11353
11354 * s390-linux-tdep.c (s390_process_record): Add support for
11355 instructions new in arch12.
11356
0aa37b65
JB
113572017-07-11 John Baldwin <jhb@FreeBSD.org>
11358
11359 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
11360 PT_GETFSBASE and PT_GETGSBASE.
11361 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
11362 PT_SETGSBASE.
11363
48aeef91
JB
113642017-07-11 John Baldwin <jhb@FreeBSD.org>
11365
11366 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
11367 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
11368 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
11369 those rules.
11370 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
11371 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
11372 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
11373 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
11374 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
11375 * features/i386/amd64.xml: Add 64bit-segments.xml.
11376 * features/i386/amd64-avx-avx512.c: Regenerated.
11377 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
11378 * features/i386/amd64-avx-mpx.c: Regenerated.
11379 * features/i386/amd64-avx.c: Regenerated.
11380 * features/i386/amd64-mpx.c: Regenerated.
11381 * features/i386/amd64.c: Regenerated.
11382 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
11383 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11384 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
11385 * regformats/i386/amd64-avx.dat: Regenerated.
11386 * regformats/i386/amd64-mpx.dat: Regenerated.
11387 * regformats/i386/amd64.dat: Regenerated.
11388
77c501bc
YQ
113892017-07-10 Yao Qi <yao.qi@linaro.org>
11390
11391 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
11392 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
11393
6dc8d757
AK
113942017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
11395
11396 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
11397 unsetenv.
11398 * gnulib/aclocal.m4: Regenerate.
11399 * gnulib/config.in: Regenerate.
11400 * gnulib/configure: Regenerate.
11401 * gnulib/import/Makefile.am: Regenerate.
11402 * gnulib/import/Makefile.in: Regenerate.
11403 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
11404 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
11405 * gnulib/import/m4/environ.m4: New file.
11406 * gnulib/import/m4/setenv.m4: New file.
11407 * gnulib/import/setenv.c: New file.
11408 * gnulib/import/unsetenv.c: New file.
11409
266934d1
SM
114102017-07-09 Simon Marchi <simon.marchi@ericsson.com>
11411
11412 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
11413 address when op is DW_OP_addr.
11414
03278692
TT
114152017-07-09 Tom Tromey <tom@tromey.com>
11416
11417 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
11418 check and apply to outer type.
11419
4b654465
JB
114202017-07-07 John Baldwin <jhb@FreeBSD.org>
11421
11422 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
11423 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
11424 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
11425 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
11426
2af9fc44
JB
114272017-07-07 John Baldwin <jhb@FreeBSD.org>
11428
11429 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
11430
382b69bb
JB
114312017-07-07 John Baldwin <jhb@FreeBSD.org>
11432
11433 * corelow.c (get_core_siginfo): Remove.
11434 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
11435 instead of get_core_siginfo.
11436 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
11437 * gdbarch.h: Re-generate.
11438 * gdbarch.c: Re-generate.
11439 * linux-tdep.c (linux_core_xfer_siginfo): New.
11440 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
11441
6e5eab33
JB
114422017-07-07 John Baldwin <jhb@FreeBSD.org>
11443
11444 * corelow.c (thread_section_name): Move to ...
11445 * gdbcore.h (thread_section_name): ... here.
11446
929edea9
JB
114472017-07-07 John Baldwin <jhb@FreeBSD.org>
11448
11449 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
11450 (struct siginfo32): New.
11451 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
11452 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
11453 via ptrace(PT_LWPINFO).
11454
762c974a
JB
114552017-07-07 John Baldwin <jhb@FreeBSD.org>
11456
11457 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
11458 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
11459 (fbsd_get_siginfo_type): New.
11460 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
11461 (_initialize_fbsd_tdep): New.
11462
33c5cd75
DB
114632017-07-06 David Blaikie <dblaikie@gmail.com>
11464
11465 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
11466 a singular dwo_unit*) to support multiple CUs in the same way that
11467 multiple TUs are supported.
11468 (create_cus_hash_table): Replace create_dwo_cu with a function for
11469 parsing multiple CUs from a DWO file.
11470 (open_and_init_dwo_file): Use create_cus_hash_table rather than
11471 create_dwo_cu.
11472 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
11473 htab_find, rather than comparing the signature to a singleton CU in
11474 the dwo_file.
11475
8455d262
PA
114762017-07-06 Pedro Alves <palves@redhat.com>
11477
11478 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
11479
4da3eb35
PA
114802017-07-04 Pedro Alves <palves@redhat.com>
11481
11482 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
11483 * gdbtypes.h (TYPE_STATIC): Delete.
11484 (struct fn_field) <is_public, is_abstract, is_static, is_final,
11485 is_synchronized, is_native>: Delete.
11486 <dummy>: Bump.
11487 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
11488 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
11489 (TYPE_FN_FIELD_ABSTRACT): Delete.
11490
5bfd255c
SM
114912017-07-03 Simon Marchi <simon.marchi@ericsson.com>
11492
11493 * buffer.h (buffer_finish): Fix spelling mistakes.
11494
25c54127
EZ
114952017-07-01 Eli Zaretskii <eliz@gnu.org>
11496
11497 * .dir-locals.el: Automatically switch to C-style comments in
11498 versions of Emacs that support the feature.
11499
dc4bde35
SDJ
115002017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11501 Pedro Alves <palves@redhat.com>
11502
11503 PR cli/21688
11504 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
11505 (process_next_line): New variable 'inline_cmd'.
11506 Adjust 'if' clauses for "python", "compile" and "guile" to use
11507 'command_name_equals' and check for '!inline_cmd'.
11508
51ed89aa
SDJ
115092017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11510
11511 PR cli/21688
11512 * cli/cli-script.c (command_name_equals_not_inline): New function.
11513 (process_next_line): Adjust 'if' clauses for "python", "compile"
11514 and "guile" to use command_name_equals_not_inline.
11515
eb17d413
PA
115162017-06-29 Pedro Alves <palves@redhat.com>
11517
11518 * completer.c (expression_completer): Call
11519 linespec_location_completer instead of location_completer.
11520
195bcdd5
PA
115212017-06-29 Pedro Alves <palves@redhat.com>
11522
11523 * completer.c (expression_completer): Remove code that recomputes
11524 'text' from 'word'.
11525
adc764e7
YQ
115262017-06-29 Yao Qi <yao.qi@linaro.org>
11527
11528 * regformats/regdat.sh: Generate code with
11529 "ifndef IN_PROCESS_AGENT".
11530
6e75794e
PA
115312017-06-28 Pedro Alves <palves@redhat.com>
11532
11533 * command.h: Include "common/scoped_restore.h".
11534
bc491f2e
YQ
115352017-06-28 Yao Qi <yao.qi@linaro.org>
11536
11537 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
11538 instead of obstack_grow.
11539
41664b45
DG
115402017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
11541
11542 PR gdb/21337
11543 * symfile.c (reread_symbols): Call objfiles_changed just before
11544 read_symbols.
11545
6da67eb1
PA
115462017-06-27 Pedro Alves <palves@redhat.com>
11547
11548 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
11549 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
11550 (completion_list_add_symbol, completion_list_add_msymbol):
11551 ... these new functions.
11552 (add_symtab_completions)
11553 (default_make_symbol_completion_list_break_on_1): Adjust.
11554
23732b1e
PA
115552017-06-27 Pedro Alves <palves@redhat.com>
11556
11557 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
11558 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
11559 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
11560 dtor.
11561 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
11562 'storage_obstack' field an auto_obstack. In-class initialize all
11563 non-bitfield fields. Make minsyms_read bool.
11564 * symfile.c (read_symbols): Adjust.
11565
a4d1e79a
AH
115662017-06-27 Alan Hayward <alan.hayward@arm.com>
11567
11568 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
11569 (gdbsim_store_register): Likewise.
11570
8268c778
PA
115712017-06-27 Pedro Alves <palves@redhat.com>
11572
11573 * c-exp.y (name_obstack): Now an auto_obstack.
11574 (yylex): Use auto_obstack::clear.
11575 (c_parse): Use auto_obstack::clear instead of reinitializing and
11576 freeing the obstack.
11577 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
11578 * d-exp.y (name_obstack): Now an auto_obstack.
11579 (yylex): Use auto_obstack::clear.
11580 (d_parse): Use auto_obstack::clear instead of reinitializing and
11581 freeing the obstack.
11582 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
11583 auto_obstack.
11584 * dwarf2read.c (create_addrmap_from_index)
11585 (dwarf2_build_psymtabs_hard)
11586 (update_enumeration_type_from_children): Likewise.
11587 * gdb_obstack.h (auto_obstack): New type.
11588 * go-exp.y (name_obstack): Now an auto_obstack.
11589 (build_packaged_name): Use auto_obstack::clear.
11590 (go_parse): Use auto_obstack::clear instead of reinitializing and
11591 freeing the obstack.
11592 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
11593 auto_obstack.
11594 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
11595 * rust-exp.y (work_obstack): Now an auto_obstack.
11596 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
11597 reinitializing and freeing the obstack.
11598 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
11599 (host_char_to_target): Use auto_obstack.
11600 * utils.h (make_cleanup_obstack_free): Delete declaration.
11601 * valprint.c (generic_emit_char, generic_printstr): Use
11602 auto_obstack.
11603
db665f42
SM
116042017-06-27 Simon Marchi <simon.marchi@ericsson.com>
11605
11606 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
11607 thread.
11608 (darwin_init_thread_list): Don't update dummy thread.
11609 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
11610
873c0814
SM
116112017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11612
11613 * record-full.c (netorder16): Remove.
11614
8b5a7a6e
SM
116152017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11616
11617 * common/diagnostics.h: Define macros for GCC.
11618 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
11619 * common/vec.h: Include diagnostics.h.
11620 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
11621 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
11622 warning.
11623
d1435379
SM
116242017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11625
11626 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
11627 New macro.
11628 * ada-lex.l: Ignore deprecated register warnings.
11629
cc75e0fd
SM
116302017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11631
11632 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
11633 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
11634
07809eaf
SM
116352017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11636
11637 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
11638 its own line.
11639
f076f034
SM
116402017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11641
11642 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
11643
0dd5cbc5
AH
116442017-06-23 Alan Hayward <alan.hayward@arm.com>
11645
11646 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
11647 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
11648 (xtensa_register_read_masked): Likewise.
11649
d4c6ce5b
SDJ
116502017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
11651
11652 * common/environ.c (gdb_environ::unset): Update comment.
11653
16892a03
AH
116542017-06-22 Alan Hayward <alan.hayward@arm.com>
11655
11656 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11657 registers.
11658
d7dcbefc
AH
116592017-06-22 Alan Hayward <alan.hayward@arm.com>
11660
11661 * record-full.c (record_full_exec_insn): Use byte_vector.
11662
b30ff123
YQ
116632017-06-22 Yao Qi <yao.qi@linaro.org>
11664
11665 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11666 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11667
4fa847d7
AH
116682017-06-22 Alan Hayward <alan.hayward@arm.com>
11669
11670 * remote.c (cached_reg): Move from here...
11671 * regcache.h (cached_reg): ...to here.
11672 * python/py-unwind.c (struct reg_info): Remove.
11673 (cached_frame_info): Use cached_reg_t.
11674 (pyuw_prev_register): Likewise.
11675 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11676 (pyuw_dealloc_cache): Free all registers.
11677
f4906a9a
PA
116782017-06-22 Pedro Alves <palves@redhat.com>
11679 Simon Marchi <simon.marchi@ericsson.com>
11680
11681 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11682 warning.
11683 * common/diagnostics.h: New file.
11684
b45a1208
PA
116852017-06-22 Pedro Alves <palves@redhat.com>
11686
11687 * common/agent.h: Add include guards.
11688
e4da2c61
SM
116892017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11690
11691 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11692 talk about addressable units instead of bytes.
11693
96160d60
SDJ
116942017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11695
11696 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11697 of '::const_iterator'.
11698
9a6c7d9c
SDJ
116992017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11700
11701 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11702 'unittests/environ-selftests.c'.
11703 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11704 * charset.c (find_charset_names): Declare object 'iconv_env'.
11705 Update code to use 'iconv_env' object. Remove call to
11706 'free_environ'.
11707 * common/environ.c: Include <utility>.
11708 (make_environ): Delete function.
11709 (free_environ): Delete function.
11710 (gdb_environ::clear): New function.
11711 (gdb_environ::operator=): New function.
11712 (gdb_environ::get): Likewise.
11713 (environ_vector): Delete function.
11714 (set_in_environ): Delete function.
11715 (gdb_environ::set): New function.
11716 (unset_in_environ): Delete function.
11717 (gdb_environ::unset): New function.
11718 (gdb_environ::envp): Likewise.
11719 * common/environ.h: Include <vector>.
11720 (struct gdb_environ): Delete; transform into...
11721 (class gdb_environ): ... this class.
11722 (free_environ): Delete prototype.
11723 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11724 environ_vector): Likewise.
11725 * infcmd.c (run_command_1): Update code to call
11726 'envp' from 'gdb_environ' class.
11727 (environment_info): Update code to call methods from 'gdb_environ'
11728 class.
11729 (unset_environment_command): Likewise.
11730 (path_info): Likewise.
11731 (path_command): Likewise.
11732 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11733 (inferior::inferior): Initialize 'environment' using the host's
11734 information.
11735 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11736 Include "environ.h".
11737 (class inferior) <environment>: Change type from 'struct
11738 gdb_environ' to 'gdb_environ'.
11739 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11740 methods from 'gdb_environ' class.
11741 * solib.c (solib_find_1): Likewise
11742 * unittests/environ-selftests.c: New file.
11743
75c554cf
YQ
117442017-06-20 Yao Qi <yao.qi@linaro.org>
11745
11746 * features/i386/i386-linux.xml: Exchange the order of including
11747 32bit-linux.xml and 32bit-sse.xml.
11748 * features/i386/i386-linux.c: Regenerated.
11749
72ddacb7
YQ
117502017-06-20 Yao Qi <yao.qi@linaro.org>
11751
11752 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11753 Delete copy ctor and assignment operator.
11754 (tdesc_type): Likewise.
11755 (tdesc_feature): Likewise.
11756 (tdesc_free_reg): Remove.
11757 (tdesc_create_reg): Use new.
11758 (tdesc_free_type): Remove.
11759 (tdesc_create_vector): Use new.
11760 (tdesc_create_union): Likewise.
11761 (tdesc_create_flags): Likewise.
11762 (tdesc_create_enum): Likewise.
11763 (tdesc_free_feature): Delete.
11764 (free_target_description): Use delete.
11765
325c9fd4
JB
117662017-06-19 John Baldwin <jhb@FreeBSD.org>
11767
11768 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11769 registers.
11770
16b7a719
PA
117712017-06-19 Pedro Alves <palves@redhat.com>
11772
11773 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11774 after gdb::unlinker.
11775
1c8e01c9
SDJ
117762017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11777
11778 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11779 gdb_environ to access an environment variable.
11780
ffce45d2
TP
117812017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11782
11783 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11784 gdb_byte*.
11785
1d4fbac9
SM
117862017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11787
11788 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11789
8465943a
SM
117902017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11791
11792 * configure: Re-generate.
11793 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11794
3e019bdc
SM
117952017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11796
11797 * configure: Re-generate.
11798 * warning.m4: Pass -Werror to compiler when checking for
11799 supported warning flags.
11800
cf0dd6f0
SM
118012017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11802
11803 * Makefile.in (COMPILE.pre): Add "-x c++".
11804
6f98355c
YQ
118052017-06-16 Alan Hayward <alan.hayward@arm.com>
11806 Pedro Alves <palves@redhat.com>
11807 Yao Qi <yao.qi@linaro.org>
11808
11809 * defs.h (RequireLongest): New.
11810 (extract_integer): Declare function template.
11811 (extract_signed_integer): Remove the declaration, but define it
11812 static inline.
11813 (extract_unsigned_integer): Likewise.
11814 (store_integer): Declare function template.
11815 (store_signed_integer): Remove the declaration, but define it
11816 static inline.
11817 (store_unsigned_integer): Likewise.
11818 * findvar.c (extract_integer): New function template.
11819 (extract_signed_integer): Remove.
11820 (extract_unsigned_integer): Remove.
11821 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11822 instantiations.
11823 (store_integer): New function template.
11824 (store_signed_integer): Remove.
11825 (store_unsigned_integer): Remove.
11826 (store_integer): Explicit instantiations.
11827 * regcache.c (regcache_raw_read_signed): Update.
11828 (regcache::raw_read): New function.
11829 (regcache::raw_read_signed): Remove.
11830 (regcache::raw_read_unsigned): Remove.
11831 (regcache_raw_read_unsigned): Update.
11832 (regcache_raw_write_unsigned): Update.
11833 (regcache::raw_write_signed): Remove.
11834 (regcache::raw_write): New function.
11835 (regcache_cooked_read_signed): Update.
11836 (regcache::raw_write_unsigned): Remove.
11837 (regcache::cooked_read_signed): Remove.
11838 (regcache_cooked_read_unsigned): Update.
11839 (regcache::cooked_read_unsigned): Remove.
11840 (regcache_cooked_write_signed): Update.
11841 (regcache_cooked_write_unsigned): Update.
11842 * regcache.h (regcache) <raw_read_signed>: Remove.
11843 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11844 <raw_read, raw_write>: New.
11845 <cooked_read_signed, cooked_write_signed>: Remove.
11846 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11847 <cooked_read, cooked_write>: New.
11848 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11849 (sh64_pseudo_register_write): Update.
11850
a87dc45a
AK
118512017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11852
11853 * arc-tdep.c (arc_disassembler_options): New variable.
11854 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11855 of default_print_insn.
11856 (arc_delayed_print_insn): Set info->section when needed,
11857 use default_print_insn to retrieve a disassembler.
11858
45159d6a
SDJ
118592017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11860
11861 PR gdb/21574
11862 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11863 to mention $SHELL and startup-with-shell.
11864
b46c4cf0
MF
118652017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11866
11867 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11868
6394c606
YQ
118692017-06-14 Yao Qi <yao.qi@linaro.org>
11870
11871 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11872 default_print_insn instead of print_insn_aarch64.
11873 * arm-tdep.c (gdb_print_insn_arm): Call
11874 default_print_insn instead of print_insn_big_arm
11875 and print_insn_little_arm.
11876 * i386-tdep.c (i386_print_insn): Call default_print_insn
11877 instead of print_insn_i386.
11878 * ia64-tdep.c (ia64_print_insn): Call
11879 default_print_insn instead of print_insn_ia64.
11880 * mips-tdep.c (gdb_print_insn_mips): Call
11881 default_print_insn instead of print_insn_big_mips
11882 and print_insn_little_mips.
11883 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11884 instead of print_insn_spu.
11885
d5722aa2
PA
118862017-06-14 Pedro Alves <palves@redhat.com>
11887
11888 * ada-lang.c: Include "common/byte-vector.h".
11889 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11890 * charset.c (wchar_iterator::iterate): Resize the vector instead
11891 of reserving it.
11892 * common/byte-vector.h: Include "common/def-vector.h".
11893 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11894 * cli/cli-dump.c: Include "common/byte-vector.h".
11895 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11896 * common/byte-vector.h: New file.
11897 * common/def-vector.h: New file.
11898 * common/default-init-alloc.h: New file.
11899 * dwarf2loc.c: Include "common/byte-vector.h".
11900 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11901 instead of reserving it.
11902 * dwarf2read.c: Include "common/byte-vector.h".
11903 (data_buf::m_vec): Now a gdb::byte_vector.
11904 * gdb_regex.c: Include "common/def-vector.h".
11905 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11906 * mi/mi-main.c: Include "common/byte-vector.h".
11907 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11908 * printcmd.c: Include "common/byte-vector.h".
11909 (print_scalar_formatted): Use gdb::byte_vector.
11910 * valprint.c: Include "common/byte-vector.h".
11911 (maybe_negate_by_bytes, print_decimal_chars): Use
11912 gdb::byte_vector.
11913
01ec7a27
SM
119142017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11915
11916 * darwin-nat.c: Include "nat/fork-inferior.h".
11917
848d9074
SM
119182017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11919
11920 * configure.nat: Factor out Darwin bits that are not
11921 architecture-specific. Add fork-inferior.o.
11922
3b912944
SM
119232017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11924
11925 * configure.nat: Factor out AIX bits that are not
11926 architecture-specific. Add fork-inferior.o.
11927
55acdf22
AA
119282017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11929
11930 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11931 (read_pieced_value, write_pieced_value): ...here. Reduce to
11932 wrappers that just call rw_pieced_value.
11933
f65e2044
AA
119342017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11935
11936 * dwarf2loc.c (write_pieced_value): When writing the data for a
11937 memory piece, use write_memory_with_notification instead of
11938 write_memory.
11939
23f945bf
AA
119402017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11941
11942 * valops.c (read_value_memory): Change embedded_offset to
11943 represent a bit offset instead of a byte offset.
11944 * value.h (read_value_memory): Adjust comment.
11945
f236533e
AA
119462017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11947
11948 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11949 dest_offset_bits and source_offset_bits.
11950 (write_pieced_value): Likewise.
11951
65d84b76
AA
119522017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11953
11954 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11955 given by DW_OP_bit_piece.
11956 (write_pieced_value): Likewise.
11957
242d31ab
AA
119582017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11959
11960 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11961 some other preparations to the places where sufficient information
11962 is available.
11963 (write_pieced_value): Likewise.
11964
03c8af18
AA
119652017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11966
11967 * dwarf2loc.c (bits_to_bytes): New function.
11968 (read_pieced_value): Fix offset calculations for register pieces
11969 on big-endian targets.
11970 (write_pieced_value): Likewise.
11971
840989c1
AA
119722017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11973
11974 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11975 (write_pieced_value): Likewise.
11976
359b19bb
AA
119772017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11978
11979 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11980 transfer the source value's least significant bits, instead of its
11981 lowest-addressed ones. Rename type_len to max_offset.
11982 (read_pieced_value): Mirror above changes to write_pieced_value as
11983 applicable.
11984
07c9ca3b
AA
119852017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11986
11987 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11988 truncate full bytes from dest_offset_bits before using it as an
11989 offset into the buffer.
11990
f1cc9874
AA
119912017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11992
11993 * dwarf2loc.c (write_pieced_value): Include transfer size in
11994 byte-wise check.
11995
cdaac320
AA
119962017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11997
11998 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11999 calculation of this_size.
12000
af547a96
AA
120012017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12002
12003 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
12004 when targeting a bit-field.
12005 (write_pieced_value): Likewise.
12006
ddd7882a
AA
120072017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12008
12009 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
12010 (allocate_piece_closure): Drop addr_size parameter.
12011 (dwarf2_evaluate_loc_desc_full): Adjust call to
12012 allocate_piece_closure.
12013
e9352324
AA
120142017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12015
12016 PR gdb/21226
12017 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
12018 the LSB end, independent of endianness.
12019
d5d1163e
AA
120202017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12021
12022 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
12023 size capping.
12024
032bb6ea
YQ
120252017-06-13 Yao Qi <yao.qi@linaro.org>
12026
12027 * mips-linux-nat.c: Move include features/mips*-linux.c to
12028 mips-linux-tdep.c.
12029 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
12030 to mips-linux-tdep.c.
12031 * mips-linux-tdep.c: Include features/mips*-linux.c
12032 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
12033 functions.
12034 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
12035 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
12036 (tdesc_mips64_dsp_linux): Declare.
12037
f12f6bad
TT
120382017-06-12 Tom Tromey <tom@tromey.com>
12039
12040 * valprint.h (val_print_type_code_int): Remove.
12041 * valprint.c (generic_val_print_int): Always call
12042 val_print_scalar_formatted.
12043 (val_print_type_code_int): Remove.
12044 * printcmd.c (print_scalar_formatted): Handle options->format==0.
12045 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
12046 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
12047 * ada-valprint.c (ada_val_print_num): Use
12048 val_print_scalar_formatted.
12049
d9109c80
TT
120502017-06-12 Tom Tromey <tom@tromey.com>
12051
12052 * printcmd.c (print_scalar_formatted): Unify the two switches.
12053 Don't convert scalars to LONGEST.
12054
4ac0cb1c
TT
120552017-06-12 Tom Tromey <tom@tromey.com>
12056
12057 PR exp/16225:
12058 * valprint.h (print_decimal_chars): Update.
12059 * valprint.c (maybe_negate_by_bytes): New function.
12060 (print_decimal_chars): Add "is_signed" argument.
12061 * printcmd.c (print_scalar_formatted): Update.
12062
30a25466
TT
120632017-06-12 Tom Tromey <tom@tromey.com>
12064
12065 PR exp/16225:
12066 * valprint.h (print_binary_chars, print_hex_chars): Update.
12067 * valprint.c (val_print_type_code_int): Update.
12068 (print_binary_chars): Add "zero_pad" argument.
12069 (emit_octal_digit): New function.
12070 (print_octal_chars): Don't zero-pad.
12071 (print_decimal_chars): Likewise.
12072 (print_hex_chars): Add "zero_pad" argument.
12073 * sh64-tdep.c (sh64_do_fp_register): Update.
12074 * regcache.c (regcache::dump): Update.
12075 * printcmd.c (print_scalar_formatted): Update.
12076 * infcmd.c (default_print_one_register_info): Update.
12077
b3464d03
PA
120782017-06-12 Pedro Alves <palves@redhat.com>
12079 Alan Hayward <alan.hayward@arm.com>
12080
12081 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
12082 (mips_eabi_push_dummy_call): Rename local 'regsize' to
12083 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
12084 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
12085 Assert that abi_regsize bytes fit in 'ref_valbuf'.
12086
4b76cda9
PA
120872017-06-12 Pedro Alves <palves@redhat.com>
12088
12089 * dwarf2read.c (mapped_symtab::data): Now a vector of
12090 symtab_index_entry instead of vector of
12091 std::unique_ptr<symtab_index_entry>. All users adjusted to check
12092 whether an element's name is NULL instead of checking whether the
12093 element itself is NULL.
12094 (find_slot): Change return type. Adjust.
12095 (hash_expand, , add_index_entry, uniquify_cu_indices)
12096 (write_hash_table): Adjust.
12097
e8f8bcb3
PA
120982017-06-12 Pedro Alves <palves@redhat.com>
12099
12100 * dwarf2read.c (recursively_count_psymbols): New function.
12101 (write_psymtabs_to_index): Call it to compute number of psyms and
12102 pass estimate size of psyms_seen to unordered_set's ctor.
12103
70a1152b
PA
121042017-06-12 Pedro Alves <palves@redhat.com>
12105
12106 * dwarf2read.c (write_hash_table): Check if key already exists
12107 before emplacing.
12108
c2f134ac
PA
121092017-06-12 Pedro Alves <palves@redhat.com>
12110
12111 * dwarf2read.c (data_buf::append_space): Rename to...
12112 (data_buf::grow): ... this, and make private. Adjust all callers.
12113 (data_buf::append_uint): New method.
12114 (add_address_entry, write_one_signatured_type)
12115 (write_psymtabs_to_index): Use it.
12116
a81e6d4d
PA
121172017-06-12 Pedro Alves <palves@redhat.com>
12118
12119 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
12120 (file_write (FILE *, const std::vector<Elem>&)): Delete.
12121 (data_buf::file_write): Call ::fwrite directly.
12122
6fd931f2
PA
121232017-06-12 Pedro Alves <palves@redhat.com>
12124
12125 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
12126 std::vector::erase.
12127
bc8f2430
JK
121282017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12129
12130 Code cleanup: C++ify .gdb_index producer.
12131 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
12132 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
12133 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
12134 (create_strtab, add_string): Remove.
12135 (file_write, data_buf): New.
12136 (struct symtab_index_entry): Use std::vector for cu_indices.
12137 (struct mapped_symtab): Use std::vector for data.
12138 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
12139 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
12140 Remove.
12141 (find_slot): Change return type. Update it to the new data structures.
12142 (hash_expand, add_index_entry): Update it to the new data structures.
12143 (offset_type_compare): Remove.
12144 (uniquify_cu_indices): Update it to the new data structures.
12145 (c_str_view, c_str_view_hasher, vector_hasher): New.
12146 (add_indices_to_cpool): Remove.
12147 (write_hash_table): Update it to the new data structures.
12148 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
12149 (eq_psymtab_cu_index): Remove.
12150 (psym_index_map): New typedef.
12151 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
12152 reference and std::unordered_map for cu_index_htab.
12153 (add_address_entry, add_address_entry_worker, write_address_map)
12154 (write_psymbols): Update it to the new data structures.
12155 (write_obstack): Remove.
12156 (struct signatured_type_index_data): Change types_list to a data_buf
12157 reference and psyms_seen to a std::unordered_set reference.
12158 (write_one_signatured_type, recursively_write_psymbols)
12159 (write_psymtabs_to_index): Update it to the new data structures.
12160
c4dcb155
SM
121612017-06-11 Simon Marchi <simon.marchi@ericsson.com>
12162
12163 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
12164 separate-debug-file commands.
12165 * symfile.h (separate_debug_file_debug): New global.
12166 * symfile.c (separate_debug_file_debug): New global.
12167 (separate_debug_file_exists, find_separate_debug_file): Add
12168 debug output.
12169 (_initialize_symfile): Add "set debug separate-debug-file"
12170 command.
12171 * build-id.c (build_id_to_debug_bfd,
12172 find_separate_debug_file_by_buildid): Add debug output.
12173
6d45d4b4
SM
121742017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
12175
12176 * gdbarch.sh (displaced_step_free_closure): Remove.
12177 * gdbarch.h, gdbarch.c: Re-generate.
12178 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
12179 displaced_step_free_closure.
12180 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
12181 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
12182 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
12183 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
12184 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
12185 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12186 * arch-utils.h (simple_displaced_step_free_closure): Remove.
12187 * arch-utils.c (simple_displaced_step_free_closure): Remove.
12188 * infrun.c (displaced_step_clear): Call xfree instead of
12189 gdbarch_displaced_step_free_closure.
12190
2f91880f
SDJ
121912017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
12192
12193 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
12194 NULL".
12195
b8b6e72f
AH
121962017-06-08 Alan Hayward <alan.hayward@arm.com>
12197
12198 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
12199 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
12200 (mn10300_push_dummy_call): Likewise.
12201
5369082e
AH
122022017-06-08 Alan Hayward <alan.hayward@arm.com>
12203
12204 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
12205
ff4ca5ac
AH
122062017-06-08 Alan Hayward <alan.hayward@arm.com>
12207
12208 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
12209
aefd8b33
SDJ
122102017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12211
12212 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
12213 able to start inferiors using a shell.
12214 (New remote packets): Announce new packet "QStartupWithShell".
12215 * remote.c: Add PACKET_QStartupWithShell.
12216 (extended_remote_create_inferior): Handle new
12217 PACKET_QStartupWithShell.
12218 (remote_protocol_features) <QStartupWithShell>: New entry for
12219 PACKET_QStartupWithShell.
12220 (_initialize_remote): Call "add_packet_config_cmd" for
12221 QStartupShell.
12222
2090129c
SDJ
122232017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12224 Pedro Alves <palves@redhat.com>
12225
12226 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
12227 and "nat/fork-inferior.h".
12228 * common/common-inferior.h: New file, with contents from
12229 "gdb/inferior.h".
12230 * commom/common-utils.c: Include "common-utils.h".
12231 (stringify_argv): New function.
12232 * common/common-utils.h (stringify_argv): New prototype.
12233 * configure.nat: Add "fork-inferior.o" as a dependency for
12234 "*linux*", "fbsd*" and "nbsd*" hosts.
12235 * corefile.c (get_exec_file): Update comment.
12236 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
12237 instead of "startup_inferior".
12238 (darwin_create_inferior): Call "add_thread_silent" after
12239 "fork_inferior".
12240 * fork-child.c: Cleanup unnecessary includes.
12241 (SHELL_FILE): Move to "common/common-fork-child.c".
12242 (environ): Likewise.
12243 (exec_wrapper): Initialize.
12244 (get_exec_wrapper): New function.
12245 (breakup_args): Move to "common/common-fork-child.c"; rename to
12246 "breakup_args_for_exec".
12247 (escape_bang_in_quoted_argument): Move to
12248 "common/common-fork-child.c".
12249 (saved_ui): New variable.
12250 (prefork_hook): New function.
12251 (postfork_hook): Likewise.
12252 (postfork_child_hook): Likewise.
12253 (gdb_startup_inferior): Likewise.
12254 (fork_inferior): Move to "common/common-fork-child.c". Update
12255 function to support gdbserver.
12256 (startup_inferior): Likewise.
12257 * gdbcore.h (get_exec_file): Remove declaration.
12258 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
12259 instead of "startup_inferior". Call "add_thread_silent" after
12260 "fork_inferior".
12261 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
12262 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
12263 instead of "startup_inferior". Call "add_thread_silent" after
12264 "fork_inferior".
12265 * inferior.h: Include "common-inferior.h".
12266 (trace_start_error): Move to "common/common-utils.h".
12267 (trace_start_error_with_name): Likewise.
12268 (fork_inferior): Move prototype to "nat/fork-inferior.h".
12269 (startup_inferior): Likewise.
12270 (gdb_startup_inferior): New prototype.
12271 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
12272 * nat/fork-inferior.h: New file.
12273 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
12274 instead of "startup_inferior". Call "add_thread_silent" after
12275 "fork_inferior".
12276 * target.h (target_terminal_init): Move prototype to
12277 "target/target.h".
12278 (target_terminal_inferior): Likewise.
12279 (target_terminal_ours): Likewise.
12280 * target/target.h (target_terminal_init): New prototype, moved
12281 from "target.h".
12282 (target_terminal_inferior): Likewise.
12283 (target_terminal_ours): Likewise.
12284 * utils.c (gdb_flush_out_err): New function.
12285
043a4934
SDJ
122862017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12287
12288 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
12289 * common/common-gdbthread.h: New file, with parts from
12290 "gdb/gdbthread.h".
12291 * gdbthread.h: Include "common-gdbthread.h".
12292 (switch_to_thread): Moved to "common/common-gdbthread.h".
12293
15652511
SDJ
122942017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
12295
12296 * Makefile.in (SFILES): Add "common/job-control.c".
12297 (HFILES_NO_SRCDIR): Add "common/job-control.h".
12298 (COMMON_OBS): Add "job-control.o".
12299 * common/job-control.c: New file, with contents from
12300 "gdb/inflow.c".
12301 * common/job-control.h: New file, with contents from "terminal.h".
12302 * fork-child.c: Include "job-control.h".
12303 * inflow.c: Include "job-control.h".
12304 (gdb_setpgid): Move to "common/common-inflow.c".
12305 (_initialize_inflow): Move setting of "job_control" to
12306 "handle_job_control".
12307 * terminal.h (job_control): Moved to "common/common-terminal.h".
12308 (gdb_setpgid): Likewise.
12309 * top.c: Include "job_control.h".
12310 * utils.c: Likewise.
12311 (job_control): Moved to "job-control.c".
12312
2d7cc5c7
PA
123132017-06-07 Pedro Alves <palves@redhat.com>
12314
12315 * Makefile.in (SFILES): Add gdb_regex.c.
12316 (COMMON_OBS): Add gdb_regex.o.
12317 * ada-lang.c (ada_add_standard_exceptions)
12318 (ada_add_exceptions_from_frame, name_matches_regex)
12319 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
12320 parameter type to compiled_regex. Adjust.
12321 (ada_exceptions_list): Use compiled_regex.
12322 * break-catch-throw.c (exception_catchpoint::pattern): Now a
12323 std::unique_ptr<compiled_regex>.
12324 (exception_catchpoint::~exception_catchpoint): Remove regfree
12325 call.
12326 (check_status_exception_catchpoint): Adjust to use compiled_regex.
12327 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
12328 * breakpoint.c (solib_catchpoint::compiled): Now a
12329 std::unique_ptr<compiled_regex>.
12330 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
12331 (check_status_catch_solib): Adjust to use compiled_regex.
12332 (add_solib_catchpoint): Adjust to use compiled_regex.
12333 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
12334 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
12335 compiled_regex reference. Adjust to use it.
12336 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
12337 declaration. Include "gdb_regex.h".
12338 (apropos_cmd): Change regex parameter to compiled_regex reference.
12339 * gdb_regex.c: New file.
12340 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
12341 declarations.
12342 (class compiled_regex): New.
12343 * linux-tdep.c: Include "common/gdb_optional.h".
12344 (struct mapping_regexes): New, factored out from
12345 mapping_is_anonymous_p, and adjusted to use compiled_regex.
12346 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
12347 gdb::optional and remove cleanups. Adjust to compiled_regex.
12348 * probe.c: Include "common/gdb_optional.h".
12349 (collect_probes): Use compiled_regex and gdb::optional and remove
12350 cleanups.
12351 * skip.c: Include "common/gdb_optional.h".
12352 (skiplist_entry::compiled_function_regexp): Now a
12353 gdb::optional<compiled_regex>.
12354 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
12355 (free_skiplist_entry): Remove regfree call.
12356 (compile_skip_regexp, skip_rfunction_p): Adjust to use
12357 compiled_regex and gdb::optional.
12358 * symtab.c: Include "common/gdb_optional.h".
12359 (search_symbols): Use compiled_regex and gdb::optional.
12360 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
12361 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
12362 to gdb_regex.c.
12363
50d6adef
AH
123642017-06-07 Alan Hayward <alan.hayward@arm.com>
12365
12366 * regcache.c (regcache::save): Avoid buffer use.
12367 (regcache::dump): Likewise.
12368
4a8a33c8
AH
123692017-06-07 Alan Hayward <alan.hayward@arm.com>
12370
12371 * sh-tdep.c (sh_pseudo_register_read): Remove
12372 MAX_REGISTER_SIZE.
12373 (sh_pseudo_register_write): Likewise.
12374 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
12375 (sh64_pseudo_register_write): Likewise
12376
d1be909e
AH
123772017-06-07 Alan Hayward <alan.hayward@arm.com>
12378
12379 * aarch64-tdep.c (aarch64_store_return_value): Use
12380 V_REGISTER_SIZE.
12381 (aarch64_pseudo_read_value): Likewise.
12382 (aarch64_pseudo_write): Likewise.
12383
f4a65042
YQ
123842017-06-06 Yao Qi <yao.qi@linaro.org>
12385
12386 * regformats/regdef.h (set_register_cache): Remove the
12387 declaration.
12388
9f7fb0aa
AH
123892017-06-06 Alan Hayward <alan.hayward@arm.com>
12390
12391 * frame.c (frame_unwind_register_signed): Use
12392 frame_unwind_register_value.
12393
e1e01040
PA
123942017-06-06 Pedro Alves <palves@redhat.com>
12395
12396 PR breakpoints/21553
12397 * breakpoint.c (create_breakpoints_sal_default)
12398 (init_breakpoint_sal, create_breakpoint_sal): Use
12399 gdb::unique_xmalloc_ptr for string parameters.
12400 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12401 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
12402 (base_breakpoint_create_breakpoints_sal)
12403 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
12404 (strace_marker_create_breakpoints_sal)
12405 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
12406 string parameters.
12407 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
12408 gdb::unique_xmalloc_ptr for string parameters.
12409 (create_breakpoint): Constify 'extra_string' and 'cond_string'
12410 parameters.
12411
fbe654c8
AH
124122017-06-06 Alan Hayward <alan.hayward@arm.com>
12413
12414 * alpha-tdep.c (alpha_register_to_value): Use
12415 get_frame_register_value.
12416 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
12417
ae0d01d6
AH
124182017-06-06 Alan Hayward <alan.hayward@arm.com>
12419
12420 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
12421 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
12422 (ia64_value_to_register): Likewise.
12423 (ia64_extract_return_value): Likewise.
12424 (ia64_store_return_value): Likewise.
12425 (ia64_push_dummy_call): Likewise.
12426
49cf576c
JB
124272017-06-04 Joel Brobecker <brobecker@adacore.com>
12428
12429 GDB 8.0 released.
12430
26b6a6ab
SM
124312017-06-03 Simon Marchi <simon.marchi@ericsson.com>
12432
12433 * x86-linux-nat.c (struct arch_lwp_info): Remove.
12434
22827c51
SM
124352017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
12436
12437 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
12438 parameter.
12439 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
12440
0e05cf3a
SM
124412017-06-02 Simon Marchi <simon.marchi@ericsson.com>
12442
12443 * event-loop.c (poll_timers): Unallocate timer using delete
12444 instead of xfree.
12445
c1fc2657
SM
124462017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12447
12448 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
12449 (struct breakpoint) <~breakpoint>: New.
12450 (struct watchpoint): Inherit from breakpoint.
12451 <~watchpoint>: New.
12452 <base>: Remove.
12453 (struct tracepoint): Inherit from breakpoint.
12454 <base>: Remove.
12455 * breakpoint.c (longjmp_breakpoint_ops): Remove.
12456 (struct longjmp_breakpoint): Inherit from breakpoint.
12457 <~longjmp_breakpoint>: New.
12458 <base>: Remove.
12459 (new_breakpoint_from_type): Remove casts.
12460 (watchpoint_in_thread_scope): Remove reference to base field.
12461 (watchpoint_del_at_next_stop): Likewise.
12462 (update_watchpoint): Likewise.
12463 (watchpoint_check): Likewise.
12464 (bpstat_check_watchpoint): Likewise.
12465 (set_longjmp_breakpoint): Likewise.
12466 (struct fork_catchpoint): Inherit from breakpoint.
12467 <base>: Remove.
12468 (struct solib_catchpoint): Inherit from breakpoint.
12469 <~solib_catchpoint>: New.
12470 <base>: Remove.
12471 (dtor_catch_solib): Change to ...
12472 (solib_catchpoint::~solib_catchpoint): ... this.
12473 (breakpoint_hit_catch_solib): Remove reference to base field.
12474 (add_solib_catchpoint): Likewise.
12475 (create_fork_vfork_event_catchpoint): Likewise.
12476 (struct exec_catchpoint): Inherit from breakpoint.
12477 <~exec_catchpoint>: New.
12478 <base>: Remove.
12479 (dtor_catch_exec): Change to ...
12480 (exec_catchpoint::~exec_catchpoint): ... this.
12481 (dtor_watchpoint): Change to ...
12482 (watchpoint::~watchpoint): ... this.
12483 (watch_command_1): Remove reference to base field.
12484 (catch_exec_command_1): Likewise.
12485 (base_breakpoint_dtor): Change to ...
12486 (breakpoint::~breakpoint): ... this.
12487 (base_breakpoint_ops): Remove dtor field value.
12488 (longjmp_bkpt_dtor): Change to ...
12489 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
12490 (strace_marker_create_breakpoints_sal): Remove reference to base
12491 field.
12492 (delete_breakpoint): Don't manually call breakpoint destructor.
12493 (create_tracepoint_from_upload): Remove reference to base field.
12494 (trace_pass_set_count): Likewise.
12495 (initialize_breakpoint_ops): Don't initialize
12496 momentary_breakpoint_ops, don't set dtors.
12497 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
12498 <~ada_catchpoint>: New.
12499 <base>: Remove.
12500 (create_excep_cond_exprs): Remove reference to base field.
12501 (dtor_exception): Change to ...
12502 (ada_catchpoint::~ada_catchpoint): ... this.
12503 (dtor_catch_exception): Remove.
12504 (dtor_catch_exception_unhandled): Remove.
12505 (dtor_catch_assert): Remove.
12506 (create_ada_exception_catchpoint): Remove reference to base
12507 field.
12508 (initialize_ada_catchpoint_ops): Don't set dtors.
12509 * break-catch-sig.c (struct signal_catchpoint): Inherit from
12510 breakpoint.
12511 <~signal_catchpoint>: New.
12512 <base>: Remove.
12513 (signal_catchpoint_dtor): Change to ...
12514 (signal_catchpoint::~signal_catchpoint): ... this.
12515 (create_signal_catchpoint): Remove reference to base field.
12516 (initialize_signal_catchpoint_ops): Don't set dtor.
12517 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
12518 from breakpoint.
12519 <~syscall_catchpoint>: New.
12520 <base>: Remove.
12521 (dtor_catch_syscall): Change to ...
12522 (syscall_catchpoint::~syscall_catchpoint): ... this.
12523 (create_syscall_event_catchpoint): Remove reference to base
12524 field.
12525 (initialize_syscall_catchpoint_ops): Don't set dtor.
12526 * break-catch-throw.c (struct exception_catchpoint): Inherit
12527 from breakpoint.
12528 <~exception_catchpoint>: New.
12529 <base>: Remove.
12530 (dtor_exception_catchpoint): Change to ...
12531 (exception_catchpoint::~exception_catchpoint): ... this.
12532 (handle_gnu_v3_exceptions): Remove reference to base field.
12533 (initialize_throw_catchpoint_ops): Don't set dtor.
12534 * ctf.c (ctf_get_traceframe_address): Remove reference to base
12535 field.
12536 * remote.c (remote_get_tracepoint_status): Likewise.
12537 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
12538 * tracefile.c (tracefile_fetch_registers): Likewise.
12539 * tracepoint.c (actions_command): Likewise.
12540 (validate_actionline): Likewise.
12541 (tfind_1): Likewise.
12542 (get_traceframe_location): Likewise.
12543 (find_matching_tracepoint_location): Likewise.
12544 (parse_tracepoint_status): Likewise.
12545 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
12546
3b0871f4
SM
125472017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12548
12549 * breakpoint.c (struct longjmp_breakpoint): New struct.
12550 (is_tracepoint_type): Change return type to bool.
12551 (is_longjmp_type): New function.
12552 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
12553 (set_raw_breakpoint_without_location): Use
12554 new_breakpoint_from_type.
12555 (set_raw_breakpoint): Likewise.
12556
a5e364af
SM
125572017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12558
12559 * breakpoint.c (new_breakpoint_from_type): New function.
12560 (create_breakpoint_sal): Use new_breakpoint_from_type and
12561 unique_ptr.
12562 (create_breakpoint): Likewise.
12563
ae3b3f34
SM
125642017-05-31 Simon Marchi <simon.marchi@ericsson.com>
12565
12566 * memattr.c (mem_info_command): Rename to ...
12567 (info_mem_command): ... this.
12568 (mem_enable_command): Rename to ...
12569 (enable_mem_command): ... this.
12570 (mem_disable_command): Rename to ...
12571 (disable_mem_command): ... this.
12572 (mem_delete_command): Rename to ...
12573 (delete_mem_command): ... this.
12574 (_initialize_mem): Adjust function names.
12575
13ace077
MM
125762017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12577
12578 * btrace.c (handle_pt_insn_events): New.
12579 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
12580 STATUS. Split into this and ...
12581 (handle_pt_insn_event_flags): ... this.
12582
c56ccc05
MM
125832017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12584
12585 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
12586 and struct pt_insn.resynced.
12587 * configure: Regenerated.
12588 * config.in: Regenerated.
12589
08c3f6d2
TW
125902017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12591
12592 * btrace.c (ftrace_find_call_by_number): New function.
12593 (ftrace_new_function): Store objects, not pointers.
12594 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
12595 ftrace_new_gap, ftrace_update_function,
12596 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
12597 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
12598 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
12599 btrace_ends_with_single_insn, btrace_call_get): Account for
12600 btrace_thread_info::functions now storing objects.
12601 * btrace.h (struct btrace_thread_info): Add constructor.
12602 (struct btrace_thread_info) <functions>: Make std::vector.
12603 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
12604 Initialize with default values.
12605 * record-btrace.c (record_btrace_frame_sniffer): Account for
12606 btrace_thread_info::functions now storing objects.
12607
8ffd39f2
TW
126082017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12609
12610 * btrace.c: Remove typedef bfun_s.
12611 (ftrace_new_gap): Directly add gaps to the list of gaps.
12612 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
12613 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
12614 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
12615 instead of gdb VEC.
12616
4aeb0dfc
TW
126172017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12618
12619 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
12620 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
12621 with btrace_thread_info::next_segment and
12622 btrace_thread_info::prev_segment.
12623 * btrace.h: Remove struct btrace_func_link.
12624 (struct btrace_function): Replace pair of function segment pointers
12625 with pair of indices.
12626 * python/py-record-btrace.c (btpy_call_prev_sibling,
12627 btpy_call_next_sibling): Replace references to
12628 btrace_thread_info::segment with btrace_thread_info::next_segment and
12629 btrace_thread_info::prev_segment.
12630 * record-btrace.c (record_btrace_frame_this_id): Use
12631 btrace_find_call_by_number.
12632
eb8f2b9c
TW
126332017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12634
12635 * btrace.c (ftrace_new_function, ftrace_fixup_level,
12636 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
12637 btrace_insn_next, btrace_insn_prev): Remove references to
12638 btrace_thread_info::flow.
12639 * btrace.h (struct btrace_function): Remove FLOW.
12640
42bfe59e
TW
126412017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12642
12643 * btrace.c (ftrace_find_call_by_number): New function.
12644 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
12645 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
12646 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
12647 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
12648 index.
12649 * btrace.h (struct btrace_function): Turn UP into an index.
12650 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
12651 as an index.
12652 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
12653 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12654 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12655
b54b03bd
TW
126562017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12657
12658 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12659 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12660 ftrace_update_function, ftrace_compute_global_level_offset,
12661 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12662 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12663 btrace_insn_end, btrace_is_empty): Remove references to
12664 btrace_thread_info::begin and btrace_thread_info::end.
12665 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12666 (struct btrace_thread_info) <functions>: Adjust comment.
12667 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12668 btrace_thread_info::begin.
12669
8286623c
TW
126702017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12671
12672 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12673 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12674 ftrace_update_function): Remove arguments that implicitly were always
12675 BTINFO->END.
12676 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12677 Don't pass BTINFO->END.
12678
a0f1b963
TW
126792017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12680
12681 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12682 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12683 btrace_find_insn_by_number): Replace function segment pointer with
12684 index.
12685 (btrace_insn_cmp): Simplify.
12686 * btrace.h: (struct btrace_insn_iterator) Rename index to
12687 insn_index. Replace function segment pointer with index into function
12688 segment vector.
12689 * record-btrace.c (record_btrace_call_history): Replace function
12690 segment pointer use with index.
12691 (record_btrace_frame_sniffer): Retrieve function call segment through
12692 vector.
12693 (record_btrace_set_replay): Remove defunc't safety check.
12694
f158f208
TW
126952017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12696
12697 * btrace.c (btrace_ends_with_single_insn): New function.
12698 (btrace_call_get, btrace_call_number, btrace_call_begin,
12699 btrace_call_end, btrace_call_next, btrace_call_prev,
12700 btrace_find_call_by_number): Use index into call segment vector
12701 instead of pointer.
12702 (btrace_call_cmp): Simplify.
12703 * btrace.h (struct btrace_call_iterator): Replace function call segment
12704 pointer with index into vector.
12705 * record-btrace.c (record_btrace_call_history): Use index instead of
12706 pointer.
12707
521103fd
TW
127082017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12709
12710 * btrace.c (btrace_insn_begin, btrace_insn_end,
12711 btrace_find_insn_by_number): Add btinfo to iterator.
12712 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12713
17b89b34
TW
127142017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12715
12716 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12717 and save pointers directly.
12718 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12719 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12720 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12721 changed signature of functions.
12722 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12723 (btrace_fetch): Remove code that adds btrace_function pointers to
12724 vector of btrace_functions.
12725 (btrace_clear): Simplify freeing vector of btrace_functions.
12726
2b51eddc
TW
127272017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12728
12729 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12730 Replace VEC_* with std::vector functions.
12731 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12732 (struct btrace_thread_info)<functions>: Change type to std::vector.
12733
db6be0d5
SM
127342017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12735
12736 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12737 "Removed targets and native configurations" up. Merge duplicate
12738 "New commands" sub-sections. Add "New options" sub-sections.
12739
b057297a
AH
127402017-05-26 Alan Hayward <alan.hayward@arm.com>
12741
12742 * defs.h (copy_integer_to_size): New declaration.
12743 * findvar.c (copy_integer_to_size): New function.
12744 (do_cint_test): New selftest function.
12745 (copy_integer_to_size_test): Likewise.
12746 (_initialize_findvar): Likewise.
12747 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12748 (mips_fbsd_collect_reg): Use raw_collect_integer.
12749 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12750 (mips64_fill_gregset): Use raw_collect_integer
12751 (mips64_fill_fpregset): Use raw_supply_integer.
12752 * regcache.c (regcache::raw_supply_integer): New function.
12753 (regcache::raw_collect_integer): Likewise.
12754 * regcache.h: (regcache::raw_supply_integer): New declaration.
12755 (regcache::raw_collect_integer): Likewise.
12756
b77b02a5
YQ
127572017-05-24 Yao Qi <yao.qi@linaro.org>
12758
12759 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12760 (COMMON_OBS): Add gdbarch-selftests.o.
12761 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12762 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12763 * gdbarch-selftests.c: New file.
12764 * regcache.h (regcache) <~regcache>: Mark it virtual if
12765 GDB_SELF_TEST.
12766 <raw_write>: Likewise.
12767
e521e87e
YQ
127682017-05-24 Yao Qi <yao.qi@linaro.org>
12769
12770 * regcache.c (current_regcache): Change it to
12771 regcache::current_regcache.
12772 (regcache_observer_target_changed): Update.
12773 (regcache_thread_ptid_changed): Make it a regcache static
12774 method.
12775 (regcache_thread_ptid_changed): Update.
12776 (class regcache_access): New.
12777 (current_regcache_test): Update.
12778 (_initialize_regcache): Update.
12779 * regcache.h: Include forward_list.
12780 (regcache): Declare regcache_thread_ptid_changed and declare
12781 registers_changed_ptid as friend.
12782
d8e07dda
YQ
127832017-05-24 Yao Qi <yao.qi@linaro.org>
12784
12785 * i387-tdep.c (i387_register_to_value): Use register_size
12786 instead of TYPE_LENGTH.
12787 * m68k-tdep.c (m68k_register_to_value): Likewise.
12788
8c8f9122
YQ
127892017-05-24 Yao Qi <yao.qi@linaro.org>
12790
12791 * i387-tdep.c (i387_convert_register_p): Return false if type
12792 code isn't TYPE_CODE_FLT.
12793
68fce50f
YQ
127942017-05-24 Yao Qi <yao.qi@linaro.org>
12795
12796 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12797 length is 4.
12798 (alpha_register_to_value): Remove type length check.
12799 (alpha_value_to_register): Likewise.
12800
88954b49
YQ
128012017-05-24 Yao Qi <yao.qi@linaro.org>
12802
12803 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12804 TYPE_CODE_FLT.
12805
e3ec9b69
YQ
128062017-05-24 Yao Qi <yao.qi@linaro.org>
12807
12808 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12809 TYPE_CODE_FLT or not.
12810
cdd238da
YQ
128112017-05-24 Yao Qi <yao.qi@linaro.org>
12812
12813 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12814 * avr-tdep.c (avr_gdbarch_init): Likewise.
12815 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12816 * cris-tdep.c (cris_gdbarch_init): Likewise.
12817 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12818 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12819 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12820 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12821 * mep-tdep.c (mep_gdbarch_init): Likewise.
12822 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12823 * mips-tdep.c (mips_gdbarch_init): Likewise.
12824 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12825 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12826 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12827 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12828 * v850-tdep.c (v850_gdbarch_init): Likewise.
12829
7a3929c4
YQ
128302017-05-24 Yao Qi <yao.qi@linaro.org>
12831
12832 * selftest-arch.c (tests_with_arch): Call registers_changed
12833 and reinit_frame_cache.
12834 * selftest.c (run_self_tests): Likewise.
12835
f4985dba
YQ
128362017-05-24 Yao Qi <yao.qi@linaro.org>
12837
12838 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12839 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12840
ab20fa4a
YQ
128412017-05-24 Yao Qi <yao.qi@linaro.org>
12842
12843 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12844 set_gdbarch_print_insn.
12845
f532ab94
YQ
128462017-05-24 Yao Qi <yao.qi@linaro.org>
12847
12848 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12849 set_gdbarch_print_insn.
12850
39503f82
YQ
128512017-05-24 Yao Qi <yao.qi@linaro.org>
12852
12853 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12854 set_gdbarch_print_insn.
12855 * arc-tdep.c (arc_gdbarch_init): Likewise.
12856 * arch-utils.c: include dis-asm.h.
12857 (default_print_insn): New function.
12858 * arch-utils.h (default_print_insn): Declare.
12859 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12860 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12861 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12862 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12863 * frv-tdep.c (frv_gdbarch_init): Likewise.
12864 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12865 * gdbarch.sh (print_insn): Use default_print_insn.
12866 * gdbarch.c: Regenerated.
12867 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12868 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12869 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12870 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12871 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12872 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12873 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12874 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12875 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12876 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12877 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12878 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12879 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12880 * mt-tdep.c (mt_gdbarch_init): Likewise.
12881 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12882 * nios2-tdep.c (nios2_print_insn): Remove.
12883 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12884 * rx-tdep.c (rx_gdbarch_init): Likewise.
12885 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12886 * score-tdep.c (score_print_insn): Remove.
12887 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12888 * sh-tdep.c (sh_gdbarch_init): Likewise.
12889 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12890 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12891 * tic6x-tdep.c (tic6x_print_insn): Remove.
12892 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12893 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12894 * v850-tdep.c (v850_gdbarch_init): Likewise.
12895 * vax-tdep.c (vax_gdbarch_init): Likewise.
12896 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12897 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12898
f7241d4f
JB
128992017-05-23 John Baldwin <jhb@FreeBSD.org>
12900
12901 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12902 (MIPS_FP0_REGNUM): Remove.
12903 (MIPS_FSR_REGNUM): Remove.
12904 (mips_fbsd_supply_fpregs): Use mips_regnum.
12905 (mips_fbsd_supply_gregs): Likewise.
12906 (mips_fbsd_collect_fpregs): Likewise.
12907 (mips_fbsd_collect_gregs): Likewise.
12908
d489d81d
JB
129092017-05-23 John Baldwin <jhb@FreeBSD.org>
12910
12911 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12912 (getpfpregs_supplies): New function.
12913 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12914 getfpregs_supplies.
12915 (mips_fbsd_store_inferior_registers): Likewise.
12916
e11b3cdc
PA
129172017-05-22 Pedro Alves <palves@redhat.com>
12918
12919 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12920 maintainer.
12921
0f068fb5
AH
129222017-05-22 Alan Hayward <alan.hayward@arm.com>
12923
12924 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12925 (store_register): Likewise.
12926 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12927 (get_decimal_float_return_value): Likewise.
12928 (do_ppc_sysv_return_value): Likewise.
12929 (ppc64_sysv_abi_push_integer): Likewise.
12930 (ppc64_sysv_abi_push_freg): Likewise.
12931 (ppc64_sysv_abi_return_value_base): Likewise.
12932 (ppc64_sysv_abi_return_value): Likewise.
12933 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12934 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12935 * rs6000-nat.c: Likewise.
12936 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12937 (rs6000_value_to_register): Likewise.
12938 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12939
e6cf65f2
TT
129402017-05-21 Tom Tromey <tom@tromey.com>
12941
12942 PR rust/21466:
12943 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12944 arrays as "[T]", not "[T; ]".
12945
43cc5389
TT
129462017-05-19 Tom Tromey <tom@tromey.com>
12947
12948 PR rust/21484:
12949 * rust-lang.c (exp_descriptor_rust): New function.
12950 (rust_language_defn): Use it.
12951 * p-lang.c (pascal_language_defn): Update.
12952 * opencl-lang.c (opencl_language_defn): Update.
12953 * objc-lang.c (objc_language_defn): Update.
12954 * m2-lang.c (m2_language_defn): Update.
12955 * language.h (struct language_defn)
12956 <la_watch_location_expression>: New member.
12957 * language.c (unknown_language_defn, auto_language_defn)
12958 (local_language_defn): Update.
12959 * go-lang.c (go_language_defn): Update.
12960 * f-lang.c (f_language_defn): Update.
12961 * d-lang.c (d_language_defn): Update.
12962 * c-lang.h (c_watch_location_expression): Declare.
12963 * c-lang.c (c_watch_location_expression): New function.
12964 (c_language_defn, cplus_language_defn, asm_language_defn)
12965 (minimal_language_defn): Use it.
12966 * breakpoint.c (watch_command_1): Call
12967 la_watch_location_expression.
12968 * ada-lang.c (ada_language_defn): Update.
12969
7a6e7fcc
RO
129702017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12971
6e7e1744
RO
12972 PR tui/21482
12973 * gdb_curses.h (NOMACROS): Define.
12974 (NCURSES_NOMACROS): Define.
12975
129762017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12977
12978 PR tui/21482
7a6e7fcc
RO
12979 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12980 arg to char *.
12981 * tui/tui-wingeneral.c (box_win): Likewise.
12982 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12983 (tui_show_source_line): Likewise.
12984 (tui_show_exec_info_content): Likewise.
12985
1933fd8e
VM
129862017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12987
12988 * sparc-tdep.c (sparc_structure_return_p)
12989 (sparc_arg_on_registers_p): New functions.
12990 (sparc32_store_arguments): Use them.
12991 * sparc64-tdep.c (sparc64_16_byte_align_p)
12992 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12993 Handle TYPE_CODE_ARRAY.
12994
21873064
YQ
129952017-05-17 Yao Qi <yao.qi@linaro.org>
12996
12997 * cli/cli-decode.c (add_alias_cmd): New function.
12998 * command.h (add_alias_cmd): Declare.
12999 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
13000 instead call add_alias_cmd.
13001
2b351b19
PA
130022017-05-17 Pedro Alves <palves@redhat.com>
13003
13004 * Makefile.in (nat_extra_makefile_frag): Rename to ...
13005 (nat_makefile_frag): ... this. All references updated.
13006 * configure.ac: Likewise.
13007 * configure.nat: Likewise. Enhance comments.
13008 * configure: Regenerate.
13009
5f2ad7a3
RO
130102017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13011
13012 * procfs.c (procfs_create_inferior): Change prototype to match
13013 definition.
13014
adf3dde5
EZ
130152017-05-13 Eli Zaretskii <eliz@gnu.org>
13016
13017 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
13018 C++ compiler warning.
13019
6830f270
TT
130202017-05-12 Tom Tromey <tom@tromey.com>
13021
13022 PR rust/21483:
13023 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
13024 recurse, just call value_struct_elt directly.
13025
68f2f2e3
TT
130262017-05-12 Tom Tromey <tom@tromey.com>
13027
13028 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
13029 OP_RUST_ARRAY>: Fix.
13030
256afbc2
TT
130312017-05-12 Tom Tromey <tom@tromey.com>
13032
13033 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
13034
94bb8dfe
YQ
130352017-05-09 Yao Qi <yao.qi@linaro.org>
13036
13037 * regcache.c: Include <forward_list>.
13038 (struct regcache_list): Remove.
13039 (current_regcache): Update.
13040 (get_thread_arch_aspace_regcache): Update for std::forward_list.
13041 (regcache_thread_ptid_changed): Likewise.
13042 (registers_changed_ptid): Likewise.
13043 (current_regcache_size): Likewise.
13044
8248946c
YQ
130452017-05-09 Yao Qi <yao.qi@linaro.org>
13046
13047 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
13048 (current_regcache_size): New function.
13049 (current_regcache_test): New function.
13050 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
13051
313c5961
AH
130522017-05-08 Alan Hayward <alan.hayward@arm.com>
13053
13054 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
13055 (print_gp_register_row): Use get_frame_register_value.
13056
27bfc1d1
AH
130572017-05-08 Alan Hayward <alan.hayward@arm.com>
13058
13059 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
13060 (mips_supply_fpregset): Likewise.
13061 (mips64_supply_gregset): Likewise.
13062
146e6c5c
AH
130632017-05-08 Alan Hayward <alan.hayward@arm.com>
13064
13065 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
13066 regcache->raw_supply_zeroed.
13067
e50f25ec
SDJ
130682017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
13069
13070 * configure.nat: Rearrange 'case' statements to match
13071 host before cpu.
13072
21ea5acd
SDJ
130732017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
13074
13075 * Makefile.in: Remove "@host_makefile_frag@". Add variables
13076 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
13077 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
13078 "@nat_extra_makefile_frag@".
13079 (Makefile): Remove dependency on "@frags@".
13080 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
13081 (data-directory/Makefile): Likewise.
13082 * config/aarch64/linux.mh: Deleted; moved contents to
13083 "gdb/configure.nat".
13084 * config/alpha/alpha-linux.mh: Likewise.
13085 * config/alpha/nbsd.mh: Likewise.
13086 * config/arm/linux.mh: Likewise.
13087 * config/arm/nbsdelf.mh: Likewise.
13088 * config/i386/cygwin.mh: Likewise.
13089 * config/i386/cygwin64.mh: Likewise.
13090 * config/i386/darwin.mh: Likewise.
13091 * config/i386/fbsd.mh: Likewise.
13092 * config/i386/fbsd64.mh: Likewise.
13093 * config/i386/go32.mh: Likewise.
13094 * config/i386/i386gnu.mh: Likewise.
13095 * config/i386/i386sol2.mh: Likewise.
13096 * config/i386/linux.mh: Likewise.
13097 * config/i386/linux64.mh: Likewise.
13098 * config/i386/mingw.mh: Likewise.
13099 * config/i386/mingw64.mh: Likewise.
13100 * config/i386/nbsd64.mh: Likewise.
13101 * config/i386/nbsdelf.mh: Likewise.
13102 * config/i386/nto.mh: Likewise.
13103 * config/i386/obsd.mh: Likewise.
13104 * config/i386/obsd64.mh: Likewise.
13105 * config/i386/sol2-64.mh: Likewise.
13106 * config/ia64/linux.mh: Likewise.
13107 * config/m32r/linux.mh: Likewise.
13108 * config/m68k/linux.mh: Likewise.
13109 * config/m68k/nbsdelf.mh: Likewise.
13110 * config/m68k/obsd.mh: Likewise.
13111 * config/m88k/obsd.mh: Likewise.
13112 * config/mips/fbsd.mh: Likewise.
13113 * config/mips/linux.mh: Likewise.
13114 * config/mips/nbsd.mh: Likewise.
13115 * config/mips/obsd64.mh: Likewise.
13116 * config/pa/linux.mh: Likewise.
13117 * config/pa/nbsd.mh: Likewise.
13118 * config/pa/obsd.mh: Likewise.
13119 * config/powerpc/aix.mh: Likewise.
13120 * config/powerpc/fbsd.mh: Likewise.
13121 * config/powerpc/linux.mh: Likewise.
13122 * config/powerpc/nbsd.mh: Likewise.
13123 * config/powerpc/obsd.mh: Likewise.
13124 * config/powerpc/ppc64-linux.mh: Likewise.
13125 * config/powerpc/spu-linux.mh: Likewise.
13126 * config/s390/linux.mh: Likewise.
13127 * config/sh/nbsd.mh: Likewise.
13128 * config/sparc/fbsd.mh: Likewise.
13129 * config/sparc/linux.mh: Likewise.
13130 * config/sparc/linux64.mh: Likewise.
13131 * config/sparc/nbsd64.mh: Likewise.
13132 * config/sparc/nbsdelf.mh: Likewise.
13133 * config/sparc/obsd64.mh: Likewise.
13134 * config/sparc/sol2.mh: Likewise.
13135 * config/tilegx/linux.mh: Likewise.
13136 * config/vax/nbsdelf.mh: Likewise.
13137 * config/vax/obsd.mh: Likewise.
13138 * config/xtensa/linux.mh: Likewise.
13139 * config/i386/i386gnu.mn: New file, with excerpts from
13140 "config/i386/i386gnu.mh".
13141 * configure: Regenerate.
13142 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
13143 *.mh files under "gdb/config".
13144 * configure.nat: New file, with contents from the
13145 "gdb/config/*/*.mh" files.
13146
7ed1acaf
TW
131472017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
13148
13149 * btrace.c (btrace_clear): Free insn vector.
13150
e13cb306
PA
131512017-05-05 Pedro Alves <palves@redhat.com>
13152
13153 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
13154 * configure: Regenerate.
13155
5ed8105e
PA
131562017-05-04 Pedro Alves <palves@redhat.com>
13157
13158 * Makefile.in (SFILES): Add progspace-and-thread.c.
13159 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
13160 (COMMON_OBS): Add progspace-and-thread.o.
13161 * breakpoint.c: Include "progspace-and-thread.h".
13162 (update_inserted_breakpoint_locations)
13163 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
13164 Use scoped_restore_current_pspace_and_thread.
13165 (create_std_terminate_master_breakpoint): Use
13166 scoped_restore_current_program_space.
13167 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
13168 (print_breakpoint_location): Use
13169 scoped_restore_current_program_space.
13170 (bp_loc_is_permanent): Use
13171 scoped_restore_current_pspace_and_thread.
13172 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
13173 (download_tracepoint_locations): Use
13174 scoped_restore_current_pspace_and_thread.
13175 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
13176 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
13177 (enum step_over_calls_kind): Moved from inferior.h.
13178 (class scoped_restore_current_thread): New class.
13179 * gdbthread.h (make_cleanup_restore_current_thread): Delete
13180 declaration.
13181 (scoped_restore_current_thread): New class.
13182 * infcmd.c: Include "common/gdb_optional.h".
13183 (continue_1, proceed_after_attach): Use
13184 scoped_restore_current_thread.
13185 (notice_new_inferior): Use scoped_restore_current_thread.
13186 * inferior.c: Include "progspace-and-thread.h".
13187 (restore_inferior, save_current_inferior): Delete.
13188 (add_inferior_command, clone_inferior_command): Use
13189 scoped_restore_current_pspace_and_thread.
13190 * inferior.h (scoped_restore_current_inferior): New class.
13191 * infrun.c: Include "progspace-and-thread.h" and
13192 "common/gdb_optional.h".
13193 (follow_fork_inferior): Use
13194 scoped_restore_current_pspace_and_thread.
13195 (scoped_restore_exited_inferior): New class.
13196 (handle_vfork_child_exec_or_exit): Use
13197 scoped_restore_exited_inferior,
13198 scoped_restore_current_pspace_and_thread,
13199 scoped_restore_current_thread and scoped_restore.
13200 (fetch_inferior_event): Use scoped_restore_current_thread.
13201 * linespec.c (decode_line_full, decode_line_1): Use
13202 scoped_restore_current_program_space.
13203 * mi/mi-main.c: Include "progspace-and-thread.h".
13204 (exec_continue): Use scoped_restore_current_thread.
13205 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
13206 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
13207 * proc-service.c (ps_pglobal_lookup): Use
13208 scoped_restore_current_program_space.
13209 * progspace-and-thread.c: New file.
13210 * progspace-and-thread.h: New file.
13211 * progspace.c (release_program_space, clone_program_space): Use
13212 scoped_restore_current_program_space.
13213 (restore_program_space, save_current_program_space)
13214 (save_current_space_and_thread): Delete.
13215 (switch_to_program_space_and_thread): Moved to
13216 progspace-and-thread.c.
13217 * progspace.h (save_current_program_space)
13218 (save_current_space_and_thread): Delete declarations.
13219 (scoped_restore_current_program_space): New class.
13220 * remote.c (remote_btrace_maybe_reopen): Use
13221 scoped_restore_current_thread.
13222 * symtab.c: Include "progspace-and-thread.h".
13223 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
13224 * thread.c (print_thread_info_1): Use
13225 scoped_restore_current_thread.
13226 (struct current_thread_cleanup): Delete.
13227 (do_restore_current_thread_cleanup)
13228 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
13229 (scoped_restore_current_thread::~scoped_restore_current_thread):
13230 ... this new dtor.
13231 (make_cleanup_restore_current_thread): Rename/convert to ...
13232 (scoped_restore_current_thread::scoped_restore_current_thread):
13233 ... this new ctor.
13234 (thread_apply_all_command): Use scoped_restore_current_thread.
13235 (thread_apply_command): Use scoped_restore_current_thread.
13236 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
13237 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
13238
f6223dbb
PA
132392017-05-04 Pedro Alves <palves@redhat.com>
13240
13241 * thread.c (make_cleanup_restore_current_thread): Move
13242 find_thread_ptid call before the is_stopped call. Assert that the
13243 thread is found. Replace is_stopped call by checking the thread's
13244 state directly. Remove unnecessary NULL-thread check.
13245
3c3ae77e
PA
132462017-05-04 Pedro Alves <palves@redhat.com>
13247
13248 * corelow.c (thread_section_name): New class.
13249 (get_core_register_section, get_core_siginfo): Use it.
13250
45eba0ab
AA
132512017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
13252
13253 * corelow.c (sniff_core_bfd): Remove extra semicolon.
13254 (get_core_register_section): Remove xfree of NULL pointer.
13255
f81fdd35
AH
132562017-05-03 Alan Hayward <alan.hayward@arm.com>
13257
13258 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
13259 * regcache.c (regcache::raw_supply_zeroed): New function.
13260 * regcache.h (regcache::raw_supply_zeroed): New declaration.
13261
35837774
SM
132622017-05-03 Simon Marchi <simon.marchi@ericsson.com>
13263
13264 * gdbarch.sh: Remove commented out definition of
13265 TARGET_CHAR_BIT.
13266 * gdbarch.h: Re-generate.
13267
c94fee56
SDJ
132682017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
13269
13270 * configure: Regenerate.
13271
d17f7b36
SM
132722017-05-02 Simon Marchi <simon.marchi@ericsson.com>
13273
13274 * solib-target.c (solib_target_relocate_section_addresses):
13275 Remove num_section_bases, num_bases, segment_bases variables.
13276
b560ebd6
SM
132772017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13278
13279 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
13280
f2f46dfc
SM
132812017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13282
13283 * solib-target.c: Include <vector>
13284 (struct lm_info_target) <~lm_info_target>: Remove.
13285 <segment_bases, section_bases>: Change type to
13286 std::vector<CORE_ADDR>.
13287 (library_list_start_segment, library_list_start_section,
13288 library_list_end_library,
13289 solib_target_relocate_section_addresses): Adjust.
13290
a0ff9e1a
SM
132912017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13292
13293 * gdbarch.sh (software_single_step): Change return type to
13294 std::vector<CORE_ADDR>.
13295 * gdbarch.c, gdbarch.h: Re-generate.
13296 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
13297 Adjust.
13298 (arm_deal_with_atomic_sequence_raw): Adjust.
13299 (thumb_get_next_pcs_raw): Adjust.
13300 (arm_get_next_pcs_raw): Adjust.
13301 (arm_get_next_pcs): Adjust.
13302 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
13303 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
13304 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
13305 (alpha_software_single_step): Adjust.
13306 * alpha-tdep.h (alpha_software_single_step): Adjust.
13307 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
13308 * arm-tdep.c (arm_software_single_step): Adjust.
13309 (arm_breakpoint_kind_from_current_state): Adjust.
13310 * arm-tdep.h (arm_software_single_step): Adjust.
13311 * breakpoint.c (insert_single_step_breakpoint): Adjust.
13312 * cris-tdep.c (cris_software_single_step): Adjust.
13313 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
13314 (micromips_deal_with_atomic_sequence): Adjust.
13315 (deal_with_atomic_sequence): Adjust.
13316 (mips_software_single_step): Adjust.
13317 * mips-tdep.h (mips_software_single_step): Adjust.
13318 * moxie-tdep.c (moxie_software_single_step): Adjust.
13319 * nios2-tdep.c (nios2_software_single_step): Adjust.
13320 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
13321 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
13322 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
13323 * s390-linux-tdep.c (s390_software_single_step): Adjust.
13324 * sparc-tdep.c (sparc_software_single_step): Adjust.
13325 * spu-tdep.c (spu_software_single_step): Adjust.
13326 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
13327
ea480a30
SM
133282017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
13329
13330 * gdbarch.sh: Use semi-colon as field separator instead of colon.
13331 * gdbarch.h: Re-generate.
13332
d050f7d7
TW
133332017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13334
13335 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
13336 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
13337 * python/py-instruction.c, python/py-instruction.h: New file.
13338 * python/py-record.c: Add py-instruction.h include.
13339 (gdbpy_initialize_record): Make gdb.Instruction a super class of
13340 gdb.RecordInstruction.
13341 * python/python-internal.h: Add gdbpy_initialize_instruction
13342 declaration.
13343 * python/python.c (do_start_initialization): Add
13344 gdbpy_initialize_instruction.
13345
14f819c8
TW
133462017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13347
13348 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
13349 Remove.
13350 (btrace_func_from_recpy_func): New function.
13351 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
13352 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
13353 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
13354 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
13355 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
13356 Also, use new helper functions.
13357 (btpy_list_item): Use new helper functions.
13358 (recpy_bt_function_call_history): Use new type name.
13359 (btpy_call_getset): Remove.
13360 (gdbpy_initialize_btrace): Remove code to initialize
13361 gdb.BtraceFunctionCall.
13362 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
13363 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
13364 recpy_bt_func_prev, recpy_bt_func_next): New export.
13365 * python/py-record.c (recpy_func_type): New static object.
13366 (recpy_func_new, recpy_func_level, recpy_func_symbol,
13367 recpy_func_instructions, recpy_func_up, recpy_func_prev,
13368 recpy_func_next): New function.
13369 (recpy_element_hash, recpy_element_richcompare): Updated comment.
13370 (recpy_func_getset): New static object.
13371 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
13372 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
13373
0ed5da75
TW
133742017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13375
13376 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
13377 (btpy_object, btpy_insn_type, btpy_new): Remove.
13378 (btpy_list_object): Use gdb.RecordInstruction type instead of
13379 gdb.BtraceInstruction type.
13380 (btrace_insn_from_recpy_insn): New function.
13381 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
13382 btpy_new.
13383 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
13384 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
13385 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
13386 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
13387 instead of btpy_object.
13388 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13389 btpy_insn_data, btpy_insn_decode): Rename to ...
13390 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
13391 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
13392 recpy_bt_insn_decode): This. Also, use new helper functions.
13393 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
13394 recpy_insn_type.
13395 (btpy_insn_getset): Remove.
13396 (gdbpy_initialize_btrace): Remove code to initialize
13397 gdb.BtraceInstruction. Use recpy_element_object.
13398 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
13399 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
13400 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
13401 * python/py-record.c (recpy_insn_type): New static object.
13402 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
13403 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
13404 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
13405 New function.
13406 (recpy_insn_getset): New static object.
13407 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
13408 * python/py-record.h (recpy_element_object): New typedef.
13409 (recpy_insn_type, recpy_insn_new): New export.
13410
913aeadd
TW
134112017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13412
13413 * py-record-btrace.c (btpy_insn_new): Removed.
13414 (btpy_insn_or_gap_new): New function.
13415 (btpy_insn_error): Removed.
13416 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
13417 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
13418 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
13419 btpy_insn_or_gap_new instead of btpy_insn_new.
13420 (btpy_insn_getset): Remove btpy_insn_error.
13421 * py-record.c (recpy_gap_type): New static object.
13422 (recpy_gap_object): New typedef.
13423 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
13424 recpy_gap_reason_string): New function.
13425 (recpy_gap_getset): New static object.
13426 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
13427 * py-record.h (recpy_gap_new): New export.
13428
a3be24ad
TW
134292017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13430
13431 * python/py-record.c (recpy_ptid): Remove.
13432 (recpy_record_getset): Remove recpy_ptid.
13433
ae20e79a
TW
134342017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13435
13436 * btrace.c (btrace_fetch): Set inferior_ptid.
13437 * python/py-record-btrace.c: Add "py-record.h" include.
13438 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
13439 recpy_bt_end, recpy_bt_instruction_history,
13440 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
13441 in gdb.Record object instead of current ptid.
13442 * python/py-record.c: Include new "py-record.h" file.
13443 (recpy_record_object): Moved to py-record.h.
13444 * python/py-record.h: New file.
13445
8d0050ea
TW
134462017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
13447
13448 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
13449 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
13450 indentation.
13451
3f380b50
JB
134522017-05-01 Joel Brobecker <brobecker@adacore.com>
13453
13454 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
13455 the past maintainers section.
13456
07495424
YQ
134572017-04-28 Yao Qi <yao.qi@linaro.org>
13458
13459 * infcmd.c (get_return_value): Use regcache ctor, and remove
13460 cleanup.
13461
deb1fa3e
YQ
134622017-04-28 Yao Qi <yao.qi@linaro.org>
13463 Pedro Alves <palves@redhat.com>
13464
13465 * regcache.c (regcache::regcache): New tag dispatch ctor.
13466 (do_cooked_read): Moved above.
13467 (regcache_dup): Use the tag dispatch ctor..
13468 * regcache.h (regcache): Declare ctor, delete copy ctor and
13469 assignment operator, remove friend regcache_dup.
13470
b421c83c
YQ
134712017-04-28 Yao Qi <yao.qi@linaro.org>
13472
13473 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
13474 call method save instead of regcache_cpy.
13475 * regcache.h (struct regcache): Make regcache_dup a friend.
13476
ef79d9a3
YQ
134772017-04-28 Yao Qi <yao.qi@linaro.org>
13478
13479 * regcache.c (struct regcache): Move to regcache.h
13480 (regcache::arch): New method.
13481 (regcache_get_ptid): Update.
13482 (get_regcache_arch): Call arch method.
13483 (get_regcache_aspace): Call method aspace.
13484 (register_buffer): Change it to method.
13485 (regcache_save): Change it to regcache::save.
13486 (regcache_restore): Likewise.
13487 (regcache_cpy_no_passthrough): Remove the declaration.
13488 (regcache_cpy): Call methods restore and cpy_no_passthrough.
13489 (regcache_cpy_no_passthrough): Change it to method
13490 cpy_no_passthrough.
13491 (regcache_register_status): Change it to method
13492 get_register_status.
13493 (regcache_invalidate): Change it to method invalidate.
13494 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
13495 (regcache_raw_update): Change it to method raw_update.
13496 (regcache_raw_read): Likewise.
13497 (regcache_raw_read_signed): Likewise.
13498 (regcache_raw_read_unsigned): Likewise.
13499 (regcache_raw_write_signed): Likewise.
13500 (regcache_raw_write_unsigned): Likewise.
13501 (regcache_cooked_read): Likewise.
13502 (regcache_cooked_read_value): Likewise.
13503 (regcache_cooked_read_signed): Likewise.
13504 (regcache_cooked_read_unsigned): Likewise.
13505 (regcache_cooked_write_signed): Likewise.
13506 (regcache_cooked_write_unsigned): Likewise.
13507 (regcache_raw_set_cached_value): Likewise.
13508 (regcache_raw_write): Likewise.
13509 (regcache_cooked_write): Likewise.
13510 (regcache_xfer_part): Likewise.
13511 (regcache_raw_read_part): Likewise.
13512 (regcache_raw_write_part): Likewise.
13513 (regcache_cooked_read_part): Likewise.
13514 (regcache_cooked_write_part): Likewise.
13515 (regcache_raw_supply): Likewise.
13516 (regcache_raw_collect): Likewise.
13517 (regcache_transfer_regset): Likewise.
13518 (regcache_supply_regset): Likewise.
13519 (regcache_collect_regset): Likewise.
13520 (regcache_debug_print_register): Likewise.
13521 (enum regcache_dump_what): Move it to regcache.h.
13522 (regcache_dump): Change it to method dump.
13523 * regcache.h (enum regcache_dump_what): New.
13524 (class regcache): New.
13525 * target.c (target_fetch_registers): Call method
13526 debug_print_register.
13527 (target_store_registers): Likewise.
13528
f8fdb78e
SM
135292017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13530
13531 * windows-nat.c (struct lm_info_windows): Initialize field.
13532 (windows_make_so): Allocate lm_info_windows with new.
13533 (windows_free_so): Free lm_info_windows with delete.
13534
9ccbfd7b
SM
135352017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13536
13537 * solib-darwin.c (struct lm_info_darwin): Initialize field.
13538 (darwin_current_sos): Allocate lm_info_darwin with new, remove
13539 cleanup.
13540 (darwin_free_so): Free lm_info_darwin with delete.
13541
76e75227
SM
135422017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13543
13544 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
13545 <l_addr_p>: Change type to bool.
13546 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
13547 (svr4_free_so): Free lm_info_svr4 with delete.
13548 (svr4_copy_library_list): Replace memcpy with call to copy
13549 constructor.
13550 (library_list_start_library, svr4_default_sos): Allocate
13551 lm_info_svr4 with new.
13552
51046d9e
SM
135532017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13554
13555 * solib-target.c (struct lm_info_target): Add destructor,
13556 initialize fields.
13557 <name>: Change type to std::string.
13558 (library_list_start_library): Allocate lm_info_target with new.
13559 (solib_target_free_library_list): Free lm_info_target with
13560 delete.
13561 (solib_target_current_sos): Adapt to std::string.
13562 (solib_target_free_so): Free lm_info_target with delete.
13563
4023ae76
SM
135642017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13565
13566 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
13567 fields.
13568 (frv_current_sos): Allocate lm_info_frv with new.
13569 (frv_relocate_main_executable): Free lm_info_frv with delete,
13570 allocate with new.
13571 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
13572
af43057b
SM
135732017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13574
13575 * solib-frv.c (struct lm_info_frv): Fix indentation.
13576
b0911207
SM
135772017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13578
13579 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
13580 map field.
13581 (dsbt_current_sos): Allocate lm_info_dsbt with new.
13582 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
13583 and allocate with new.
13584 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
13585
6c401f72
SM
135862017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13587
13588 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
13589 <filename, member_name>: Change type to std::string.
13590 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
13591 (library_list_start_library): Allocate lm_info_aix with new.
13592 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
13593 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
13594 with copy constructor.
13595
d0e449a1
SM
135962017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13597
13598 * solist.h (struct lm_info): Remove.
13599 (struct lm_info_base): New class.
13600 (struct so_list) <lm_info>: Change type to lm_info_base *.
13601 * nto-tdep.c (struct lm_info): Remove.
13602 (lm_addr): Adjust.
13603 * solib-aix.c (struct lm_info): Rename to ...
13604 (struct lm_info_aix): ... this. Extend lm_info_base.
13605 (lm_info_p): Rename to ...
13606 (lm_info_aix_p): ... this, and adjust.
13607 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
13608 solib_aix_parse_libraries, library_list_start_library,
13609 solib_aix_free_library_list, solib_aix_parse_libraries,
13610 solib_aix_get_library_list,
13611 solib_aix_relocate_section_addresses, solib_aix_free_so,
13612 solib_aix_get_section_offsets,
13613 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
13614 Adjust.
13615 (struct solib_aix_inferior_data) <library_list>: Adjust.
13616 * solib-darwin.c (struct lm_info): Rename to ...
13617 (struct lm_info_darwin): ... this. Extend lm_info_base.
13618 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
13619 * solib-dsbt.c (struct lm_info): Rename to ...
13620 (struct lm_info_dsbt): ... this. Extend lm_info_base.
13621 (struct dsbt_info) <main_executable_lm_info): Adjust.
13622 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
13623 dsbt_relocate_section_addresses): Adjust.
13624 * solib-frv.c (struct lm_info): Rename to ...
13625 (struct lm_info_frv): ... this. Extend lm_info_base.
13626 (main_executable_lm_info): Adjust.
13627 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
13628 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
13629 find_canonical_descriptor_in_load_object,
13630 frv_fdpic_find_canonical_descriptor): Adjust.
13631 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
13632 to lm_info_svr4.
13633 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
13634 svr4_clear_so, svr4_copy_library_list,
13635 library_list_start_library, svr4_default_sos, svr4_read_so_list,
13636 svr4_current_sos, svr4_fetch_objfile_link_map,
13637 solist_update_incremental): Adjust.
13638 * solib-svr4.h (struct lm_info_svr4): Move here from
13639 solib-svr4.c.
13640 * solib-target.c (struct lm_info): Rename to ...
13641 (struct lm_info_target): ... this. Extend lm_info_base.
13642 (lm_info_p): Rename to ...
13643 (lm_info_target_p): ... this.
13644 (solib_target_parse_libraries, library_list_start_segment,
13645 library_list_start_section, library_list_start_library,
13646 library_list_end_library, solib_target_free_library_list,
13647 solib_target_current_sos, solib_target_free_so,
13648 solib_target_relocate_section_addresses): Adjust.
13649 * windows-nat.c (struct lm_info): Rename to ...
13650 (struct lm_info_windows): ... this. Extend lm_info_base.
13651 (windows_make_so, handle_load_dll, handle_unload_dll,
13652 windows_xfer_shared_libraries): Adjust.
13653
434a4023
SM
136542017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13655
13656 * solib-darwin.c (struct darwin_so_list): Remove.
13657 (darwin_current_sos): Allocate an so_list object instead of a
13658 darwin_so_list, separately allocate an lm_info object.
13659 (darwin_free_so): Free lm_info.
13660
428544e8
JB
136612017-04-28 John Baldwin <jhb@FreeBSD.org>
13662
13663 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13664 with fprintf_filtered.
13665
4621115f
YQ
136662017-04-28 Yao Qi <yao.qi@linaro.org>
13667
13668 * regcache.c (regcache::regcache): New function.
13669 (regcache::~regcache): New function.
13670 (regcache_xmalloc_1): Remove.
13671 (regcache_xmalloc): Call new regcache.
13672 (regcache_xfree): Call delete regcache.
13673 (get_thread_arch_aspace_regcache): Call new regcache.
13674
339053c2
YQ
136752017-04-28 Yao Qi <yao.qi@linaro.org>
13676
13677 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13678 lwp instead of ptid_get_lwp.
13679
7974a605
YQ
136802017-04-28 Yao Qi <yao.qi@linaro.org>
13681
13682 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13683 lwp_info instead of getting from inferior_ptid.
13684
e15c3eb4
KS
136852017-04-27 Keith Seitz <keiths@redhat.com>
13686
13687 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13688 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13689 (CV_CONVERSION_BADNESS): Define.
13690 (rank_one_type): Remove overly restrictive rvalue reference
13691 rank checks.
13692 Add cv-qualifier checks and subranks for type equality.
13693 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13694 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13695 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13696
72bc1d24
SM
136972017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13698
13699 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13700 count when creating the object.
13701
55bcecda
UW
137022017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13703 Ulrich Weigand <uweigand@de.ibm.com>
13704
13705 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13706 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13707 is used in AIX.
13708 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13709 (process_xcoff_symbol): Likewise.
13710 (scan_xcoff_symtab): Likewise.
13711
5c99fcf8
AH
137122017-04-26 Alan Hayward <alan.hayward@arm.com>
13713
13714 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13715 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13716 (ia64_access_reg): Use get_frame_register_unsigned.
13717 (ia64_access_rse_reg): Likewise.
13718 (ia64_libunwind_frame_prev_register): Likewise.
13719
b41c5a85
JW
137202017-04-26 Jiong Wang <jiong.wang@arm.com>
13721
13722 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13723 * gdbarch.c: Regenerated.
13724 * gdbarch.h: Regenerated.
13725 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13726 visibility external.
13727 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13728 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13729 (enum cfa_how_kind): Move to ...
13730 (struct dwarf2_frame_state_reg_info): Likewise.
13731 (struct dwarf2_frame_state): Likewise.
13732 * dwarf2-frame.h: ... here.
13733 (dwarf2_frame_state_alloc_regs): New declaration.
13734 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13735 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13736
c185f580
AH
137372017-04-26 Alan Hayward <alan.hayward@arm.com>
13738
13739 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13740 regcache_raw_read_unsigned.
13741 (xtensa_pseudo_register_write): Likewise.
13742
19c45594
AH
137432017-04-26 Alan Hayward <alan.hayward@arm.com>
13744
13745 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13746 (nds32_pseudo_register_write): Likewise.
13747
4658f12e
YQ
137482017-04-25 Yao Qi <yao.qi@linaro.org>
13749
13750 * regcache.c (struct regcache) <readonly_p>: Change its type
13751 to bool.
13752 (regcache_xmalloc_1): Update parameter type and callers update.
13753
d581dda8
YQ
137542017-04-25 Yao Qi <yao.qi@linaro.org>
13755
13756 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13757 set_gdbarch_wchar_bit.
13758 * arm-tdep.c (arm_gdbarch_init): Likewise.
13759
debed3db
PA
137602017-04-25 Pedro Alves <palves@redhat.com>
13761
13762 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13763 (BothAreRelocatable, memcopy, memmove): Don't define.
13764 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13765 macros.
13766
b0b92aeb
PA
137672017-04-25 Pedro Alves <palves@redhat.com>
13768
13769 * common/common-defs.h: Include "common/poison.h".
13770 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13771 and adjust.
13772 * common/poison.h: New file.
13773 * common/traits.h: Include <type_traits>.
13774 (Not, Or, Requires): New, moved from common/function-view.h.
13775
16c4d54a
PA
137762017-04-25 Pedro Alves <palves@redhat.com>
13777
13778 * breakpoint.h (struct breakpoint): In-class initialize all
13779 fields. Make boolean fields "bool".
13780 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13781 memset call and initializations no longer necessary.
13782
b5c36682
PA
137832017-04-25 Pedro Alves <palves@redhat.com>
13784
13785 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13786 reference.
13787 (pt_btrace_insn): New function.
13788 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13789
5625a286
PA
137902017-04-25 Pedro Alves <palves@redhat.com>
13791
13792 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13793 "base" field and inherit from "bp_location" instead. Add
13794 non-default ctor.
13795 (allocate_location_exception): Use new non-default ctor.
13796 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13797 (init_bp_location): Convert to ...
13798 (bp_location::bp_location): ... this new ctor, and remove memset
13799 call.
13800 (base_breakpoint_allocate_location): Use the new non-default ctor.
13801 * breakpoint.h (bp_location): Now a class. Declare default and
13802 non-default ctors. In-class initialize all members.
13803 (init_bp_location): Remove declaration.
13804
23bcc18f
PA
138052017-04-25 Pedro Alves <palves@redhat.com>
13806
13807 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13808 assignment operator.
13809
e1ba3053
YQ
138102017-04-24 Yao Qi <yao.qi@linaro.org>
13811
13812 * doublest.c (convert_doublest_to_floatformat): Call
13813 floatformat_totalsize_bytes.
13814
10f489e5
TT
138152017-04-22 Tom Tromey <tom@tromey.com>
13816
13817 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13818 ui_out_emit_list.
13819 * stack.c (print_frame): Use ui_out_emit_list.
13820 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13821 ui_out_emit_list.
13822 * mi/mi-main.c (print_one_inferior)
13823 (mi_cmd_data_list_register_names)
13824 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13825 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13826 ui_out_emit_list.
13827 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13828 (mi_output_solib_attribs): Use ui_out_emit_list,
13829 ui_out_emit_tuple.
13830 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13831 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13832 (mi_cmd_stack_list_args, list_args_or_locals): Use
13833 ui_out_emit_list.
13834 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13835 * breakpoint.c (print_solib_event, output_thread_groups): Use
13836 ui_out_emit_list.
13837
0092b74d
TT
138382017-04-22 Tom Tromey <tom@tromey.com>
13839
13840 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13841 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13842 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13843
a14a62dd
TT
138442017-04-22 Tom Tromey <tom@tromey.com>
13845
13846 * tracepoint.c (tvariables_info_1)
13847 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13848
46b9c129
TT
138492017-04-22 Tom Tromey <tom@tromey.com>
13850
13851 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13852 annotate_arg_emitter.
13853 * breakpoint.c (print_mention_watchpoint)
13854 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13855 * annotate.h (struct annotate_arg_emitter): New.
13856
2e783024
TT
138572017-04-22 Tom Tromey <tom@tromey.com>
13858
13859 * record-btrace.c (record_btrace_insn_history)
13860 (record_btrace_insn_history_range, record_btrace_call_history)
13861 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13862 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13863 ui_out_emit_tuple.
13864 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13865 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13866 * skip.c (skip_info): Use ui_out_emit_tuple.
13867 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13868 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13869 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13870 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13871 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13872 ui_out_emit_tuple.
13873 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13874 (output_register, mi_cmd_data_read_memory)
13875 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13876 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13877 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13878 Use ui_out_emit_tuple.
13879 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13880 ui_out_emit_tuple.
13881 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13882 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13883 * linux-thread-db.c (info_auto_load_libthread_db): Use
13884 ui_out_emit_tuple.
13885 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13886 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13887 * disasm.c (do_mixed_source_and_assembly_deprecated)
13888 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13889 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13890 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13891 * breakpoint.c (print_one_breakpoint_location)
13892 (print_one_breakpoint): Use ui_out_emit_tuple.
13893 * auto-load.c (print_script, info_auto_load_cmd): Use
13894 ui_out_emit_tuple.
13895 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13896
9be21bb4
SM
138972017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13898
13899 * thread.c (print_thread_info_1): Remove dead code.
13900
0d4c07af
JK
139012017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13902
13903 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13904 GDB_SELF_TEST.
13905 * arm-tdep.c (selftests::arm_record_test): Likewise.
13906
4daf993d
YQ
139072017-04-21 Yao Qi <yao.qi@linaro.org>
13908
13909 * regcache.c (regcache_restore): Remove argument 2. Replace
13910 argument 3 with regcache. Get register status from
13911 src->register_status and get register contents from
13912 register_buffer (src, regnum).
13913 (regcache_cpy): Update.
13914
a6c21d4a
PA
139152017-04-19 Pedro Alves <palves@redhat.com>
13916
13917 * gdbthread.h (thread): Add missing closing parenthesis in
13918 comment.
13919
3a3fd0fd
PA
139202017-04-19 Pedro Alves <palves@redhat.com>
13921
13922 * common/refcounted-object.h: New file.
13923 * gdbthread.h: Include "common/refcounted-object.h".
13924 (thread_info): Inherit from refcounted_object and add comments.
13925 (thread_info::incref, thread_info::decref)
13926 (thread_info::m_refcount): Delete.
13927 (thread_info::deletable): Use the refcounted_object::refcount()
13928 method.
13929 * inferior.c (current_inferior_): Add comment.
13930 (set_current_inferior): Increment/decrement refcounts.
13931 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13932 not-deletable instead of comparing with the current inferior.
13933 (initialize_inferiors): Increment the initial inferior's refcount.
13934 * inferior.h (struct inferior): Forward declare.
13935 Include "common/refcounted-object.h".
13936 (current_inferior, set_current_inferior): Move declaration to
13937 before struct inferior's definition, and fix comment.
13938 (inferior): Inherit from refcounted_object. Add comments.
13939 * thread.c (switch_to_thread_no_regs): Reference the thread's
13940 inferior pointer directly instead of doing a ptid lookup.
13941 (switch_to_no_thread): New function.
13942 (switch_to_thread(thread_info *)): New function, factored out
13943 from ...
13944 (switch_to_thread(ptid_t)): ... this.
13945 (restore_current_thread): Delete.
13946 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13947 fields, and add 'inf' field.
13948 (do_restore_current_thread_cleanup): Check whether old->inf is
13949 alive instead of looking up an inferior by ptid. Use
13950 switch_to_thread and switch_to_no_thread.
13951 (restore_current_thread_cleanup_dtor): Use old->inf directly
13952 instead of lookup up an inferior by id. Decref the inferior.
13953 Don't restore 'removable'.
13954 (make_cleanup_restore_current_thread): Same the inferior pointer
13955 in old, instead of the inferior number. Incref the inferior.
13956 Don't save/clear 'removable'.
13957
9bcb1f16
PA
139582017-04-19 Pedro Alves <palves@redhat.com>
13959
13960 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13961 unittests/scoped_restore-selftests.c.
13962 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13963 * common/scoped_restore.h (scoped_restore_base): Make "class".
13964 (scoped_restore_base::release): New public method.
13965 (scoped_restore_base::scoped_restore_base): New protected ctor.
13966 (scoped_restore_base::m_saved_var): New protected field.
13967 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13968 scoped_restore_base base class instead of m_saved_var directly.
13969 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13970 (scoped_restore_tmpl::scoped_restore_tmpl(const
13971 scoped_restore_tmpl<T>&)): Likewise.
13972 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13973 method.
13974 (scoped_restore_tmpl::saved_var): New method.
13975 (scoped_restore_tmpl::m_saved_var): Delete.
13976 * inferior.h (inferior::detaching): Now a bool.
13977 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13978 cleanup.
13979 * unittests/scoped_restore-selftests.c: New file.
13980
26fcd539
PA
139812017-04-19 Pedro Alves <palves@redhat.com>
13982
13983 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13984 Re-sort in alphabetic order.
13985
fdd243b0
PA
139862017-04-18 Pedro Alves <palves@redhat.com>
13987
13988 * xml-support.c (obstack_xml_printf): Delete.
13989 * xml-support.h (obstack_xml_printf): Delete.
13990
4895cde2
PA
139912017-04-18 Pedro Alves <palves@redhat.com>
13992
13993 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13994 vdebug, verror, body_text, start_element, end_element, name,
13995 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13996 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13997 is_xinclude>: Make private and add m_ prefix.
13998 (gdb_xml_parser::body_text): New method, based on ...
13999 (gdb_xml_body_text): ... this. Adjust.
14000 (gdb_xml_parser::vdebug): New method, based on ...
14001 (gdb_xml_debug): ... this. Adjust.
14002 (gdb_xml_parser::verror): New method, based on ...
14003 (gdb_xml_error): ... this. Adjust.
14004 (gdb_xml_parser::start_element): New method, based on ...
14005 (gdb_xml_start_element): ... this. Adjust.
14006 (gdb_xml_start_element_wrapper): Defer to
14007 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
14008 (gdb_xml_parser::end_element): New method, based on ...
14009 (gdb_xml_end_element_wrapper): ... this. Adjust.
14010 (gdb_xml_parser::~gdb_xml_parser): Adjust.
14011 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
14012 (gdb_xml_parser::use_dtd): New method, based on ...
14013 (gdb_xml_use_dtd): ... this. Adjust.
14014 (gdb_xml_parser::parse): New method, based on ...
14015 (gdb_xml_parse): ... this. Adjust.
14016 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
14017 (xinclude_start_include): Adjust to call the parser's name method.
14018 (xml_xinclude_default, xml_xinclude_start_doctype)
14019 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
14020 method.
14021 (xml_process_xincludes): Adjust to call parser methods.
14022 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
14023 declarations.
14024
bd8a901f
PA
140252017-04-18 Pedro Alves <palves@redhat.com>
14026
14027 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
14028 gdb::optional<std::string>.
14029 * xml-support.c: Include <string>.
14030 (scope_level::scope_level(scope_level &&))
14031 (scope_level::~scope_level): Delete.
14032 (scope_level::body): Now a std::string.
14033 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
14034 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
14035 parameter.
14036 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
14037 (xinclude_parsing_data::output): Now a std::string reference.
14038 (xinclude_start_include): Adjust.
14039 (xml_xinclude_default): Adjust.
14040 (xml_process_xincludes): Add 'output' parameter, and return bool.
14041 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
14042 and return bool.
14043 * xml-tdesc.c: Include <unordered_map> and <string>.
14044 (tdesc_xml_cache): Delete.
14045 (tdesc_xml_cache_s): Delete.
14046 (xml_cache): Now an std::unordered_map.
14047 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
14048 (target_fetch_description_xml): Change return type to
14049 gdb::optional<std::string>, and adjust.
14050 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
14051 (target_fetch_description_xml): Change return type to
14052 gdb::optional<std::string>.
14053
d35d1958
PA
140542017-04-18 Pedro Alves <palves@redhat.com>
14055
14056 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14057 unittests/optional-selftests.c.
14058 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
14059 * unittests/optional-selftests.c: New file.
14060 * unittests/optional/assignment/1.cc: New file.
14061 * unittests/optional/assignment/2.cc: New file.
14062 * unittests/optional/assignment/3.cc: New file.
14063 * unittests/optional/assignment/4.cc: New file.
14064 * unittests/optional/assignment/5.cc: New file.
14065 * unittests/optional/assignment/6.cc: New file.
14066 * unittests/optional/assignment/7.cc: New file.
14067 * unittests/optional/cons/copy.cc: New file.
14068 * unittests/optional/cons/default.cc: New file.
14069 * unittests/optional/cons/move.cc: New file.
14070 * unittests/optional/cons/value.cc: New file.
14071 * unittests/optional/in_place.cc: New file.
14072 * unittests/optional/observers/1.cc: New file.
14073 * unittests/optional/observers/2.cc: New file.
14074
22796e97
PA
140752017-04-18 Pedro Alves <palves@redhat.com>
14076
14077 * common/gdb_optional.h: Include common/traits.h.
14078 (in_place_t): New type.
14079 (in_place): New constexpr variable.
14080 (optional::optional): Remove member initialization of
14081 m_instantiated.
14082 (optional::optional(in_place_t...)): New constructor.
14083 (optional::~optional): Use reset.
14084 (optional::optional(const optional&)): New.
14085 (optional::optional(const optional&&)): New.
14086 (optional::optional(T &)): New.
14087 (optional::optional(T &&)): New.
14088 (operator::operator=(const optional &)): New.
14089 (operator::operator=(optional &&)): New.
14090 (operator::operator= (const T &))
14091 (operator::operator= (T &&))
14092 (operator::emplace (Args &&... args)): Return a T&. Use reset.
14093 (operator::reset): New.
14094 (operator::m_instantiated):: Add in-class initializer.
14095 * common/traits.h: Include <type_traits>.
14096 (struct And): New types.
14097
a7fc9b61
PA
140982017-04-18 Pedro Alves <palves@redhat.com>
14099
14100 * xml-support.c: Include <vector>.
14101 (scope_level::scope_level(const gdb_xml_element *))
14102 (scope_level::scope_level(scope_level&&)): New.
14103 (scope_level::~scope_level): New.
14104 (scope_level_s): Delete.
14105 (gdb_xml_parser::scopes): Now a std::vector.
14106 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
14107 Use std::vector.
14108 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
14109 scope cleanup code.
14110 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
14111 of the scopes member. Use std::vector::emplace_back.
14112
010151c9
PA
141132017-04-18 Pedro Alves <palves@redhat.com>
14114
14115 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
14116 a bool.
14117 (gdb_xml_end_element): Change type of first parameter.
14118 (gdb_xml_cleanup): Rename to ...
14119 (gdb_xml_parser::~gdb_xml_parser): ... this.
14120 (gdb_xml_create_parser_and_cleanup): Delete with ...
14121 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
14122 to this new ctor.
14123 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
14124 using gdb_xml_create_parser_and_cleanup.
14125 (xinclude_parsing_data): Add ctor/dtor.
14126 (xml_xinclude_cleanup): Delete.
14127 (xml_process_xincludes): Create a local xinclude_parsing_data
14128 instead of heap-allocating one. Create a local gdb_xml_parser
14129 instead of heap-allocating one with
14130 gdb_xml_create_parser_and_cleanup.
14131
d56060f0
JB
141322017-04-18 John Baldwin <jhb@FreeBSD.org>
14133
14134 PR threads/20743
14135 * fbsd-nat.c (resume_one_thread_cb): Remove.
14136 (resume_all_threads_cb): Remove.
14137 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
14138 iterate_over_threads.
14139
305d16a9
JB
141402017-04-17 Joel Brobecker <brobecker@adacore.com>
14141
14142 * NEWS: Create a new section for the next release branch.
14143 Rename the section of the current branch, now that it has
14144 been cut.
14145
8bb57231
JB
141462017-04-17 Joel Brobecker <brobecker@adacore.com>
14147
14148 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
14149 * version.in: Bump version to 8.0.50.DATE-git.
14150
096c92dd
SDJ
141512017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
14152
14153 PR gdb/21385
14154 * windows-nat.c (windows_create_inferior): Declare 'allargs'
14155 independently of the host, and fix build breakage on Cygwin.
14156
0550c955
PA
141572017-04-13 Pedro Alves <palves@redhat.com>
14158
14159 * inferior.c (free_inferior): Convert to ...
14160 (inferior::~inferior): ... this dtor.
14161 (inferior::inferior): New ctor, factored out from ...
14162 (add_inferior_silent): ... here. Allocate the inferior with a new
14163 expression.
14164 (delete_inferior): Call delete instead of free_inferior.
14165 * inferior.h (gdb_environ, continuation): Forward declare.
14166 (inferior): Now a class. Add in-class initialization to all
14167 members. Make boolean fields bool, except 'detaching'.
14168 (inferior::inferior): New explicit ctor.
14169 (inferior::~inferior): New.
14170
e3d60dfc
PA
141712017-04-13 Pedro Alves <palves@redhat.com>
14172
14173 * inferior.c (init_inferior_list): Delete.
14174 * inferior.h (init_inferior_list): Delete.
14175
5fd69d0a
PA
141762017-04-13 Pedro Alves <palves@redhat.com>
14177
14178 PR threads/13217
14179 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
14180 (top level): Call it twice, with different thread sets.
14181
c6609450
PA
141822017-04-13 Pedro Alves <palves@redhat.com>
14183
14184 * thread.c: Include <algorithm>.
14185 (thread_array_cleanup): Delete.
14186 (scoped_inc_dec_ref): New class.
14187 (live_threads_count): New function.
14188 (set_thread_refcount): Delete.
14189 (tp_array_compar_ascending): Now a bool.
14190 (tp_array_compar): Convert to a std::sort comparison function.
14191 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
14192 and live_threads_count.
14193
2a00d7ce
PA
141942017-04-13 Pedro Alves <palves@redhat.com>
14195
14196 * infrun.c (follow_fork_inferior): Also switch the current
14197 inferior.
14198
441d7c93
PA
141992017-04-13 Pedro Alves <palves@redhat.com>
14200
14201 * breakpoint.c (watch_command_1): Save watchpoint-frame info
14202 before calling create_internal_breakpoint.
14203
808480f6
PA
142042017-04-13 Pedro Alves <palves@redhat.com>
14205
14206 * fork-child.c (execv_argv): New class.
14207 (breakup_args): Refactored as ...
14208 (execv_argv::init_for_no_shell): .. this method of execv_argv.
14209 Copy arguments to storage and replace separators with NULL
14210 terminators in place.
14211 (escape_bang_in_quoted_argument): Adjust to return bool.
14212 (execv_argv::execv_argv): New ctor.
14213 (execv_argv::init_for_shell): New method, factored out from
14214 fork_inferior. Don't strdup strings into the vector.
14215 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
14216 Remove free_vector_argv call.
14217
ad3d022a
YQ
142182017-04-13 Yao Qi <yao.qi@linaro.org>
14219
14220 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
14221 tdep->rx_psw_type.
14222
e6ddc3bf
YQ
142232017-04-13 Yao Qi <yao.qi@linaro.org>
14224
14225 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
14226 * rx-tdep.c (rx_gdbarch_init): Likewise.
14227
bfb8cf90
PA
142282017-04-13 Pedro Alves <palves@redhat.com>
14229
14230 * breakpoint.h (struct breakpoint): Reindent.
14231
f5336ca5
PA
142322017-04-13 Pedro Alves <palves@redhat.com>
14233
14234 * breakpoint.c (bp_location): Rename to ...
14235 (bp_locations): ... this. All references updated.
14236 (bp_location_count): Rename to ...
14237 (bp_locations_count): ... this. All references updated.
14238 (bp_location_placed_address_before_address_max): Rename to ...
14239 (bp_locations_placed_address_before_address_max): ... this. All
14240 references updated.
14241 (bp_location_shadow_len_after_address_max): Rename to ...
14242 (bp_locations_shadow_len_after_address_max): ... this. All
14243 references updated.
14244 (bp_location_compare_addrs): Rename to ...
14245 (bp_locations_compare_addrs): ... this. All references updated.
14246 (bp_location_compare):Rename to ...
14247 (bp_locations_compare): ... this. All references updated.
14248 (bp_location_target_extensions_update): Rename to ...
14249 (bp_locations_target_extensions_update): ... this. All references
14250 updated.
14251
be628ab8
SDJ
142522017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14253
14254 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
14255 * common/common.m4: Check headers 'termios.h', 'termio.h' and
14256 'sgtty.h'.
14257 * common/gdb_termios.h: New file, with parts of "terminal.h".
14258 * inflow.c: Include "gdb_termios.h".
14259 * ser-unix.c: Include "gdb_termios.h".
14260 * terminal.h: Move terminal-related defines to
14261 "common/gdb_termios.h".
14262
8e9e35b1
TT
142632017-04-12 Tom Tromey <tom@tromey.com>
14264
14265 * probe.c (parse_probes): Update.
14266 * location.h (delete_event_location): Don't declare.
14267 (event_location_deleter::operator()): Update.
14268 * location.c (event_location_deleter::operator()): Rename from
14269 delete_event_location.
14270 * linespec.h (linespec_result) <location>: Change type to
14271 event_location_up.
14272 * linespec.c (canonicalize_linespec, event_location_to_sals)
14273 (decode_objc): Update.
14274 (linespec_result): Don't call delete_event_location.
14275 * breakpoint.c (create_breakpoints_sal)
14276 (bkpt_probe_create_sals_from_location)
14277 (strace_marker_create_sals_from_location): Update.
14278
16e802b9
TT
142792017-04-12 Tom Tromey <tom@tromey.com>
14280
14281 * linespec.h (struct linespec_result): Add constructor and
14282 destructor.
14283 (init_linespec_result, destroy_linespec_result)
14284 (make_cleanup_destroy_linespec_result): Don't declare.
14285 * linespec.c (init_linespec_result): Remove.
14286 (linespec_result::~linespec_result): Rename from
14287 destroy_linespec_result. Update.
14288 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
14289 Remove.
14290 * breakpoint.c (create_breakpoint, break_range_command)
14291 (decode_location_default): Update.
14292 * ax-gdb.c (agent_command_1): Update.
14293
d28cd78a
TT
142942017-04-12 Tom Tromey <tom@tromey.com>
14295
14296 * remote.c (remote_download_tracepoint): Update.
14297 * python/py-breakpoint.c (bppy_get_location): Update.
14298 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
14299 (gdbscm_breakpoint_location): Update.
14300 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
14301 * breakpoint.h (struct breakpoint) <location, location_range_end>:
14302 Change type to event_location_up.
14303 * breakpoint.c (create_overlay_event_breakpoint)
14304 (create_longjmp_master_breakpoint)
14305 (create_std_terminate_master_breakpoint)
14306 (create_exception_master_breakpoint)
14307 (breakpoint_event_location_empty_p, print_breakpoint_location)
14308 (print_one_breakpoint_location, create_thread_event_breakpoint)
14309 (init_breakpoint_sal, create_breakpoint)
14310 (print_recreate_ranged_breakpoint, break_range_command)
14311 (init_ada_exception_breakpoint, say_where): Update.
14312 (base_breakpoint_dtor): Don't call delete_event_location.
14313 (bkpt_print_recreate, tracepoint_print_recreate)
14314 (dprintf_print_recreate, update_static_tracepoint)
14315 (breakpoint_re_set_default): Update.
14316
711799d5
TT
143172017-04-12 Tom Tromey <tom@tromey.com>
14318
14319 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
14320 type of "to_do". Update.
14321 (compute_stack_depth): Use std::vector.
14322
52d214d3
TT
143232017-04-12 Tom Tromey <tom@tromey.com>
14324
14325 * printcmd.c (find_instruction_backward): Use std::vector.
14326
4c404b8b
TT
143272017-04-12 Tom Tromey <tom@tromey.com>
14328
14329 * symfile.c (objfilep): Remove typedef.
14330 (reread_symbols): Use a std::vector.
14331
156d9eab
TT
143322017-04-12 Tom Tromey <tom@tromey.com>
14333
14334 * mi/mi-main.c (exec_direction_forward): Remove.
14335 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
14336 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
14337 scoped_restore.
14338 * guile/guile.c (guile_repl_command, guile_command)
14339 (gdbscm_execute_gdb_command): Use scoped_restore.
14340 * go-exp.y (go_parse): Use scoped_restore.
14341 * d-exp.y (d_parse): Use scoped_restore.
14342 * cli/cli-decode.c (cmd_func): Use scoped_restore.
14343 * c-exp.y (c_parse): Use scoped_restore.
14344
4d89769a
TT
143452017-04-12 Tom Tromey <tom@tromey.com>
14346
14347 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
14348 (mi_parse): Update return type.
14349 (mi_parse_free): Remove.
14350 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
14351 (mi_parse::~mi_parse): Rename from mi_parse_free.
14352 (mi_parse_cleanup): Remove.
14353 (mi_parse): Return a unique_ptr. Use new.
14354 * mi/mi-main.c (mi_execute_command): Update.
14355
4b217cc7
TT
143562017-04-12 Tom Tromey <tom@tromey.com>
14357
14358 * location.c (explicit_location_lex_one): Return a
14359 unique_xmalloc_ptr.
14360 (string_to_explicit_location): Update. Remove cleanups.
14361
59d3651b
TT
143622017-04-12 Tom Tromey <tom@tromey.com>
14363
14364 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
14365 (compare_value_and_voffset): Change type. Update.
14366 (compute_vtable_size): Change type of "offset_vec".
14367 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
14368 (gnuv3_get_typeid): Remove extraneous declaration.
14369
b24b0d6c
TT
143702017-04-12 Tom Tromey <tom@tromey.com>
14371
14372 * charset.h (wchar_iterator): Fix comment.
14373
80a3b8c5
TT
143742017-04-12 Tom Tromey <tom@tromey.com>
14375
14376 * charset.c (iconv_wrapper): New class.
14377 (cleanup_iconv): Remove.
14378 (convert_between_encodings): Use it.
14379
c83dd867
TT
143802017-04-12 Tom Tromey <tom@tromey.com>
14381
14382 * symfile.h (increment_reading_symtab): Update type.
14383 * symfile.c (decrement_reading_symtab): Remove.
14384 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
14385 * psymtab.c (psymtab_to_symtab): Update.
14386 * dwarf2read.c (dw2_instantiate_symtab): Update.
14387
0e8621a0
TT
143882017-04-12 Tom Tromey <tom@tromey.com>
14389
14390 * jit.c (struct jit_reader): Declare separately. Add constructor
14391 and destructor. Change type of "handle".
14392 (loaded_jit_reader): Define separately.
14393 (jit_reader_load): Update. New "new".
14394 (jit_reader_unload_command): Use "delete".
14395 * gdb-dlfcn.h (struct dlclose_deleter): New.
14396 (gdb_dlhandle_up): New typedef.
14397 (gdb_dlopen, gdb_dlsym): Update types.
14398 (gdb_dlclose): Remove.
14399 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
14400 (gdb_dlsym): Change type of "handle".
14401 (make_cleanup_dlclose): Remove.
14402 (dlclose_deleter::operator()): Rename from gdb_dlclose.
14403 * compile/compile-c-support.c (load_libcc): Update.
14404
67d89901
TT
144052017-04-12 Tom Tromey <tom@tromey.com>
14406
14407 * symtab.h (find_pcs_for_symtab_line): Change return type.
14408 * symtab.c (find_pcs_for_symtab_line): Change return type.
14409 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
14410 type of "vec". Update.
14411 (ltpy_get_pcs_for_line): Update.
14412 * linespec.c (decode_digits_ordinary): Update.
14413
93921405
TT
144142017-04-12 Tom Tromey <tom@tromey.com>
14415
14416 * tracepoint.c (actions_command): Update.
14417 * python/python.c (python_command, python_interactive_command):
14418 Update.
14419 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
14420 * guile/guile.c (guile_command): Update.
14421 * defs.h (read_command_lines, read_command_lines_1): Return
14422 command_line_up.
14423 (command_lines_deleter): New struct.
14424 (command_line_up): New typedef.
14425 * compile/compile.c (compile_code_command)
14426 (compile_print_command): Update.
14427 * cli/cli-script.h (get_command_line, copy_command_lines): Return
14428 command_line_up.
14429 (make_cleanup_free_command_lines): Remove.
14430 * cli/cli-script.c (get_command_line, read_command_lines_1)
14431 (copy_command_lines): Return command_line_up.
14432 (while_command, if_command, read_command_lines, define_command)
14433 (document_command): Update.
14434 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
14435 Remove.
14436 * breakpoint.h (breakpoint_set_commands): Change type of
14437 "commands".
14438 * breakpoint.c (breakpoint_set_commands): Change type of
14439 "commands". Update.
14440 (do_map_commands_command, update_dprintf_command_list)
14441 (create_tracepoint_from_upload): Update.
14442
ffc2605c
TT
144432017-04-12 Tom Tromey <tom@tromey.com>
14444
14445 * tracepoint.c (scope_info): Update.
14446 * spu-tdep.c (spu_catch_start): Update.
14447 * python/python.c (gdbpy_decode_line): Update.
14448 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
14449 * python/py-breakpoint.c (bppy_init): Update.
14450 * probe.c (parse_probes): Update.
14451 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
14452 * location.h (event_location_deleter): New struct.
14453 (event_location_up): New typedef.
14454 (new_linespec_location, new_address_location, new_probe_location)
14455 (new_explicit_location, copy_event_location)
14456 (string_to_event_location, string_to_event_location_basic)
14457 (string_to_explicit_location): Update return type.
14458 (make_cleanup_delete_event_location): Remove.
14459 * location.c (new_linespec_location, new_address_location)
14460 (new_probe_location, new_explicit_location, copy_event_location):
14461 Return event_location_up.
14462 (delete_event_location_cleanup)
14463 (make_cleanup_delete_event_location): Remove.
14464 (string_to_explicit_location, string_to_event_location_basic)
14465 (string_to_event_location): Return event_location_up.
14466 * linespec.c (canonicalize_linespec, event_location_to_sals)
14467 (decode_line_with_current_source)
14468 (decode_line_with_last_displayed, decode_objc): Update.
14469 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
14470 * completer.c (location_completer): Update.
14471 * cli/cli-cmds.c (edit_command, list_command): Update.
14472 * breakpoint.c (create_overlay_event_breakpoint)
14473 (create_longjmp_master_breakpoint)
14474 (create_std_terminate_master_breakpoint)
14475 (create_exception_master_breakpoint)
14476 (create_thread_event_breakpoint): Update.
14477 (init_breakpoint_sal): Update. Remove some dead code.
14478 (create_breakpoint_sal): Change type of "location". Update.
14479 (create_breakpoints_sal, create_breakpoint, break_command_1)
14480 (dprintf_command, break_range_command, until_break_command)
14481 (init_ada_exception_breakpoint)
14482 (strace_marker_create_sals_from_location)
14483 (update_static_tracepoint, trace_command, ftrace_command)
14484 (strace_command, create_tracepoint_from_upload): Update.
14485 * break-catch-throw.c (re_set_exception_catchpoint): Update.
14486 * ax-gdb.c (agent_command_1): Update.
14487
8f10c932
PA
144882017-04-12 Pedro Alves <palves@redhat.com>
14489
14490 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
14491 * configure.tgt: Handle i[34567]86-*-go32* and
14492 i[34567]86-*-msdosdjgpp*.
14493 * i386-tdep.c (i386_svr4_reg_to_regnum):
14494 Make extern.
14495 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
14496 i386-go32-tdep.c.
14497 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
14498 * i386-go32-tdep.c: New file.
14499 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
14500 declarations.
14501
0a31ccfb
SM
145022017-04-12 Simon Marchi <simon.marchi@ericsson.com>
14503
14504 * aix-thread.c (pd_status2str): Change return type to const char *.
14505
e9bb3fbb
PA
145062017-04-12 Pedro Alves <palves@redhat.com>
14507
14508 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
14509 calls to set_gdbarch_gnu_triplet_regexp.
14510
53375380
PA
145112017-04-12 Pedro Alves <palves@redhat.com>
14512
14513 PR gdb/21323
14514 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
14515 New enum value.
14516 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
14517 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
14518 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
14519 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
14520 * gdbarch.h, gdbarch.c: Regenerate.
14521 * aarch64-tdep.c (aarch64_gdbarch_init): Override
14522 gdbarch_wchar_bit and gdbarch_wchar_signed.
14523 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
14524 * arm-tdep.c (arm_gdbarch_init): Likewise.
14525 * avr-tdep.c (avr_gdbarch_init): Likewise.
14526 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
14527 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
14528 * i386-tdep.c (i386_go32_init_abi): Likewise.
14529 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
14530 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
14531 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
14532 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
14533 * sh-tdep.c (sh_gdbarch_init): Likewise.
14534 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
14535 * sparc64-tdep.c (sparc64_init_abi): Likewise.
14536 * windows-tdep.c (windows_init_abi): Likewise.
14537 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
14538
53e710ac
PA
145392017-04-12 Pedro Alves <palves@redhat.com>
14540
14541 PR c++/21323
14542 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
14543 cplus_primitive_type_char32_t>: New enum values.
14544 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
14545 and cplus_primitive_type_char32_t.
14546 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
14547 32, use the archtecture's built-in type for char16_t and char32_t,
14548 respectively. Otherwise, fallback to init_integer_type as before,
14549 but make the type unsigned, and issue a complaint.
14550 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
14551
ab0538b8
AH
145522017-04-12 Alan Hayward <alan.hayward@arm.com>
14553
5e0e0422 14554 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
14555 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
14556
5430098f
SDJ
145572017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14558
14559 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
14560 'const char *'.
14561
7c5ded6a
SDJ
145622017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14563
14564 * common/common-utils.c (free_vector_argv): New function.
14565 * common/common-utils.h: Include <vector>.
14566 (free_vector_argv): New prototype.
14567 * darwin-nat.c (darwin_create_inferior): Rewrite function
14568 prototype in order to constify "exec_file" and accept a
14569 "std::string" for "allargs".
14570 * fork-child.c: Include <vector>.
14571 (breakup_args): Rewrite function, using C++.
14572 (fork_inferior): Rewrite function header, constify "exec_file_arg"
14573 and accept "std::string" for "allargs". Update the code to
14574 calculate "argv" based on "allargs". Update calls to "exec_fun"
14575 and "execvp".
14576 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
14577 order to constify "exec_file" and accept a "std::string" for
14578 "allargs".
14579 * go32-nat.c (go32_create_inferior): Likewise.
14580 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
14581 * infcmd.c (run_command_1): Constify "exec_file". Use
14582 "std::string" for inferior arguments.
14583 * inferior.h (fork_inferior): Update prototype.
14584 * linux-nat.c (linux_nat_create_inferior): Rewrite function
14585 prototype in order to constify "exec_file" and accept a
14586 "std::string" for "allargs".
14587 * nto-procfs.c (procfs_create_inferior): Likewise.
14588 * procfs.c (procfs_create_inferior): Likewise.
14589 * remote-sim.c (gdbsim_create_inferior): Likewise.
14590 * remote.c (extended_remote_run): Update code to accept
14591 "std::string" as argument.
14592 (extended_remote_create_inferior): Rewrite function prototype in
14593 order to constify "exec_file" and accept a "std::string" for
14594 "allargs".
14595 * rs6000-nat.c (super_create_inferior): Likewise.
14596 (rs6000_create_inferior): Likewise.
14597 * target.h (struct target_ops) <to_create_inferior>: Likewise.
14598 * windows-nat.c (windows_create_inferior): Likewise.
14599
ae0eee42
PA
146002017-04-11 Pedro Alves <palves@redhat.com>
14601
14602 * thread.c: Fix whitespace throughout.
14603
a6acac06
PR
146042017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
14605
14606 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
14607
64403bd1
AH
146082017-04-11 Alan Hayward <alan.hayward@arm.com>
14609
14610 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
14611
a5bef50f
SDJ
146122017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
14613
14614 PR gdb/21364
14615 * osdata.c (info_osdata): Check if 'type' is an empty string
14616 instead of NULL.
14617
9295a5a9
PA
146182017-04-10 Pedro Alves <palves@redhat.com>
14619
14620 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
14621 (ptid_to_global_thread_id, in_thread_list)
14622 (do_captured_list_thread_ids, set_resumed, set_running)
14623 (set_executing, set_stop_requested, finish_thread_state)
14624 (validate_registers_access, can_access_registers_ptid)
14625 (print_thread_info_1, switch_to_thread)
14626 (do_restore_current_thread_cleanup)
14627 (make_cleanup_restore_current_thread, thread_command)
14628 (thread_name_command): Use operator== instead of ptid_equal.
14629
996812e3
PA
146302017-04-10 Pedro Alves <palves@redhat.com>
14631
14632 * thread.c (struct current_thread_cleanup) <next>: Delete field.
14633 (current_thread_cleanup_chain): Delete.
14634 (restore_current_thread_cleanup_dtor)
14635 (make_cleanup_restore_current_thread): Remove references to
14636 current_thread_cleanup_chain.
14637
845b344f
AH
146382017-04-10 Alan Hayward <alan.hayward@arm.com>
14639
14640 * msp430-tdep.c (msp430_pseudo_register_read): Never return
14641 REG_UNKNOWN.
14642
803bdfe4
YQ
146432017-04-10 Yao Qi <yao.qi@linaro.org>
14644
14645 PR gdb/19942
14646 * gdbthread.h (thread_info::deletable): New method.
14647 (thread_info::incref): New method.
14648 (thread_info::decref): New method.
14649 (thread_info::refcount): Move it to private.
14650 * infrun.c (save_stop_context): Call inc_refcount.
14651 (release_stop_context_cleanup): Likewise.
14652 * thread.c (set_thread_exited): New function.
14653 (init_thread_list): Delete "tp" only it is deletable, otherwise
14654 call set_thread_exited.
14655 (delete_thread_1): Call set_thread_exited.
14656 (current_thread_cleanup) <inferior_pid>: Remove.
14657 <thread>: New field.
14658 (restore_current_thread_ptid_changed): Removed.
14659 (do_restore_current_thread_cleanup): Adjust.
14660 (restore_current_thread_cleanup_dtor): Don't call
14661 find_thread_ptid.
14662 (set_thread_refcount): Use dec_refcount.
14663 (make_cleanup_restore_current_thread): Adjust.
14664 (thread_apply_all_command): Call inc_refcount.
14665 (_initialize_thread): Don't call
14666 observer_attach_thread_ptid_changed.
14667
8c25b497
YQ
146682017-04-10 Yao Qi <yao.qi@linaro.org>
14669
14670 * thread.c (delete_thread_1): Hoist code on marking thread as
14671 exited.
14672
8473b447
SM
146732017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14674
14675 * windows-nat.c (windows_detach): Initialize ptid with
14676 minus_one_ptid.
14677
6670ec13
SM
146782017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14679
14680 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14681
ba2f91bb
AH
146822017-04-07 Alan Hayward <alan.hayward@arm.com>
14683
14684 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14685 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14686 (bfin_pseudo_register_write): Likewise
14687
436252de
SM
146882017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14689
14690 * common/ptid.h (struct ptid): Change to...
14691 (class ptid_t): ... this.
14692 <ptid_t>: New constructors.
14693 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14694 matches>: New methods.
14695 <make_null, make_minus_one>: New static methods.
14696 <pid>: Rename to...
14697 <m_pid>: ...this.
14698 <lwp>: Rename to...
14699 <m_lwp>: ...this.
14700 <tid>: Rename to...
14701 <m_tid>: ...this.
14702 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14703 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14704 as references, move comment to class ptid_t.
14705 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14706 ptid_t static methods.
14707 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14708 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14709 Take ptid arguments as references, implement using ptid_t methods.
14710 * unittests/ptid-selftests.c: New file.
14711 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14712 unittests/ptid-selftests.c.
14713 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14714
0dedf377
TP
147152017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14716
14717 * python/python.c (python_run_simple_file): Cast mode literal to
14718 non-const char pointer as expected by PyFile_FromString.
14719
4e9868d4
SM
147202017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14721
14722 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14723 minus_one_ptid and null_ptid.
14724
9bf2a700
PA
147252017-04-05 Pedro Alves <palves@redhat.com>
14726
14727 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14728 * configure: Regenerate.
14729
a121b7c1
PA
147302017-04-05 Pedro Alves <palves@redhat.com>
14731
14732 * ada-exp.y (yyerror): Constify.
14733 * ada-lang.c (bound_name, get_selections)
14734 (ada_variant_discrim_type)
14735 (ada_variant_discrim_name, ada_value_struct_elt)
14736 (ada_lookup_struct_elt_type, is_unchecked_variant)
14737 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14738 (catch_ada_exception_command_split)
14739 (catch_ada_assert_command_split, catch_assert_command)
14740 (ada_op_name): Constify.
14741 * ada-lang.h (ada_yyerror, get_selections)
14742 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14743 * arc-tdep.c (arc_print_frame_cache): Constify.
14744 * arm-tdep.c (arm_skip_stub): Constify.
14745 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14746 (gen_aggregate_elt_ref): Constify.
14747 * bcache.c (print_bcache_statistics): Constify.
14748 * bcache.h (print_bcache_statistics): Constify.
14749 * break-catch-throw.c (catch_exception_command_1):
14750 * breakpoint.c (struct ep_type_description::description):
14751 Constify.
14752 (add_solib_catchpoint): Constify.
14753 (catch_fork_command_1): Add cast.
14754 (add_catch_command): Constify.
14755 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14756 Constify.
14757 * bsd-uthread.c (bsd_uthread_state): Constify.
14758 * buildsym.c (patch_subfile_names): Constify.
14759 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14760 Constify.
14761 * c-exp.y (yyerror): Constify.
14762 (token::oper): Constify.
14763 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14764 * c-varobj.c (cplus_describe_child): Constify.
14765 * charset.c (find_charset_names): Add cast.
14766 (find_charset_names): Constify array and add const_cast.
14767 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14768 (edit_command): Constify.
14769 * cli/cli-decode.c (lookup_cmd): Constify.
14770 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14771 Constify.
14772 (struct dump_context): Constify.
14773 (add_dump_command, restore_command): Constify.
14774 * cli/cli-script.c (get_command_line): Constify.
14775 * cli/cli-script.h (get_command_line): Constify.
14776 * cli/cli-utils.c (check_for_argument): Constify.
14777 * cli/cli-utils.h (check_for_argument): Constify.
14778 * coff-pe-read.c (struct read_pe_section_data): Constify.
14779 * command.h (lookup_cmd): Constify.
14780 * common/print-utils.c (decimal2str): Constify.
14781 * completer.c (gdb_print_filename): Constify.
14782 * corefile.c (set_gnutarget): Constify.
14783 * cp-name-parser.y (yyerror): Constify.
14784 * cp-valprint.c (cp_print_class_member): Constify.
14785 * cris-tdep.c (cris_register_name, crisv32_register_name):
14786 Constify.
14787 * d-exp.y (yyerror): Constify.
14788 (struct token::oper): Constify.
14789 * d-lang.h (d_yyerror): Constify.
14790 * dbxread.c (struct header_file_location::name): Constify.
14791 (add_old_header_file, add_new_header_file, last_function_name)
14792 (dbx_next_symbol_text, add_bincl_to_list)
14793 (find_corresponding_bincl_psymtab, set_namestring)
14794 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14795 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14796 * defs.h (command_line_input, print_address_symbolic)
14797 (deprecated_readline_begin_hook): Constify.
14798 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14799 Constify.
14800 * event-top.c (handle_line_of_input): Constify and add cast.
14801 * exceptions.c (catch_errors): Constify.
14802 * exceptions.h (catch_errors): Constify.
14803 * expprint.c (print_subexp_standard, op_string, op_name)
14804 (op_name_standard, dump_raw_expression, dump_raw_expression):
14805 * expression.h (op_name, op_string, dump_raw_expression):
14806 Constify.
14807 * f-exp.y (yyerror): Constify.
14808 (struct token::oper): Constify.
14809 (struct f77_boolean_val::name): Constify.
14810 * f-lang.c (f_word_break_characters): Constify.
14811 * f-lang.h (f_yyerror): Constify.
14812 * fork-child.c (fork_inferior): Add cast.
14813 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14814 (new_variant): Constify.
14815 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14816 * gdbarch.c: Regenerate.
14817 * gdbcore.h (set_gnutarget): Constify.
14818 * go-exp.y (yyerror): Constify.
14819 (token::oper): Constify.
14820 * go-lang.h (go_yyerror): Constify.
14821 * go32-nat.c (go32_sysinfo): Constify.
14822 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14823 * guile/scm-cmd.c (cmdscm_function): Constify.
14824 * guile/scm-param.c (pascm_param_value): Constify.
14825 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14826 (h8300sx_register_name): Constify.
14827 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14828 Constify.
14829 * ia64-tdep.c (ia64_register_names): Constify.
14830 * infcmd.c (construct_inferior_arguments): Constify.
14831 (path_command, attach_post_wait): Constify.
14832 * language.c (show_range_command, show_case_command)
14833 (unk_lang_error): Constify.
14834 * language.h (language_defn::la_error)
14835 (language_defn::la_name_of_this): Constify.
14836 * linespec.c (decode_line_2): Constify.
14837 * linux-thread-db.c (thread_db_err_str): Constify.
14838 * lm32-tdep.c (lm32_register_name): Constify.
14839 * m2-exp.y (yyerror): Constify.
14840 * m2-lang.h (m2_yyerror): Constify.
14841 * m32r-tdep.c (m32r_register_names): Constify and make static.
14842 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14843 * m88k-tdep.c (m88k_register_name): Constify.
14844 * macroexp.c (appendmem): Constify.
14845 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14846 (upgrade_type, parse_external, parse_partial_symbols)
14847 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14848 (new_symbol): Constify.
14849 * memattr.c (mem_info_command): Constify.
14850 * mep-tdep.c (register_name_from_keyword): Constify.
14851 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14852 Constify.
14853 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14854 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14855 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14856 cast.
14857 (mi_execute_async_cli_command): Constify.
14858 * mips-tdep.c (mips_register_name): Constify.
14859 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14860 (am33_register_name, am33_2_register_name)
14861 * moxie-tdep.c (moxie_register_names): Constify.
14862 * nat/linux-osdata.c (osdata_type): Constify fields.
14863 * nto-tdep.c (nto_parse_redirection): Constify.
14864 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14865 (lookup_child_selector): Constify.
14866 (objc_methcall::name): Constify.
14867 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14868 (lookup_struct_typedef): Constify.
14869 * objfiles.c (pc_in_section): Constify.
14870 * objfiles.h (pc_in_section): Constify.
14871 * p-exp.y (struct token::oper): Constify.
14872 (yyerror): Constify.
14873 * p-lang.h (pascal_yyerror): Constify.
14874 * parser-defs.h (op_name_standard): Constify.
14875 (op_print::string): Constify.
14876 (exp_descriptor::op_name): Constify.
14877 * printcmd.c (print_address_symbolic): Constify.
14878 * psymtab.c (print_partial_symbols): Constify.
14879 * python/py-breakpoint.c (stop_func): Constify.
14880 (bppy_get_expression): Constify.
14881 * python/py-cmd.c (cmdpy_completer::name): Constify.
14882 (cmdpy_function): Constify.
14883 * python/py-event.c (evpy_add_attribute)
14884 (gdbpy_initialize_event_generic): Constify.
14885 * python/py-event.h (evpy_add_attribute)
14886 (gdbpy_initialize_event_generic): Constify.
14887 * python/py-evts.c (add_new_registry): Constify.
14888 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14889 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14890 * python/py-inferior.c (get_buffer): Add cast.
14891 * python/py-param.c (parm_constant::name): Constify.
14892 * python/py-unwind.c (fprint_frame_id): Constify.
14893 * python/python.c (gdbpy_parameter_value): Constify.
14894 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14895 * remote.c (memory_packet_config::name): Constify.
14896 (show_packet_config_cmd, remote_write_bytes)
14897 (remote_buffer_add_string):
14898 * reverse.c (exec_reverse_once): Constify.
14899 * rs6000-tdep.c (variant::name, variant::description): Constify.
14900 * rust-exp.y (rustyyerror): Constify.
14901 * rust-lang.c (rust_op_name): Constify.
14902 * rust-lang.h (rustyyerror): Constify.
14903 * serial.h (serial_ops::name): Constify.
14904 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14905 (sh_sh3e_register_name, sh_sh2e_register_name)
14906 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14907 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14908 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14909 (sh_sh4al_dsp_register_name): Constify.
14910 * sh64-tdep.c (sh64_register_name): Constify.
14911 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14912 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14913 * stabsread.c (patch_block_stabs, read_type_number)
14914 (ref_map::stabs, ref_add, process_reference)
14915 (symbol_reference_defined, define_symbol, define_symbol)
14916 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14917 (read_one_struct_field, read_struct_fields, read_baseclasses)
14918 (read_tilde_fields, read_struct_type, read_array_type)
14919 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14920 (read_huge_number, read_range_type, read_args, common_block_start)
14921 (find_name_end): Constify.
14922 * stabsread.h (common_block_start, define_symbol)
14923 (process_one_symbol, symbol_reference_defined, ref_add):
14924 * symfile.c (get_section_index, add_symbol_file_command):
14925 * symfile.h (get_section_index): Constify.
14926 * target-descriptions.c (tdesc_type::name): Constify.
14927 (tdesc_free_type): Add cast.
14928 * target.c (find_default_run_target):
14929 (add_deprecated_target_alias, find_default_run_target)
14930 (target_announce_detach): Constify.
14931 (do_option): Constify.
14932 * target.h (add_deprecated_target_alias): Constify.
14933 * thread.c (print_thread_info_1): Constify.
14934 * top.c (deprecated_readline_begin_hook, command_line_input):
14935 Constify.
14936 (init_main): Add casts.
14937 * top.h (handle_line_of_input): Constify.
14938 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14939 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14940 (tfind_command): Rename to ...
14941 (tfind_command_1): ... this and constify.
14942 (tfind_command): New function.
14943 (tfind_end_command, tfind_start_command): Adjust.
14944 (encode_source_string): Constify.
14945 * tracepoint.h (encode_source_string): Constify.
14946 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14947 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14948 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14949 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14950 * tui/tui-win.c (parse_scrolling_args): Constify.
14951 * tui/tui-windata.c (tui_erase_data_content): Constify.
14952 * tui/tui-windata.h (tui_erase_data_content): Constify.
14953 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14954 * tui/tui.c (tui_enable): Add cast.
14955 * utils.c (defaulted_query): Constify.
14956 (init_page_info): Add cast.
14957 (puts_debug, subset_compare): Constify.
14958 * utils.h (subset_compare): Constify.
14959 * varobj.c (varobj_format_string): Constify.
14960 * varobj.h (varobj_format_string): Constify.
14961 * vax-tdep.c (vax_register_name): Constify.
14962 * windows-nat.c (windows_detach): Constify.
14963 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14964 * xml-support.c (gdb_xml_end_element): Constify.
14965 * xml-tdesc.c (tdesc_start_reg): Constify.
14966 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14967 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14968 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14969
995816ba
PA
149702017-04-05 Pedro Alves <palves@redhat.com>
14971
14972 * proc-api.c (struct trans): Constify.
14973 (procfs_note): Constify.
14974 * proc-events.c (struct trans, syscall_table):
14975 * proc-flags.c (struct trans): Constify.
14976 * proc-utils.h (procfs_note): Constify.
14977 * proc-why.c (struct trans): Constify.
14978 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14979 (procfs_detach): Constify.
14980 * sol-thread.c (struct string_map): Constify.
14981 (td_err_string, td_state_string): Constify.
14982
3e83a920
PA
149832017-04-05 Pedro Alves <palves@redhat.com>
14984
14985 * proc-api.c (procfs_filename): Don't initialize
14986 procfs_filename.
14987 (prepare_to_trace): Assume procfs_filename is non-NULL.
14988 (_initialize_proc_api): Give procfs_filename a default value here.
14989
63160a43
PA
149902017-04-05 Pedro Alves <palves@redhat.com>
14991
14992 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14993 'cond_string' parameter.
14994 (extract_exception_regexp): Constify 'string' parameter.
14995 (catch_exception_command_1): Constify.
14996 * breakpoint.c (init_catchpoint)
14997 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14998 parameter.
14999 (ep_parse_optional_if_clause, catch_fork_command_1)
15000 (catch_exec_command_1): Constify.
15001 * breakpoint.h (init_catchpoint): Constify 'cond_string'
15002 parameter.
15003 (ep_parse_optional_if_clause): Constify.
15004 * cli/cli-utils.c (remove_trailing_whitespace)
15005 (check_for_argument): Constify.
15006 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
15007 non-const overload.
15008 (check_for_argument): Likewise.
15009
9b2eba3d
PA
150102017-04-05 Pedro Alves <palves@redhat.com>
15011
15012 * event-top.c (command_line_handler): Add cast to execute_command
15013 call.
15014 * record-btrace.c (cmd_record_btrace_bts_start)
15015 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
15016 (cmd_record_btrace_start): Add cast to execute_command call.
15017 * record-full.c (record_full_goto_insn):
15018 * record.c (record_start, record_stop): Add cast to
15019 execute_command_to_string calls.
15020 (cmd_record_start): Add cast to execute_command calls.
15021
2adadf51
PA
150222017-04-05 Pedro Alves <palves@redhat.com>
15023
15024 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
15025 static inline function.
15026 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
15027 array and use gdb_PyArg_ParseTupleAndKeywords.
15028 * python/py-cmd.c (cmdpy_init): Likewise.
15029 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
15030 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
15031 (infpy_search_memory): Likewise.
15032 * python/py-objfile.c (objfpy_add_separate_debug_file)
15033 (gdbpy_lookup_objfile): Likewise.
15034 * python/py-symbol.c (gdbpy_lookup_symbol)
15035 (gdbpy_lookup_global_symbol): Likewise.
15036 * python/py-type.c (gdbpy_lookup_type): Likewise.
15037 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
15038 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
15039 Likewise.
15040
0d1f4ceb
PA
150412017-04-05 Pedro Alves <palves@redhat.com>
15042
15043 * python/python-internal.h (gdb_PyGetSetDef): New type.
15044 * python/py-block.c (block_object_getset)
15045 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
15046 * python/py-event.c (event_object_getset)
15047 (finish_breakpoint_object_getset): Likewise.
15048 * python/py-inferior.c (inferior_object_getset): Likewise.
15049 * python/py-infthread.c (thread_object_getset): Likewise.
15050 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
15051 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
15052 * python/py-objfile.c (objfile_getset): Likewise.
15053 * python/py-progspace.c (pspace_getset): Likewise.
15054 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
15055 Likewise.
15056 * python/py-record.c (recpy_record_getset): Likewise.
15057 * python/py-symbol.c (symbol_object_getset): Likewise.
15058 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
15059 Likewise.
15060 * python/py-type.c (type_object_getset, field_object_getset):
15061 Likewise.
15062 * python/py-value.c (value_object_getset): Likewise.
15063
4d759979
PA
150642017-04-05 Pedro Alves <palves@redhat.com>
15065
15066 * python/python-internal.h (gdb_PyObject_CallMethod)
15067 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
15068 New functions.
15069 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
15070 (PySys_GetObject, PySys_SetPath): New macros.
15071
fdf9e36f
PA
150722017-04-05 Pedro Alves <palves@redhat.com>
15073
15074 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
15075 info_osdata_command.
15076 * osdata.c (info_osdata_command): Rename to ...
15077 (info_osdata): ... this. Constify 'type' parameter, and remove
15078 the 'from_tty' parameter. Accept NULL TYPE.
15079 (info_osdata_command): New function.
15080 * osdata.h (info_osdata_command): Remove declaration.
15081 (info_osdata): New declaration.
15082
9f33b8b7
PA
150832017-04-05 Pedro Alves <palves@redhat.com>
15084
15085 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
15086 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
15087 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
15088 parameter.
15089 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
15090 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
15091 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
15092 parameter.
15093 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
15094 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
15095 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
15096 (mi_cmd_file_list_exec_source_files)
15097 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
15098 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
15099 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
15100 parameter.
15101 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
15102 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
15103 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
15104 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
15105 (mi_cmd_stack_info_frame): Constify 'command' parameter.
15106 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
15107 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
15108 'command' parameter.
15109 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
15110 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
15111 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
15112 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
15113 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
15114 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
15115 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
15116 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
15117 (mi_cmd_var_set_update_range): Constify 'command' parameter.
15118 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
15119 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
15120 parameter.
15121 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
15122 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
15123 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
15124 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
15125 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
15126 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
15127 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
15128 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
15129 (mi_cmd_data_list_changed_registers)
15130 (mi_cmd_data_write_register_values)
15131 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
15132 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
15133 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
15134 (mi_cmd_list_features, mi_cmd_list_target_features)
15135 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
15136 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
15137 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
15138 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
15139 (mi_cmd_trace_frame_collected): Constify 'command'
15140 parameter.
15141 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
15142 'command' parameter.
15143
67cb5b2d
PA
151442017-04-05 Pedro Alves <palves@redhat.com>
15145
15146 * ada-lang.c (ada_completer_word_break_characters): Now a const
15147 array.
15148 (ada_get_gdb_completer_word_break_characters): Constify.
15149 * completer.c (gdb_completer_command_word_break_characters)
15150 (gdb_completer_file_name_break_characters)
15151 (gdb_completer_quote_characters): Now const arrays.
15152 (get_gdb_completer_quote_characters): Constify.
15153 (set_rl_completer_word_break_characters): New function.
15154 (set_gdb_completion_word_break_characters)
15155 (complete_line_internal): Use it.
15156 * completer.h (get_gdb_completer_quote_characters): Constify.
15157 (set_rl_completer_word_break_characters): Declare.
15158 * f-lang.c (f_word_break_characters): Constify.
15159 * language.c (default_word_break_characters): Constify.
15160 * language.h (language_defn::la_word_break_characters): Constify.
15161 (default_word_break_characters): Constify.
15162 * top.c (init_main): Use set_rl_completer_word_break_characters.
15163
7a114964
PA
151642017-04-05 Pedro Alves <palves@redhat.com>
15165
15166 * aix-thread.c (aix_thread_pid_to_str)
15167 (aix_thread_extra_thread_info): Constify.
15168 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
15169 * bsd-uthread.c (bsd_uthread_extra_thread_info)
15170 (bsd_uthread_pid_to_str): Constify.
15171 * corelow.c (core_pid_to_str): Constify.
15172 * darwin-nat.c (darwin_pid_to_str): Constify.
15173 * fbsd-nat.c (fbsd_pid_to_str): Constify.
15174 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
15175 Constify.
15176 * gnu-nat.c (gnu_pid_to_str): Constify.
15177 * go32-nat.c (go32_pid_to_str): Constify.
15178 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
15179 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
15180 * inferior.c (inferior_pid_to_str): Constify.
15181 * linux-nat.c (linux_nat_pid_to_str): Constify.
15182 * linux-tdep.c (linux_core_pid_to_str): Constify.
15183 * linux-thread-db.c (thread_db_pid_to_str)
15184 (thread_db_extra_thread_info): Constify.
15185 * nto-tdep.c (nto_extra_thread_info): Constify.
15186 * nto-tdep.h (nto_extra_thread_info): Constify.
15187 * obsd-nat.c (obsd_pid_to_str): Constify.
15188 * procfs.c (procfs_pid_to_str): Constify.
15189 * ravenscar-thread.c (ravenscar_extra_thread_info)
15190 (ravenscar_pid_to_str): Constify.
15191 * remote-sim.c (gdbsim_pid_to_str): Constify.
15192 * remote.c (remote_threads_extra_info, remote_pid_to_str):
15193 Constify.
15194 * sol-thread.c (solaris_pid_to_str): Constify.
15195 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
15196 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
15197 * target.c (default_pid_to_str, target_pid_to_str)
15198 (normal_pid_to_str, default_pid_to_str): Constify.
15199 * target.h (target_ops::to_pid_to_str)
15200 (target_ops::to_extra_thread_info): Constify.
15201 (target_pid_to_str, normal_pid_to_str): Constify.
15202 * windows-nat.c (windows_pid_to_str): Constify.
15203 * gdbarch.sh (core_pid_to_str): Constify.
15204 * target-delegates.c: Regenerate.
15205 * gdbarch.h, gdbarch.c: Regenerate.
15206
69bbf465
PA
152072017-04-05 Pedro Alves <palves@redhat.com>
15208
15209 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
15210 the memory of the temporary warning_pre_print override.
15211 * utils.c (warning_pre_print): Constify.
15212 * utils.h (warning_pre_print): Constify.
15213
be47f9e8
PA
152142017-04-05 Pedro Alves <palves@redhat.com>
15215
15216 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
15217 (shell_command): New function.
15218 (make_command): Use std::string.
15219 (init_cli_cmds): Register shell_command instead of shell_escape.
15220
bde6261a
PA
152212017-04-05 Pedro Alves <palves@redhat.com>
15222
15223 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
15224 * tracepoint.c (default_collect): Don't initialize.
15225
b38ef47f
PA
152262017-04-05 Pedro Alves <palves@redhat.com>
15227
15228 * macroexp.c (macro_buffer::shared): Now a bool.
15229 (init_buffer): Update.
15230 (init_shared_buffer): Constify 'addr' parameter.
15231 (substitute_args, expand, macro_expand, macro_expand_next): Remove
15232 casts.
15233
f995bbe8
PA
152342017-04-05 Pedro Alves <palves@redhat.com>
15235
15236 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
15237 * disasm.c (set_disassembler_options): Constify local.
15238 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
15239
4a596fe2
SDJ
152402017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
15241
15242 PR gdb/21352
15243 * tracefile.c (tsave_command): Fix argument parsing for '-r'
15244 option.
15245
2cad08ea
YQ
152462017-04-05 Yao Qi <yao.qi@linaro.org>
15247
15248 * frame.c (frame_unwind_register_unsigned): Call
15249 frame_unwind_register_value.
15250
55a98976
YQ
152512017-04-05 Yao Qi <yao.qi@linaro.org>
15252
15253 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
15254 Use gdb_test_multiple, and don't match anchor.
15255
4ac40124
PA
152562017-04-05 Pedro Alves <palves@redhat.com>
15257
15258 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
15259 (Write After Approval): Remove Simon Marchi.
15260
c053b654
PA
152612017-04-05 Pedro Alves <palves@redhat.com>
15262
15263 * common/gdb_optional.h (optional::optional): Make constexpr and
15264 initialize m_dummy.
15265
4c7bf4f9
JB
152662017-04-04 John Baldwin <jhb@FreeBSD.org>
15267
15268 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15269 (amd64fbsd_jmp_buf_reg_offset): Remove.
15270 (amd64fbsd_supply_uthread): Remove function.
15271 (amd64fbsd_collect_uthread): Remove function.
15272 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
15273 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
15274 (x86_64-*-freebsd*): Remove bsd-uthread.o.
15275 (fbsd-nat.c): Update comment.
15276 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
15277 (i386fbsd_jmp_buf_reg_offset): Remove.
15278 (i386fbsd_supply_uthread): Remove function.
15279 (i386fbsd_collect_uthread): Remove function.
15280 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
15281
1e1a8bef
JB
152822017-04-04 John Baldwin <jhb@FreeBSD.org>
15283
15284 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
15285 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
15286 * NEWS: Mention that support for FreeBSD/alpha was removed.
15287 * alpha-fbsd-tdep.c: Delete file.
15288 * config/alpha/fbsd.mh: Delete file.
15289 * configure.host: Delete alpha*-*-freebsd* and
15290 alpha*-*-kfreebsd*-gnu.
15291 * configure.tgt: Delete alpha*-*-freebsd* and
15292 alpha*-*-kfreebsd*-gnu.
15293
49907934
JB
152942017-04-04 John Baldwin <jhb@FreeBSD.org>
15295
15296 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
15297 amd64bsd_store_inferior_registers): Use ptid from regcache.
15298
6f77053d
PA
152992017-04-04 Pedro Alves <palves@redhat.com>
15300
15301 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
15302 data fields, make them private and add "m_" prefixes.
15303 (lnp_state_machine::lnp_state_machine): New ctor.
15304 (record_line, check_line_address, handle_set_discriminator)
15305 (handle_set_address, handle_advance_pc, handle_special_opcode)
15306 (handle_advance_line, handle_set_file, handle_negate_stmt)
15307 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
15308 (end_sequence, advance_line): New methods.
15309 (m_gdbarch, m_record_lines_p): New fields.
15310 (lnp_reader_state): Delete.
15311 (dwarf_record_line): Rename to ...
15312 (lnp_state_machine::record_line): ... adjust.
15313 (init_lnp_state_machine): Delete.
15314 (lnp_state_machine::lnp_state_machine): New.
15315 (check_line_address): Rename to ...
15316 (lnp_state_machine::check_line_address): This.
15317 (dwarf_decode_lines_1): Remove reference to "reader_state".
15318 Adjust lnp_state_machine having a non-default ctor. Use bool.
15319 State machine internal state manipulation moved to
15320 lnp_state_machine methods.
15321
9c541725
PA
153222017-04-04 Pedro Alves <palves@redhat.com>
15323
15324 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15325 unittests/offset-type-selftests.c.
15326 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
15327 * common/offset-type.h: New file.
15328 * common/preprocessor.h: New file.
15329 * common/traits.h: New file.
15330 * common/valid-expr.h: New file.
15331 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
15332 sect_offset and cu_offset strong typedefs throughout.
15333 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
15334 typedefs throughout.
15335 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
15336 sect_offset and cu_offset strong typedefs throughout.
15337 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
15338 typedefs throughout.
15339 * gdbtypes.h: Include "common/offset-type.h".
15340 (cu_offset): Now an offset type (strong typedef) instead of a
15341 struct.
15342 (sect_offset): Likewise.
15343 (union call_site_parameter_u): Rename "param_offset" field to
15344 "param_cu_off".
15345 * unittests/offset-type-selftests.c: New file.
15346
ecfb656c
PA
153472017-04-04 Pedro Alves <palves@redhat.com>
15348
15349 * common/underlying.h: New file.
15350 * dwarf2read.c: Include "common/gdb_optional.h" and
15351 "common/underlying.h".
15352 (dir_index, file_name_index): New types.
15353 (file_entry): Use them.
15354 (file_entry::include): Use to_underlying.
15355 (line_header::add_file_name): Use dir_index.
15356 (read_formatted_entries): Use gdb::optional. Read form before
15357 writting to file_entry.
15358 (dwarf_decode_line_header): Use dir_index.
15359 (lnp_state_machine::current_file): Use to_underlying.
15360 (lnp_state_machine::file): Change type to file_name_index.
15361 (dwarf_record_line): Use to_underlying.
15362 (init_lnp_state_machine): Use file_name_index.
15363 (dwarf_decode_lines_1): Use dir_index and file_name_index.
15364
d194f1fe
PA
153652017-04-04 Pedro Alves <palves@redhat.com>
15366
15367 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
15368 operator bool, has_value and get methods.
15369
fff8551c
PA
153702017-04-04 Pedro Alves <palves@redhat.com>
15371
15372 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
15373 fields.
15374 (line_header): Initialize all data fields. Change type of
15375 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
15376 Change type of include_dirs to std::vector<const char *>. Remove
15377 num_include_dirs, include_dirs_size. Change type of file_names to
15378 std::vector<file_entry>. Remove num_file_names, file_names_size.
15379 (line_header::line_header): New.
15380 (line_header::add_include_dir, line_header::add_file_name): New
15381 methods.
15382 (line_header::include_dir_at): Remove NULL check.
15383 (line_header::file_name_at): Add const overload.
15384 (line_header_up): New unique_ptr typedef.
15385 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
15386 std::vector. Remove free_line_header call.
15387 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
15388 free_line_header call.
15389 (free_cu_line_header): Delete.
15390 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
15391 (setup_type_unit_groups): Use line_header_up instead of cleanups.
15392 Adjust to use std::vector.
15393 (free_line_header): Delete.
15394 (free_line_header_voidp): Use delete.
15395 (add_include_dir): Replace with ...
15396 (line_header::add_include_dir): ... this method. Use std::vector.
15397 (add_file_name): Replace with ...
15398 (line_header::add_file_name): ... this method. Use std::vector.
15399 (add_include_dir_stub): Delete.
15400 (read_formatted_entries): Remove memset.
15401 (dwarf_decode_line_header): Return a line_header_up instead of a
15402 raw pointer. Remove cleanup handling. Pass lambdas to
15403 read_formatted_entries. Adjust to use line_header methods.
15404 (dwarf_decode_lines_1): Adjust to use line_header methods.
15405 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
15406 use std::vector.
15407
d62a8ae2
SM
154082017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
15409
15410 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
15411 instead of struct ptid.
15412
db3a1dc7
AH
154132017-05-04 Alan Hayward <alan.hayward@arm.com>
15414
15415 * frame.c (get_frame_register_bytes): Unwind using value.
15416 (put_frame_register_bytes): Likewise.
15417
b1b45502
IB
154182017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
15419
15420 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
15421 aggregate-like.
15422
ec13808e
JK
154232017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
15424
15425 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
15426
12316564
YQ
154272017-03-29 Yao Qi <yao.qi@linaro.org>
15428
15429 * gdbthread.h (struct thread_info): Declare constructor and
15430 destructor. Add some in-class member initializers.
15431 * thread.c (free_thread): Remove.
15432 (init_thread_list): Call delete instead of free_thread.
15433 (new_thread): Call thread_info constructor.
15434 (thread_info::thread_info): New function.
15435 (thread_info::~thread_info): New function.
15436 (delete_thread_1): Call delete instead of free_thread.
15437 (make_cleanup_restore_current_thread): Move tp and frame to
15438 inner block.
15439
fe5f7374
AK
154402017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15441
15442 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
15443 (arc_skip_prologue): Likewise.
15444 (arc_make_frame_cache): Likewise.
15445 (arc_pv_get_operand): New function.
15446 (arc_is_in_prologue): Likewise.
15447 (arc_analyze_prologue): Likewise.
15448 (arc_print_frame_cache): Likewise.
15449 (MAX_PROLOGUE_LENGTH): New constant.
15450
eea78757
AK
154512017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15452
15453 * configure.tgt: Add arc-insn.o.
15454 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
15455 (dump_arc_instruction_command): New function.
15456 (arc_fprintf_disasm): Likewise.
15457 (arc_disassemble_info): Likewise.
15458 (arc_insn_get_operand_value): Likewise.
15459 (arc_insn_get_operand_value_signed): Likewise.
15460 (arc_insn_get_memory_base_reg): Likewise.
15461 (arc_insn_get_memory_offset): Likewise.
15462 (arc_insn_get_branch_target): Likewise.
15463 (arc_insn_dump): Likewise.
15464 (arc_insn_get_linear_next_pc): Likewise.
15465 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
15466 (arc_disassemble_info): Likewise.
15467 (arc_insn_get_branch_target): Likewise.
15468 (arc_insn_get_linear_next_pc): Likewise.
15469 * NEWS: Mention new "maint print arc arc-instruction".
15470
3be78afd
AK
154712017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15472
15473 * arc-tdep (maintenance_print_arc_list): New variable.
15474 (maintenance_print_arc_command): New function.
15475
296ec4fa
AK
154762017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15477
15478 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
15479 Add "limm" and "reserved".
15480 (arc_cannot_fetch_register, arc_cannot_store_register): Add
15481 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
15482 * arc-tdep.h (arc_regnum): Likewise.
15483
f74f865e
MF
154842017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15485
15486 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15487 for THREADPTR register.
15488 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
15489 register.
15490 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
15491 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
15492 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
15493
0d0bf81a
MF
154942017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15495
15496 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
15497 registers above gdbarch_num_regs (gdbarch) as privileged in
15498 call0 ABI.
15499
0ce4291e
MF
155002017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15501
15502 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15503 for a single specified register or for all registers in
15504 a0_base..a0_base + C0_NREGS range.
15505 (supply_gregset_reg): Call regcache_raw_supply for a single
15506 specified register or for all registers in a0_base..a0_base +
15507 C0_NREGS range.
15508
c56054f9
MF
155092017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15510
15511 * arch/xtensa.h (C0_NREGS): Add definition.
15512 * xtensa-tdep.c (C0_NREGS): Remove definition.
15513
a4398628
MF
155142017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15515
15516 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
15517 Drop xtensa_default_isa initialization.
15518 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
15519
8c43009f
PA
155202017-03-27 Pedro Alves <palves@redhat.com>
15521
15522 * dwarf2read.c (file_entry) <dir_index>: Add comment.
15523 (file_entry::include_dir): New method.
15524 (line_header::include_dir_at, line_header::file_name_at): New
15525 methods.
15526 (setup_type_unit_groups, setup_type_unit_groups)
15527 (psymtab_include_file_name): Simplify using the new methods.
15528 (lnp_state_machine) <the_line_header>: New field.
15529 <file>: Add comment.
15530 (lnp_state_machine::current_file): New method.
15531 (dwarf_record_line): Simplify using the new methods.
15532 (init_lnp_state_machine): Initialize the "the_line_header" field.
15533 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
15534 Simplify using the new methods.
15535
a7e80b9e
PA
155362017-03-27 Pedro Alves <palves@redhat.com>
15537
15538 * cp-name-parser.y (make_empty): Delete.
15539 (demangler_special, nested_name, ptr_operator, array_indicator)
15540 (direct_declarator, declarator_1): Use fill_comp instead of
15541 make_empty.
15542
21047726
PA
155432017-03-27 Pedro Alves <palves@redhat.com>
15544
15545 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
15546 to ATTRIBUTE_PRINTF.
15547 * solib-target.c (library_list_start_list): Print "string" not
15548 "version".
15549 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
15550 gdb_xml_error call.
15551
d721ba37
PA
155522017-03-27 Pedro Alves <palves@redhat.com>
15553
15554 * dwarf2read.c (struct file_and_directory): New.
15555 (dwarf2_get_dwz_file): Adjust to use std::string.
15556 (dw2_get_file_names_reader): Adjust to use file_and_directory.
15557 (find_file_and_directory): Adjust to return a file_and_directory
15558 object.
15559 (read_file_scope): Adjust to use file_and_directory. Remove
15560 make_cleanup/do_cleanups calls.
15561 (open_and_init_dwp_file): Adjust to use std::string. Remove
15562 make_cleanup/do_cleanups calls.
15563 * python/python.c (do_start_initialization): Adjust to ldirname
15564 returning a std::string.
15565 * utils.c (ldirname): Now returns a std::string.
15566 * utils.h (ldirname): Change return type to std::string.
15567 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
15568 returning a std::string.
15569 * xml-tdesc.c (file_read_description_xml): Likewise.
15570
ed771251
AH
155712017-03-24 Alan Hayward <alan.hayward@arm.com>
15572
15573 * regcache.c (regcache_debug_print_register): New function.
15574 * regcache.h (regcache_debug_print_register): New declaration.
15575 * target.c (debug_print_register): Remove.
15576 (target_fetch_registers): Call regcache_debug_print_register.
15577 (target_store_registers): Likewise.
15578
568c1b9f
PB
155792017-03-24 Pádraig Brady <pbrady@fb.com>
15580
15581 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
15582 reference beyond the 'lh->include_dirs' array before accessing to
15583 it.
15584 (psymtab_include_file_name): Likewise.
15585 (dwarf_decode_lines_1): Likewise.
15586 (dwarf_decode_lines): Likewise.
15587 (file_file_name): Likewise.
15588
3e00d44f
SM
155892017-03-23 Simon Marchi <simon.marchi@ericsson.com>
15590
15591 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
15592 inferior_ptid.
15593 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15594 ps_lsetfpregs): Likewise.
15595 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
15596 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15597 ps_lsetfpregs): Likewise.
15598 * target.c (target_fetch_registers, target_store_registers):
15599 Remove asserts.
15600
077ae656
AH
156012017-03-23 Alan Hayward <alan.hayward@arm.com>
15602
15603 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
15604
1e2b521d
YQ
156052017-03-23 Yao Qi <yao.qi@linaro.org>
15606
15607 * aarch64-tdep.c (aarch64_process_record_test): Declare.
15608 (_initialize_aarch64_tdep): Register it.
15609 (aarch64_record_load_store): Handle PRFM instruction.
15610 (aarch64_process_record_test): New function.
15611
33877125
YQ
156122017-03-23 Yao Qi <yao.qi@linaro.org>
15613
15614 * aarch64-tdep.c (aarch64_record_load_store): Fix code
15615 indentation.
15616
a0eef940
YQ
156172017-03-23 Yao Qi <yao.qi@linaro.org>
15618
15619 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
15620
3f2a3564
PR
156212017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15622
15623 python/python.c (do_start_initialization): Fix memory leak.
15624
b67aeab0
SM
156252017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
15626
15627 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
15628 using get_ptrace_pid.
15629 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
15630 inferior_ptid.
15631 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
15632 inferior_ptid instead of pid.
15633
ffdbe864
YQ
156342017-03-22 Yao Qi <yao.qi@linaro.org>
15635
15636 * aarch64-tdep.c: Wrap locally used classes in anonymous
15637 namespace.
15638 * arm-tdep.c: Likewise.
15639 * linespec.c: Likewise.
15640 * ui-out.c: Likewise.
15641
9d736fbf
JG
156422017-03-22 Jonah Graham <jonah@kichwacoders.com>
15643
15644 PR gdb/19637
15645 * python/lib/gdb/printer/bound_registers.py: Import sys.
15646
3de88e9a
SM
156472017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15648
15649 * windows-nat.c (do_windows_fetch_inferior_registers): Add
15650 windows_thread_info parameter and use it instead of
15651 current_thread.
15652 (windows_fetch_inferior_registers): Don't set current_thread,
15653 pass the thread to do_windows_fetch_inferior_registers. Use
15654 ptid from regcache instead of inferior_ptid.
15655 (do_windows_store_inferior_registers): Add windows_thread_info
15656 parameter and use it instead of current_thread.
15657 (windows_store_inferior_registers): Don't set current_thread,
15658 pass the thread to do_windows_store_inferior_registers. Use
15659 ptid from regcache instead of inferior_ptid.
15660
0e7b8f61
SM
156612017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15662
15663 * ser-mingw.c (ser_windows_raw): Remove reference to
15664 struct serial::current_timeout.
15665
5badf10a
IR
156662017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15667
15668 PR tdep/20928
15669 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15670 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15671 (sparc64_fsr_type): Fix %fsr decoding.
15672
cee59b3f
TW
156732017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15674
15675 * python/py-record-btrace.c (btpy_insn_data): Change return type
15676 for Python 2.
15677
639a9038
SM
156782017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15679
15680 * spu-linux-nat.c (spu_fetch_inferior_registers,
15681 spu_store_inferior_registers): Use ptid from regcache, set and
15682 restore inferior_ptid.
15683 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15684 Likewise.
15685
bcc0c096
SM
156862017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15687
15688 * i386-linux-nat.c (fetch_register, store_register,
15689 i386_linux_fetch_inferior_registers,
15690 i386_linux_store_inferior_registers): Use ptid from regcache.
15691 * ia64-linux-nat.c (ia64_linux_fetch_register,
15692 ia64_linux_store_register): Likewise.
15693 * inf-ptrace.c (inf_ptrace_fetch_register,
15694 inf_ptrace_store_register): Likewise.
15695 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15696 m32r_linux_store_inferior_registers): Likewise.
15697 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15698 m68kbsd_store_inferior_registers): Likewise.
15699 * m68k-linux-nat.c (fetch_register, store_register,
15700 m68k_linux_fetch_inferior_registers,
15701 m68k_linux_store_inferior_registers): Likewise.
15702 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15703 m88kbsd_store_inferior_registers): Likewise.
15704 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15705 mips_fbsd_store_inferior_registers): Likewise.
15706 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15707 mips64_linux_regsets_store_registers): Likewise.
15708 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15709 mipsnbsd_store_inferior_registers): Likewise.
15710 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15711 mips64obsd_store_inferior_registers): Likewise.
15712 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15713 Likewise.
15714 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15715 ppcfbsd_store_inferior_registers): Likewise.
15716 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15717 ppc_linux_store_inferior_registers): Likewise.
15718 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15719 ppcnbsd_store_inferior_registers): Likewise.
15720 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15721 ppcobsd_store_registers): Likewise.
15722 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15723 Likewise.
15724 * ravenscar-thread.c (ravenscar_fetch_registers,
15725 ravenscar_store_registers, ravenscar_prepare_to_store):
15726 Likewise.
15727 * record-btrace.c (record_btrace_fetch_registers,
15728 record_btrace_store_registers, record_btrace_prepare_to_store):
15729 Likewise.
15730 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15731 Lookup inferior using ptid from regcache, instead of
15732 current_inferior.
15733 * remote.c (remote_fetch_registers, remote_store_registers): Use
15734 ptid from regcache.
15735 * rs6000-nat.c (fetch_register, store_register): Likewise.
15736 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15737 s390_linux_store_inferior_registers): Likewise.
15738 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15739 shnbsd_store_inferior_registers): Likewise.
15740 * sol-thread.c (sol_thread_fetch_registers,
15741 sol_thread_store_registers): Likewise.
15742 * sparc-nat.c (sparc_fetch_inferior_registers,
15743 sparc_store_inferior_registers): Likewise.
15744 * tilegx-linux-nat.c (fetch_inferior_registers,
15745 store_inferior_registers): Likewise.
15746 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15747 vaxbsd_store_inferior_registers): Likewise.
15748 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15749 store_xtregs): Likewise.
15750
c0f55cc6
AV
157512017-03-20 Artemiy Volkov <artemiyv@acm.org>
15752
15753 PR gdb/14441
15754 * NEWS: Mention support for rvalue references in GDB and python.
15755 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15756 supports both lvalue and rvalue references.
15757
15c0a2a9
AV
157582017-03-20 Artemiy Volkov <artemiyv@acm.org>
15759
15760 PR gdb/14441
15761 * gdbtypes.c (rank_one_type): Implement overloading
15762 resolution rules regarding rvalue references.
15763
aa006118
AV
157642017-03-20 Artemiy Volkov <artemiyv@acm.org>
15765
15766 PR gdb/14441
15767 * aarch64-tdep.c (aarch64_type_align)
15768 (aarch64_extract_return_value, aarch64_store_return_value): Change
15769 lvalue reference type checks to general reference type checks.
15770 * amd64-tdep.c (amd64_classify): Likewise.
15771 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15772 Likewise.
15773 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15774 (arm_store_return_value): Likewise.
15775 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15776 * c-typeprint.c (c_print_type): Likewise.
15777 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15778 (cplus_number_of_children, cplus_describe_child): Likewise.
15779 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15780 * completer.c (expression_completer): Likewise.
15781 * cp-support.c (make_symbol_overload_list_adl_namespace):
15782 Likewise.
15783 * darwin-nat-info.c (info_mach_region_command): Likewise.
15784 * dwarf2loc.c (entry_data_value_coerce_ref)
15785 (value_of_dwarf_reg_entry): Likewise.
15786 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15787 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15788 Likewise.
15789 * findvar.c (extract_typed_address, store_typed_address):
15790 Likewise.
15791 * gdbtypes.c (rank_one_type): Likewise.
15792 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15793 * infcall.c (value_arg_coerce): Likewise.
15794 * language.c (pointer_type): Likewise.
15795 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15796 Likewise.
15797 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15798 * mn10300-tdep.c (mn10300_type_align): Likewise.
15799 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15800 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15801 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15802 Likewise.
15803 * printcmd.c (print_formatted, x_command): Likewise.
15804 * python/py-type.c (typy_get_composite, typy_template_argument):
15805 Likewise.
15806 * python/py-value.c (valpy_referenced_value)
15807 (valpy_get_dynamic_type, value_has_field): Likewise.
15808 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15809 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15810 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15811 * spu-tdep.c (spu_scalar_value_p): Likewise.
15812 * symtab.c (lookup_symbol_aux): Likewise.
15813 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15814 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15815 Likewise.
15816 * valops.c (value_cast_pointers, value_cast)
15817 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15818 (value_struct_elt, value_struct_elt_bitpos)
15819 (value_find_oload_method_list, find_overload_match)
15820 (value_rtti_indirect_type): Likewise.
15821 * valprint.c (val_print_scalar_type_p, generic_val_print):
15822 Likewise.
15823 * value.c (value_actual_type, value_as_address, unpack_long)
15824 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15825 (coerce_ref): Likewise.
15826 * varobj.c (varobj_get_value_type): Likewise.
15827
3fcf899d
AV
158282017-03-20 Artemiy Volkov <artemiyv@acm.org>
15829
15830 PR gdb/14441
15831 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15832 table of constants.
15833 * python/lib/gdb/command/explore.py: Support exploring values
15834 of rvalue reference types.
15835 * python/lib/gdb/types.py: Implement get_basic_type() for
15836 rvalue reference types.
15837 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15838 constant.
15839 * python/py-value.c (valpy_getitem): Add an rvalue reference
15840 check.
15841 (valpy_reference_value): Add new parameter "refcode".
15842 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15843 New wrappers for valpy_reference_value().
15844 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15845 (gdbpy_invoke_xmethod): Likewise.
15846
4297a3f0
AV
158472017-03-20 Artemiy Volkov <artemiyv@acm.org>
15848
15849 PR gdb/14441
15850 * dwarf2read.c (process_die, read_type_die_1): Handle the
15851 DW_TAG_rvalue_reference_type DIE.
15852 (read_tag_reference_type): Add new parameter "refcode".
15853
e1cb3213
AV
158542017-03-20 Artemiy Volkov <artemiyv@acm.org>
15855
15856 PR gdb/14441
15857 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15858 (c_type_print_modifier, c_type_print_varspec_suffix)
15859 (c_type_print_base): Support printing rvalue reference types.
15860 * c-valprint.c (c_val_print, c_value_print): Support printing
15861 rvalue reference values.
15862
e4347c89
AV
158632017-03-20 Artemiy Volkov <artemiyv@acm.org>
15864
15865 PR gdb/14441
15866 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15867 typename.
15868 * cp-support.c (replace_typedefs): Handle
15869 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15870 * python/py-type.c (typy_lookup_type): Likewise.
15871
53cc15f5
AV
158722017-03-20 Artemiy Volkov <artemiyv@acm.org>
15873
15874 PR gdb/14441
15875 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15876 * parse.c (insert_type): Change assert statement.
15877 (follow_types): Handle rvalue reference types.
15878 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15879 constant.
15880
a65cfae5
AV
158812017-03-20 Artemiy Volkov <artemiyv@acm.org>
15882
15883 PR gdb/14441
15884 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15885 value_ref() interface.
15886 * c-valprint.c (c_value_print): Likewise.
15887 * infcall.c (value_arg_coerce): Likewise.
15888 * python/py-value.c (valpy_reference_value): Likewise.
15889 * valops.c (value_cast, value_reinterpret_cast)
15890 (value_dynamic_cast, typecmp): Likewise.
15891 (value_ref): Parameterize by kind of return value reference type.
15892 * value.h (value_ref): Add new parameter "refcode".
15893
3b224330
AV
158942017-03-20 Artemiy Volkov <artemiyv@acm.org>
15895
15896 PR gdb/14441
15897 * dwarf2read.c (read_tag_reference_type): Use
15898 lookup_lvalue_reference_type() instead of lookup_reference_type().
15899 * eval.c (evaluate_subexp_standard): Likewise.
15900 * f-exp.y: Likewise.
15901 * gdbtypes.c (make_reference_type, lookup_reference_type):
15902 Generalize with rvalue reference types.
15903 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15904 convenience wrappers for lookup_reference_type().
15905 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15906 reference kind parameter.
15907 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15908 wrappers for lookup_reference_type().
15909 * guile/scm-type.c (gdbscm_type_reference): Use
15910 lookup_lvalue_reference_type() instead of lookup_reference_type().
15911 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15912 * parse.c (follow_types): Likewise.
15913 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15914 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15915 Likewise.
15916 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15917 (gdbpy_invoke_xmethod): Likewise.
15918 * stabsread.c: Provide extra argument to make_reference_type()
15919 call.
15920 * valops.c (value_ref, value_rtti_indirect_type): Use
15921 lookup_lvalue_reference_type() instead of lookup_reference_type().
15922
f9aeb8d4
AV
159232017-03-20 Artemiy Volkov <artemiyv@acm.org>
15924
15925 PR gdb/14441
15926 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15927 (TYPE_IS_REFERENCE): New macro.
15928 (struct type): Add rvalue_reference_type field.
15929 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15930
51457a05
MAL
159312017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15932
15933 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15934 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15935 New function definition.
15936 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15937 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15938 New function declaration.
15939 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15940 * mi/mi-interp.h: New file.
15941 * solib.c (info_sharedlibrary_command): Replace for loop with
15942 ALL_SO_LIBS macro
15943 * solib.h (update_solib_list): New function declaration.
15944 (so_list_head): Move macro.
15945 * solist.h (ALL_SO_LIBS): New macro.
15946
e696b3ad
MAL
159472017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15948
15949 * infcmd.c (post_create_inferior): Remove unused argument in
15950 call to solib_add.
15951 * remote.c (remote_start_remote): Likewise.
15952 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15953 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15954 (enable_break): Likewise.
15955 * solib.c (update_solib_list): Remove unused target argument
15956 and its documentation.
15957 (solib_add): Remove unused target argument. Remove unused
15958 argument in call to update_solib_list.
15959 (info_sharedlibrary_command): Remove unused argument in call
15960 to update_solib_list.
15961 (sharedlibrary_command): Remove unused argument in call to
15962 solib_add.
15963 (handle_solib_event): Likewise.
15964 (reload_shared_libraries): Likewise.
15965 * solib.h (solib_add): Remove unused target argument.
15966
dcb84eda
AA
159672017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15968
15969 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15970 (s390_displaced_step_fixup): Cover relative branches with the
15971 default fixup handling. This fixes lack of support for some
15972 relative branch instructions.
15973
d9cb6cdc
SM
159742017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15975
15976 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15977 ptid from regcache.
15978
1afaf9f4
SM
159792017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15980
15981 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15982 i386_darwin_store_inferior_registers): Use ptid from regcache.
15983
aac12e24
SM
159842017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15985
15986 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15987 i386bsd_store_inferior_registers): Use ptid from regcache.
15988
bbe1eef1
SM
159892017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15990
15991 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15992 hppaobsd_store_registers): Use ptid from regcache.
15993
10799020
SM
159942017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15995
15996 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15997 hppanbsd_store_registers): Use ptid from regcache.
15998
00204cf7
SM
159992017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
16000
16001 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
16002 from regcache. Use get_ptrace_pid.
16003
11a33714
SM
160042017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
16005
16006 * corelow.c (get_core_register_section): Use ptid from regcache,
16007 update doc.
16008
317cd492
SM
160092017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
16010
16011 * bsd-uthread.c (bsd_uthread_fetch_registers,
16012 bsd_uthread_store_registers): Use ptid from regcache, set and
16013 restore inferior_ptid.
16014
9ac8a7c2
SM
160152017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
16016
16017 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
16018 fetch_fp_regs, store_register, store_regs, store_fp_register,
16019 store_fp_regs): Use ptid from regcache.
16020
4ac4bb6a
SM
160212017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
16022
16023 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
16024 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
16025 store_vfp_regs): Use ptid from regcache.
16026
9bcbdca8
PA
160272017-03-17 Pedro Alves <palves@redhat.com>
16028
16029 PR remote/21188
16030 * ser-base.c (ser_base_wait_for): Add comment.
16031 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
16032 version.
16033 * ser-unix.c (hardwire_raw): Remove reference to
16034 scb->current_timeout.
16035 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
16036 (hardwire_ops): Install ser_base_readchar instead of
16037 hardwire_readchar.
16038 * serial.h (struct serial) <current_timeout, timeout_remaining>:
16039 Remove fields.
16040
7503099f
JG
160412017-03-17 Jonah Graham <jonah@kichwacoders.com>
16042
16043 PR gdb/19637
16044 * python/lib/gdb/printer/bound_registers.py: Add support for
16045 Python 3.
16046
7942e96e
AA
160472017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
16048
16049 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
16050 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
16051 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
16052 byte_offset to subobj_byte_offset. Fix the handling of
16053 DWARF_VALUE_STACK on big-endian targets when coming via an
16054 implicit pointer.
16055 (dwarf2_evaluate_loc_desc): Adjust call to
16056 dwarf2_evaluate_loc_desc_full.
16057 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
16058 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
16059
ba14f379
YQ
160602017-03-16 Yao Qi <yao.qi@linaro.org>
16061
16062 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
16063 and REVSH instructions.
16064
b121eeb9
YQ
160652017-03-16 Yao Qi <yao.qi@linaro.org>
16066
16067 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
16068 (arm_record_test): Declare.
16069 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
16070 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
16071 align with the manual.
16072 (thumb_record_misc): Adjust the code order to align with the
16073 manual.
16074 (thumb2_record_decode_insn_handler): Fix instruction matching.
16075 (instruction_reader_thumb): New class.
16076 (arm_record_test): New function.
16077
728a7913
YQ
160782017-03-16 Yao Qi <yao.qi@linaro.org>
16079
16080 * arm-tdep.c (abstract_memory_reader): New class.
16081 (instruction_reader): New class.
16082 (extract_arm_insn): Add argument 'reader'. Callers updated.
16083 (decode_insn): Likewise.
16084
34b43320
DE
160852017-03-16 Doug Evans <dje@google.com>
16086
a7c0469f
DE
16087 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
16088 member. Change type of TYPE member to SCM. All uses updated.
16089 (lsscm_make_lazy_string_smob): Add assert.
16090 (lsscm_make_lazy_string): Flag bad length values.
16091 (lsscm_elt_type): New function.
16092 (gdbscm_lazy_string_to_value): Rewrite to use
16093 lsscm_safe_lazy_string_to_value.
16094 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
16095 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
16096 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
16097 in incoming type.
16098 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
16099 * guile/scm-type.c (tyscm_scm_to_type): New function.
16100
161012017-03-15 Doug Evans <dje@google.com>
16102
34b43320
DE
16103 PR python/17728, python/18439, python/18779
16104 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
16105 member. Change type of TYPE member to PyObject *. All uses updated.
16106 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
16107 (gdbpy_create_lazy_string_object): Flag bad length values.
16108 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
16109 Handle typedefs in incoming type.
16110 (stpy_lazy_string_elt_type): New function.
16111 (gdbpy_extract_lazy_string): Call it.
16112 * python/py-value.c (valpy_lazy_string): Flag bad length values.
16113 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
16114 typedefs in incoming type.
16115
a3a5fecc
DE
161162017-03-16 Doug Evans <dje@google.com>
16117
16118 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
16119 * guile/scm-type.c (tyscm_scm_to_type): New function.
16120
28f1c605
JW
161212017-03-16 Jiong Wang <jiong.wang@arm.com>
16122
16123 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
16124 "ULONGEST" for "skip".
16125
87c336f6
AA
161262017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
16127
16128 PR gdb/21220
16129 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
16130 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
16131 (inf_ptrace_peek_poke): ...here. New function. Now also loop
16132 over ptrace peek/poke until end of buffer or error.
16133
cf81cf60
SM
161342017-03-14 Simon Marchi <simon.marchi@ericsson.com>
16135
16136 * parse.c (length_of_subexp): Make static.
16137 * parser-defs.h (length_of_subexp): Remove.
16138
a379284a
AA
161392017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
16140
16141 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
16142 as well.
16143
8a6200ba
PA
161442017-03-14 Pedro Alves <palves@redhat.com>
16145
16146 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
16147 (main): Use std::unique_ptr. Remove calls to
16148 cp_demangled_name_parse_free.
16149
f79ec206
SM
161502017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16151
16152 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
16153 alphabsd_store_inferior_registers): Use regcache->ptid instead
16154 of inferior_ptid.
16155
edb5fb00
SM
161562017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16157
16158 * aix-thread.c (aix_thread_fetch_registers,
16159 aix_thread_store_registers): Use regcache->ptid instead of
16160 inferior_ptid.
16161
55119686
SM
161622017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16163
16164 * aarch64-linux-nat.c (fetch_gregs_from_thread,
16165 store_gregs_to_thread, fetch_fpregs_from_thread,
16166 store_fpregs_to_thread): Use regcache->ptid instead of
16167 inferior_ptid.
16168
6a06fbb7
SM
161692017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16170
16171 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
16172 amd64_linux_fetch_inferior_registers): Use regcache->ptid
16173 instead of inferior_ptid.
16174
c6386875
SM
161752017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16176
16177 * target.c (target_fetch_registers, target_store_registers): Add
16178 assert.
16179
ddaaf0fb
SM
161802017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
16181
16182 * regcache.h (regcache_get_ptid): New function.
16183 * regcache.c (regcache_get_ptid): New function.
16184
b9da89d1 161852017-03-13 Mark Wielaard <mark@klomp.org>
16186
16187 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
16188
5f4d1085
KS
161892017-03-10 Keith Seitz <keiths@redhat.com>
16190
16191 PR c++/8218
16192 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
16193
c65d6b55
PA
161942017-03-08 Pedro Alves <palves@redhat.com>
16195
16196 PR gdb/18360
16197 * infrun.c (start_step_over, do_target_resume, resume)
16198 (restart_threads): Assert we're not resuming a thread that is
16199 meant to be stopped.
16200 (infrun_thread_stop_requested_callback): Delete.
16201 (infrun_thread_stop_requested): If the thread is internally
16202 stopped, queue a pending stop event and clear the thread's
16203 inline-frame state.
16204 (handle_stop_requested): New function.
16205 (handle_syscall_event, handle_inferior_event_1): Use
16206 handle_stop_requested.
16207 (handle_stop_requested): New function.
16208 (handle_signal_stop): Set the thread's stop_signal here instead of
16209 at caller.
16210 (finish_step_over): Clear step over info unconditionally.
16211 (handle_signal_stop): If the user had interrupted the event
16212 thread, consider the stop a random signal.
16213 (handle_signal_stop) <signal arrived while stepping over
16214 breakpoint>: Don't restart threads here.
16215 (stop_waiting): Don't clear step-over info here.
16216
15c22686
PA
162172017-03-08 Pedro Alves <palves@redhat.com>
16218
16219 PR 21206
16220 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
16221 goes to argument 2, not 1.
16222
6e5d74e7
PA
162232017-03-08 Pedro Alves <palves@redhat.com>
16224
16225 PR cli/21218
16226 * top.c (gdb_readline_wrapper): Avoid passing NULL to
16227 display_gdb_prompt.
16228 (command_line_input): Add comment.
16229
9753a2f6
PA
162302017-03-08 Pedro Alves <palves@redhat.com>
16231
16232 PR tui/21216
16233 * tui/tui-file.c (tui_file::write): New.
16234 * tui/tui-file.h (tui_file): Override "write".
16235 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
16236 factored out from ...
16237 (tui_puts): ... here.
16238 (tui_putc): Use them.
16239 (tui_write): New function.
16240 * tui/tui-io.h (tui_write): Declare.
16241
1672e0d9
SDJ
162422017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
16243
16244 * Makefile.in (SFILES): Replace "environ.c" with
16245 "common/environ.c".
16246 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
16247 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
16248 to...
16249 * common/environ.c: ... here.
16250 * environ.h: Moved to...
16251 * common/environ.h: ... here.
16252
f7bb4e3a
PB
162532017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16254
16255 * gdbarch.sh (pstring_ptr): New static function.
16256 (gdbarch_disassembler_options): Use it.
16257 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
16258 not valid_disassembler_option->name.
16259 * gdbarch.c: Regenerate.
16260
e45ced6c
PB
162612017-03-07 Peter Bergner <bergner@vnet.ibm.com>
16262
16263 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
16264
5f6fd321
PA
162652017-03-07 Pedro Alves <palves@redhat.com>
16266
16267 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
16268
6dbb839a 162692017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
16270
16271 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
16272 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
16273 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 16274 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 16275
d274ecf4
SM
162762017-03-06 Simon Marchi <simon.marchi@ericsson.com>
16277
16278 * xtensa-linux-nat.c (fetch_gregs): Remove const.
16279
df97be55
SM
162802017-03-03 Simon Marchi <simon.marchi@ericsson.com>
16281
16282 * remote.c (remote_add_target_side_commands): Use range-based
16283 for loop.
16284
7d45f3df
YQ
162852017-03-03 Yao Qi <yao.qi@linaro.org>
16286
16287 PR gdb/21165
16288 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
16289 value is lazy.
16290 * valprint.c (common_val_print): Likewise.
16291
65b48a81
PB
162922017-02-28 Peter Bergner <bergner@vnet.ibm.com>
16293
16294 * NEWS: Mention new set/show disassembler-options commands.
16295 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
16296 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
16297 (prospective_options): New static variable.
16298 (gdb_disassembler::gdb_disassembler): Initialize
16299 m_di.disassembler_options.
16300 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
16301 (get_disassembler_options): New function.
16302 (set_disassembler_options): Likewise.
16303 (set_disassembler_options_sfunc): Likewise.
16304 (show_disassembler_options_sfunc): Likewise.
16305 (disassembler_options_completer): Likewise.
16306 (_initialize_disasm): Likewise.
16307 * disasm.h (get_disassembler_options): New prototype.
16308 (set_disassembler_options): Likewise.
16309 * gdbarch.sh (gdbarch_disassembler_options): New variable.
16310 (gdbarch_verify_disassembler_options): Likewise.
16311 * gdbarch.c: Regenerate.
16312 * gdbarch.h: Likewise.
16313 * arm-tdep.c (num_disassembly_options): Delete.
16314 (set_disassembly_style): Likewise.
16315 (arm_disassembler_options): New static variable.
16316 (set_disassembly_style_sfunc): Convert short style name into long
16317 option name. Call set_disassembler_options.
16318 (show_disassembly_style_sfunc): New function.
16319 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
16320 set_gdbarch_verify_disassembler_options.
16321 (_initialize_arm_tdep): Delete regnames variable and update callers.
16322 (arm_disassembler_options): Initialize.
16323 (disasm_options): New variable.
16324 (num_disassembly_options): Rename from this...
16325 (num_disassembly_styles): ...to this. Compute by scanning through
16326 disasm_options.
16327 (valid_disassembly_styles): Initialize using disasm_options.
16328 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
16329 set_arm_regname_option.
16330 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
16331 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
16332 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
16333 set_gdbarch_verify_disassembler_options.
16334 * s390-tdep.c (s390_disassembler_options): New static variable.
16335 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
16336 set_gdbarch_verify_disassembler_options.
16337
d538e36d
SM
163382017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16339
16340 * remote.c (remote_add_target_side_condition): Remove "struct"
16341 keyword from range-based for loop.
16342
83621223
SM
163432017-02-27 Simon Marchi <simon.marchi@ericsson.com>
16344
16345 * remote.c (remote_add_target_side_condition): Use range-based
16346 for loop. Update comment.
16347
2123df0e
YQ
163482017-02-27 Yao Qi <yao.qi@linaro.org>
16349
16350 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
16351
8e368124
AH
163522017-02-26 Alan Hayward <alan.hayward@arm.com>
16353
16354 * regcache.c (regcache_raw_update): New function.
16355 (regcache_raw_read): Move code to regcache_raw_update.
16356 * regcache.h (regcache_raw_update): New declaration.
16357 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
16358
a49dd8dd
JK
163592017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
16360
16361 * dwarf2read.c (create_debug_type_hash_table): Initialize
16362 header.signature and header.type_offset_in_tu.
16363
34e4bae9
PA
163642017-02-24 Pedro Alves <palves@redhat.com>
16365
16366 * symtab.c (make_file_symbol_completion_list_1): Use
16367 add_symtab_completions.
16368
b0e4b369
AH
163692017-02-24 Alan Hayward <alan.hayward@arm.com>
16370
16371 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
16372
975c21ab
AH
163732017-02-24 Alan Hayward <alan.hayward@arm.com>
16374
16375 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
16376 I386_MAX_REGISTER_SIZE.
16377 (i386_pseudo_register_write): Likewise.
16378 (i386_process_record): Likewise.
16379 * i387-tdep.c (i387_supply_xsave): Likewise.
16380 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
16381 (store_register): Likewise.
16382
14bc53a8
PA
163832017-02-23 Pedro Alves <palves@redhat.com>
16384
16385 * ada-lang.c: Include "common/function-view.h".
16386 (ada_iterate_over_symbols): Adjust to use function_view as
16387 callback type.
16388 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
16389 (ada_make_symbol_completion_list): Use a lambda.
16390 (ada_exc_search_name_matches): Delete.
16391 (name_matches_regex): New.
16392 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
16393 * compile/compile-c-support.c: Include "common/function-view.h".
16394 (print_one_macro): Change prototype to accept a ui_file pointer.
16395 (write_macro_definitions): Use a lambda.
16396 * dwarf2read.c: Include "common/function-view.h".
16397 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
16398 (dw2_expand_symtabs_matching): Adjust to use function_view as
16399 callback type.
16400 * language.h: Include "common/function-view.h".
16401 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
16402 function_view as callback type.
16403 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
16404 * linespec.c: Include "common/function-view.h".
16405 (collect_info::add_symbol): New method.
16406 (struct symbol_and_data_callback, iterate_inline_only, struct
16407 symbol_matcher_data, iterate_name_matcher): Delete.
16408 (iterate_over_all_matching_symtabs): Adjust to use function_view
16409 as callback type and lambdas.
16410 (iterate_over_file_blocks): Adjust to use function_view as
16411 callback type.
16412 (decode_compound_collector): Now a class with private fields.
16413 (decode_compound_collector::release_symbols): New method.
16414 (collect_one_symbol): Rename to...
16415 (decode_compound_collector::operator()): ... this and adjust.
16416 (lookup_prefix_sym): decode_compound_collector construction bits
16417 move to decode_compound_collector ctor. Pass the
16418 decode_compound_collector object directly as callback. Remove
16419 cleanups and use decode_compound_collector::release_symbols
16420 instead.
16421 (symtab_collector): Now a class with private fields.
16422 (symtab_collector::release_symtabs): New method.
16423 (add_symtabs_to_list): Rename to...
16424 (symtab_collector::operator()): ... this and adjust.
16425 (collect_symtabs_from_filename): symtab_collector construction
16426 bits move to symtab_collector ctor. Pass the symtab_collector
16427 object directly as callback. Remove cleanups and use
16428 symtab_collector::release_symtabs instead.
16429 (collect_symbols): Delete.
16430 (add_matching_symbols_to_info): Use lambdas.
16431 * macrocmd.c (print_macro_callback): Delete.
16432 (info_macro_command): Use a lambda.
16433 (info_macros_command): Pass print_macro_definition as callable
16434 directly.
16435 (print_one_macro): Remove 'ignore' parameter.
16436 (macro_list_command): Adjust.
16437 * macrotab.c (macro_for_each_data::fn): Now a function_view.
16438 (macro_for_each_data::user_data): Delete field.
16439 (foreach_macro): Adjust to call the function_view.
16440 (macro_for_each): Adjust to use function_view as callback type.
16441 (foreach_macro_in_scope): Adjust to call the function_view.
16442 (macro_for_each_in_scope): Adjust to use function_view as callback
16443 type.
16444 * macrotab.h: Include "common/function-view.h".
16445 (macro_callback_fn): Declare a prototype instead of a pointer.
16446 Remove "user_data" parameter.
16447 (macro_for_each, macro_for_each_in_scope): Adjust to use
16448 function_view as callback type.
16449 * psymtab.c (partial_map_expand_apply)
16450 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
16451 Adjust to use function_view as callback type and to return bool.
16452 (psym_expand_symtabs_matching): Adjust to use function_view as
16453 callback types.
16454 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
16455 to use function_view as callback type and to return bool.
16456 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
16457 callback types.
16458 * symfile.c (expand_symtabs_matching): Adjust to use function_view
16459 as callback types.
16460 * symfile.h: Include "common/function-view.h".
16461 (expand_symtabs_file_matcher_ftype)
16462 (expand_symtabs_symbol_matcher_ftype)
16463 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
16464 return bool.
16465 (quick_symbol_functions::map_symtabs_matching_filename)
16466 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
16467 function_view as callback type and return bool.
16468 (expand_symtabs_matching): Adjust to use function_view as callback
16469 type.
16470 (maintenance_expand_name_matcher)
16471 (maintenance_expand_file_matcher): Delete.
16472 (maintenance_expand_symtabs): Use lambdas.
16473 * symtab.c (iterate_over_some_symtabs): Adjust to use
16474 function_view as callback types and return bool.
16475 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
16476 of a cleanup.
16477 (lookup_symtab_callback): Delete.
16478 (lookup_symtab): Use a lambda.
16479 (iterate_over_symbols): Adjust to use function_view as callback
16480 type.
16481 (struct search_symbols_data, search_symbols_file_matches)
16482 (search_symbols_name_matches): Delete.
16483 (search_symbols): Use a pair of lambdas.
16484 (struct add_name_data, add_macro_name, symbol_completion_matcher)
16485 (symtab_expansion_callback): Delete.
16486 (default_make_symbol_completion_list_break_on_1): Use lambdas.
16487 * symtab.h: Include "common/function-view.h".
16488 (iterate_over_some_symtabs): Adjust to use function_view as
16489 callback type and return bool.
16490 (iterate_over_symtabs): Adjust to use function_view as callback
16491 type.
16492 (symbol_found_callback_ftype): Remove 'data' parameter and return
16493 bool.
16494 (iterate_over_symbols): Adjust to use function_view as callback
16495 type.
16496
07e253aa
PA
164972017-02-23 Pedro Alves <palves@redhat.com>
16498
16499 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
16500 (%.o) <unittests/%.c>: New pattern.
16501 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
16502 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
16503 * common/function-view.h: New file.
16504 * unittests/function-view-selftests.c: New file.
16505 * configure: Regenerate.
16506
8eaf5320
SM
165072017-02-23 Simon Marchi <simon.marchi@ericsson.com>
16508
16509 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
16510 inferior_ptid.
16511 * go32-nat.c (go32_thread_alive): Likewise.
16512
38768751
YQ
165132017-02-23 Yao Qi <yao.qi@linaro.org>
16514
16515 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
16516 delete.
16517
0a8beaba
YQ
165182017-02-23 Yao Qi <yao.qi@linaro.org>
16519
16520 * varobj.c (varobj_clear_saved_item): Use delete instead of
16521 xfree.
16522 (update_dynamic_varobj_children): Likewise.
16523
58fdfd2c
JK
165242017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16525
16526 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
16527
1b90b139
SM
165282017-02-21 Simon Marchi <simon.marchi@ericsson.com>
16529
16530 * common/enum-flags.h (enum_flags::enum_flags): Initialize
16531 m_enum_value to 0 in default constructor.
16532
2039d74e
EBM
165332017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
16534
16535 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
16536 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
16537 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
16538 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
16539 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
16540 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
16541 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
16542 IS_STORE_CONDITIONAL_INSN.
16543
7814882a
JK
165442017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16545
16546 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
16547
0ae60b63
JK
165482017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16549
16550 * NEWS (Changes since GDB 7.12): Add DWARF-5.
16551
0224619f
JK
165522017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16553
16554 * dwarf2read.c (skip_one_die, read_attribute_value)
16555 (dwarf2_const_value_attr, dump_die_shallow)
16556 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
16557 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
16558
0af92d60
JK
165592017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16560
16561 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
16562 (dwarf_parse_macro_header): Accept DWARF version 5.
16563 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
16564
216f72a1
JK
165652017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16566
16567 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
16568 DW_AT_GNU_*.
16569 * common/common-exceptions.h (enum errors): Likewise.
16570 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
16571 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
16572 (dwarf_expr_context::execute_stack_op): Likewise.
16573 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
16574 Likewise.
16575 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
16576 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
16577 (show_entry_values_debug, call_site_to_target_addr)
16578 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
16579 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
16580 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
16581 (value_of_dwarf_block_entry, indirect_pieced_value)
16582 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
16583 (disassemble_dwarf_expression): Likewise.
16584 * dwarf2read.c (process_die, inherit_abstract_dies)
16585 (read_call_site_scope): Likewise.
16586 * gdbtypes.h (struct func_type, struct call_site_parameter)
16587 (struct call_site): Likewise.
16588 * stack.c (read_frame_arg): Likewise.
16589 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
16590
43988095
JK
165912017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16592
16593 * defs.h (read_unsigned_leb128): New declaration.
16594 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
16595 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
16596 (dwarf2_find_location_expression): Call also
16597 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
16598 * dwarf2loc.h (dwarf2_version): New declaration.
16599 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
16600 rnglists.
16601 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
16602 .debug_rnglists.
16603 (struct dwop_section_names): Add loclists_dwo.
16604 (dwop_section_names): Add .debug_loclists.dwo.
16605 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
16606 (struct dwarf2_per_cu_data): Add dwarf_version.
16607 (struct dwo_sections): Add loclists.
16608 (struct attr_abbrev): Add implicit_const.
16609 (read_indirect_line_string): New declaration.
16610 (read_unsigned_leb128): Delete declaration.
16611 (rcuh_kind): New definition.
16612 (read_and_check_comp_unit_head): Change parameter
16613 is_debug_types_section to section_kind.
16614 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
16615 (read_comp_unit_head): Change parameter abfd to section, add parameter
16616 section_kind. Handle DWARF-5.
16617 (error_check_comp_unit_head): Accept also DWARF version 5.
16618 (read_and_check_comp_unit_head): Change parameter
16619 is_debug_types_section to section_kind.
16620 (read_and_check_type_unit_head): Delete function.
16621 (read_abbrev_offset): Handle DWARF-5.
16622 (create_debug_type_hash_table): Add parameter section_kind. Process
16623 only DW_UT_type. Use signature and type_offset_in_tu from struct
16624 comp_unit_head.
16625 (create_debug_types_hash_table): Update create_debug_type_hash_table
16626 caller.
16627 (create_all_type_units): Call create_debug_type_hash_table.
16628 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
16629 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
16630 caller.
16631 (skip_one_die): Handle DW_FORM_implicit_const.
16632 (dwarf2_rnglists_process): New function.
16633 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
16634 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
16635 (read_attribute_value): Handle DW_FORM_implicit_const,
16636 DW_FORM_line_strp.
16637 (read_attribute): Handle DW_FORM_implicit_const.
16638 (read_indirect_string_at_offset_from): New function from
16639 read_indirect_string_at_offset.
16640 (read_indirect_string_at_offset): Call
16641 read_indirect_string_at_offset_from.
16642 (read_indirect_line_string_at_offset): New function.
16643 (read_indirect_string): New function comment.
16644 (read_indirect_line_string): New function.
16645 (read_unsigned_leb128): Make it global.
16646 (dwarf2_string_attr): Handle DWARF-5.
16647 (add_include_dir_stub, read_formatted_entries): New functions.
16648 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
16649 Handle DWARF-5.
16650 (per_cu_header_read_in): Update read_comp_unit_head caller.
16651 (dwarf2_version): New function.
16652 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
16653 rnglists.
16654 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16655 fields.
16656
22d2f3ab
JK
166572017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16658
16659 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16660
5f46c5a5
JK
166612017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16662
16663 * dwarf2read.c (dwarf2_ranges_process): New function from
16664 dwarf2_ranges_read.
16665 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16666 dwarf2_ranges_process.
16667
78d4d2c5
JK
166682017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16669
16670 * dwarf2read.c (create_debug_type_hash_table): New function from
16671 create_debug_types_hash_table.
16672 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16673 (create_all_type_units, open_and_init_dwo_file): Update
16674 create_debug_types_hash_table callers.
16675
1b076f25
SDJ
166762017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16677
16678 PR gdb/16188
16679 * fork-child.c (trace_start_error): Fix thinko. va_end should
16680 refer to 'ap', not 'args'.
16681
0db8980c
SDJ
166822017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16683 Pedro Alves <palves@redhat.com>
16684
16685 PR gdb/16188
16686 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16687 calls succeeded.
16688 * fork-child.c (trace_start_error): New function.
16689 (trace_start_error_with_name): Likewise.
16690 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16691 * inf-ptrace.c (inf_ptrace_me): Likewise.
16692 * inferior.h (trace_start_error): New prototype.
16693 (trace_start_error_with_name): Likewise.
16694
99e8a4f9
SDJ
166952017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16696
16697 PR gdb/21164
16698 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16699 NULL before using it.
16700 * symmisc.c (maintenance_print_symbols): Likewise.
16701 (maintenance_print_msymbols): Likewise.
16702
4e746bb6
TW
167032017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16704
16705 * NEWS: Add record Python bindings entry.
16706
167072017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16708
16709 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16710 py-record-full.o.
16711 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16712 * python/py-record-btrace.c, python/py-record-btrace.h,
16713 python/py-record-full.c, python/py-record-full.h: New file.
16714 * python/py-record.c: Add include for py-record-btrace.h and
16715 py-record-full.h.
16716 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16717 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16718 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16719 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16720 New definition.
16721 (gdbpy_initialize_btrace): New export.
16722 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16723
167242017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16725
16726 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16727 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16728 * python/py-record.c: New file.
16729 * python/python-internal.h (gdbpy_start_recording,
16730 gdbpy_current_recording, gdpy_stop_recording,
16731 gdbpy_initialize_record): New export.
16732 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16733 (python_GdbMethods): Add gdbpy_start_recording,
16734 gdbpy_current_recording and gdbpy_stop_recording.
16735
167362017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16737
16738 * record-btrace.c (record_btrace_record_method): New function.
16739 (init_record_btrace_ops): Initialize to_record_method.
16740 * record-full.c (record_full_record_method): New function.
16741 (init_record_full_ops, init_record_full_core_ops): Add
16742 record_full_record_method.
16743 * record.h (enum record_method): New enum.
16744 * target-debug.h (target_debug_print_enum_record_method: New define.
16745 * target-delegates.c: Regenerate.
16746 * target.c (target_record_method): New function.
16747 * target.h: Include record.h.
16748 (struct target_ops) <to_record_method>: New field.
16749 (target_record_method): New export.
16750
167512017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16752
16753 * record.h (record_start, record_stop): New export.
16754 * record.c (record_start, record_stop): New function.
16755
167562017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16757
16758 * btrace.c (btrace_fetch): Copy function call segments pointer
16759 into a vector.
16760 (btrace_clear): Clear the vector.
16761 (btrace_find_insn_by_number): Use binary search to find the correct
16762 function call segment.
16763 * btrace.h (brace_fun_p): New typedef.
16764 (struct btrace_thread_info) <functions>: New field.
16765
167662017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16767
16768 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16769 * btrace.c (btrace_decode_error): ... here. New function.
16770 * btrace.h (btrace_decode_error): New export.
16771
167722017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16773
16774 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16775 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16776 btrace_find_insn_by_number): Remove special case for gaps.
16777 * btrace.h (btrace_insn_get_error): New export.
16778 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16779 * record-btrace.c (btrace_insn_history): Print number for gaps.
16780 (record_btrace_info, record_btrace_goto): Handle gaps.
16781
3f77c769
TT
167822017-02-14 Tom Tromey <tom@tromey.com>
16783
16784 PR python/13598:
16785 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16786 event.
16787 * python/py-evts.c (gdbpy_initialize_py_events): Add
16788 before_prompt registry.
16789 * python/py-events.h (events_object) <before_prompt>: New field.
16790
4c2c7ac6
MM
167912017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16792
16793 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16794
5cf30ebf
LM
167952017-02-13 Luis Machado <lgustavo@codesourcery.com>
16796
16797 * symfile (_initialize_symfile): Add usage text to the load command's
16798 help text.
16799
26a06916
SM
168002017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16801
16802 * utils.c (defaulted_query): Don't query on secondary UIs.
16803
0b145e37
TT
168042017-02-10 Tom Tromey <tom@tromey.com>
16805
16806 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16807
2d8365c4
TT
168082017-02-10 Tom Tromey <tom@tromey.com>
16809
16810 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16811 "cleanup" local.
16812 * python/py-type.c (typy_legacy_template_argument): Remove
16813 unnecessary "cleanup" local.
16814
2bb8f231
TT
168152017-02-10 Tom Tromey <tom@tromey.com>
16816
16817 * python/python.c (do_start_initialization): New function, from
16818 _initialize_python.
16819 (_initialize_python): Call do_start_initialization.
16820 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16821 goto.
16822
1bdfaf42
TT
168232017-02-10 Tom Tromey <tom@tromey.com>
16824
16825 * python/py-prettyprint.c (pretty_print_one_value): Use
16826 gdbpy_ref.
16827
88b6faea
TT
168282017-02-10 Tom Tromey <tom@tromey.com>
16829
16830 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16831 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16832 gdbpy_ref.
16833 * python/py-type.c (field_new): Use gdbpy_ref.
16834 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16835 gdbpy_ref.
16836 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16837 (py_free_pspace): Likewise.
16838 (pspace_to_pspace_object): Likewise.
16839 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16840 (py_free_objfile): Likewise.
16841 (objfile_to_objfile_object): Likewise.
16842 * python/py-inferior.c (delete_thread_object): Use
16843 gdbpy_ref.
16844 (infpy_read_memory): Likewise.
16845 (py_free_inferior): Likewise.
16846 * python/py-evtregistry.c (create_eventregistry_object): Use
16847 gdbpy_ref.
16848 * python/py-event.c (create_event_object): Use gdbpy_ref.
16849
7780f186
TT
168502017-02-10 Tom Tromey <tom@tromey.com>
16851
16852 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16853 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16854 used.
16855 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16856 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16857 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16858 python/py-framefilter.c, python/py-function.c,
16859 python/py-inferior.c, python/py-infevents.c,
16860 python/py-linetable.c, python/py-newobjfileevent.c,
16861 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16862 python/py-signalevent.c, python/py-stopevent.c,
16863 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16864 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16865 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16866 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16867
d4b0bb18
TT
168682017-02-10 Tom Tromey <tom@tromey.com>
16869
16870 * ui-out.h (ui_out_emit_type): New class.
16871 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16872 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16873 and ui_out_emit_tuple.
16874 (enumerate_locals): Likewise.
16875 (py_mi_print_variables, py_print_locals, py_print_args): Use
16876 ui_out_emit_list.
16877 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16878 ui_out_emit_list.
16879 * common/gdb_optional.h: New file.
16880
f67f945c
MG
168812017-02-10 Martin Galvan <martingalvan@sourceware.org>
16882
16883 * MAINTAINERS (Write After Approval): Update my e-mail address.
16884
18da0c51
MG
168852017-02-10 Martin Galvan <martingalvan@sourceware.org>
16886
16887 PR gdb/21122
16888 * breakpoint.c (_initialize_breakpoint): Update the help description
16889 of the 'commands' command to indicate that it takes a list argument.
16890
62c14536
SM
168912017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16892
16893 * interps.c (current_interp_set_logging): Remove "return".
16894
ff6fa247
GB
168952017-02-09 Gary Benson <gbenson@redhat.com>
16896
16897 * symtab.c (add_symtab_completions): Prevent NULL pointer
16898 dereference.
16899
a474bd8e
PA
169002017-02-08 Pedro Alves <palves@redhat.com>
16901
16902 * interps.c (interp::interp): Remove reference to quiet_p.
16903 (interp_set): Make static. Remove dead "Switching to" output
16904 code.
16905 (interp_quiet_p, interp_set_quiet): Delete.
16906 (interpreter_exec_cmd): Don't set the interpreter quiet.
16907 * interps.h (interp_quiet_p): Make static.
16908 (class interp) <quiet_p>: Remove field
16909
3d7b173c
JG
169102017-02-08 Jerome Guitton <guitton@adacore.com>
16911
604c4576
JG
16912 * cli/cli-decode.c (find_command_name_length): Make it extern.
16913 * cli/cli-decode.h (find_command_name_length): Declare.
16914 * cli/cli-script.c (command_name_equals, line_first_arg):
16915 New functions.
16916 (process_next_line): Use cli-decode to parse command names.
16917 (build_command_line): Make args a constant pointer.
16918
169192017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 16920
3d7b173c
JG
16921 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16922 Remove case-insensitive search.
16923
1291063d
JM
169242017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16925
16926 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16927 at the end of the line. Avoids an ARI warning.
16928
20b477a7
LM
169292017-02-06 Luis Machado <lgustavo@codesourcery.com>
16930
16931 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16932 rdseed instructions.
16933 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16934
3f7b46f2
IR
169352017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16936
16937 PR tdep/20936
16938 Provide and use sparc32 and sparc64 target description XML files.
16939 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16940 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16941 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16942 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16943 * features/sparc/sparc32-solaris.xml: New file.
16944 * features/sparc/sparc64-solaris.xml: New file.
16945 * features/sparc/sparc32-solaris.c: Generated.
16946 * features/sparc/sparc64-solaris.c: Generated.
16947 * sparc-tdep.h: Account for differences in target descriptions.
16948 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16949 (sparc32_register_type): Use target provided registers.
16950 (validate_tdesc_registers): New function.
16951 (sparc32_gdbarch_init): Use tdesc_has_registers.
16952 Set pseudoregister functions.
16953 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16954 (sparc64_register_type): Use target provided registers.
16955 (sparc64_init_abi): Set pseudoregister functions.
16956
f0fd41c1
TT
169572017-02-03 Tom Tromey <tom@tromey.com>
16958
16959 PR rust/21097:
16960 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16961 with a single member.
16962
d6f9b0fb
PA
169632017-02-03 Pedro Alves <palves@redhat.com>
16964
16965 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16966 (cli_interp_base::~cli_interp_base): New.
16967 (cli_interp): New struct.
16968 (as_cli_interp): Cast the interp itself to cli_interp.
16969 (cli_interpreter_pre_command_loop): Rename to ...
16970 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16971 parameter.
16972 (cli_interpreter_init): Rename to ...
16973 (cli_interp::init): ... this. Remove 'self' parameter. Use
16974 boolean. Make extern.
16975 (cli_interpreter_resume): Rename to ...
16976 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16977 extern.
16978 (cli_interpreter_suspend): Rename to ...
16979 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16980 extern.
16981 (cli_interpreter_exec): Rename to ...
16982 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16983 extern.
16984 (cli_interpreter_supports_command_editing): Rename to ...
16985 (cli_interp_base::supports_command_editing): ... this. Remove
16986 'interp' parameter. Make extern.
16987 (cli_ui_out): Rename to ...
16988 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16989 Make extern.
16990 (cli_set_logging): Rename to ...
16991 (cli_interp_base::set_logging): ... this. Remove 'interp'
16992 parameter. Make extern.
16993 (cli_interp_procs): Delete.
16994 (cli_interp_factory): Adjust to use "new".
16995 * cli/cli-interp.h: Include "interps.h".
16996 (struct cli_interp_base): New struct.
16997 * interps.c (struct interp): Delete. Fields moved to interps.h.
16998 (interp_new): Delete.
16999 (interp::interp, interp::~interp): New.
17000 (interp_set): Use bool, and return void. Assume the interpreter
17001 has suspend, init and resume methods, and that the all return
17002 void.
17003 (set_top_level_interpreter): interp_set returns void.
17004 (interp_ui_out): Adapt.
17005 (current_interp_set_logging): Adapt.
17006 (interp_data): Delete.
17007 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
17008 (interp_exec): Adapt.
17009 (top_level_interpreter_data): Delete.
17010 * interps.h (interp_init_ftype, interp_resume_ftype)
17011 (interp_suspend_ftype, interp_exec_ftype)
17012 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
17013 (class interp): New.
17014 (interp_new): Delete.
17015 (interp_set): Now returns void. Use bool.
17016 (interp_data, top_level_interpreter_data): Delete.
17017 * mi/mi-common.h: Include interps.h.
17018 (class mi_interp): Inherit from interp. Define a ctor. Declare
17019 init, resume, suspect, exec, interp_ui_out, set_logging and
17020 pre_command_loop methods.
17021 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
17022 (mi_interpreter_init): Rename to ...
17023 (mi_interp::init): ... this. Remove the 'interp' parameter, use
17024 bool, return void and make extern. Adjust.
17025 (mi_interpreter_resume): ... Rename to ...
17026 (mi_interp::resume): ... this. Remove the 'data' parameter,
17027 return void and make extern. Adjust.
17028 (mi_interpreter_suspend): ... Rename to ...
17029 (mi_interp::suspend): ... this. Remove the 'data' parameter,
17030 return void and make extern. Adjust.
17031 (mi_interpreter_exec): ... Rename to ...
17032 (mi_interp::exec): ... this. Remove the 'data' parameter and make
17033 extern. Adjust.
17034 (mi_interpreter_pre_command_loop): ... Rename to ...
17035 (mi_interp::pre_command_loop): ... this. Remove the 'self'
17036 parameter and make extern.
17037 (mi_on_normal_stop_1): Adjust.
17038 (mi_ui_out): Rename to ...
17039 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
17040 parameter and make extern. Adjust.
17041 (mi_set_logging): Rename to ...
17042 (mi_interp::set_logging): ... this. Remove the 'interp'
17043 parameter and make extern. Adjust.
17044 (mi_interp_procs): Delete.
17045 (mi_interp_factory): Adjust to use 'new'.
17046 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
17047 (mi_print_exception, mi_execute_command, mi_load_progress):
17048 Adjust.
17049 * tui/tui-interp.c (tui_interp): New class.
17050 (as_tui_interp): Return a tui_interp pointer.
17051 (tui_on_normal_stop, tui_on_signal_received)
17052 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
17053 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
17054 to use interp::interp_ui_out.
17055 (tui_init): Rename to ...
17056 (tui_interp::init): ... this. Remove the 'self' parameter, use
17057 bool, return void and make extern. Adjust.
17058 (tui_resume): Rename to ...
17059 (tui_interp::resume): ... this. Remove the 'data' parameter,
17060 return void and make extern. Adjust.
17061 (tui_suspend): Rename to ...
17062 (tui_interp::suspend): ... this. Remove the 'data' parameter,
17063 return void and make extern. Adjust.
17064 (tui_ui_out): Rename to ...
17065 (tui_interp::interp_ui_out): ... this. Remove the 'self'
17066 parameter, and make extern. Adjust.
17067 (tui_exec): Rename to ...
17068 (tui_interp::exec): ... this. Remove the 'data' parameter and
17069 make extern.
17070 (tui_interp_procs): Delete.
17071 (tui_interp_factory): Use "new".
17072
65c40c95
TT
170732017-02-02 Tom Tromey <tom@tromey.com>
17074
17075 * rust-exp.y (ends_raw_string, space_then_number)
17076 (rust_identifier_start_p): Return bool.
17077 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
17078 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
17079 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
17080 (rust_chartype_p): Return bool.
17081 (val_print_struct, rust_print_struct_def, rust_print_type):
17082 Update.
17083 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
17084 Return bool.
17085
b50f188d
TT
170862017-02-02 Tom Tromey <tom@tromey.com>
17087
17088 * rust-lang.c: Reindent.
17089
03c85b11
TT
170902017-02-02 Tom Tromey <tom@tromey.com>
17091
17092 * rust-lang.h (rust_crate_for_block): Update.
17093 * rust-lang.c (rust_crate_for_block): Return std::string.
17094 (rust_get_disr_info): Use std:;string, not
17095 gdb::unique_xmalloc_ptr.
17096 * rust-exp.y (crate_name): Update.
17097
9b6da501
PA
170982017-02-02 Pedro Alves <palves@redhat.com>
17099
17100 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
17101 field out of gdb_disassembler_test and make it static.
17102
ec4cb20b
PA
171032017-02-02 Pedro Alves <palves@redhat.com>
17104
17105 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
17106 mi1_interp and mi_interp fields.
17107
5be5dbf0
PA
171082017-02-02 Pedro Alves <palves@redhat.com>
17109
616268b6
PA
17110 * cli/cli-interp.c (struct saved_output_files, saved_output):
17111 Moved from cli/cli-logging.c.
17112 (cli_set_logging): New function.
17113 (cli_interp_procs): Install cli_set_logging.
17114 * cli/cli-interp.h (make_logging_output, cli_set_logging):
17115 Declare.
17116 * cli/cli-logging.c (struct saved_output_files, saved_output):
17117 Moved to cli/cli-interp.c.
17118 (pop_output_files): Don't save outputs here.
17119 (make_logging_output): New function.
17120 (handle_redirections): Don't build tee nor save previous outputs
17121 here.
17122 * interps.c (current_interp_set_logging): Change prototype.
17123 Assume there's always a set_logging_proc method installed.
17124 * interps.h (interp_set_logging_ftype): Change prototype.
17125 (current_interp_set_logging): Change prototype and adjust comment.
17126 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
17127 use make_logging_output.
17128 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
171292017-02-02 Pedro Alves <palves@redhat.com>
17130
5be5dbf0
PA
17131 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
17132 from ...
17133 (set_logging_overwrite): ... here.
17134 (logging_no_redirect_file): Delete.
17135 (set_logging_redirect): Don't handle redirection on the fly.
17136 Instead warn that "logging off" / "logging on" is necessary.
17137 (pop_output_files): Delete references to logging_no_redirect_file.
17138 (show_logging_command): Always speak in terms of what will happen
17139 once logging is reenabled.
17140
c99cc448
PA
171412017-02-02 Pedro Alves <palves@redhat.com>
17142
17143 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
17144
8b172ce7
PA
171452017-02-02 Pedro Alves <palves@redhat.com>
17146
17147 * disasm.c (gdb_pretty_print_insn): Rename to ...
17148 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
17149 Remove gdbarch parameter. Adapt to clear the object's buffers
17150 instead of allocating new buffers, and to print using the object's
17151 gdb_disassembler instead of calling gdb_print_insn.
17152 (dump_insns): Use gdb_pretty_print_disassembler.
17153 * disasm.h (gdb_pretty_print_insn): Delete declaration.
17154 (gdb_pretty_print_disassembler): New class.
17155 * record-btrace.c (btrace_insn_history): Use
17156 gdb_pretty_print_disassembler.
17157
d7e74731
PA
171582017-02-02 Pedro Alves <palves@redhat.com>
17159
17160 * ada-lang.c (type_as_string): Use string_file.
17161 * ada-valprint.c (ada_print_floating): Use string_file.
17162 * ada-varobj.c (ada_varobj_scalar_image)
17163 (ada_varobj_get_value_image): Use string_file.
17164 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
17165 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
17166 * breakpoint.c (update_inserted_breakpoint_locations)
17167 (insert_breakpoint_locations, reattach_breakpoints)
17168 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
17169 (print_it_watchpoint): Use string_file.
17170 (save_breakpoints): Use stdio_file.
17171 * c-exp.y (oper): Use string_file.
17172 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
17173 tee_file.
17174 (pop_output_files): Use delete.
17175 (handle_redirections): Use stdio_file and tee_file.
17176 * cli/cli-setshow.c (do_show_command): Use string_file.
17177 * compile/compile-c-support.c (c_compute_program): Use
17178 string_file.
17179 * compile/compile-c-symbols.c (generate_vla_size): Take a
17180 'string_file &' instead of a 'ui_file *'.
17181 (generate_c_for_for_one_variable): Take a 'string_file &' instead
17182 of a 'ui_file *'. Use string_file.
17183 (generate_c_for_variable_locations): Take a 'string_file &'
17184 instead of a 'ui_file *'.
17185 * compile/compile-internal.h (generate_c_for_for_one_variable):
17186 Take a 'string_file &' instead of a 'ui_file *'.
17187 * compile/compile-loc2c.c (push, pushf, unary, binary)
17188 (print_label, pushf_register_address, pushf_register)
17189 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
17190 'ui_file *'. Adjust.
17191 * compile/compile.c (compile_to_object): Use string_file.
17192 * compile/compile.h (compile_dwarf_expr_to_c)
17193 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
17194 'ui_file *'.
17195 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
17196 (replace_typedefs_qualified_name): Use string_file and
17197 obstack_copy0.
17198 * disasm.c (gdb_pretty_print_insn): Use string_file.
17199 (gdb_disassembly): Adjust reference the null_stream global.
17200 (do_ui_file_delete): Delete.
17201 (gdb_insn_length): Use null_stream.
17202 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
17203 * dwarf2loc.c (dwarf2_compile_property_to_c)
17204 (locexpr_generate_c_location, loclist_generate_c_location): Take a
17205 'string_file &' instead of a 'ui_file *'.
17206 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
17207 * dwarf2read.c (do_ui_file_peek_last): Delete.
17208 (dwarf2_compute_name): Use string_file.
17209 * event-top.c (gdb_setup_readline): Use stdio_file.
17210 * gdbarch.sh (verify_gdbarch): Use string_file.
17211 * gdbtypes.c (safe_parse_type): Use null_stream.
17212 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
17213 string_file.
17214 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
17215 'string_file *' instead of a 'ui_file *'.
17216 (gdbscm_arch_disassemble): Use string_file.
17217 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
17218 * guile/scm-ports.c (class ioscm_file_port): Now a class that
17219 inherits from ui_file.
17220 (ioscm_file_port_delete, ioscm_file_port_rewind)
17221 (ioscm_file_port_put): Delete.
17222 (ioscm_file_port_write): Rename to ...
17223 (ioscm_file_port::write): ... this. Remove file_port_magic
17224 checks.
17225 (ioscm_file_port_new): Delete.
17226 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
17227 ui_file_up.
17228 * guile/scm-type.c (tyscm_type_name): Use string_file.
17229 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
17230 Use string_file.
17231 * infcmd.c (print_return_value_1): Use string_file.
17232 * infrun.c (print_target_wait_results): Use string_file.
17233 * language.c (add_language): Use string_file.
17234 * location.c (explicit_to_string_internal): Use string_file.
17235 * main.c (captured_main_1): Use null_file.
17236 * maint.c (maintenance_print_architecture): Use stdio_file.
17237 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
17238 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
17239 event_channel>: Change type to mi_console_file pointer.
17240 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
17241 (mi_console_file_delete): Delete.
17242 (struct mi_console_file): Delete.
17243 (mi_console_file_magic): Delete.
17244 (mi_console_file_new): Delete.
17245 (mi_console_file::mi_console_file): New.
17246 (mi_console_file_delete): Delete.
17247 (mi_console_file_fputs): Delete.
17248 (mi_console_file::write): New.
17249 (mi_console_raw_packet): Delete.
17250 (mi_console_file::flush): New.
17251 (mi_console_file_flush): Delete.
17252 (mi_console_set_raw): Rename to ...
17253 (mi_console_file::set_raw): ... this.
17254 * mi/mi-console.h (class mi_console_file): New class.
17255 (mi_console_file_new, mi_console_set_raw): Delete.
17256 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
17257 (mi_set_logging): Use delete and tee_file. Adjust.
17258 * mi/mi-main.c (output_register): Use string_file.
17259 (mi_cmd_data_evaluate_expression): Use string_file.
17260 (mi_cmd_data_read_memory): Use string_file.
17261 (mi_cmd_execute, print_variable_or_computed): Use string_file.
17262 * mi/mi-out.c (mi_ui_out::main_stream): New.
17263 (mi_ui_out::rewind): Use main_stream and
17264 string_file.
17265 (mi_ui_out::put): Use main_stream and string_file.
17266 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17267 Allocate a 'string_file' instead.
17268 (mi_out_new): Don't allocate a mem_fileopen stream here.
17269 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
17270 (mi_ui_out::main_stream): Declare method.
17271 * printcmd.c (eval_command): Use string_file.
17272 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
17273 * python/py-arch.c (archpy_disassemble): Use string_file.
17274 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
17275 * python/py-frame.c (frapy_str): Use string_file.
17276 * python/py-framefilter.c (py_print_type, py_print_single_arg):
17277 Use string_file.
17278 * python/py-type.c (typy_str): Use string_file.
17279 * python/py-unwind.c (unwind_infopy_str): Use string_file.
17280 * python/py-value.c (valpy_str): Use string_file.
17281 * record-btrace.c (btrace_insn_history): Use string_file.
17282 * regcache.c (regcache_print): Use stdio_file.
17283 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
17284 * remote.c (escape_buffer): Use string_file.
17285 * rust-lang.c (rust_get_disr_info): Use string_file.
17286 * serial.c (serial_open_ops_1): Use stdio_file.
17287 (do_serial_close): Use delete.
17288 * stack.c (print_frame_arg): Use string_file.
17289 (print_frame_args): Remove local mem_fileopen stream, not used.
17290 (print_frame): Use string_file.
17291 * symmisc.c (maintenance_print_symbols): Use stdio_file.
17292 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
17293 Take a 'string_file *' instead of a 'ui_file *'.
17294 * top.c (new_ui): Use stdio_file and stderr_file.
17295 (free_ui): Use delete.
17296 (execute_command_to_string): Use string_file.
17297 (quit_confirm): Use string_file.
17298 * tracepoint.c (collection_list::append_exp): Use string_file.
17299 * tui/tui-disasm.c (tui_disassemble): Use string_file.
17300 * tui/tui-file.c: Don't include "ui-file.h".
17301 (enum streamtype, struct tui_stream): Delete.
17302 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
17303 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
17304 (tui_file::tui_file): New method.
17305 (tui_file_fputs): Delete.
17306 (tui_file_get_strbuf): Delete.
17307 (tui_file::puts): New method.
17308 (tui_file_adjust_strbuf): Delete.
17309 (tui_file_flush): Delete.
17310 (tui_file::flush): New method.
17311 * tui/tui-file.h: Tweak intro comment.
17312 Include ui-file.h.
17313 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
17314 (tui_file_adjust_strbuf): Delete declarations.
17315 (class tui_file): New class.
17316 * tui/tui-io.c (tui_initialize_io): Use tui_file.
17317 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
17318 (tui_register_format): Use string_stream.
17319 * tui/tui-stack.c (tui_make_status_line): Use string_file.
17320 (tui_get_function_from_frame): Use string_file.
17321 * typeprint.c (type_to_string): Use string_file.
17322 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
17323 (null_stream): New global.
17324 (ui_file_delete): Delete.
17325 (ui_file::ui_file): New.
17326 (null_file_isatty): Delete.
17327 (ui_file::~ui_file): New.
17328 (null_file_rewind): Delete.
17329 (ui_file::printf): New.
17330 (null_file_put): Delete.
17331 (null_file_flush): Delete.
17332 (ui_file::putstr): New.
17333 (null_file_write): Delete.
17334 (ui_file::putstrn): New.
17335 (null_file_read): Delete.
17336 (ui_file::putc): New.
17337 (null_file_fputs): Delete.
17338 (null_file_write_async_safe): Delete.
17339 (ui_file::vprintf): New.
17340 (null_file_delete): Delete.
17341 (null_file::write): New.
17342 (null_file_fseek): Delete.
17343 (null_file::puts): New.
17344 (ui_file_data): Delete.
17345 (null_file::write_async_safe): New.
17346 (gdb_flush, ui_file_isatty): Adjust.
17347 (ui_file_put, ui_file_rewind): Delete.
17348 (ui_file_write): Adjust.
17349 (ui_file_write_for_put): Delete.
17350 (ui_file_write_async_safe, ui_file_read): Adjust.
17351 (ui_file_fseek): Delete.
17352 (fputs_unfiltered): Adjust.
17353 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
17354 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
17355 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
17356 (set_ui_file_data): Delete.
17357 (string_file::~string_file, string_file::write)
17358 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
17359 (do_ui_file_as_string, ui_file_as_string): Delete.
17360 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
17361 (struct mem_file): Delete.
17362 (mem_file_new): Delete.
17363 (stdio_file::stdio_file): New.
17364 (mem_file_delete): Delete.
17365 (stdio_file::stdio_file): New.
17366 (mem_fileopen): Delete.
17367 (stdio_file::~stdio_file): New.
17368 (mem_file_rewind): Delete.
17369 (stdio_file::set_stream): New.
17370 (mem_file_put): Delete.
17371 (stdio_file::open): New.
17372 (mem_file_write): Delete.
17373 (stdio_file_magic, struct stdio_file): Delete.
17374 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
17375 (stdio_file::flush): New.
17376 (stdio_file_read): Rename to ...
17377 (stdio_file::read): ... this. Adjust.
17378 (stdio_file_write): Rename to ...
17379 (stdio_file::write): ... this. Adjust.
17380 (stdio_file_write_async_safe): Rename to ...
17381 (stdio_file::write_async_safe) ... this. Adjust.
17382 (stdio_file_fputs): Rename to ...
17383 (stdio_file::puts) ... this. Adjust.
17384 (stdio_file_isatty): Delete.
17385 (stdio_file_fseek): Delete.
17386 (stdio_file::isatty): New.
17387 (stderr_file_write): Rename to ...
17388 (stderr_file::write) ... this. Adjust.
17389 (stderr_file_fputs): Rename to ...
17390 (stderr_file::puts) ... this. Adjust.
17391 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
17392 (stderr_file::stderr_file): New.
17393 (tee_file_magic): Delete.
17394 (struct tee_file): Delete.
17395 (tee_file::tee_file): New.
17396 (tee_file_new): Delete.
17397 (tee_file::~tee_file): New.
17398 (tee_file_delete): Delete.
17399 (tee_file_flush): Rename to ...
17400 (tee_file::flush): ... this. Adjust.
17401 (tee_file_write): Rename to ...
17402 (tee_file::write): ... this. Adjust.
17403 (tee_file::write_async_safe): New.
17404 (tee_file_fputs): Rename to ...
17405 (tee_file::puts): ... this. Adjust.
17406 (tee_file_isatty): Rename to ...
17407 (tee_file::isatty): ... this. Adjust.
17408 * ui-file.h (struct obstack, struct ui_file): Don't
17409 forward-declare.
17410 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
17411 (ui_file_write_ftype)
17412 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
17413 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
17414 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
17415 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
17416 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
17417 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
17418 (set_ui_file_fseek): Delete.
17419 (ui_file_data, ui_file_delete, ui_file_rewind)
17420 (struct ui_file): New.
17421 (ui_file_up): New.
17422 (class null_file): New.
17423 (null_stream): Declare.
17424 (ui_file_write_for_put, ui_file_put): Delete.
17425 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
17426 Delete.
17427 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
17428 (gdb_fopen, tee_file_new): Delete.
17429 (struct string_file): New.
17430 (struct stdio_file): New.
17431 (stdio_file_up): New.
17432 (struct stderr_file): New.
17433 (class tee_file): New.
17434 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
17435 of a 'ui_file *'. Adjust.
17436 * ui-out.h (class ui_out) <field_stream>: Likewise.
17437 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
17438 (null_stream): Delete.
17439 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
17440 Adjust.
17441 * utils.h (struct ui_file): Delete forward declaration..
17442 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
17443 (error_stream): Take a 'string_file &' instead of a
17444 'ui_file *'.
17445 * varobj.c (varobj_value_get_print_value): Use string_file.
17446 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
17447 * gdbarch.c: Regenerate.
17448
187808b0
PA
174492017-02-02 Pedro Alves <palves@redhat.com>
17450
17451 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
17452 (gdb_pretty_print_insn): ... this. Now a free function. Add back
17453 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
17454 Adjust to call gdb_print_insn instead of
17455 gdb_disassembler::print_insn.
17456 (dump_insns, do_mixed_source_and_assembly_deprecated)
17457 (do_mixed_source_and_assembly, do_assembly_only): Add back a
17458 'gdbarch' parameter. Remove gdb_disassembler parameter.
17459 (gdb_disassembly): Don't allocate a gdb_disassembler here.
17460 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
17461 declaration.
17462 (gdb_pretty_print_insn): Re-add declaration.
17463 * record-btrace.c (btrace_insn_history): Don't allocate a
17464 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
17465
7a8eb317
SM
174662017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
17467
17468 * disasm.h (gdb_disassembly): Remove file_string parameter.
17469 * disasm.c (gdb_disassembly): Likewise.
17470 * cli/cli-cmds.c (print_disassembly): Adapt.
17471 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
17472 * stack.c (do_gdb_disassembly): Likewise.
17473
7346ef59
AA
174742017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
17475
17476 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
17477 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
17478 targets. And if the implicit value is longer than needed, extract
17479 the first bytes instead of the "least significant" ones.
17480
cd4007e4
MM
174812017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17482
17483 * btrace.c (btrace_enable): Do not call btrace_add_pc for
17484 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
17485 (btrace_fetch): Assert can_access_registers_ptid.
17486 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
17487 validate_registers_access.
17488
cf77c34e
MM
174892017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17490
17491 * gdbthread.h (can_access_registers_ptid): New.
17492 * thread.c (can_access_registers_ptid): New.
17493
be85ce7d
PA
174942017-02-01 Pedro Alves <palves@redhat.com>
17495
17496 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
17497
29b0b251
PA
174982017-01-31 Pedro Alves <palves@redhat.com>
17499
17500 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
17501 Fix typos.
17502
289b5b24
PA
175032017-01-31 Pedro Alves <palves@redhat.com>
17504
17505 * stack.c (print_frame_args): Remove local mem_fileopen stream,
17506 not used.
17507
b47413b4
PA
175082017-01-31 Pedro Alves <palves@redhat.com>
17509
17510 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
17511
60adb36c
PA
175122017-01-31 Pedro Alves <palves@redhat.com>
17513
17514 * common/scoped_restore.h
17515 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
17516 change the value's parameter type to T2.
17517 (make_scoped_restore): Likewise.
17518
2735833d
WT
175192017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17520 Richard Henderson <rth@redhat.com>
17521
17522 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
17523 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
17524 GS_BASE for older kernels.
17525 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
17526 GS_BASE for older kernels.
17527 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
17528 and GS_BASE to the offset table.
17529 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
17530 system register group.
17531 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
17532 for older kernels.
17533 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
17534 amd64 ABI.
17535 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
17536 AMD64_GSBASE_REGNUM.
17537 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
17538 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
17539 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
17540 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
17541 i386/64bit-segments.xml in those rules.
17542 * features/i386/64bit-segments.xml: New file.
17543 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
17544 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
17545 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
17546 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
17547 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
17548 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
17549 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
17550 * features/i386/amd64-avx-linux.c: Regenerated.
17551 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
17552 * features/i386/amd64-avx-mpx.c: Regenerated.
17553 * features/i386/amd64-avx512-linux.c: Regenerated.
17554 * features/i386/amd64-linux.c: Regenerated.
17555 * features/i386/amd64-mpx-linux.c: Regenerated.
17556 * features/i386/i386-avx-mpx-linux.c: Regenerated.
17557 * features/i386/i386-avx-mpx.c: Regenerated.
17558 * features/i386/x32-avx-linux.c: Regenerated.
17559 * features/i386/x32-avx512-linux.c: Regenerated.
17560 * regformats/i386/amd64-avx-linux.dat: Regenerated.
17561 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
17562 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
17563 * regformats/i386/amd64-linux.dat: Regenerated.
17564 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
17565 * regformats/i386/x32-avx-linux.dat: Regenerated.
17566 * regformats/i386/x32-avx512-linux.dat: Regenerated.
17567 * regformats/i386/x32-linux.dat: Regenerated.
17568
8884e97e
WT
175692017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17570
17571 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
17572 Set to AMD64_NUM_REGS.
17573
7005d26a
WT
175742017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17575
17576 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
17577 that checks validity of a register number.
17578
4bd2e1b2
KC
175792017-01-27 Kees Cook <keescook@google.com>
17580
17581 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
17582 fetch_fpregs if target has fpa registers.
17583 (arm_linux_store_inferior_registers): Call store_fpregs if target
17584 has fpa registers.
17585
7cf1de6c
AA
175862017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
17587
17588 * cris-tdep.c (cris_gdbarch_init): Remove check for
17589 info.byte_order and force it to BFD_ENDIAN_LITTLE.
17590
874a1c8c
AT
175912017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
17592
17593 * corelow.c (get_core_register_section): Check for regset
17594 existence before checking for REGSET_VARIABLE_SIZE.
17595
d8b49cf0
YQ
175962017-01-26 Yao Qi <yao.qi@linaro.org>
17597 Pedro Alves <palves@redhat.com>
17598
17599 PR gdb/20939
17600 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
17601 call memory_error, save memaddr instead.
17602 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
17603 negative, cal memory_error.
17604 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
17605
658ca58c
YQ
176062017-01-26 Yao Qi <yao.qi@linaro.org>
17607
17608 * disasm-selftests.c (memory_error_test): New function.
17609 (_initialize_disasm_selftests): Register memory_error_test.
17610
79843d45
YQ
176112017-01-26 Yao Qi <yao.qi@linaro.org>
17612
17613 * Makefile.in (SFILES): Add disasm-selftests.c and
17614 selftest-arch.c.
17615 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
17616 * disasm-selftests.c: New file.
17617 * selftest-arch.c: New file.
17618 * selftest-arch.h: New file.
17619
8cafda32
YQ
176202017-01-26 Yao Qi <yao.qi@linaro.org>
17621
17622 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
17623 to bfd_arch_mep. Don't return 0 if section is not
17624 found. Call print_insn_mep.
17625
e47ad6c0
YQ
176262017-01-26 Pedro Alves <palves@redhat.com>
17627 Yao Qi <yao.qi@linaro.org>
17628
17629 * arm-tdep.c: Include "disasm.h".
17630 (gdb_print_insn_arm): Update code to get gdbarch.
17631 * disasm.c (dis_asm_read_memory): Change it to
17632 gdb_disassembler::dis_asm_read_memory.
17633 (dis_asm_memory_error): Likewise.
17634 (dis_asm_print_address): Likewise.
17635 (gdb_pretty_print_insn): Change it to
17636 gdb_disassembler::pretty_print_insn.
17637 (dump_insns): Add one argument gdb_disassemlber. All
17638 callers updated.
17639 (do_mixed_source_and_assembly_deprecated): Likewise.
17640 (do_mixed_source_and_assembly): Likewise.
17641 (do_assembly_only): Likewise.
17642 (gdb_disassembler::gdb_disassembler): New.
17643 (gdb_disassembler::print_insn): New.
17644 * disasm.h (class gdb_disassembler): New.
17645 (gdb_pretty_print_insn): Remove declaration.
17646 (gdb_disassemble_info): Likewise.
17647 * guile/scm-disasm.c (class gdbscm_disassembler): New.
17648 (gdbscm_disasm_read_memory_worker): Update.
17649 (gdbscm_disasm_read_memory): Update.
17650 (gdbscm_disasm_memory_error): Remove.
17651 (gdbscm_disasm_print_address): Remove.
17652 (gdbscm_disassembler::gdbscm_disassembler): New.
17653 (gdbscm_print_insn_from_port): Update.
17654 * mips-tdep.c: Include disasm.h.
17655 (gdb_print_insn_mips): Update code to get gdbarch.
17656 * record-btrace.c (btrace_insn_history): Update.
17657 * spu-tdep.c: Include disasm.h.
17658 (struct spu_dis_asm_data): Remove.
17659 (struct spu_dis_asm_info): New.
17660 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17661 SPU id.
17662 (gdb_print_insn_spu): Cast disassemble_info to
17663 spu_dis_asm_info.
17664
80d75874
YQ
176652017-01-26 Yao Qi <yao.qi@linaro.org>
17666
17667 * disasm.c (do_ui_file_delete): Delete.
17668 (gdb_insn_length): Move code creating stream to ...
17669 * utils.c (null_stream): ... here. New function.
17670 * utils.h (null_stream): Declare.
17671
60685cd0
SM
176722017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17673
17674 * python/py-inferior.c (find_thread_object): Return directly
17675 from the loop. Remove "found" variable.
17676
eb1cdb62
JB
176772017-01-21 Joel Brobecker <brobecker@adacore.com>
17678
17679 GDB 7.12.1 released.
17680
b1ce6568
SM
176812017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17682
17683 * python/py-function.c (fnpy_call): Reorder declarations to have
17684 the gdbpy_enter object declared first.
17685 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17686
6f8b0407
SM
176872017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17688
fec93fb1 17689 PR python/21068
6f8b0407
SM
17690 * python/python-internal.h (PyMem_RawMalloc): Define for
17691 Python < 3.4.
17692 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17693 PyMem_RawMalloc instead of PyMem_Malloc.
17694
78cbbba8
LM
176952017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17696 Luis Machado <lgustavo@codesourcery.com>
17697
17698 * NEWS (New commands): Mention flash-erase.
17699 (New MI commands): Mention target-flash-erase.
17700 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17701 command.
17702 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17703 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17704 * target.c (flash_erase_command): New function.
17705 (initialize_targets): Add new flash-erase command.
17706 * target.h (flash_erase_command): New declaration.
17707
2132fe85
JB
177082017-01-20 Joel Brobecker <brobecker@adacore.com>
17709
17710 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17711 HAVE_SYS_PROCFS_H is defined.
17712
d1dff226
AH
177132017-01-18 Alan Hayward <alan.hayward@arm.com>
17714
17715 * remote.c (struct cached_reg): Change data into a pointer.
17716 * (stop_reply_dtr): Free data pointers before deleting vector.
17717 (process_stop_reply): Likewise.
17718 (remote_parse_stop_reply): Allocate space for data
17719
9890e433
AH
177202017-01-18 Alan Hayward <alan.hayward@arm.com>
17721
17722 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17723 MAX_REGISTER_SIZE.
17724 (amd64_pseudo_register_read_value): Likewise.
17725 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17726 (store_register_using_P): Likewise.
17727 * regcache.c (regcache_xfer_part): Likewise.
17728
7a36499a
IR
177292017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17730
17731 Split real and pseudo registers.
17732 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17733 (sparc32_pseudo_regnum): New enum.
17734 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17735 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17736 (SPARC32_CP0_REGISTERS): New macro.
17737 (sparc32_pseudo_register_name): New function.
17738 (sparc32_register_name): Use sparc32_pseudo_register_name.
17739 (sparc32_pseudo_register_type): New function.
17740 (sparc32_register_type): Use sparc32_pseudo_register_type.
17741 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17742 pseudo register numbers.
17743 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17744 (SPARC64_CP0_REGISTERS): New macro.
17745 (sparc64_pseudo_register_name): New function.
17746 (sparc64_register_name): Use sparc64_pseudo_register_name.
17747 (sparc64_pseudo_register_type): New function.
17748 (sparc64_register_type): Use sparc64_pseudo_register_type.
17749 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17750 pseudo register numbers.
17751 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17752 sparc64_store_arguments): Handle pseudo register numbers.
17753
6f8976bf
YQ
177542017-01-13 Yao Qi <yao.qi@linaro.org>
17755
17756 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17757 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17758 output.
17759 (getpkt_or_notif_sane_1): Likewise.
17760
e4241ace
YQ
177612017-01-13 Yao Qi <yao.qi@linaro.org>
17762
17763 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17764 of CC. Pass "-x c++-header" instead of "-x c".
17765
3015c064
SM
177662017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17767
17768 * remote.c (remote_can_async_p): Update comment.
17769
fde1b17d
SM
177702017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17771
17772 * linux-nat.c (linux_nat_can_async_p): Update comment.
17773
ca1ca08b
SM
177742017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17775
17776 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17777
4ad2da73
SM
177782017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17779
17780 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17781
c8b23b3f
TT
177822017-01-10 Tom Tromey <tom@tromey.com>
17783
17784 * python/py-type.c (typy_legacy_template_argument): Update.
17785 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17786 ~demangle_parse_info): Declare new members.
17787 (cp_demangled_name_to_comp): Return unique_ptr.
17788 (cp_demangled_name_parse_free)
17789 (make_cleanup_cp_demangled_name_parse_free)
17790 (cp_new_demangle_parse_info): Remove.
17791 * cp-support.c (do_demangled_name_parse_free_cleanup)
17792 (make_cleanup_cp_demangled_name_parse_free): Remove.
17793 (inspect_type, cp_canonicalize_string_full)
17794 (cp_canonicalize_string): Update.
17795 (mangled_name_to_comp): Change return type.
17796 (cp_class_name_from_physname, method_name_from_physname)
17797 (cp_func_name, cp_remove_params): Update.
17798 * cp-name-parser.y (demangle_parse_info): New constructor, from
17799 cp_new_demangle_parse_info.
17800 (~demangle_parse_info): New destructor, from
17801 cp_demangled_name_parse_free.
17802 (cp_merge_demangle_parse_infos): Update.
17803 (cp_demangled_name_to_comp): Change return type.
17804
1ac32117
TT
178052017-01-10 Tom Tromey <tom@tromey.com>
17806
17807 * top.c (prevent_dont_repeat): Change return type.
17808 * python/python.c (execute_gdb_command): Use std::string.
17809 Update.
17810 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17811 * command.h (prevent_dont_repeat): Change return type.
17812 * breakpoint.c (bpstat_do_actions_1): Update.
17813
0cf08227
TT
178142017-01-10 Tom Tromey <tom@tromey.com>
17815
17816 * value.h (scoped_value_mark::~scoped_value_mark): Call
17817 free_to_mark.
17818 (scoped_value_mark::free_to_mark): New method.
17819 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17820 scoped_value_mark.
17821
eb115069
TT
178222017-01-10 Tom Tromey <tom@tromey.com>
17823
17824 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17825 (valpy_reference_value, valpy_const_value, valpy_get_address)
17826 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17827 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17828 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17829 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17830 scoped_value_mark.
17831 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17832 * value.h (scoped_value_mark): New class.
17833
906768f9
TT
178342017-01-10 Tom Tromey <tom@tromey.com>
17835
17836 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17837 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17838 * psymtab.c (discard_psymtabs_upto): Remove.
17839 (make_cleanup_discard_psymtabs): Remove.
17840 (struct psymtab_state): Remove.
17841
bef155c3
TT
178422017-01-10 Tom Tromey <tom@tromey.com>
17843
17844 * record-full.c (record_full_save_cleanups): Remove.
17845 (record_full_save): Use gdb::unlinker.
17846 * gcore.c (do_bfd_delete_cleanup): Remove.
17847 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17848 cleanups.
17849 * dwarf2read.c (unlink_if_set): Remove.
17850 (write_psymtabs_to_index): Use gdb::unlinker.
17851 * common/gdb_unlinker.h: New file.
17852
192b62ce
TT
178532017-01-10 Tom Tromey <tom@tromey.com>
17854
17855 * windows-tdep.c (windows_xfer_shared_library): Update.
17856 * windows-nat.c (windows_make_so): Update.
17857 * utils.h (make_cleanup_bfd_unref): Remove.
17858 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17859 * symfile.h (symfile_bfd_open)
17860 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17861 * symfile.c (read_symbols, symbol_file_add)
17862 (separate_debug_file_exists): Update.
17863 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17864 (generic_load, reread_symbols): Update.
17865 * symfile-mem.c (symbol_file_add_from_memory): Update.
17866 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17867 (spu_symbol_file_add_from_memory): Update.
17868 * solist.h (struct target_so_ops) <bfd_open>: Return
17869 gdb_bfd_ref_ptr.
17870 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17871 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17872 gdb_bfd_ref_ptr.
17873 (solib_map_sections, reload_shared_libraries_1): Update.
17874 * solib-svr4.c (enable_break): Update.
17875 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17876 * solib-frv.c (enable_break2): Update.
17877 * solib-dsbt.c (enable_break): Update.
17878 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17879 gdb_bfd_ref_ptr.
17880 (darwin_solib_get_all_image_info_addr_at_init): Update.
17881 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17882 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17883 * record-full.c (record_full_save): Update.
17884 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17885 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17886 * minidebug.c (find_separate_debug_file_in_section): Return
17887 gdb_bfd_ref_ptr.
17888 * machoread.c (macho_add_oso_symfile): Change abfd to
17889 gdb_bfd_ref_ptr.
17890 (macho_symfile_read_all_oso): Update.
17891 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17892 (macho_symfile_read): Update.
17893 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17894 (jit_bfd_try_read_symtab): Update.
17895 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17896 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17897 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17898 gdb_bfd_ref_ptr.
17899 (gdb_bfd_ref_policy): New struct.
17900 (gdb_bfd_ref_ptr): New typedef.
17901 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17902 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17903 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17904 gdb_bfd_ref_ptr.
17905 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17906 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17907 (gcore_command): Update.
17908 * exec.c (exec_file_attach): Update.
17909 * elfread.c (elf_symfile_read): Update.
17910 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17911 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17912 (open_and_init_dwo_file): Update.
17913 (open_dwp_file): Return gdb_bfd_ref_ptr.
17914 (open_and_init_dwp_file): Update.
17915 * corelow.c (core_open): Update.
17916 * compile/compile-object-load.c (compile_object_load): Update.
17917 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17918 * coffread.c (coff_symfile_read): Update.
17919 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17920 gdb_bfd_ref_ptr. Rename.
17921 (dump_bfd_file, restore_command): Update.
17922 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17923 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17924 (find_separate_debug_file_by_buildid): Update.
17925
50315b21
TT
179262017-01-10 Tom Tromey <tom@tromey.com>
17927
17928 * common/gdb_ref_ptr.h: New file.
17929 * python/py-ref.h (struct gdbpy_ref_policy): New.
17930 (gdbpy_ref): Now a typedef.
17931
fc4007c9
TT
179322017-01-10 Tom Tromey <tom@tromey.com>
17933
17934 * utils.h (make_cleanup_htab_delete): Don't declare.
17935 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17936 Remove.
17937 * linespec.c (decode_compound_collector): Add constructor,
17938 destructor.
17939 (lookup_prefix_sym): Remove cleanup.
17940 (symtab_collector): Add constructor, destructor.
17941 (collect_symtabs_from_filename): Remove cleanup.
17942 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17943 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17944 Use htab_up.
17945 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17946 * dwarf2read.c (dw2_expand_symtabs_matching)
17947 (dw2_map_symbol_filenames, dwarf_decode_macros)
17948 (write_psymtabs_to_index): Use htab_up.
17949 * dwarf2loc.c (func_verify_no_selftailcall)
17950 (call_site_find_chain_1, func_verify_no_selftailcall)
17951 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17952 std::vector, gdb::unique_xmalloc_ptr.
17953 (call_sitep): Remove typedef.
17954 (dwarf2_locexpr_baton_eval): Remove unused variable.
17955
8dbcee67
TT
179562017-01-10 Tom Tromey <tom@tromey.com>
17957
17958 * python/python-internal.h (make_cleanup_py_decref)
17959 (make_cleanup_py_xdecref): Don't declare.
17960 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17961 (py_xdecref, make_cleanup_py_xdecref): Remove.
17962
13df46cc
TT
179632017-01-10 Tom Tromey <tom@tromey.com>
17964
17965 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17966 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17967
06fc9bf7
TT
179682017-01-10 Tom Tromey <tom@tromey.com>
17969
17970 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17971
830a4934
TT
179722017-01-10 Tom Tromey <tom@tromey.com>
17973
17974 * python/py-utils.c (unicode_to_encoded_string)
17975 (python_string_to_target_string)
17976 (python_string_to_target_python_string)
17977 (python_string_to_host_string, gdbpy_obj_to_string)
17978 (get_addr_from_python): Use gdbpy_ref.
17979
4586d543
TT
179802017-01-10 Tom Tromey <tom@tromey.com>
17981
17982 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17983 gdbpy_ref.
17984
59876f8f
TT
179852017-01-10 Tom Tromey <tom@tromey.com>
17986
17987 * python/python.c (eval_python_command, gdbpy_decode_line)
17988 (gdbpy_run_events, gdbpy_start_type_printers)
17989 (gdbpy_apply_type_printers): Use gdbpy_ref.
17990
97d83487
TT
179912017-01-10 Tom Tromey <tom@tromey.com>
17992
17993 * python/py-param.c (get_doc_string, compute_enum_values): Use
17994 gdbpy_ref.
17995
9205649a
TT
179962017-01-10 Tom Tromey <tom@tromey.com>
17997
17998 * python/py-inferior.c (find_thread_object, build_inferior_list):
17999 Use gdbpy_ref.
18000
74c49d45
TT
180012017-01-10 Tom Tromey <tom@tromey.com>
18002
18003 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
18004
16361ffb
TT
180052017-01-10 Tom Tromey <tom@tromey.com>
18006
18007 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
18008 gdbpy_ref.
18009
905f2cca
TT
180102017-01-10 Tom Tromey <tom@tromey.com>
18011
18012 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
18013 extra incref.
18014 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
18015 Use gdbpy_ref.
18016
64081434
TT
180172017-01-10 Tom Tromey <tom@tromey.com>
18018
18019 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
18020 gdbpy_ref.
18021
59e9e831
TT
180222017-01-10 Tom Tromey <tom@tromey.com>
18023
18024 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
18025 decref results of PyArg_ParseTupleAndKeywords.
18026
9de10f6d
TT
180272017-01-10 Tom Tromey <tom@tromey.com>
18028
18029 * python/python.c (python_run_simple_file): Use
18030 unique_xmalloc_ptr, gdbpy_ref.
18031
2bd5759d
TT
180322017-01-10 Tom Tromey <tom@tromey.com>
18033
18034 * python/py-prettyprint.c (print_stack_unless_memory_error)
18035 (print_string_repr, print_children): Use gdbpy_ref.
18036 (dummy_python_frame): New class.
18037 (dummy_python_frame::dummy_python_frame): Rename from
18038 push_dummy_python_frame.
18039 (py_restore_tstate): Remove.
18040
3b4e0e01
TT
180412017-01-10 Tom Tromey <tom@tromey.com>
18042
18043 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
18044
17a22718
TT
180452017-01-10 Tom Tromey <tom@tromey.com>
18046
18047 * python/python.c (ensure_python_env, restore_python_env):
18048 Remove.
18049 * python/python-internal.h (ensure_python_env): Don't declare.
18050 * varobj.h (varobj_ensure_python_env): Don't declare.
18051 * varobj.c (varobj_ensure_python_env): Remove.
18052
68cdc557
TT
180532017-01-10 Tom Tromey <tom@tromey.com>
18054
18055 * varobj.c (varobj_value_get_print_value): Use
18056 gdbpy_enter_varobj.
18057
1eba6383
TT
180582017-01-10 Tom Tromey <tom@tromey.com>
18059
18060 * python/py-prettyprint.c (print_string_repr, print_children):
18061 Update.
18062 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
18063 of "encoding".
18064 * varobj.c (varobj_value_get_print_value): Update.
18065 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
18066
bde7b3e3
TT
180672017-01-10 Tom Tromey <tom@tromey.com>
18068
18069 * varobj.c (varobj_get_display_hint)
18070 (dynamic_varobj_has_child_method, install_new_value_visualizer)
18071 (varobj_set_visualizer, free_variable): Use
18072 gdbpy_enter_varobj.
18073
a7785f8c
TT
180742017-01-10 Tom Tromey <tom@tromey.com>
18075
18076 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
18077 (do_finish_initialization): New function. Use gdbpy_ref.
18078 (gdbpy_finish_initialization): Use gdbpy_enter. Call
18079 do_finish_initialization.
18080
2865bfce
TT
180812017-01-10 Tom Tromey <tom@tromey.com>
18082
18083 * python/py-param.c (get_set_value, get_show_value): Use
18084 gdbpy_enter, gdbpy_ref.
18085
0e9dcc75
TT
180862017-01-10 Tom Tromey <tom@tromey.com>
18087
18088 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
18089
12a5cedd
TT
180902017-01-10 Tom Tromey <tom@tromey.com>
18091
18092 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
18093
788f2586
TT
180942017-01-10 Tom Tromey <tom@tromey.com>
18095
18096 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
18097 Use gdbpy_enter_varobj.
18098
6cd67bea
TT
180992017-01-10 Tom Tromey <tom@tromey.com>
18100
18101 * varobj.c (gdbpy_enter_varobj): New constructor.
18102 * python/python-internal.h (gdbpy_enter_varobj): New class.
18103 * python/py-varobj.c (py_varobj_get_iterator): Use
18104 gdbpy_enter_varobj.
18105
14b122bf
TT
181062017-01-10 Tom Tromey <tom@tromey.com>
18107
18108 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
18109 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
18110 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
18111 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
18112 unique_xmalloc_ptr.
18113 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
18114
bf1ca3b9
TT
181152017-01-10 Tom Tromey <tom@tromey.com>
18116
18117 * python/py-xmethods.c (invoke_match_method): Use
18118 gdbpy_ref.
18119
572a5524
TT
181202017-01-10 Tom Tromey <tom@tromey.com>
18121
18122 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
18123 gdbpy_enter, gdbpy_ref.
18124
396a78b6
TT
181252017-01-10 Tom Tromey <tom@tromey.com>
18126
18127 * python/python.c (python_interactive_command): Use gdbpy_enter.
18128
a88b13c7
TT
181292017-01-10 Tom Tromey <tom@tromey.com>
18130
18131 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
18132 gdbpy_ref.
18133
e9f0c363
TT
181342017-01-10 Tom Tromey <tom@tromey.com>
18135
18136 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
18137 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
18138
6349f452
TT
181392017-01-10 Tom Tromey <tom@tromey.com>
18140
18141 * utils.h (htab_deleter): New struct.
18142 (htab_up): New typedef.
18143 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
18144 gdbpy_enter, gdbpy_ref, htab_up.
18145
c0171de6
TT
181462017-01-10 Tom Tromey <tom@tromey.com>
18147
18148 * python/py-unwind.c (pending_frame_invalidate): Remove.
18149 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
18150
f18e226f
TT
181512017-01-10 Tom Tromey <tom@tromey.com>
18152
18153 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
18154 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
18155
c57af3f1
TT
181562017-01-10 Tom Tromey <tom@tromey.com>
18157
18158 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
18159
60e600ec
TT
181602017-01-10 Tom Tromey <tom@tromey.com>
18161
18162 * python/python.c (gdbpy_eval_from_control_command)
18163 (gdbpy_source_script, gdbpy_run_events)
18164 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
18165 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
18166 gdbpy_enter.
18167
bf7da5b0
TT
181682017-01-10 Tom Tromey <tom@tromey.com>
18169
18170 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
18171
2d38bced
TT
181722017-01-10 Tom Tromey <tom@tromey.com>
18173
18174 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
18175
07bc7329
TT
181762017-01-10 Tom Tromey <tom@tromey.com>
18177
18178 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
18179 (python_on_inferior_call_pre, python_on_inferior_call_post)
18180 (python_on_memory_change, python_on_register_change)
18181 (python_inferior_exit, python_new_objfile, add_thread_object)
18182 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
18183
6e7c365e
TT
181842017-01-10 Tom Tromey <tom@tromey.com>
18185
18186 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
18187 (bpfinishpy_handle_exit): Use gdbpy_enter.
18188
6ba0cd40
TT
181892017-01-10 Tom Tromey <tom@tromey.com>
18190
18191 * python/py-cmd.c (cmdpy_destroyer)
18192 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
18193 gdbpy_enter.
18194
de2dc875
TT
181952017-01-10 Tom Tromey <tom@tromey.com>
18196
18197 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
18198 gdbpy_enter.
18199 (gdbpy_breakpoint_has_cond): Likewise.
18200
4ecee2c4
TT
182012017-01-10 Tom Tromey <tom@tromey.com>
18202
18203 * python/python.c (gdbpy_enter): New constructor.
18204 (~gdbpy_enter): New destructor.
18205 (restore_python_env, ensure_python_env): Rewrite.
18206 * python/python-internal.h (gdbpy_enter): New class.
18207
37fce74f
TT
182082017-01-10 Tom Tromey <tom@tromey.com>
18209
18210 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
18211
53a0cca3
TT
182122017-01-10 Tom Tromey <tom@tromey.com>
18213
18214 * python/py-value.c (value_has_field, get_field_flag)
18215 (get_field_type, valpy_getitem, convert_value_from_python): Use
18216 gdbpy_ref.
18217
ff3724f5
TT
182182017-01-10 Tom Tromey <tom@tromey.com>
18219
18220 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
18221 gdbpy_ref.
18222
0700aea5
TT
182232017-01-10 Tom Tromey <tom@tromey.com>
18224
18225 * python/py-prettyprint.c (search_pp_list)
18226 (find_pretty_printer_from_objfiles)
18227 (find_pretty_printer_from_progspace)
18228 (find_pretty_printer_from_gdb, find_pretty_printer)
18229 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
18230 gdbpy_ref.
18231
1bb44c9f
TT
182322017-01-10 Tom Tromey <tom@tromey.com>
18233
18234 * python/py-param.c (call_doc_function): Use gdbpy_ref.
18235
87ce03fd
TT
182362017-01-10 Tom Tromey <tom@tromey.com>
18237
18238 * python/py-linetable.c (build_line_table_tuple_from_pcs)
18239 (ltpy_get_all_source_lines): Use gdbpy_ref.
18240
ee0a3fb8
TT
182412017-01-10 Tom Tromey <tom@tromey.com>
18242
18243 * python/py-framefilter.c (extract_sym, extract_value)
18244 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
18245 gdbpy_ref.
18246
bf2a52fa
TT
182472017-01-10 Tom Tromey <tom@tromey.com>
18248
18249 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
18250
f59fe7f8
TT
182512017-01-10 Tom Tromey <tom@tromey.com>
18252
18253 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
18254
80bd970a
TT
182552017-01-10 Tom Tromey <tom@tromey.com>
18256
18257 * python/py-function.c (convert_values_to_python, fnpy_init): Use
18258 gdbpy_ref.
18259
d1b3de2e
TT
182602017-01-10 Tom Tromey <tom@tromey.com>
18261
18262 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
18263
3bb43384
TT
182642017-01-10 Tom Tromey <tom@tromey.com>
18265
18266 * python/py-type.c (convert_field, make_fielditem, typy_fields)
18267 (typy_range): Use gdbpy_ref.
18268
abf5651e
TT
182692017-01-10 Tom Tromey <tom@tromey.com>
18270
18271 * python/py-threadevent.c (create_thread_event_object): Use
18272 gdbpy_ref.
18273 * python/py-stopevent.c (create_stop_event_object): Simplify.
18274 (emit_stop_event): Use gdbpy_ref.
18275 * python/py-signalevent.c (create_signal_event_object): Use
18276 gdbpy_ref.
18277 * python/py-newobjfileevent.c (create_new_objfile_event_object)
18278 (emit_new_objfile_event, create_clear_objfiles_event_object)
18279 (emit_clear_objfiles_event): Use gdbpy_ref.
18280 * python/py-infevents.c (create_inferior_call_event_object)
18281 (create_register_changed_event_object)
18282 (create_memory_changed_event_object, emit_inferior_call_event)
18283 (emit_memory_changed_event, emit_register_changed_event): Use
18284 gdbpy_ref.
18285 * python/py-exitedevent.c (create_exited_event_object)
18286 (emit_exited_event): Use gdbpy_ref.
18287 * python/py-event.h (evpy_emit_event): Remove
18288 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
18289 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
18290 * python/py-continueevent.c (emit_continue_event): Use
18291 gdbpy_ref.
18292 * python/py-breakpoint.c (gdbpy_breakpoint_created)
18293 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
18294 gdbpy_ref.
18295 * python/py-bpevent.c (create_breakpoint_event_object): Use
18296 gdbpy_ref.
18297
a68ff33e
TT
182982017-01-10 Tom Tromey <tom@tromey.com>
18299
18300 * python/py-ref.h: New file.
18301
7becfd03
SM
183022017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18303
18304 * cli-out.c (cli_ui_out::do_redirect): Change return type to
18305 void.
18306 * cli-out.h (cli_ui_out::do_redirect): Likewise.
18307 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
18308 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
18309 * ui-out.c (ui_out::redirect): Likewise.
18310 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
18311 * cli/cli-logging.c (set_logging_redirect): Update call site of
18312 ui_out::redirect.
18313 (handle_redirections): Likewise.
18314 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
18315 * top.c (execute_command_to_string): Likewise.
18316 * utils.c (do_ui_out_redirect_pop): Likewise.
18317
df294654
SM
183182017-01-10 Simon Marchi <simon.marchi@ericsson.com>
18319
18320 * stack.c (_initialize_stack): Update "frame" command help message.
18321
f5e6296e
IB
183222017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
18323
18324 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
18325
0e2d6fa6
YQ
183262017-01-06 Yao Qi <yao.qi@linaro.org>
18327
18328 * x86-linux-nat.h: Include gdb_proc_service.h.
18329
44d6d3f9
YQ
183302017-01-06 Yao Qi <yao.qi@linaro.org>
18331
18332 * ser-base.h: Include serial.h.
18333
656731fe
YQ
183342017-01-06 Yao Qi <yao.qi@linaro.org>
18335
18336 * ppc-linux-tdep.h: Include ppc-tdep.h.
18337
1ca8f924
YQ
183382017-01-06 Yao Qi <yao.qi@linaro.org>
18339
18340 * nat/amd64-linux-siginfo.h: Include signal.h.
18341
bc3008c4
YQ
183422017-01-06 Yao Qi <yao.qi@linaro.org>
18343
18344 * nat/aarch64-linux-hw-point.h: Include break-common.h.
18345
66c80d03
YQ
183462017-01-06 Yao Qi <yao.qi@linaro.org>
18347
18348 * mi/mi-parse.h: Include mi-cmds.h.
18349
051d2dda
YQ
183502017-01-06 Yao Qi <yao.qi@linaro.org>
18351
18352 * inf-loop.c: Don't include "target.h".
18353 * inf-loop.h: Include it here.
18354
8018d34f
YQ
183552017-01-06 Yao Qi <yao.qi@linaro.org>
18356
18357 * dfp.h: Include "dboulest.h" and "expression.h".
18358
c0b8369c
YQ
183592017-01-06 Yao Qi <yao.qi@linaro.org>
18360
18361 * ax-gdb.h: Include "ax.h".
18362
ad5cba2a
YQ
183632017-01-06 Yao Qi <yao.qi@linaro.org>
18364
18365 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
18366 with nat/gdb_ptrace.h.
18367
1c33cd7f
YQ
183682017-01-05 Yao Qi <yao.qi@linaro.org>
18369
18370 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
18371 new line.
18372 (mips64_fbsd_sigframe_init): Likewise.
18373
c988ac1d
JB
183742017-01-04 John Baldwin <jhb@FreeBSD.org>
18375
18376 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
18377 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
18378
b268007c
JB
183792017-01-04 John Baldwin <jhb@FreeBSD.org>
18380
18381 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
18382 * NEWS: Mention new FreeBSD/mips native configuration.
18383 * config/mips/fbsd.mh: New file.
18384 * configure.host: Add mips*-*-freebsd*.
18385 * mips-fbsd-nat.c: New file.
18386
387360da
JB
183872017-01-04 John Baldwin <jhb@FreeBSD.org>
18388
18389 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
18390 (ALLDEPFILES): Add mips-fbsd-tdep.c.
18391 * NEWS: Mention new FreeBSD/mips target.
18392 * configure.tgt: Add mips*-*-freebsd*.
18393 * mips-fbsd-tdep.c: New file.
18394 * mips-fbsd-tdep.h: New file.
18395
2aaaf250
YQ
183962017-01-04 Yao Qi <yao.qi@linaro.org>
18397
18398 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
18399 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
18400
61baf725
JB
184012017-01-01 Joel Brobecker <brobecker@adacore.com>
18402
6dbb839a 18403 Update copyright year range in all GDB files.
61baf725 18404
c113e7ff 184052017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 18406
c113e7ff 18407 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 18408
c113e7ff 18409For older changes see ChangeLog-2016.
c906108c
SS
18410\f
18411Local Variables:
18412mode: change-log
18413left-margin: 8
18414fill-column: 74
18415version-control: never
57da7796 18416coding: utf-8
c906108c 18417End:
This page took 2.76542 seconds and 4 git commands to generate.